Release/v2.25.0 - #106
Conversation
Add platform-aware concept graph rebuilds, bounded graph context for smart recall, and scalable Console atlas rendering without changing the 14-tool public surface.
Align package, registry, container, and install-document version metadata for the v2.25.0 release.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
📜 Recent review details🧰 Additional context used📓 Path-based instructions (4)**/*📄 CodeRabbit inference engine (AGENTS.md)
Files:
marm-mcp-server/tests/**/*.py📄 CodeRabbit inference engine (AGENTS.md)
Files:
**/tests/**⚙️ CodeRabbit configuration file
Files:
**/*.py⚙️ CodeRabbit configuration file
Files:
🔇 Additional comments (2)
📝 WalkthroughWalkthroughChangesThe PR adds platform-aware, schema-versioned concept graphs, bounded graph-context enrichment for smart recall, fail-open response limiting, atlas-based console visualization, and updated contracts, upgrade guidance, tests, and release documentation. Estimated code review effort: 5 (Critical) | ~120 minutes Possibly related PRs
🚥 Pre-merge checks | ✅ 2✅ Passed checks (2 passed)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 3
🧹 Nitpick comments (1)
marm-console/server/concept_store.py (1)
16-16: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winVersion constant duplicated across repos — bump risk.
_CURRENT_CONCEPT_SCHEMA_VERSION = "2"here mirrors the MCP server'sCONCEPT_SCHEMA_VERSION = 2. When the concept schema bumps, forgetting this copy will make the console silently reportrebuild_required(or accept a stale schema) with no test catching the drift. Consider deriving it from the MCP source of truth or documenting/testing the coupling.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@marm-console/server/concept_store.py` at line 16, Update _CURRENT_CONCEPT_SCHEMA_VERSION in concept_store.py to avoid an unvalidated duplicate of the MCP server’s CONCEPT_SCHEMA_VERSION: derive or import the shared source-of-truth value where feasible, otherwise add a focused coupling test that detects version drift and preserves rebuild_required behavior for mismatches.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@marm-mcp-server/marm_mcp_server/endpoints/concepts.py`:
- Around line 358-382: Update _marm_concept_build and _prepare_build_schema so
the CONCEPTS_AVAILABLE check occurs before any reset or derived-graph deletion,
especially for search_all=True requests. Return the existing
unavailable-concepts response without modifying the live graph, and preserve the
current rebuild behavior when concepts support is available.
In `@marm-mcp-server/marm-docs/README.md`:
- Line 538: The README mirror was edited directly instead of being regenerated.
Revert the changes in marm-mcp-server/marm-docs/README.md and update the
corresponding root README.md content, then run the repository’s README
generation process to regenerate the mirror, including the sections represented
by marm_smart_recall and the other affected entries.
In `@marm-mcp-server/README.md`:
- Line 33: Move the concept graph rebuild documentation changes from the
generated marm-mcp-server README mirror to the canonical root README.md,
including all referenced occurrences, then regenerate marm-mcp-server/README.md
from the root source to keep the release documentation synchronized.
---
Nitpick comments:
In `@marm-console/server/concept_store.py`:
- Line 16: Update _CURRENT_CONCEPT_SCHEMA_VERSION in concept_store.py to avoid
an unvalidated duplicate of the MCP server’s CONCEPT_SCHEMA_VERSION: derive or
import the shared source-of-truth value where feasible, otherwise add a focused
coupling test that detects version drift and preserves rebuild_required behavior
for mismatches.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: ba52c8d1-aab1-402b-97ee-35138c77339a
📒 Files selected for processing (33)
AGENTS.mdCHANGELOG.mdREADME.mddocs/INSTALL-DOCKER.mddocs/INSTALL-LINUX.mddocs/INSTALL-PLATFORMS.mddocs/INSTALL-WINDOWS.mddocs/PROTOCOL-LITE.mddocs/PROTOCOL.mdmarm-console/artifacts/marm-console/src/components/knowledge/ExplorerTab.tsxmarm-console/artifacts/marm-console/src/components/knowledge/GraphViz.tsxmarm-console/artifacts/marm-console/src/components/knowledge/shared.tsxmarm-console/artifacts/marm-console/src/hooks/use-marm-queries.tsmarm-console/artifacts/marm-console/src/lib/marm-api.tsmarm-console/artifacts/marm-console/src/lib/marm-types.tsmarm-console/server/concept_store.pymarm-console/server/endpoints/concepts.pymarm-console/tests/test_concept_store.pymarm-mcp-server/README.mdmarm-mcp-server/marm-docs/PROTOCOL-LITE.mdmarm-mcp-server/marm-docs/PROTOCOL.mdmarm-mcp-server/marm-docs/README.mdmarm-mcp-server/marm_mcp_server/core/concept_db.pymarm-mcp-server/marm_mcp_server/core/models.pymarm-mcp-server/marm_mcp_server/endpoints/concepts.pymarm-mcp-server/marm_mcp_server/endpoints/memory.pymarm-mcp-server/marm_mcp_server/server_stdio.pymarm-mcp-server/marm_mcp_server/services/graph_context.pymarm-mcp-server/marm_mcp_server/services/recall.pymarm-mcp-server/marm_mcp_server/services/stdio_graph_tools.pymarm-mcp-server/server.jsonmarm-mcp-server/tests/test_graph_context.pymarm-mcp-server/tests/test_stdio_transport.py
📜 Review details
🧰 Additional context used
📓 Path-based instructions (13)
**/*
📄 CodeRabbit inference engine (AGENTS.md)
Keep changes surgical: modify only what the task requires, match existing style, and preserve behavior during refactors.
Files:
docs/INSTALL-DOCKER.mddocs/PROTOCOL-LITE.mdAGENTS.mddocs/INSTALL-LINUX.mddocs/INSTALL-WINDOWS.mddocs/INSTALL-PLATFORMS.mdmarm-console/artifacts/marm-console/src/components/knowledge/shared.tsxmarm-mcp-server/marm-docs/PROTOCOL.mdmarm-mcp-server/marm-docs/PROTOCOL-LITE.mdmarm-console/server/endpoints/concepts.pymarm-mcp-server/server.jsonmarm-mcp-server/marm_mcp_server/server_stdio.pydocs/PROTOCOL.mdmarm-mcp-server/tests/test_stdio_transport.pymarm-mcp-server/marm_mcp_server/core/models.pymarm-console/artifacts/marm-console/src/hooks/use-marm-queries.tsmarm-console/artifacts/marm-console/src/lib/marm-api.tsmarm-console/artifacts/marm-console/src/components/knowledge/ExplorerTab.tsxmarm-mcp-server/marm_mcp_server/endpoints/memory.pymarm-mcp-server/marm_mcp_server/services/recall.pyCHANGELOG.mdmarm-mcp-server/marm_mcp_server/services/stdio_graph_tools.pymarm-console/artifacts/marm-console/src/lib/marm-types.tsmarm-mcp-server/marm_mcp_server/services/graph_context.pymarm-mcp-server/README.mdREADME.mdmarm-mcp-server/marm-docs/README.mdmarm-mcp-server/tests/test_graph_context.pymarm-console/artifacts/marm-console/src/components/knowledge/GraphViz.tsxmarm-console/tests/test_concept_store.pymarm-mcp-server/marm_mcp_server/core/concept_db.pymarm-console/server/concept_store.pymarm-mcp-server/marm_mcp_server/endpoints/concepts.py
{marm-mcp-server/pyproject.toml,marm-mcp-server/server.json,marm-mcp-server/marm_mcp_server/__init__.py,marm-mcp-server/marm_mcp_server/config/settings.py,marm-mcp-server/marm_mcp_server/server.py,marm-mcp-server/Dockerfile,docker-compose.yml,README.md,docs/INSTALL-*.md}
📄 CodeRabbit inference engine (AGENTS.md)
When bumping the version, update every listed version source and run
python scripts/find-versions.py; follow SemVer: MAJOR for breaking changes, MINOR for new tools/parameters/features, and PATCH for fixes or documentation updates.
Files:
docs/INSTALL-DOCKER.mddocs/INSTALL-LINUX.mddocs/INSTALL-WINDOWS.mddocs/INSTALL-PLATFORMS.mdmarm-mcp-server/server.jsonREADME.md
**/*.md
⚙️ CodeRabbit configuration file
**/*.md: Only flag documentation issues that are materially wrong, misleading for installation/release behavior, or inconsistent with live MCP behavior. Skip style, phrasing, formatting, and wording preferences.
Files:
docs/INSTALL-DOCKER.mddocs/PROTOCOL-LITE.mdAGENTS.mddocs/INSTALL-LINUX.mddocs/INSTALL-WINDOWS.mddocs/INSTALL-PLATFORMS.mdmarm-mcp-server/marm-docs/PROTOCOL.mdmarm-mcp-server/marm-docs/PROTOCOL-LITE.mddocs/PROTOCOL.mdCHANGELOG.mdmarm-mcp-server/README.mdREADME.mdmarm-mcp-server/marm-docs/README.md
{README.md,docs/PROTOCOL.md,docs/PROTOCOL-LITE.md,marm-mcp-server/marm-docs/README.md,marm-mcp-server/marm-docs/docs/PROTOCOL.md,marm-mcp-server/marm-docs/docs/PROTOCOL-LITE.md}
📄 CodeRabbit inference engine (AGENTS.md)
When adding or removing an MCP tool, update all documentation containing full tool lists and update the FAQ tool counts.
Files:
docs/PROTOCOL-LITE.mddocs/PROTOCOL.mdREADME.mdmarm-mcp-server/marm-docs/README.md
**/*.py
⚙️ CodeRabbit configuration file
**/*.py: Prioritize runtime correctness, async/concurrency safety, SQLite transaction safety, auth/rate-limit behavior, release-breaking packaging issues, and MCP protocol compatibility.
Files:
marm-console/server/endpoints/concepts.pymarm-mcp-server/marm_mcp_server/server_stdio.pymarm-mcp-server/tests/test_stdio_transport.pymarm-mcp-server/marm_mcp_server/core/models.pymarm-mcp-server/marm_mcp_server/endpoints/memory.pymarm-mcp-server/marm_mcp_server/services/recall.pymarm-mcp-server/marm_mcp_server/services/stdio_graph_tools.pymarm-mcp-server/marm_mcp_server/services/graph_context.pymarm-mcp-server/tests/test_graph_context.pymarm-console/tests/test_concept_store.pymarm-mcp-server/marm_mcp_server/core/concept_db.pymarm-console/server/concept_store.pymarm-mcp-server/marm_mcp_server/endpoints/concepts.py
marm-mcp-server/{marm_mcp_server/server.py,marm_mcp_server/server_stdio.py,server.json}
📄 CodeRabbit inference engine (AGENTS.md)
When adding or removing an MCP tool, update the HTTP route and whitelist, the STDIO wrapper or service registration, and the
server.jsontools array.
Files:
marm-mcp-server/server.jsonmarm-mcp-server/marm_mcp_server/server_stdio.py
marm-mcp-server/marm_mcp_server/**/*.py
📄 CodeRabbit inference engine (AGENTS.md)
marm-mcp-server/marm_mcp_server/**/*.py: MARM is a local-first Python FastAPI MCP server; endpoint logic belongs inmarm_mcp_server/endpoints/, while shared helpers belong incore/.
All memory writes must use the serialized asynchronous write queue; do not add bypass paths.marm_log_entrymust dual-write a log row and semantic memory, but semantic-store failure must not fail the log write.
Keep the memory database and concept-graph database isolated; never share connections between their SQLite connection pools.
marm_smart_recallmust keep primary memory ranking authoritative; graph enrichment is read-only, fail-open, bounded, and must be trimmed before primary results when enforcing response limits.
Use one lazily loaded, lock-serialized fastembed encoder with 512 dimensions. Writes must succeed when the encoder is unavailable.
For new tools, follow the existing flow: implement inendpoints/, register and whitelist the HTTP route, add the STDIO wrapper, and complete the consistency checklist.
Prefer the smallest solution; avoid speculative abstractions and unnecessary configuration flags. Keep orchestration in the current owner file and extract modules only at real boundaries.
Use minimal comments only for non-obvious rationale; do not add comments that merely narrate the next line.
Files:
marm-mcp-server/marm_mcp_server/server_stdio.pymarm-mcp-server/marm_mcp_server/core/models.pymarm-mcp-server/marm_mcp_server/endpoints/memory.pymarm-mcp-server/marm_mcp_server/services/recall.pymarm-mcp-server/marm_mcp_server/services/stdio_graph_tools.pymarm-mcp-server/marm_mcp_server/services/graph_context.pymarm-mcp-server/marm_mcp_server/core/concept_db.pymarm-mcp-server/marm_mcp_server/endpoints/concepts.py
marm-mcp-server/marm_mcp_server/{server.py,server_stdio.py,services/stdio_graph_tools.py}
📄 CodeRabbit inference engine (AGENTS.md)
HTTP and STDIO transports must remain in exact parity. HTTP tools are registered through
MCP_TOOL_OPERATIONS; STDIO uses the FastMCP app and explicit graph/concept registration while preserving tool-list order.
Files:
marm-mcp-server/marm_mcp_server/server_stdio.pymarm-mcp-server/marm_mcp_server/services/stdio_graph_tools.py
marm-mcp-server/tests/**/*.py
📄 CodeRabbit inference engine (AGENTS.md)
marm-mcp-server/tests/**/*.py: Run tests withpytestfrommarm-mcp-server/; use real FastAPI endpoints and SQLite, mocking only when it meaningfully speeds tests and matches real behavior with at least 95% fidelity.
Every new MARM Console API route requires at least one happy-path FastAPI response-contract test with the MCP adapter stubbed.
Do not write existence-check or coded-to-pass tests; prefer deep tests exercising real paths over broad shallow coverage.
Usepytest.mark.skiponly for genuinely unavailable dependencies, such as an unavailable embedding model or spaCy concepts extra, never merely for effort.
Files:
marm-mcp-server/tests/test_stdio_transport.pymarm-mcp-server/tests/test_graph_context.py
**/tests/**
⚙️ CodeRabbit configuration file
**/tests/**: Focus on tests that are flaky, non-isolated, incorrectly asserting behavior, or missing coverage for a changed high-risk path. Skip minor naming, comments, and layout preferences.
Files:
marm-mcp-server/tests/test_stdio_transport.pymarm-mcp-server/tests/test_graph_context.pymarm-console/tests/test_concept_store.py
marm-mcp-server/marm_mcp_server/endpoints/**/*.py
📄 CodeRabbit inference engine (AGENTS.md)
When adding a tool, implement its endpoint logic in the appropriate surface module under
endpoints/.
Files:
marm-mcp-server/marm_mcp_server/endpoints/memory.pymarm-mcp-server/marm_mcp_server/endpoints/concepts.py
marm-mcp-server/marm_mcp_server/{core/graph_supervisor.py,core/graph_client.py,services/stdio_graph_tools.py}
📄 CodeRabbit inference engine (AGENTS.md)
The code-graph binary must be supervised as a lazily started child process using newline-delimited JSON-RPC, run degraded on failure, and never allow graph or concept failures to break the seven core memory tools.
Files:
marm-mcp-server/marm_mcp_server/services/stdio_graph_tools.py
{README.md,marm-mcp-server/README.md,marm-mcp-server/marm-docs/README.md}
📄 CodeRabbit inference engine (AGENTS.md)
README mirrors are generated: edit only the root
README.mdas the source of truth; the PyPI and text-only variants must not be hand-edited.
Files:
marm-mcp-server/README.mdREADME.mdmarm-mcp-server/marm-docs/README.md
🧠 Learnings (1)
📓 Common learnings
Learnt from: CR
Repo: Lyellr88/marm-memory
Timestamp: 2026-07-20T05:46:47.528Z
Learning: Never commit changes without an explicit user request.
🪛 ast-grep (0.44.1)
marm-mcp-server/marm_mcp_server/core/concept_db.py
[info] 362-362: use jsonify instead of json.dumps for JSON output
Context: json.dumps([memory_id])
Note: [CWE-116] Improper Encoding or Escaping of Output.
(use-jsonify)
🪛 OpenGrep (1.25.0)
marm-mcp-server/marm_mcp_server/services/graph_context.py
[ERROR] 115-122: SQL query built via f-string passed to execute()/executemany(). Use parameterized queries with placeholders instead.
(coderabbit.sql-injection.python-fstring-execute)
[ERROR] 126-133: SQL query built via f-string passed to execute()/executemany(). Use parameterized queries with placeholders instead.
(coderabbit.sql-injection.python-fstring-execute)
[ERROR] 216-222: SQL query built via f-string passed to execute()/executemany(). Use parameterized queries with placeholders instead.
(coderabbit.sql-injection.python-fstring-execute)
[ERROR] 233-240: SQL query built via f-string passed to execute()/executemany(). Use parameterized queries with placeholders instead.
(coderabbit.sql-injection.python-fstring-execute)
[ERROR] 266-272: SQL query built via f-string passed to execute()/executemany(). Use parameterized queries with placeholders instead.
(coderabbit.sql-injection.python-fstring-execute)
marm-mcp-server/marm_mcp_server/core/concept_db.py
[ERROR] 257-257: SQL query built via f-string passed to execute()/executemany(). Use parameterized queries with placeholders instead.
(coderabbit.sql-injection.python-fstring-execute)
🔇 Additional comments (35)
AGENTS.md (1)
16-16: LGTM!CHANGELOG.md (1)
8-15: LGTM!README.md (1)
31-31: LGTM!Also applies to: 578-578, 601-601, 769-769, 779-785
docs/INSTALL-DOCKER.md (1)
5-5: LGTM!marm-mcp-server/marm_mcp_server/server_stdio.py (1)
70-72: LGTM!Also applies to: 92-92
marm-mcp-server/server.json (1)
36-36: LGTM!Also applies to: 84-84
marm-mcp-server/tests/test_stdio_transport.py (1)
764-785: LGTM!docs/INSTALL-LINUX.md (1)
5-5: LGTM!Also applies to: 323-323
docs/INSTALL-PLATFORMS.md (1)
1-1: LGTM!docs/INSTALL-WINDOWS.md (1)
5-5: LGTM!Also applies to: 296-296
docs/PROTOCOL-LITE.md (1)
30-30: LGTM!docs/PROTOCOL.md (1)
32-37: LGTM!marm-mcp-server/marm-docs/PROTOCOL-LITE.md (1)
30-30: LGTM!marm-mcp-server/marm-docs/PROTOCOL.md (1)
32-37: LGTM!marm-mcp-server/marm_mcp_server/core/concept_db.py (3)
46-77: LGTM!
189-265: LGTM!
388-413: 🎯 Functional CorrectnessNo action needed —
endpoints/concepts.pyalready passesplatform=mem_platformintofind_similar_entities, so the duplicate scan stays scoped correctly.> Likely an incorrect or invalid review comment.marm-mcp-server/marm_mcp_server/services/graph_context.py (3)
79-164: LGTM!
167-298: LGTM!
301-332: LGTM!marm-mcp-server/marm_mcp_server/endpoints/memory.py (1)
267-381: LGTM!marm-mcp-server/marm_mcp_server/services/recall.py (1)
98-216: LGTM!marm-mcp-server/tests/test_graph_context.py (1)
20-294: LGTM!marm-console/server/concept_store.py (1)
407-591: LGTM!marm-console/server/endpoints/concepts.py (1)
78-79: LGTM!marm-console/tests/test_concept_store.py (1)
14-302: LGTM!marm-mcp-server/marm_mcp_server/core/models.py (1)
202-205: LGTM!marm-mcp-server/marm_mcp_server/endpoints/concepts.py (1)
152-154: LGTM!Also applies to: 175-175, 192-192, 209-215, 325-341
marm-mcp-server/marm_mcp_server/services/stdio_graph_tools.py (1)
274-320: LGTM!marm-console/artifacts/marm-console/src/lib/marm-types.ts (1)
219-292: LGTM!marm-console/artifacts/marm-console/src/lib/marm-api.ts (1)
205-206: LGTM!marm-console/artifacts/marm-console/src/hooks/use-marm-queries.ts (1)
22-22: LGTM!Also applies to: 286-293
marm-console/artifacts/marm-console/src/components/knowledge/ExplorerTab.tsx (1)
113-113: LGTM!Also applies to: 183-183, 260-266, 303-311
marm-console/artifacts/marm-console/src/components/knowledge/GraphViz.tsx (1)
48-53: LGTM!Also applies to: 85-85, 104-132, 134-146, 226-246, 280-281
marm-console/artifacts/marm-console/src/components/knowledge/shared.tsx (1)
3-3: LGTM!
| | Tool | What it does | Key parameters | | ||
| |------|--------------|----------------| | ||
| | `marm_smart_recall` | Hybrid recall: exact lane for config keys, commands, and file paths; semantic rerank for natural-language queries | `query`, `limit`, `session_name`, `search_all`, `detail=1/2/3`, `project`, `platform`, `exact_mode` | | ||
| | `marm_smart_recall` | Hybrid memory recall with an additive, bounded concept/code graph sidecar when a compatible graph exists | `query`, `limit`, `session_name`, `search_all`, `detail=1/2/3`, `project`, `platform`, `exact_mode` | |
There was a problem hiding this comment.
📐 Maintainability & Code Quality | 🟠 Major | ⚡ Quick win
Regenerate this README mirror instead of editing it directly.
marm-mcp-server/marm-docs/README.md is generated from the root README.md; direct edits here can be overwritten and create release-documentation drift. Revert these mirror changes and regenerate it from the updated root README.
Also applies to: 561-561, 729-730, 739-745
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@marm-mcp-server/marm-docs/README.md` at line 538, The README mirror was
edited directly instead of being regenerated. Revert the changes in
marm-mcp-server/marm-docs/README.md and update the corresponding root README.md
content, then run the repository’s README generation process to regenerate the
mirror, including the sections represented by marm_smart_recall and the other
affected entries.
Source: Coding guidelines
|
|
||
| - marm-console now ships as the local web app for memory, knowledge, projects, and MCP-backed memory mutation actions. Packaging and one-command startup polish are still in progress. | ||
| - **Embedding upgrade:** v2.24 switches MARM to Jina v2 Small. Existing MiniLM data must be migrated before restart: stop MARM, run `marm-mcp-server --migrate-embeddings`, then restart. See [Upgrade Existing Embeddings](#upgrade-existing-embeddings). | ||
| - **Concept graph rebuild:** the platform-aware graph schema requires one full rebuild. After upgrading, run `marm_concept_build(search_all=True)` once. MARM backs up and rebuilds only the derived concept database; memories are not modified. |
There was a problem hiding this comment.
📐 Maintainability & Code Quality | 🟠 Major | ⚡ Quick win
Update the canonical README instead of editing this generated mirror.
Apply these changes to the root README.md, then regenerate marm-mcp-server/README.md; otherwise the release documentation can drift or be overwritten.
Also applies to: 580-580, 603-603, 771-771, 781-787
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@marm-mcp-server/README.md` at line 33, Move the concept graph rebuild
documentation changes from the generated marm-mcp-server README mirror to the
canonical root README.md, including all referenced occurrences, then regenerate
marm-mcp-server/README.md from the root source to keep the release documentation
synchronized.
Source: Coding guidelines
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 2734f40481
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| raw_edges = connection.execute( | ||
| """SELECT id, source_id, target_id, predicate, memory_id | ||
| FROM relationships ORDER BY id""" | ||
| ).fetchall() |
There was a problem hiding this comment.
Bound atlas sampling before loading all relationships
When the concept graph is larger than the atlas budget, this still materializes every relationship with an unbounded SELECT ... FROM relationships before later reducing the response to 4,000 sampled visual edges. On users' accumulated graphs from repeated search_all builds, opening the Console Knowledge page now pays O(total relationships) memory and latency even though oversized graphs are explicitly sampled; the previous overview query was SQL-bounded to 600 edges. Please cap/stream the candidate set or push the sampling into SQL before fetching all rows.
Useful? React with 👍 / 👎.
| graph_rebuilt = await asyncio.to_thread(_prepare_build_schema, req) | ||
| except ValueError: | ||
| return { |
There was a problem hiding this comment.
Persist rebuild-required build failures for polling
For a Console-triggered scoped build against a legacy platformless graph, this new schema-prep error path returns before _create_build_run persists the caller-provided run_id. The Console only updates its local queued job on transport failure, so it will keep polling a nonexistent build row and show the job as queued until the stale timeout instead of immediately surfacing rebuild_required; create/update the build run before this return or have the Console consume the MCP error response.
Useful? React with 👍 / 👎.
| {selectedId === null && overviewGraph && ( | ||
| <Badge variant="outline" className="h-6 text-[10px] font-mono"> | ||
| {overviewGraph.mode === 'full' | ||
| ? `Full atlas · ${overviewGraph.rendered.nodes} nodes` | ||
| : `Connected sample · ${overviewGraph.rendered.nodes}/${overviewGraph.total.nodes} nodes`} | ||
| </Badge> |
There was a problem hiding this comment.
Render isolated full-atlas nodes instead of counting them
In full-atlas mode this badge reports overviewGraph.rendered.nodes, which includes isolated entities returned by the new overview API, but GraphViz still builds its visible node set only from endpoints of visible edges when seed_id is null. Any concept with degree 0 is therefore counted as rendered but is dropped from the canvas and cannot be clicked; this is especially visible for stores with single-entity memories or no relationships. Either include isolated nodes in the overview rendering path or stop counting them as rendered.
Useful? React with 👍 / 👎.
Preserve derived graphs when concept extraction is unavailable, persist rebuild-required runs for Console polling, bound sampled atlas reads, and render isolated atlas entities.
There was a problem hiding this comment.
Actionable comments posted: 1
🧹 Nitpick comments (1)
marm-mcp-server/tests/test_concept_endpoints.py (1)
176-178: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low valueUse
INSERT OR REPLACEto guarantee test state.Using
UPDATEassumes theschema_versionrow was already inserted during DB initialization. If the test database is initialized empty or the schema setup logic changes in the future, theUPDATEwill quietly affect 0 rows, and the test will fail to simulate the legacy state. UsingINSERT OR REPLACEensures the setup is bulletproof.♻️ Proposed refactor
- conn.execute( - "UPDATE concept_schema_metadata SET value = '1' WHERE key = 'schema_version'" - ) + conn.execute( + "INSERT OR REPLACE INTO concept_schema_metadata (key, value) VALUES ('schema_version', '1')" + )🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@marm-mcp-server/tests/test_concept_endpoints.py` around lines 176 - 178, Replace the UPDATE statement in the test setup with an INSERT OR REPLACE for the schema_version key, ensuring value '1' is written whether or not the metadata row already exists.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@marm-mcp-server/tests/test_concept_endpoints.py`:
- Around line 170-192: Add a test alongside
test_scoped_legacy_build_persists_rebuild_required_run that invokes
marm_concept_build with search_all=True against a legacy schema. Verify the
explicit rebuild succeeds, backup_and_reset_concept_database creates a
timestamped backup of the existing database, and the active graph is reset as
expected, including any relevant build-run status or metadata assertions.
---
Nitpick comments:
In `@marm-mcp-server/tests/test_concept_endpoints.py`:
- Around line 176-178: Replace the UPDATE statement in the test setup with an
INSERT OR REPLACE for the schema_version key, ensuring value '1' is written
whether or not the metadata row already exists.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: 2e4fa2ce-db2b-413f-b122-5c7a7d36b7a2
📒 Files selected for processing (5)
marm-console/artifacts/marm-console/src/components/knowledge/GraphViz.tsxmarm-console/server/concept_store.pymarm-console/tests/test_concept_store.pymarm-mcp-server/marm_mcp_server/endpoints/concepts.pymarm-mcp-server/tests/test_concept_endpoints.py
🚧 Files skipped from review as they are similar to previous changes (4)
- marm-console/tests/test_concept_store.py
- marm-console/server/concept_store.py
- marm-mcp-server/marm_mcp_server/endpoints/concepts.py
- marm-console/artifacts/marm-console/src/components/knowledge/GraphViz.tsx
📜 Review details
🧰 Additional context used
📓 Path-based instructions (3)
marm-mcp-server/tests/**/*.py
📄 CodeRabbit inference engine (AGENTS.md)
marm-mcp-server/tests/**/*.py: Run tests withpytestfrommarm-mcp-server/; tests should exercise real FastAPI endpoints and real SQLite, mocking only when it closely matches real behavior and meaningfully speeds testing.
Every new MARM Console API route must have at least one happy-path FastAPI response-contract test with the MCP adapter stubbed.
Do not write existence-check or coded-to-pass tests; prefer deep tests exercising real paths over broad shallow coverage.
Usepytest.mark.skiponly for genuinely unavailable dependencies, never merely to avoid implementation effort.
Files:
marm-mcp-server/tests/test_concept_endpoints.py
**/tests/**
⚙️ CodeRabbit configuration file
**/tests/**: Focus on tests that are flaky, non-isolated, incorrectly asserting behavior, or missing coverage for a changed high-risk path. Skip minor naming, comments, and layout preferences.
Files:
marm-mcp-server/tests/test_concept_endpoints.py
**/*.py
⚙️ CodeRabbit configuration file
**/*.py: Prioritize runtime correctness, async/concurrency safety, SQLite transaction safety, auth/rate-limit behavior, release-breaking packaging issues, and MCP protocol compatibility.
Files:
marm-mcp-server/tests/test_concept_endpoints.py
🧠 Learnings (1)
📓 Common learnings
Learnt from: CR
Repo: Lyellr88/marm-memory
Timestamp: 2026-07-20T07:11:31.917Z
Learning: Never commit changes without an explicit user request.
Verify full concept rebuilds back up legacy graph data, reset the derived schema, and persist successful build-run state.
Graph-aware recall and Console atlas
graph_contexttomarm_smart_recall. Primary memory ranking stays authoritative, andgraph lookup fails open when the concept database is missing, empty, unavailable, or needs rebuilding.
marm_concept_build(search_all=True)rebuild, with a timestamped backup of only the derived concept database.platformscope tomarm_concept_recallover both HTTP and STDIO while preserving the existing 14-tool public surface.
on large graphs. The UI now uses adaptive force layout, weighted relationships, focused labels, and stable manual
pause behavior.
Console behavior.
Validation
78 passedfor graph context, concept endpoint, and STDIO transport coverage.14 passedfor Console concept-store and atlas coverage.python scripts/find-tools.pyandvalidate_server_json.pypassed.git diff --checkpassed.Summary by CodeRabbit
New Features
Bug Fixes
Documentation
marm_concept_build(search_all=True)), including legacy/platform-attribution correction notes and updated tool/protocol descriptions.