# Echo Recognition

> Detect when a user repeats themselves and treat it as emphasis or a re-ask — not a fresh independent input that deserves a near-duplicate reply.

- **Category**: Agentic AI
- **Subcategory**: Verification & Reflection
- **Canonical URL**: https://designpattern.fyi/patterns/echo_recognition/

---

## Description
**Intent**: Surface the user's underlying dissatisfaction with the prior reply instead of regurgitating the same answer.

**Context**: Your conversational agent talks with humans over many turns. Real users sometimes repeat themselves on purpose — the previous reply missed the point, they want to underline urgency, or they're worried the message didn't go through. Treating a repeat as fresh input produces a near-duplicate response that frustrates the user further.

**Solution**: Maintain a small ring of recent incoming messages with timestamps. On each new input, compute similarity to the recent ring (normalized exact match, high token overlap). On hit: surface the prior reply, ask 'what did I miss?' or 'I read this as emphasis — should I deepen X or pivot?'. Treat the pair (original + echo) as one reinforced turn, weighted higher in attention.


## Use Cases
- The agent receives messages from users who repeat themselves to emphasize or re-ask.
- Treating a repeat as fresh input would produce duplicate or near-duplicate replies.
- The agent has access to short-term history of the user's recent messages.





## Trade-offs


### Advantages

- Recognizes emphasis-by-repetition instead of ignoring the signal.

- Avoids redundant near-duplicate responses that frustrate users.

- Surfaces the user's underlying dissatisfaction with the prior reply.




### Considerations & Drawbacks

- False positives when the user genuinely meant to ask the same thing twice (different referents).

- Calling out the echo can feel passive-aggressive if phrased poorly.

- Threshold tuning is per-domain and requires empirical calibration.







---
**Reference**: [Original Source](https://www.agentpatternscatalog.org/patterns/echo-recognition/)

