← Back to Blog
Best Practices

What Should an AI Remember - and What Should It Forget?

Nexus Team September 4, 2026 8 min read

Persistent memory is useful because an AI can carry context forward. Unselective memory is dangerous for the same reason.

If a system stores everything, it accumulates noise, contradictions, sensitive information, and instructions that were never meant to become permanent. If it stores too little, every session starts with the same explanations.

The goal is not maximum retention. It is useful, controlled continuity.

A simple test for every memory

Before preserving something, ask:

  1. Will this likely affect future work?
  2. Is it stable enough to remain useful?
  3. Can the user reasonably expect it to be retained?
  4. Is memory the right system of record?
  5. Can it be corrected or deleted later?

If the answer to several of those questions is no, the information probably belongs only in the current context window.

What is usually worth remembering

Decisions and rationale

The most valuable project memories often follow this pattern:

We chose X because of Y, after rejecting Z for reason Q.

The choice alone helps. The rationale prevents the next agent or teammate from reopening the same debate without new evidence.

Good examples:

  • Use PostgreSQL because the workflow requires relational constraints and transactions
  • Keep the legacy endpoint until mobile version 4.2 reaches the adoption threshold
  • Use browser-based OAuth instead of distributing permanent API keys

Durable preferences

Preferences reduce repetitive correction when they are stable and genuinely affect the response.

Examples:

  • Prefer TypeScript for new services
  • Start answers at the point and avoid long introductions
  • Use dry-run mode before executing a production data change

Avoid converting every situational choice into a permanent preference. “Use Python for this script” does not necessarily mean “Always use Python.”

Important outcomes and failures

A result is worth remembering when it changes what should happen next time.

  • A migration failed because of a lock timeout
  • A particular API rejects duplicate idempotency keys after 24 hours
  • A deployment succeeded only after a cache was invalidated

Store enough context to make the lesson reusable: project, conditions, approach, outcome, and any follow-up decision.

Relationships and ownership

Knowing that a person owns a service or that one project depends on another can make future assistance much more relevant.

These facts change, so they should be updateable and ideally tied to a source or timestamp.

Reusable procedures

Memory can point an agent toward a release checklist, investigation pattern, or handoff process. If the procedure must be enforced, put it in automation or authoritative documentation too.

The distinction between facts, events, and procedures is explored in Semantic vs. Episodic vs. Procedural Memory for AI Agents.

What usually should not be remembered

Secrets

Passwords, API keys, private keys, access tokens, recovery codes, and raw credentials do not belong in conversational memory.

Use a secrets manager. A memory system can remember where an approved secret is managed, but not the secret itself.

Momentary conversation mechanics

“Yes,” “try again,” partial drafts, tool chatter, and acknowledgements rarely help a future session. Saving them increases the retrieval surface without adding meaning.

Unconfirmed speculation

Early hypotheses should not become durable facts merely because they appeared in a confident sentence.

If a theory is worth preserving, label it accurately:

Hypothesis: the timeout may be caused by connection pool exhaustion. Not yet verified.

Even better, wait for the outcome and store the resolved episode.

Data that belongs in an authoritative system

Memory should not replace source control, ticketing, contracts, customer records, or policy repositories.

It can remember that a particular issue resolved a specific entitlement bug, and link to it. The issue itself remains authoritative.

Sensitive information without a clear purpose

Personal, health, financial, legal, or employment information deserves a higher retention threshold. “It may be useful someday” is not enough.

Collect less, explain why, restrict access, and give the user meaningful control.

Remembering is not binary

A memory can have more states than kept or deleted.

Active

Current and eligible for ordinary recall.

Superseded

Preserved for historical explanation but no longer treated as the current fact.

We previously used provider A. The current provider is B as of August 2026.

Expiring

Useful for a defined period, then automatically removed or downgraded.

Examples include temporary workarounds, incident coordination details, and short-lived project assignments.

Archived

Available through deliberate search but not injected into routine prompts.

Deleted

Removed from active storage and derived indexes according to the system’s deletion policy.

This richer lifecycle reduces a common failure: returning an old decision alongside its replacement without indicating which one is current.

The importance of provenance

A memory is easier to trust when the system can answer:

  • Who or what created it?
  • When was it created?
  • Which project or conversation did it come from?
  • Was it a user statement, an inferred summary, or a tool result?
  • Has it been updated or superseded?

Provenance lets an agent weigh evidence. A current architecture document should generally outrank an old conversational guess. An explicit user correction should outrank an inference.

Automatic capture needs stronger filters

Manual storage benefits from user intent: someone chose to remember the item.

Automatic capture is more convenient but requires careful selection. A good automatic system should favor:

  • Final decisions over brainstorming
  • Outcomes over raw process
  • Specific facts over vague summaries
  • User corrections over earlier assumptions
  • Durable context over temporary state

It should also provide an incognito or “do not remember this” path for work that should remain ephemeral.

Team memory raises the stakes

A private memory affects one person’s future sessions. A shared memory can affect an entire team.

Before promoting something to shared visibility, consider:

  • Is it verified?
  • Is the author authorized to establish it for the team?
  • Does it contain private or customer-specific information?
  • Is there an authoritative source to link?
  • Who owns keeping it current?

Shared context can accelerate onboarding and handoffs, but only if the team can trust it. See Shared Context for AI Coding Teams for the broader workflow.

A practical retention template

When storing an important memory, capture:

Decision or fact:
Why it matters:
Project or scope:
Source:
Date:
Review or expiry date, if any:
What it supersedes:

Not every field must be visible to the user, but the system should preserve enough structure to support correction and retrieval.

Forgetting is a feature

Useful intelligence depends on exclusion. An agent needs the right five memories more than it needs access to fifty thousand undifferentiated messages.

Forgetting can mean deletion, expiry, supersession, lower retrieval priority, or moving an item out of automatic recall. Each mechanism keeps the active memory set aligned with reality.

The quality of a memory layer is not measured by how much it retains. It is measured by whether the right context appears, the wrong context stays out, and the user remains in control.

Build a memory system you can correct

Start your 14-day Nexus-Catalyst trial to test persistent context designed around recall, ownership, and user-controlled memory lifecycle.