AGENTS.md for committed project knowledge and .agents.local.md for your personal scratchpad.
Choose your install method
- Existing project
- New template project
- OpenClaw
Copy the Agent Context System files into a project you already have.The init command creates
1
Clone and copy the files
Run the following from your project root:This copies
AGENTS.md, the agent-context CLI, the agent_docs/ reference directory, and the scripts/ directory into your project root, then removes the temporary clone.2
Run init
.agents.local.md from the template, adds it to .gitignore, and asks which agent tools you use. It then creates the appropriate config file for each tool you select.3
Edit AGENTS.md
Open
AGENTS.md and replace the placeholder content with real information about your project: name, stack, commands, patterns, boundaries, and gotchas. This is the highest-leverage edit you will make.What init creates
After running./agent-context init, your project will contain the following files:
.agents.local.md is added to .gitignore automatically. It is personal and should not be committed.
Validate your setup
After init, run the following to confirm everything is wired up correctly:AGENTS.md exists and is under 120 lines, that .agents.local.md is gitignored, and that at least one agent tool config is present.
Other CLI commands
After setup
Once init completes:- Fill in
AGENTS.mdwith your actual project name, stack, commands, and the patterns and gotchas specific to your codebase. - Fill in
agent_docs/with deeper references your agent should load on demand — architecture decisions, full conventions, extended gotchas. Delete any sections that do not apply. - Customize
.agents.local.mdwith your personal preferences (planning style, code preferences, tone). - Work normally. Your agent reads
AGENTS.mdand.agents.local.mdat session start, does the task, and updates the scratchpad at session end. - Promote what sticks. When a pattern recurs across three or more sessions, the agent flags it in the scratchpad’s “Ready to Promote” section. You decide when to move it into
AGENTS.md.