Skip to content

feat: add repository-scoped memory - #36

Open
mkaz wants to merge 1 commit into
jayzeng:mainfrom
mkaz:mkaz/33-repo-memory
Open

feat: add repository-scoped memory#36
mkaz wants to merge 1 commit into
jayzeng:mainfrom
mkaz:mkaz/33-repo-memory

Conversation

@mkaz

@mkaz mkaz commented Aug 27, 2026

Copy link
Copy Markdown

Summary

  • add repository-scoped memory under the nearest Git root alongside existing user-wide memory
  • infer scope from prompts while allowing explicit scope overrides across memory tools
  • load and search both scopes, with repository context prioritized before user context
  • add scoped recovery/status behavior, per-repository qmd collections, tests, and documentation

Closes #33

How to test

  • npm test (198 tests)
  • npm run build
  • npm run lint
  • qmd cache test
  • git diff --check

API-backed E2E tests were not run.

Storage and qmd behavior

Repository memory is stored in .pi/agent/memory/ at the nearest Git root. Existing user memory remains in ~/.pi/agent/memory/, and neutral requests continue to default to user scope. Repository search uses a separate qmd collection per Git repository; the existing user-memory file format is unchanged.

Add repository-local memory alongside user-wide memory, including natural-language scope inference and explicit scope controls.

Load both scopes into context, search separate qmd collections together, and report scoped status and recovery data. Update tests and documentation for the new behavior.

Closes jayzeng#33

Signed-off-by: Marcus Kazmierczak <marcus@mkaz.com>
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.

per-project memory

1 participant