Skip to content

[codex] Add memory query result cache - #59

Open
saurabhhhcodes wants to merge 1 commit into
DevSecOpsLab-CSIE-NPU:mainfrom
saurabhhhcodes:codex/memory-query-cache
Open

saurabhhhcodes wants to merge 1 commit into
DevSecOpsLab-CSIE-NPU:mainfrom
saurabhhhcodes:codex/memory-query-cache

Conversation

@saurabhhhcodes

Copy link
Copy Markdown

Summary

  • add a TTL-backed in-memory cache for identical memory_query dispatches
  • invalidate cached query results after memory_add, memory_update, and memory_delete in the same session
  • expose queryCacheHits and queryCacheMisses through memory_access_analytics
  • cover cache hits, invalidation, TTL override, and analytics stats with focused Bun tests

Closes #44

Validation

  • npx --yes bun test src/mcp-server-cache.test.ts
  • npx --yes bun test
  • npx --yes bun run build
  • npx --yes tsc --noEmit fails on existing unrelated src/tui.ts(50,3): 'api.command' is possibly 'undefined'

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.

[Prefix-KV #3] MCP server semantic query result cache

1 participant