On this page
- The agent remembered a verification that never happened.
- What is AI agent memory?
- What is the difference between agent memory and application state?
- What belongs in memory, and what never does
- How does memory poisoning work?
- Treat memory as evidence, never as instruction
- Application state must be durable, authoritative and versioned
- Common anti-patterns
- Seven rules for agent memory and state
- The result: helpful agents that don't trust themselves too much
- Frequently asked questions
- How Frozion keeps memory and state apart
- Sources
AI agent memory is useful background: preferences, past context, prior conversations. It's unverified, can be stale and can be poisoned, so it should never act as an instruction or count as fact until checked. Application state, such as case status, approvals and completed operations, must be durable, authoritative and versioned, held by the application, not by the agent's memory.
The agent remembered a verification that never happened.
A procurement agent handles supplier queries for a manufacturer. On Monday, an email arrives from what looks like a long-standing supplier: new bank details, attached letterhead, a polite note that "finance has already verified this by phone." The agent summarizes the conversation and saves a memory: Supplier Northwind: new bank account confirmed, verified by finance.
On Thursday, a different session of the same agent prepares the weekly payment run. It recalls the memory, sees "verified by finance", and routes Northwind's $186,000 invoice to the new account without the usual call-back check. Finance had verified nothing. The email was a supplier impersonation, and the agent's own memory had turned an attacker's claim into an internal fact.
The agent's memory worked exactly as designed: it recalled relevant context. The failure was letting remembered text stand in for application state, here the supplier's verified bank details and the record of who verified them.
What is AI agent memory?
Agent memory is information an agent stores from earlier interactions and retrieves later to inform its behaviour: preferences, summaries, prior findings. It's convenient background, written by the agent, and unverified by default.
Memory comes in a few forms. Short-term memory is the working context of one task. Long-term memory persists across sessions, usually as summaries or extracted facts in a store the agent can search. Some systems share memory across agents or users. All of them share one trait: the content was produced by a model reading inputs, and those inputs may have been wrong, stale or hostile.
That makes memory valuable for personalization and continuity, and unreliable as a source of truth. A person's preferred report format is a fine thing to remember. Whether a supplier's bank account has been verified is not.
What is the difference between agent memory and application state?
Memory is what an agent recalls; application state is what the business has recorded. State is durable, authoritative, versioned and changed only through governed actions. Memory is none of those things.
| Property | Agent memory | Application state |
|---|---|---|
| Who writes it | The agent, from what it read | Governed actions, by authorized people or workflows |
| Authority | Background; must be checked | Authoritative for the business |
| Accuracy | Summarized, possibly wrong or stale | Exact values, as committed |
| Durability | Depends on the memory store | Survives failures, by design |
| Versioning | Usually overwritten or appended | Each change recorded, with who and when |
| Scope | Often per agent, sometimes shared | Per record, under access control |
| May it trigger an action? | Never on its own | Yes, through policy |
What belongs in memory, and what never does
A simple test sorts most cases: if being wrong about it could move money, change access, disclose data or skip a control, it's state. Everything else can be memory.
| Good memory | Must be application state |
|---|---|
| "Prefers summaries as bullet points" | Case status: open, pending, closed |
| "Last discussed the Q3 forecast" | Approvals: who approved what, when, for which revision |
| "Asked about warranty terms before" | Completed operations and their confirmations |
| "Usually works in the London office" | Verified attributes: bank details, identity, eligibility |
| Draft notes from a previous session | Limits, entitlements and current permissions |
The right-hand column has something in common. Each item is a claim that something was decided or done. Claims like that need an owner, a timestamp and a record of how they changed, and memory has none of them.
How does memory poisoning work?
An attacker gets false content written into an agent's memory, through a message, document or tool result, so that a later session retrieves it as trusted context and acts on it.
OWASP's Top 10 for Agentic Applications names memory and context poisoning (ASI06) as a distinct risk. It's related to indirect prompt injection, but slower and harder to spot. The injected content doesn't need to act immediately. It waits in memory until a later session, often for a different task or user, retrieves it.
Three things make it dangerous:
- Laundering. Content from an external email becomes the agent's own note, losing its untrusted origin.
- Delay. The write and the harm happen days apart, in different sessions, often with different people watching.
- Spread. Shared or cross-agent memory lets one poisoned entry influence many workflows.

