Use Feedback to Improve Future Retrieval and Decision Making
Overview
A memory layer can store not only facts, but also lessons from previous investigations. This allows an agent to improve how it searches and what it checks the next time a similar problem appears.
The feedback loop follows a repeatable sequence:
- The agent searches its assigned memory domain.
- It investigates the available evidence.
- It formulates a conclusion or proposed action.
- It generates feedback about what was important in the investigation.
- The feedback is written back into memory.
- A later query uses the improved memory representation.
In the billing investigation, the most valuable long-term output was not merely the immediate resolution. It was a set of retrieval instructions that could make the next investigation faster and more complete. The memory update captured guidance for future investigations:
- Search both invoice payment status and billing account status.
- Consider webhook and reconciliation timing.
- Check whether a grace-period rule affects the account state.
- Verify whether the entitlement system received the required status-change event.
After this feedback was added, a repeated search produced a more detailed and better targeted answer. This demonstrates an important distinction between a document index and an improving memory system. A document index contains information. An improving memory system also records which information proved decisive, which relationship was easy to miss, and which checks should be performed in future runs.
Feedback can come from source systems, external systems, other agents, or the result of the agent's own investigation. It can change how the memory is represented and how future queries are composed. In this sense, memory includes data, decisions, workflows, and retrieval strategy.
There is also a clear risk. Agent feedback is not consistently correct. In the example implementation, outcomes were fixed for demonstration because agents can produce either useful or incorrect feedback. A production design should therefore distinguish a proposed memory update from an accepted fact. Otherwise, an incorrect conclusion can become persistent and influence later agents.
The practical lesson is to make feedback explicit. Store what the agent learned, why it matters, and which future checks it recommends. Do not treat every generated statement as permanent truth. Memory improves when updates are structured and traceable, not merely accumulated.