Problem
Agents often write memories or update heuristics immediately after generating an answer. That creates weak learning signals:
- A plausible answer can be recorded as if it worked.
- Retrieved memories get credited even when the final action later fails.
- Human review, tests, production incidents, and real replies are disconnected from the memory records that influenced the action.
- Future agents cannot audit which past commitments were predictions, which were settled facts, and which were never verified.
The result is memory that compounds confidence faster than it compounds truth.
Solution
Add a commitment ledger between retrieval and memory updates.
- Before acting, record the goal, the retrieved memories or context IDs, the planned action, and the expected success condition.
- Execute the action normally: code change, email, research answer, deployment, ticket update, or tool call.
- Wait for a real outcome: passing tests, merged PR, user confirmation, incident resolution, benchmark result, support reply, or other external signal.
- Settle the commitment with a provenance tier and update memory credit only from that settlement.
commitment = ledger.open({
goal,
retrieved_ids,
planned_action,
success_condition
})
result = act(planned_action)
outcome = verifier.wait_for_signal(result, success_condition)
ledger.close(commitment.id, outcome)
memory.credit(
retrieved_ids,
reward=outcome.score,
provenance=outcome.provenance
)
Useful provenance tiers:
- self-graded: the agent believes it worked; weak prior only.
- runtime: a local tool, test, or evaluator produced a checkable result.
- external: the outside world answered, such as a merge, reply, production metric, or incident closure.
- owner: a responsible human explicitly accepted or rejected the result.
This separates "the agent predicted this would help" from "reality confirmed it helped."
How to use it
Use this when an agent repeatedly works in the same environment and later reality can verify whether the action helped.
Implementation checklist:
- Define the smallest commitment record that preserves auditability: goal, retrieved context IDs, planned action, and expected outcome.
- Make unsettled commitments first-class. Do not let them silently become validated memories.
- Use weak credit for self-grades and stronger credit for runtime, external, or owner-verified outcomes.
- Store negative outcomes too. Failed commitments are useful counterexamples when future tasks look semantically similar.
- Periodically summarize settled commitments into higher-level guidance, but keep links back to the original evidence.
Common applications:
- Coding agents that retrieve past fixes, then settle credit from tests, CI, review, or merge status.
- Research agents that cite prior notes, then settle credit from human acceptance or downstream reuse.
- Operations agents that propose mitigations, then settle credit from incident metrics or postmortems.
Trade-offs
Pros:
- Prevents unverified self-belief from becoming high-confidence memory.
- Creates an auditable chain from retrieved context to action to outcome.
- Makes failures reusable without erasing the evidence trail.
- Supports delayed learning when the real answer arrives minutes, days, or weeks later.
Cons:
- Requires durable storage for open commitments.
- Needs a verifier or human process that can map outcomes back to commitments.
- Adds latency to high-confidence learning because credit waits for settlement.
- Can overfit to easy-to-measure outcomes if qualitative review is never included.
References
- AccInt uses this pattern as an implementation example: https://github.com/maxbaluev/accreted-intelligence
- Reflexion: Language Agents with Verbal Reinforcement Learning: https://arxiv.org/abs/2303.11366
- SWE-bench: Can Language Models Resolve Real-World GitHub Issues?: https://arxiv.org/abs/2310.06770
- Google SRE Book, Postmortem Culture: https://sre.google/sre-book/postmortem-culture/