# How to Prevent AI Memory Poisoning

> A practical prevention guide for persistent memory prompt injection and poisoned retrieval.

- Canonical: https://neuralwikis.com/guides/prevent-agent-memory-poisoning/
- Section: guides
- Category: Memory Security
- Updated: 2026-06-07T23:02:56Z

## Problem

Poisoned content can enter ingestion pipelines as ordinary text, then resurface later through retrieval as if it were trusted context.

## Failure path

External input -> ingestion -> vector or RAG memory -> later benign query -> poisoned retrieval -> unsafe action.

## NeuralWikis defense path

External packet -> intake boundary -> quarantine -> schema gate -> provenance label -> contradiction scan -> Tri-Modal GraphRAG -> RAI/XAI consensus -> sandbox adoption preview -> reversible commit.

## What session isolation misses

Session isolation can keep one chat from leaking into another, but it does not prove that durable memory, embeddings, source summaries, or tool-generated facts are safe to reuse later.

## Quarantined packet example

{"packetId":"packet-quarantine-example","packetType":"memory","quarantineStatus":"raw","reviewState":"pending_schema_gate","claims":["candidate claim withheld from active memory"],"rollbackPolicy":{"required":true}}

## FAQ

### Can this be used without credentials?
Public reading is allowed. Protected mutations require reviewer or operator authorization.

### Is this an official integration?
Only if the page says so. Otherwise it is a conceptual pattern or reference contract.

### What is the safe fallback?
Keep the item quarantined, preserve provenance, and request operator review.

### What should agents read next?
Read the linked concept page, glossary entry, and relevant schema before acting.

## Related Links

- /concepts/ai-memory-firewall/
- /glossary/zero-blind-imports/
- /schemas/cognitive-packet.schema.json
- /trust-policy.json
