

# Feedback loop

An Agent Context improves from how your agents use it. Trace analysis learns from records of that use, called *traces*, and proposes the reusable knowledge that it finds as changesets. These learnings from the feedback loop flow back into your Agent Context according to your curation policies. Your agents then retrieve the improved context, and their next traces continue the loop.

**Note**  
The feedback loop is in Public Preview.

The loop runs for an Agent Context after you turn on trace analysis for it (see [Turn on trace analysis](feedback-turn-on.md)). It has four steps:

1.  **Use** – Your agents query the Agent Context to complete their tasks.

1.  **Trace** – Each agent session produces traces. A trace records the steps of the session, such as the questions the agent received, the tools it called, and the context it retrieved.

1.  **Analyze** – Trace analysis reads the traces and extracts reusable knowledge from them, such as skills.

1.  **Write back** – AWS Context proposes these learnings as changesets. Your curation policies apply each changeset to the Agent Context or hold it for review (see [Review proposals and quality signals](review-proposals.md)). The default curation policy holds them for review. On the **Curation** tab, the changesets show **Trace analysis** under **Generated by**. After a learning is published, the agents and users who can read it retrieve it in their next queries.

Trace analysis learns from two sources of traces: the agents built into AWS Context, and your own agents. For more information, see [Trace sources](feedback-trace-sources.md).

For more information about sessions, when an analysis runs, and how trace analysis evaluates learnings, see [How trace analysis works](feedback-how-it-works.md). For more information about how long AWS Context keeps traces, see [Data retention for traces](data-protection.md#data-protection-traces).

**Topics**
+ [Turn on trace analysis](feedback-turn-on.md)
+ [Trace analysis role](trace-analysis-role.md)
+ [Trace sources](feedback-trace-sources.md)
+ [How trace analysis works](feedback-how-it-works.md)
+ [Who can see learnings from your traces](feedback-visibility.md)