Repository navigation
docs(plan): QA-fix plan for the 2026-06-26 Havaya QA report - #89
Conversation
Plan (for codex review) addressing all findings from the 2026-06-26 manual QA pass on app.havaya.me + life v2026.06.20.2. Covers both repos: - [HIGH] custom summary method dropped: parseTitleDate strips pre-TITLE content (app.havaya); prod logs confirm the method was sent + the marker emitted. - [HIGH] durable memory not recalled across chats: saving works (add_episode succeeds), retrieval is discretionary -> add a deterministic MEMORY_RECALL.md injection mirroring the app_profile bootstrap (openclaw). - Google Doc raw-edit is by-design (415); small UX guard. - home owner-note/videos = docs/data, not a bug; QA-guide nav fixes; test-data enablement for the blocked cases. Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
|
@codex please review this plan (not code — a plan doc). It addresses the 2026-06-26 Havaya QA findings across two repos. Focus on: (1) Issue 2 — the deterministic MEMORY_RECALL.md injection design (group-id parity with the life-memory-scope hook, fail-open/timebox on the per-turn bootstrap path, TTL cache, reuse of the app_profile bootstrap pattern); (2) Issue 1 — the parseTitleDate rewrite (keep TITLE/DATE extraction while preserving leading/body content). Flag any risk, simpler approach, or missing edge case before we implement. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: e2a0401abb
ℹ️ 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".
| 1. **New** `src/agents/graphiti-recall-client.ts` — a small server-side streamable-HTTP MCP client that | ||
| calls Graphiti `search_memory_facts` directly (bypassing the agent tool loop). Mirror the | ||
| handshake/SSE-parse in `ops/graphiti-life/proxy/graphiti-proxy.js` | ||
| (`initialize` → `notifications/initialized` → `tools/call`; headers incl. `Host: localhost:8000`; | ||
| target `GRAPHITI_URL` default `http://graphiti-mcp:8000/mcp`). Use `fetch` + `AbortController`. |
There was a problem hiding this comment.
Keep Graphiti recall behind an explicit scope boundary
Because this plan talks directly to graphiti-mcp rather than the existing proxy, the current safety mapping in ops/graphiti-life/proxy/graphiti-proxy.js is no longer on the path. For this direct bootstrap client, explicitly require the same buildUpstreamCall behavior for search_memory_facts (group_ids: [groupId], no caller-supplied group_id/group_ids/center_node_uuid, and fail closed on unsafe group ids), or call a server-side proxy helper instead; otherwise a small implementation miss can search the wrong/default scope even though the derived group id string itself is correct.
Useful? React with 👍 / 👎.
| App-sessions only; **timebox ~1.5-2.5s + fail-open** (any error/empty/no-scope → return files | ||
| unchanged, never block the turn); **short-TTL cache (~10 min, keyed by group id)** so it doesn't hit | ||
| Graphiti every turn. |
There was a problem hiding this comment.
Invalidate the recall cache after memory writes
A 10-minute cache keyed only by group id can reproduce the QA failure: if chat A builds MEMORY_RECALL.md, then the user saves a new goal, and chat B starts within the TTL, chat B receives the stale cached facts and still cannot recall the just-saved goal. Either skip caching for the first implementation, use a much shorter/per-turn cache, or add an invalidation path on successful Graphiti writes (add_memory/upstream add_episode) so cross-chat recall is immediate.
Useful? React with 👍 / 👎.
…essions (QA 4A) (#90) * feat(memory): deterministic durable-memory recall injection for app sessions Report 4A: a goal saved in one app chat was not recalled in a new chat. Saving works (verified: add_episode succeeded + search_memory_facts returns the fact); the gap is retrieval — it is discretionary and the slim app prompt often skips search_memory_facts at the start of a new chat. Mirror the proven app_profile bootstrap: fetch the user's top durable facts server-side and inject them as a synthetic MEMORY_RECALL.md context file every turn (app sessions only), so recall no longer depends on the model searching. - graphiti-recall-client.ts: read-only search_memory_facts over the streamable -HTTP MCP endpoint, mirroring the graphiti-proxy capability boundary — the only scope input is a server-derived groupId, unsafe ids fail closed, the call hard -sets group_ids:[groupId] and no caller group_id/group_ids/center_node_uuid can pass through. node:http (Host: localhost:8000) like the proxy; timeboxed. - memory-recall-context.ts: appendMemoryRecallBootstrapFile — group id derived byte-identically to the life-memory-scope hook; ~2s timebox + fail-open; NO cross-turn cache (codex P2: avoid stale recall right after a write). - bootstrap-files.ts: chain after appendAppProfileBootstrapFile (post-shaping). - agents-md-memory-section.md: note that MEMORY_RECALL.md is pre-injected. - 27 vitest (incl. wire/scope/timebox + hook group-id parity + fail-open + no -stale-cache). pnpm check (format + tsgo + lint) green. Implements Issue 2 of docs/experiments/plans/qa-fixes-2026-06-26.md (#89). Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]> * chore(fmt): clear pre-existing oxfmt 0.33.0 drift (unblock check) oxfmt 0.33.0 flags two files this branch does not otherwise touch (SKILL.md, the cron-generated bug_list.md) — identical to main, whose older CI run passed. Reformat them so the `check` gate is green here. Note: the daily bug_list autoscan cron will re-drift bug_list.md unless it also formats / is ignored (separate follow-up). Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]> --------- Co-authored-by: Liran Peretz <[email protected]> Co-authored-by: Claude Opus 4.8 (1M context) <[email protected]>
What
Plan document (for codex review before implementation) addressing every finding from the 2026-06-26 manual QA pass on app.havaya.me + life v2026.06.20.2. Lands in
docs/experiments/plans/qa-fixes-2026-06-26.md. It spans two repos — this PR is the review surface; the code PRs follow inapp.havayaandopenclawafter review.Findings & fixes (root causes verified against prod logs + the Graphiti server)
parseTitleDate()strips all content before the TITLE line. Prod logs: method was sent (methodChars=134) and the model did emit the marker — the parser deletes it.node:test.add_episodesucceeded on the test date); retrieval is discretionary, no deterministic injection.MEMORY_RECALL.mdinjection mirroring theapp_profilebootstrap (openclaw) + vitest.updateTextFilerejects Google Docs (415).editableflag + disabled Save w/ note./drive/admin/,/life,me.havaya.appin the report.Two of the report's own hypotheses (DB-wiring for #1, save-failure for #2) were disproven by the evidence and corrected in the plan.
🤖 Generated with Claude Code