Skip to content

Persist explicit internal session provenance across saves and resume - #359

Draft
Brian Krabach (bkrabach) wants to merge 1 commit into
mainfrom
fix/internal-session-provenance
Draft

Brian Krabach (bkrabach) wants to merge 1 commit into
mainfrom
fix/internal-session-provenance

Conversation

@bkrabach

@bkrabach Brian Krabach (bkrabach) commented Sep 23, 2026 •

Copy link
Copy Markdown
Collaborator

Internal background jobs currently leave ordinary root CLI histories without a reliable producer declaration. Persist an explicit AMPLIFIER_SESSION_VISIBILITY=internal and bounded optional AMPLIFIER_SESSION_PURPOSE at creation, before execution, then retain it through incremental/final/error saves and resume. Ordinary JSON/agent-launched conversations stay chats; independent human forks explicitly remain chats. No title/prompt/TTY heuristic or legacy rewrite.

Validation: 134 targeted tests pass, covering actual native saves, initialization failure, failed execution, empty/legacy resume, all independent fork entrypoints, and shared ownership. An opt-in paired memory → actual CLI initializer/headless persistence → Unified discovery fixture passes with synthetic Core execution and zero model calls. Changed existing files add no Ruff findings relative to their baseline (87 existing findings); new provenance module/tests pass Ruff.

This is one part of a three-repository bridge: CLI persistence + Unified consumer support must be present for the memory producer label to prevent ordinary-list leakage. Production/example-session/browser acceptance was not performed; existing saved histories stay unchanged.

Paired Unified consumer: microsoft/amplifier-unified#187. Memory producer: microsoft/amplifier-bundle-memory#16. CLI producer: #359. This remains a reviewable three-part change; nothing has been merged or deployed by this task.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant