A shopping assistant should remember a customer's size preferences across visits, but forget the details of each browsing session. What fits?
- Exam domain
- Agentic AI17% of the exam
- Difficulty
- Medium
- In this mock
- 9 questions on this domainPractise this domain
Why the exam asks this
Objective in the exam guide: Short-term and long-term agent memory, and when each is appropriate.
Memory and state decide how agents behave over time.
Why C is the answer
Short-term session memory plus a long-term preference store
Short-term memory holds the current conversation context. Long-term memory stores durable facts, such as preferences, and retrieves them in later sessions.
Remember: Short-term for the session, long-term for durable facts.
How it works
Stateless calls carry no memory. Stateful agents manage context per turn and keep long-term memory in external stores.
In detail
- Short-term: this session.
- Long-term: durable facts across sessions.
Every option, checked
Knowing why each wrong option fails is how you rule it out on exam day.
A. Store nothing so the agent stays statelessWrong
Stateless agents cannot remember preferences.
B. Fine-tune the model after each conversationWrong
Fine-tuning per conversation is slow and risky.
C. Short-term session memory plus a long-term preference storeRight
Short-term for the session, long-term for durable facts.
D. Put everything in the context window forever and let it grow with every message in every visitWrongMost tempting
Context windows are finite and costly.
Why it tempts: Long context windows seem to make memory free.
Use case
An illustrative scenario, not a real incident.
Illustrative: the assistant recalls "size M, prefers cotton" from a store keyed by customer ID.
See it in different ways
mindmap
root(("Memory"))
n1["Short-term"]
n2["Current conversation"]
n3["Scratchpad"]
n4["Long-term"]
n5["Preferences"]
n6["Past outcomes"]
n7["Context engineering"]
n8["What to include each turn"]How to read this chart
- The centre is "Memory".
- "Short-term" covers "Current conversation", "Scratchpad".
- "Long-term" covers "Preferences", "Past outcomes".
- "Context engineering" covers "What to include each turn".
sequenceDiagram participant P0 as User participant P1 as Agent participant P2 as Memory store P0->>P1: new visit P1->>P2: look up preferences P2-->>P1: size M, cotton P1-->>P0: tailored suggestions
How to read this chart
- 1. User sends "new visit" to Agent.
- 2. Agent sends "look up preferences" to Memory store.
- 3. Agent gets a reply from Memory store: "size M, cotton".
- 4. User gets a reply from Agent: "tailored suggestions".