Add external agent memory migration (#33444)

## What changed

- Add a feature-gated `MEMORY` migration item to the app-server protocol and TUI.
- Discover project memory Markdown files, preserve their project scope, and copy selected projects into the Codex memory extension workspace.
- Detect changed, renamed, and removed source projects, report per-project import failures, and enqueue memory consolidation after workspace changes.

## Testing

- Cover memory discovery, selection, synchronization, scope validation, feature gating, protocol results, and TUI rendering.

GitOrigin-RevId: 9b17b2e9a639a064dba8aaffbec6345ae419018e
This commit is contained in:
charlesgong-openai authored and copyberry committed 2026-07-15 22:49:52 +00:00
1 parent 08924bca00
commit 7d1218a997
35 files changed
+1750 -23

No files matched your search

@@ -575,6 +575,9 @@ pub enum ExternalAgentConfigMigrationItemType {
#[serde(rename = "COMMANDS")]
#[ts(rename = "COMMANDS")]
Commands,
#[serde(rename = "MEMORY")]
#[ts(rename = "MEMORY")]
Memory,
#[serde(rename = "SESSIONS")]
#[ts(rename = "SESSIONS")]
Sessions,
@@ -654,6 +657,8 @@ pub struct MigrationDetails {
pub subagents: Vec<SubagentMigration>,
#[serde(default)]
pub commands: Vec<CommandMigration>,
#[serde(default, skip_serializing_if = "Vec::is_empty")]
pub memory: Vec<String>,
}
#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, Eq, JsonSchema, TS)]