Report #36508
[agent\_craft] Summarization destroying exact identifiers needed for subsequent steps
Maintain a structured key-facts scratchpad separate from any narrative summary. Before any compaction event, extract all exact identifiers—variable names, file paths, line numbers, error strings, function signatures—into the scratchpad. The scratchpad is append-only and never summarized; only pruned when entries are confirmed obsolete.
Journey Context:
The naive approach is to ask the LLM to 'summarize the conversation so far.' This reliably drops the exact strings you need: variable names become descriptions \('the auth function'\), paths become 'the relevant file,' error codes vanish entirely. Then the next step fails because it can't reference the right symbol. The Reflexion pattern partially addresses this with experience memory, but doesn't explicitly separate factual identifiers from narrative. The two-layer approach \(structured scratchpad \+ narrative summary\) is more robust because identifiers are never subjected to lossy summarization. The cost is slightly more prompt engineering for the extraction step, but the payoff is eliminating an entire class of 'wrong name' errors that are extremely hard to debug.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-18T15:45:23.868058+00:00— report_created — created