# The agent's guide

This is the manual an agent (or the person who runs one) reads: how memprove is installed, how a repository is
enabled, what one Session does from `begin` to `end`, what the Context Pack says, how the Claude Code hook and the MCP
server work, how a Session another agent left is taken over, and how the record is corrected. `memprove --help` and
`memprove <command> --help` print the usage and exit codes of every command without a daemon; this guide says the
same as they do, and the tests hold the two together. `docs/architecture.md` says how it is built;
`docs/takeover-eval.md` says how the takeover is evaluated with a real client.

Terms. A **Project** is a Git repository the operator registered; a **Workspace** is one of its worktrees. A **Task**
is a unit of work; a **Session** is one agent's stretch of work on it, with a declared agent (name, role, parent
Session). A **run** (`memprove run`) records a command's result and seals a **Snapshot** of the repository state; a
**fact** cites runs as its **Evidence**. A **Checkpoint** records facts, open items, decisions and the one **next
action** in force. The **Capsule** is the Task's record as the daemon judges it now; the **Pack** is its rendering
within a budget. A fact's **verdict** is `verified`, `stale`, `unconfirmed` or `tampered`, by deterministic rules,
never by a model.

## Sections

- [Install, upgrade and backup](/docs/guide/install-upgrade-and-backup/)
- [Enabling memprove in a project](/docs/guide/enabling-memprove-in-a-project/)
- [Unattended takeover](/docs/guide/unattended-takeover/)
- [One Session, start to end](/docs/guide/one-session-start-to-end/)
- [Several runs in one state](/docs/guide/several-runs-in-one-state/)
- [When a test fails](/docs/guide/when-a-test-fails/)
- [Correcting the record: supersede, withdraw, reaffirm, decide](/docs/guide/correcting-the-record/)
- [A Session that was not ended](/docs/guide/a-session-that-was-not-ended/)
- [The Context Pack (resume --pack)](/docs/guide/the-context-pack/)
- [The SessionStart hook (memprove hook)](/docs/guide/the-sessionstart-hook/)
- [The MCP server (memprove mcp)](/docs/guide/the-mcp-server/)
- [Completing a Task](/docs/guide/completing-a-task/)
- [memprove run exit codes](/docs/guide/memprove-run-exit-codes/)
- [Exit codes of the other commands](/docs/guide/exit-codes-of-the-other-commands/)
- [Known limits](/docs/guide/known-limits/)
