Skip to content

feat(ox-core): add per-project memory directory support - #987

Open
hakula139 wants to merge 1 commit into
mainfrom
feat/project-memory
Open

hakula139 wants to merge 1 commit into
mainfrom
feat/project-memory

Conversation

@hakula139

Copy link
Copy Markdown
Member

Summary

  • Add crates/ox-core/src/memory.rs with MemoryStore, MemoryEntry, MemoryError, default_memory_root, and project_key using zero new external dependencies.
  • Resolve per-project memory directories under $XDG_DATA_HOME/ox/memory/<project-key>/ (falling back to $HOME/.local/share/ox/memory/<project-key>/, overridable for tests) with deterministic slug + 64-bit FNV-1a keys.
  • Support reading, writing, deleting, and listing MEMORY.md and topic Markdown files, plus bounded prompt_section() / prompt_section_bounded() formatting for system prompt injection.
  • Add docs/reference/memory.md and link it in docs/README.md.

Test plan

  • nix develop -c run-hooks (all 20 hooks passed)
  • nix develop -c cargo doc --no-deps (passed)
  • nix develop -c cargo llvm-cov --workspace --show-missing-lines (crates/ox-core/src/memory.rs at 90.91% line coverage, workspace total 94.61%)

Related

@hakula139 hakula139 self-assigned this Dec 1, 2026
@codecov

codecov Bot commented Dec 1, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 91.52542% with 30 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
crates/ox-core/src/memory.rs 91.52% 30 Missing ⚠️

📢 Thoughts on this report? Let us know!

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.

Keep a memory directory for each project

1 participant