agentpack
Agentpack is a repo-native task continuity server for AI coding agents, enabling durable state recording and retrieval across sessions, clients, and context resets.
Context & Resumption
load_context— Load compact task context (Task Passport, decisions, sources, checkpoints) at session startresume— Generate a budgeted markdown resume of task statereplay— Replay the full task timelinediff— Compare two checkpoints to see what changed
Recording Durable State
record_decision— Record a decision made during the task, with optional file references and evidencerecord_dead_end— Record a failed approach so future agents avoid repeating itattach_evidence— Attach evidence such as test output, command output, notes, or linksrecord_source— Cache a reviewed source file with its hash and conclusion to avoid re-reading unchanged filescheckpoint— Create a named checkpoint with status, summary, and next actions
Task Passport Lifecycle
task_start— Create a new Task Passport with title, objective, constraints, scope, risk, and next actionstask_status— Print a quick summary of the current Task Passporttask_update— Update objective, constraints, scope, next actions, tags, or risktask_update_verification— Update verification status, summary, and evidence referencestask_finalize— Close the current task with a final verification statustask_park/task_switch— Park the active task and switch between open taskstask_list— List all Task Passports with statuses and branchestask_handoff— Generate a compact handoff summary for switching chats, clients, or agentstask_role— Read or update guidance for a specific role lane (scout, builder, reviewer, archivist)
Auditing & Health Checks
task_audit— Audit the current Task Passport for continuity risks (stale sources, drift, missing next actions)source_status— Check whether recorded source file conclusions are still valid, changed, or missingrelease_preflight— Run a read-only release preflight report
Bundle Import/Export (Portable Handoffs)
bundle_export— Export a redacted, structured task bundle JSONbundle_inspect— Validate and summarize a bundle without writing statebundle_import_plan— Preview what a bundle import would do without applying changesbundle_import— Import a task bundle (applied only whenwrite: trueis set)
Agentpack
Repo-native task continuity for AI coding agents.
Coding agents forget. Agentpack gives them the task state they need to continue.
Here it is live. Session 1: Claude Code investigates a flaky test and records what it learns through the Agentpack MCP tools. Session 2, next day, empty context: the agent loads the task state and picks up exactly where the first session stopped — no re-investigation:

Prefer to poke at it by hand? The same flow driven from the CLI is in docs/DEMOS.md.
Every session ends the same way: the context window gets compacted, the chat closes, the task waits until tomorrow. The next session starts from zero — re-reading files, rediscovering decisions, retrying approaches that already failed.
Agentpack keeps a small, reviewable task ledger in .agentpack/ inside your repo. Connected agents record durable state as they work — the goal, decisions, dead ends, verification evidence, checkpoints — and the next session loads it back and continues. That next session can be the same agent after compaction, a different client, or you returning next week.
Local-first. Plain files in your repo. No cloud, no telemetry, no network calls.
Agent-oriented. A local MCP server plus generated project instructions (
AGENTS.md,CLAUDE.md, Cursor rules) tell agents when to load and record state.Human-friendly. The same state is available through the CLI for inspection, debugging, and manual handoff.
Quick start
Requires Node.js >= 20.
npm install -g agentpack-cli
cd path/to/your/repo
agentpack init # once per repo
agentpack install claude --write # per client: codex | claude | cursor | claude-desktopRestart or reconnect the coding-agent client. From then on the agent loads Agentpack context at session start, records durable decisions, sources, and evidence while working, and checkpoints meaningful progress.
Run agentpack doctor to verify the setup, and agentpack resume --preset agent --query "<topic>" to inspect the task state yourself.
See docs/INTEGRATIONS.md for client-by-client setup, including what each installer writes and why.
Related MCP server: MCP Server Boilerplate
How it works
At session start, the agent loads compact Agentpack context: the current Task Passport, recent checkpoints, decisions, and reviewed source conclusions.
While working, it records durable state — decisions worth keeping, approaches that failed, verification evidence — and caches reviewed source conclusions with file hashes so unchanged files don't need re-reading.
At a coherent boundary, it creates a checkpoint with status, next actions, and git state.
The next session — any MCP-connected agent — continues from that state instead of rebuilding it from chat history.
The ledger is task-scoped: a Task Passport carries the goal, status, constraints, write scope, next actions, and verification for the current task, with an explicit lifecycle (start, park, switch, finalize) for handoffs. An optional task gate (native Claude Code, Codex, and Cursor hooks plus a client-neutral pre-commit hook) warns — or in block mode, stops — when edits bypass the active task.
Context is budgeted: resume output is compressed under a rough token estimate, so agents get the useful state back, not a pile of history.
When it helps
The context window is compacted mid-task and the next turn needs the state back.
You start a fresh chat or session on an ongoing task.
You switch between Claude Code, Cursor, Codex, or another MCP client.
You return to a refactor or bugfix days later.
Another agent — or a teammate's agent — continues from your checkpoint.
You split one session across parts of a monorepo (
api/,frontend/,cron/) with short scoped tasks, and the task gate keeps the agent from drifting outside the folder the current task owns.
A side effect: agents spend fewer tokens re-reading unchanged files and re-explaining old decisions.
Security posture
Zero runtime dependencies, exact dev dependencies, committed lockfile,
ignore-scripts=true.No telemetry and no network calls during normal CLI or MCP operation.
Best-effort redaction of secret-looking values in stored context and handoff output.
Releases are published from GitHub Actions with npm provenance (Trusted Publisher, no long-lived tokens); verify with
npm audit signatures.
See SECURITY.md for the full policy.
Documentation
docs/INTEGRATIONS.md — safe setup for Codex, Claude Code, Cursor, Claude Desktop, and git hooks
docs/CLI.md — full CLI reference, budgets, and manual fallback workflows
docs/MCP.md — the MCP server contract and tool list
docs/TASK-PASSPORT.md — task lifecycle, handoffs, and portable bundles
docs/DEMOS.md — compact continuity demos you can run yourself
docs/VISION.md — the strategic north star
Contributing / local development
Clone the repo and use Node 20+:
npm ci --ignore-scripts
npm test
npm run mcp:smoke
node dist/src/agentpack.js --helpThis repo uses Agentpack on itself through MCP — docs/DOGFOOD.md describes the working protocol, docs/SETUP.md the full setup, and docs/RELEASING.md the release process.
Mirror: Codeberg. Issues, releases, and npm provenance stay on GitHub.
Maintenance
Latest Blog Posts
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/ihorponom/agentpack'
If you have feedback or need assistance with the MCP directory API, please join our Discord server