> ## Documentation Index
> Fetch the complete documentation index at: https://agent-memory.dev/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Provenance

> Where every record came from

Every observation and memory carries an immutable origin block stamped at write time:

```json theme={"dark"}
{ "channel": "tool", "detail": "Bash", "capturedAt": "2026-08-15T12:00:00Z" }
```

Channels: `user` (typed by the user), `agent` (the agent runtime), `tool` (returned by a tool), `import` (transcripts and exports), `shared` (another agent).

Derived records inherit their source origin through compression, so content can always answer where it entered the system. This is the base for trust-aware retrieval: tool and import channels are exactly where untrusted content arrives.

## Per-agent scoping

Saves accept an `agentId`; recall filters by it across search, smart-search, and MCP. With `AGENTMEMORY_AGENT_SCOPE=isolated` the API refuses cross-agent reads rather than silently widening.
