Skip to content

Commit 3c272e2

Browse files
committed
chore: update insights and agent configurations for v0.3.0a7
- Bumped managed block version in AGENTS.md from v0.3.0a5 to v0.3.0a7. - Expanded gsd-parallel-executor insights with additional entries on agent behavior and configuration requirements. - Added new insights on mem0 SDK and coderag evaluation stability to INDEX.md. - Adjusted continual-learning hook state to reflect updated run metrics.
1 parent 5c484af commit 3c272e2

21 files changed

Lines changed: 311 additions & 6 deletions

.claude/insights/INDEX.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
11
# Insights Index
22

33
- [gsd-parallel-executor](gsd-parallel-executor.md) — supamem-specific overrides for GSD parallel executor agents (no `--no-verify`, SUMMARY.md filesystem-only)
4+
- [mem0-sdk-eval](mem0-sdk-eval.md) — mem0 SDK gotchas when wiring as a peer in coderag eval path
5+
- [coderag-eval-rocm](coderag-eval-rocm.md) — ROCm GPU stability + silent-failure gaps in the coderag eval runner under combined HyDE+rerank load
6+
- [supamem-installation](supamem-installation.md) — init/config-vs-collection gap, index boot ordering, editable uv-tool install vs PyPI
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
---
2+
topic: coderag-eval-rocm
3+
globs: ["src/supamem/eval/coderag/**", "src/supamem/rerankers/**", "src/supamem/retrieval/tuned_hybrid_hyde.py"]
4+
updated: 2026-05-11
5+
entries: 3
6+
---
7+
- The combined `tuned_hybrid_hyde` retrieval + `mxbai-rerank-base-v2` rerank stack triggers an AMD ROCm 6.4 `HW Exception by GPU node-1 ... reason :GPU Hang` on RX 6800 XT after only a handful of scoring batches when both axes of load run simultaneously (Ollama HyDE rewrites + mxbai forward passes). 17-E (AST-only + default rerank) and 17-F (HyDE-only + default rerank, no re-ingest) ran cleanly because they don't stack both pressures. Mitigation when ADR §9 needs the combined data point: split the workload (run scoring in smaller batches, drain Ollama between batches), or accept the combined configuration as an opt-in-only documented limitation.
8+
- After a ROCm GPU Hang, `ollama` unloads `llama3.2:3b` from VRAM and `supamem doctor` warm-pool panel will report `NOT loaded — first HyDE call will pay 10–30s`. Before retrying any HyDE eval after a hang, re-run `ollama run llama3.2:3b ""` and confirm the doctor panel flips back to `loaded` — otherwise the first measured query absorbs cold-start latency and pollutes p95.
9+
- `src/supamem/eval/coderag/runner.py` silently swallows mid-run GPU errors: when reranker forward passes fail on a hung GPU, the eval exits cleanly with code 0 and writes NO output JSON, so a green exit code does NOT mean the run succeeded. Always assert the output JSON exists before declaring a Wave-3 measurement plan complete. Bug-shaped: runner should either re-raise on reranker exceptions or write a partial envelope flagged `incomplete: true` so the orchestrator can detect the gap.
Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,14 @@
11
---
22
topic: gsd-parallel-executor
33
globs: [".planning/**", ".claude/agents/**"]
4-
updated: 2026-05-03
5-
entries: 2
4+
updated: 2026-05-10
5+
entries: 8
66
---
77
- When spawning gsd-executor agents in this repo, drop the `--no-verify` flag from the parallel-execution prompt — the project's PreToolUse hook (`block-no-verify@1.1.2`) rejects it, and Plan 10-01's executor confirmed pre-commit hooks are fast enough that parallel worktree runs do not contend.
88
- SUMMARY.md cannot be git-committed in this repo because `.planning/` is gitignored AND `commit_docs: false` in `.planning/config.json` (CLAUDE.md hard constraint: supamem ships as a clean Python package). Tell parallel executors to write SUMMARY.md to the plan directory and rely on worktree filesystem-state preservation through `Agent(isolation="worktree")` auto-merge — do NOT use `git add --force` on `.planning/`, that would push planning artifacts to main.
9+
- Orchestrator MUST `cp` SUMMARY.md from `<worktree>/.planning/phases/<phase>/<plan>-SUMMARY.md` to the main tree BEFORE running `git worktree remove --force` — auto-merge does not carry gitignored files. Without this rescue, the SUMMARY (which encodes deviations like filename mismatches and floor-clamp design choices) is permanently lost when the worktree dir is deleted (#2070 pattern).
10+
- Locked Claude Code worktrees (`isolation="worktree"`) require `git worktree remove -f -f` (double-force) when the agent process still pins them via lock-reason `claude agent agent-<id> (pid <N>)`. Single `-f` errors with `cannot remove a locked working tree`. Always pair with `git branch -D worktree-agent-<id>` afterward; the branch survives single-force removal.
11+
- gsd-executor subagents in this repo do NOT have `mcp__supamem__*` in their tool whitelist as of 2026-05-10, despite the v0.2.5+ agent-patcher promise (`supamem repair` should add it). Three Wave-2 executors (17-B/C/D) all reported "supamem search empty — proceeding from code". Executors honor the dual-memory rule by reading durable planning artifacts (CONTEXT.md/RESEARCH.md/PATTERNS.md) — front-load these in the planner so executors don't need MCP. Investigation owed: why the patcher isn't reaching the gsd-executor agent file.
12+
- Plans whose verification path is `set config X then run pipeline Y` MUST be checked at plan-time for the actual data flow from X to Y in the codebase. Phase 17 Plan E presupposed `chunker = "tree_sitter_code"` would propagate through `eval --suite coderag --full`, but `coderag/ingest.py` hardcodes `chunk_markdown` (D-SCOPE-05 carry-lock) AND `eval/runner.py`'s coderag branch never invokes ingest at all. Carry-lock tests can hide such gaps from the planner because the lock makes the dispatch site invisible. Add a goal-backward "config→behavior wiring exists?" check to gsd-plan-checker for any plan whose checkpoint command toggles config.
13+
- The Agent tool's `isolation: "worktree"` parameter must be passed explicitly — it is NOT inferred from `subagent_type: "gsd-executor"`. Without it, the executor runs on the orchestrator's main checkout, fails the protected-ref HEAD assertion (`refusing to self-recover via git update-ref`, #2924), and aborts before any tasks execute. The execute-phase workflow's prose template includes `isolation="worktree"` but the tool-call schema requires you to set the parameter on every dispatch.
14+
- After merging an executor worktree back, run the orchestrator's post-merge test gate with the SAME extras the executor used. The executor's worktree venv had `eval` + `ast-chunker` extras, but a stray `uv sync --extra dev` on the main tree strips them — dispatch tests then fail with `ModuleNotFoundError: pytrec_eval`/`tree_sitter` even though the executor reported a green suite. Re-sync with `uv sync --extra dev --extra eval --extra ast-chunker --extra peers-mem0` (full superset) before declaring the gate green.

.claude/insights/mem0-sdk-eval.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
---
2+
topic: mem0-sdk-eval
3+
globs: ["src/supamem/eval/coderag/peers/**", ".planning/phases/**mem0**"]
4+
updated: 2026-05-08
5+
entries: 2
6+
---
7+
- Set `OPENAI_API_KEY=<any-non-empty>` (e.g. `sk-dummy-disabled`) before constructing `mem0.Memory(...)` in eval paths even when downstream calls use `infer=False` — the SDK eagerly instantiates an OpenAI LLM client at `Memory.__init__`, so missing env raises before any `infer=False` codepath runs; the dummy value never leaves the local process.
8+
- Scope the OPENAI_API_KEY workaround INLINE on the mem0 eval invocation (`OPENAI_API_KEY=sk-dummy-disabled uv run --no-sync supamem eval ... --peer mem0 ...`); do NOT export it shell-globally, because `auto_goldens` enforces a D-07 invariant ("auto-goldens MUST stay offline — refused to run with SaaS LLM env vars set") and any `OPENAI_API_KEY` value (including the dummy) trips it across `tests/test_eval_runner_scoped.py` + `tests/test_eval_judge.py` (12 false-failure tests collapse the moment the env var is unset).
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
---
2+
topic: supamem-installation
3+
globs: ["src/supamem/init.py", "src/supamem/indexer/**", ".supamem/**", "src/supamem/install/**"]
4+
updated: 2026-06-11
5+
entries: 3
6+
---
7+
- `supamem init` exits 3 when `.supamem/config.toml` already exists and will NOT create a missing Qdrant collection — after a Qdrant data wipe doctor reports "collection missing" but neither `init` (config gate) nor `repair` (MCP/agents/models only) fixes it; recreate the hybrid collection (`create_collection` from `supamem.init`) or accept `init --force` (overwrites config) before `index`.
8+
- `supamem index` assumes the configured collection already exists: boot-time validity/path-prefix/classifier migrations hit Qdrant first and emit 404 storms with zero upserts if the collection is absent — treat "index ran but doctor still says collection missing" as "collection never created", not "index failed silently".
9+
- `uv tool install -e .` on the supamem dev tree pulls mxbai-rerank → CUDA torch (multi-GB, long download); global PyPI `uv tool install supamem` stays on the published wheel without that path — use `uv run supamem` for v0.3.x dev work and only editable-install globally when you explicitly need the dev version on PATH.

0 commit comments

Comments
 (0)