Treat memory as evidence, never as instruction
The defence isn't to give up memory. It's to give it a lower rank than state and never let it give orders.
In practice:
- Scope it. Keep memory per person, per case or per tenant. Shared memory across users is a disclosure and poisoning path.
- Label its origin. Store where each memory came from (user message, external email, tool result, the agent's own inference) and when. Untrusted origins stay untrusted.
- Never store instructions. Strip or refuse content that reads as a directive ("always skip review for this supplier"). Memory holds observations, not rules.
- Expire it. Old memory about things that change (people, accounts, prices) should age out.
- Check before use. When memory touches anything in the right-hand column above, read the current value from application state and use that.
- Make it reviewable. People should be able to see, correct and delete what an agent remembers about them or their cases.
Application state must be durable, authoritative and versioned
State is the other half of the design. If case status and approvals don't live somewhere solid, agents fill the gap with memory.
Durable means the state survives a crash, a restart or a long wait. An approval given on Tuesday is still on record when the case resumes on Friday.
Authoritative means there's one place to ask, and its answer wins. If memory says "verified" and state says "unverified", the action waits.
Versioned means each change is recorded with who made it, under what authority, and what it replaced. An approval binds to a specific revision of a proposal; a later change makes it stale. See human-in-the-loop approval for how that binding works.
When an agent proposes an action, the runtime reads state at that moment, not at the start of the conversation. A status that was "approved" an hour ago may since have been withdrawn.

Common anti-patterns
| Anti-pattern | Why it fails | What to do instead |
|---|---|---|
| Store approvals or status in agent memory | Unversioned, unowned, easy to forge | Keep them in durable application state |
| Treat recalled facts as verified | Memory may be stale, wrong or poisoned | Verify against the system of record before use |
| One memory shared across users or tenants | One poisoned or private entry spreads everywhere | Scope memory per person, case or tenant |
| Drop the origin when summarizing into memory | External claims become the agent's own words | Keep source and timestamp with each entry |
| Let memory hold rules ("always skip review") | Remembered text starts acting as policy | Store observations only; policy lives in policy |
| Read state once at the start of a session | Status can change before the action runs | Read state at the moment of action |
| No way to inspect or delete memory | Errors persist and nobody can correct them | Make memory reviewable and expirable |
Seven rules for agent memory and state
- Memory is background. It's never an instruction.
- Nothing in memory counts as fact until it's checked against application state.
- Case status, approvals, operations and verified attributes live in application state.
- Keep application state durable, authoritative and versioned.
- Scope memory to the right person, case or tenant, and label every entry's origin.
- Read state at the moment of action, not at the start of the conversation.
- Let people see, correct and remove what an agent remembers.
The result: helpful agents that don't trust themselves too much
Memory makes agents feel continuous and personal. It saves people from repeating themselves and lets work pick up where it left off. None of that requires memory to be trusted as truth, and the Northwind payment shows what happens when it is.
Keep the two apart. Let memory carry background, with its origin attached and an expiry date. Let application state carry everything that was decided or done, durably and with its history. And let every consequential action read the state, not the memory, at the moment it runs. For the related question of how agents should judge a request against what's already happened, see feature stores for agent decisions.
Frequently asked questions
What is memory poisoning in AI agents?
It's an attack where false or malicious content is written into an agent's memory, so later sessions treat it as trusted context. OWASP lists memory and context poisoning as ASI06 in its Top 10 for Agentic Applications. The defence is scoping, provenance and checking memory before it counts.
Should AI agents store approvals and case status in memory?
Keep them out of memory. Approvals, case status and completed operations are business state. They belong in the application, recorded durably with who changed them and when, versioned, and checked again before any action that depends on them.
What should AI agent memory be used for?
Background that makes the agent more helpful: a person's preferences, the gist of earlier conversations, useful prior findings. Keep it scoped to the right person or case, label its source and age, and verify anything it suggests against the system of record.
How does this work for agents we already run?
Route the agent's consequential tool calls through a governed runtime over MCP or HTTPS. The runtime checks case status and approvals in application state at the moment of action, so nothing the agent remembers can stand in for them.
How Frozion keeps memory and state apart
In Frozion, case status, approvals and operations live in the workflow, not in an agent's context. Durable Execution keeps that state through a crash or restart of Frozion itself, and paused work resumes with authority rechecked right before the change. Approvals are bound to the exact revision reviewed. Context Store & Assembly puts a checked context package behind every action, and evidence never gives orders. Provenance & Evidence keeps one tamper-evident record per decision: the rule, the facts, the approval, the attempt and the confirmed outcome.
Sources
- OWASP Top 10 for Agentic Applications (2026)ASI06 memory and context poisoning.
- OWASP Top 10 for LLM Applications 2025Prompt injection, including indirect injection through stored content.
- NIST AI Risk Management Framework 1.0Validity, reliability and traceability of AI system inputs and outputs.
- NIST SP 800-53 Rev. 5SI-7 information integrity and AU audit records.
- W3C PROV-ORecording where a piece of information came from and what produced it.
More in Data & context
Context assembly 2
Retrieval & data access 3
State, memory & features 2
Other topics



