Skip to content

feat(v3.0): cross-project unified memory#25

Open
RichardHightower wants to merge 3 commits intomainfrom
feature/v3.0-cross-project-memory
Open

feat(v3.0): cross-project unified memory#25
RichardHightower wants to merge 3 commits intomainfrom
feature/v3.0-cross-project-memory

Conversation

@RichardHightower
Copy link
Copy Markdown
Contributor

Summary

Implements the first v3.0 feature: federated query across multiple project stores.

What changed

File Change
proto/memory.proto Added all_projects flag to RouteQueryRequest, project attribution field to RetrievalResult
memory-types/config.rs New CrossProjectConfig { registered: Vec<PathBuf> } + projects field in Settings
memory-storage/db.rs Added Storage::open_read_only() for federation
memory-service/federated.rs (NEW) federated_query() — fans out to registered stores, merges results, project attribution, fail-open
memory-service/retrieval.rs Wired federated_query behind all_projects opt-in flag
e2e-tests/cross_project_test.rs (NEW) 4 E2E tests
.planning/STATE.md, .planning/ROADMAP.md v3.0 Phase 51 progress recorded

Design decisions

  • Opt-in only — default single-project behavior is completely unchanged
  • Fail-open — unavailable stores are silently skipped, never block a query
  • Project attributionproject field on results uses serde(default) for backward-compatible JSON, matching the existing agent field pattern from v2.1
  • Index-free fallback — added a primary TOC fallback inside federated_query so cross-project works even when BM25/vector indexes aren't built for a store
  • Config-driven — register project paths in config.toml under [projects]

Tests

13/13 passing:

  • 9 unit tests (federated module)
  • 4 E2E tests: merged results, project attribution, fail-open on unavailable store, default behavior unchanged

Usage

# ~/.config/agent-memory/config.toml
[projects]
registered = [
  "/path/to/project-a",
  "/path/to/project-b"
]

Then query with --all-projects flag or all_projects: true in config.

- Add registered_projects config for multi-store federation
- Implement FederatedQueryHandler with fail-open semantics
- Add project attribution field to query results
- Wire cross-project behind opt-in flag
- Add E2E tests for multi-store query and attribution
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