Skip to main content

Agent Setup

cognitiveOS is agent-agnostic. init generates both CLAUDE.md and AGENTS.md (identical routing tables) plus an agent skill and a keeper subagent for whichever agents you pick, so your agent reads your context automatically. Nothing here is manual: the first wizard question is a multi-select of agents (all four ticked by default), and init writes the right files for each one you keep checked.

What each agent loads

AgentSkill / rule it loadsKeeper subagentSession hooks
Claude Code.claude/skills/cognitiveos/SKILL.md + slash hooks /start-session /end-session /dump.claude/agents/0xnull-the-keeper.mdSessionStart auto-loads STATE.md, ✅ Stop reminds you to save it
Codex CLI.codex/skills/cognitiveos/SKILL.md (+ AGENTS.md).codex/agents/0xnull-the-keeper.tomlnot yet
Antigravity.agents/skills/cognitiveos/SKILL.md (+ AGENTS.md).agents/agents/0xnull-the-keeper/agent.jsonPreInvocation auto-loads STATE.md
Cursor / Windsurf.cursor/rules/cognitiveos.mdc (+ AGENTS.md).cursor/agents/0xnull-the-keeper.mdn/a

Claude Code and Antigravity get the deterministic session hooks that load STATE.md with zero typing, and Claude Code alone gets the Stop-hook save reminder. Codex and Cursor load the skill and AGENTS.md, so they pick up context on read; the automatic hook for those is an open community target. See The Keeper for what the keeper subagent actually does.

The skill is the operating manual

The generated SKILL.md (or .mdc rule for Cursor) is what your agent triggers automatically. It carries the zone routing, the one-task and ADHD response rules, and a silent work loop: read state, take one action, update, re-read. It's why the agent behaves the same across every supported tool.

CLAUDE.md = AGENTS.md

The two routing files are byte-identical on purpose. cognitiveos check detects drift between them, and check --fix regenerates CLAUDE.md from AGENTS.md (the source of truth). --fix never touches STATE.md or your own content.

init never overwrites or deletes your files. Existing configs and skill files are kept and merged, not clobbered.

Project skill vs global skill

init writes a project skill, scoped to the project you ran it in. If you want /cognitiveos available before you've even scaffolded a project, run cognitiveos install-skill once per machine: it writes the same skill to your home agent-skill dirs (~/.claude, ~/.codex, ~/.agents), so any future project can invoke it directly. See Commands.

See also: Hooks · The Keeper · Getting Started.