Skip to content

Run portable memory inference in private Core sessions - #17

Merged
Brian Krabach (bkrabach) merged 3 commits into
mainfrom
fix/sessionless-memory-inference
Sep 23, 2026
Merged

Brian Krabach (bkrabach) merged 3 commits into
mainfrom
fix/sessionless-memory-inference

Conversation

@bkrabach

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

Copy link
Copy Markdown
Collaborator

Portable memory suggestions currently launch amplifier run, creating an ordinary conversation for a single inference. This change uses public Foundation/Core APIs to run the inference in an internal, tool-free AmplifierSession, with generated sessions, transcripts, usage records and module caches under the existing memory home's private runtime subtree. No amplifier-app-cli package, import or executable is required.

Standalone installation now declares Core ≥2.0.1, Foundation and uv. An explicit amplifier-memory setup prepares the configured provider sources and dependencies in a new private generation. Inference never installs or activates modules. Offline readiness checks block timer installation/start/restart before mutation when the environment, configuration or prepared sources have changed. Ordinary doctor/update maintain the memory tool rather than an Amplifier CLI installation.

Foundation merges shared, workspace and local settings. Named accounts and explicit provider/model choices are preserved. Role routing requires a prepared resolver configured through config.hooks; routing only supplied by bundle includes is not composed and fails visibly before a call. Explicit bundle/module composition requires host-resolved inference. Receipts distinguish response-reported and request-selected models; SDK defaults absent from both remain unknown. The dedicated console process loads missing shared credential environment values, with existing process values taking precedence; embedding APIs remain environment-neutral. Provider-owned OAuth refresh storage retains its configured ownership. Healthy model calls have no fixed completion deadline, and owned session resources are cleaned up on success, error and cancellation.

Unified's existing mounted-provider consolidation remains unchanged. This replaces the portable CLI path; it does not delete, rewrite or backfill historical sessions. Neither #16 nor microsoft/amplifier-app-cli#359 is a dependency. See docs/PRIVATE_INFERENCE_VALIDATION.md for the acceptance boundary.

Validation:

  • Fresh standalone uv-tool installation on Python 3.13 with the published Core 2.0.1 wheel; CLI package and executable absent.
  • Actual setup command and default console suggest callback using real Core/Foundation lifecycle and routing with a synthetic provider: one inference, correct named account/model, private internal job, usage recorded, source transcripts/settings preserved, and no re-ingestion or Git tracking of generated state. Inference network/non-Git subprocesses were denied and Python writes confined to the private fixture.
  • Initial implementation full suite: 480 passed, 10 failures. All ten reproduced unchanged on base b224eea: missing Linux systemctl and macOS Git manual formatting. Final focused runtime suite after the last setup guards: 18 passed.
  • Latest review corrections: 146 ordinary focused tests passed with Core pytest plugin enabled; pytest-asyncio is declared in the dev group. Includes missing-resolver refusal, model provenance and dangling private ignore-file symlinks.
  • Separate module suites: 206 passed, one skipped, one Mac path assertion reproduced unchanged on base. Injection conformance reports no Broken; tool wording and budget phrase failures both reproduce on base (budget422/500tokens). These residuals are not claimed as green merge gates.
  • Ruff, formatting, diff checks and dependency lock check passed.

The fresh standalone proof was recorded at implementation65a6128; the exact latest correction head is10e5a25 and was checked by the ordinary focused/module/conformance runs described above. This remains a draft for review; the repository-required owner-host save/load session smoke is still unfulfilled. No real provider SDK/account/OAuth acceptance, model-quality test, real OS timer activation, component adoption or production deployment was performed. Readiness verifies installed source/configuration identity and does not claim upstream freshness or successful live authentication.

@bkrabach Brian Krabach (bkrabach) changed the title Run portable memory suggestions without CLI sessions Run portable memory inference in private Core sessions Sep 23, 2026
@bkrabach
Brian Krabach (bkrabach) marked this pull request as ready for review September 23, 2026 23:02
@bkrabach
Brian Krabach (bkrabach) merged commit 60b1241 into main Sep 23, 2026
1 check passed
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