Skip to content

sxnzs/amnesiac-agents

v1.0.0MIT

One agent setup for Claude Code, Codex, OpenCode, Pi, Gemini/Antigravity, and Cursor: skills, guards, and adapters from a single source of truth.

Amnesiac Agents

verify

One setup for Claude Code, Codex, OpenCode, Pi, Gemini/Antigravity, and Cursor, built on the single-loop pattern: one model, one context, skills and tools that load on demand, hard limits in the harness, and a subagent only when it earns its place.

You edit one place (~/agent-kit). Every host reads it through symlinks.

What you get:

  • One instruction file (AGENTS.md) shared by every host.
  • 24 skills that load on demand, split into user-invoked workflows and model-invoked helpers.
  • A guard (guard/policy.json) that blocks destructive commands and asks before commits, pushes, publishes, deploys, and sends, with the same rules on every host.
  • A fresh-context verifier subagent per host, for black box checks of finished work.

Requirements: macOS or Linux, bash, python3, git, and jq for the Claude Code stop hook. node is optional and only enables the guard parity test.

Install

Recommended: clone + install.sh (all hosts, guards, and adapters)

git clone https://github.com/sxnzs/amnesiac-agents.git ~/agent-kit
cd ~/agent-kit
./install.sh --dry-run              # preview what will change
./install.sh                        # install for every host detected on this machine

Options:

./install.sh --all                  # wire up all five installer hosts even if not installed yet
./install.sh --only=claude,gemini   # target specific hosts (claude,codex,opencode,pi,gemini)
./install.sh --uninstall            # remove links and merged config entries

Existing files are moved to *.bak.<timestamp>. JSON configs are merged and your values win. Codex config.toml is created only if missing. A ~/.claude/CLAUDE.md you wrote yourself is kept and only gains one import line.

Read AGENTS.md and adapters/claude/CLAUDE.md before you install: they are opinionated. The Claude Code rules tell it to commit and push each working, tested change as it goes.

After install: open Codex once and approve the hook in /hooks, then restart any running agent.

To update on any machine:

cd ~/agent-kit && git pull && ./install.sh

Alternative: native plugin install (skills + agents only)

In Claude Code:

/plugin marketplace add sxnzs/amnesiac-agents
/plugin install amnesiac-agents@amnesiac-agents

In Cursor, clone into the local plugins folder and restart Cursor (it skips symlinks that point outside that folder). This path follows Cursor's plugin docs and the manifest validates, but it has not been tested in Cursor yet:

git clone https://github.com/sxnzs/amnesiac-agents.git ~/.cursor/plugins/local/amnesiac-agents

Native plugin install gives you the skills and the verifier subagent. Use ./install.sh when you also want the shared AGENTS.md, guard/policy.json hooks, bin/cm code-mode helper, and Codex/OpenCode/Pi/Gemini wiring. The writing and jev-search skills call their scripts under ~/.agents/skills/, so those two need ./install.sh.

Get started

Two steps:

  1. Run /ask-kit whenever you are unsure which skill fits. It is the only command you need to remember.
  2. Invoke a workflow skill directly when you know the stage (e.g. /spec-build, /prewalk, /ship, /retro), or let the model-invoked skills (debug, design, diff-review, verify-artifacts, etc.) load on demand.

New here? Read the getting-started guide or the per-host notes.

Usage

Skills are split into user-invoked (trigger explicitly: /name in Claude Code or OpenCode, /skill:name in Pi, $name in Codex) and model-invoked (loaded automatically when relevant).

/ask-kit I want to refactor this module and add deterministic checks so the same bugs stop coming back
/spec-build turn the decisions in our thread into a local spec and vertical TDD slices
/ship

User-invoked skills (13)

SkillBucketPurpose
agent-setupengineeringOnboard a repository for agents and fix recurring session failures without a full rewrite.
ambition-amplifierproductivityPush a task higher on Altitude, Depth, and Range using real tools, raw data, and an outside judge.
ask-kitproductivityMap every skill by workflow stage so you only need to remember one name.
bonsaiengineeringRefactor a whole repo in five gated phases so boundaries, bans, and checks live in tools instead of prose.
fold-subagentengineeringFold an unnecessary subagent, router, or specialist into skills and tools in the main loop.
handoffproductivityDelegate primary-source research, write cross-session handoffs, and script human-only setup wizards.
harness-auditengineeringAudit local agent CLI and desktop setups using raw session telemetry, hook benchmarks, and a fresh red team check.
nextproductivityRead the current state of the work and recommend one concrete next step.
prewalkproductivityLand the first real slice or opening section and hand off the live trajectory and check gate to a fast worker.
retroengineeringRun a session retrospective and promote repeated corrections downward into deterministic checks.
shipengineeringCommit and push finished work cleanly across every touched repository.
spec-buildengineeringTurn settled decisions into local specs, wayfinding maps, and vertical TDD slices.
teachproductivityTeach a concept and build lasting understanding through guided practice.

Model-invoked skills (11)

SkillBucketPurpose
agent-architectureengineeringDesign, review, or simplify an AI agent or harness.
debugengineeringDiagnose hard bugs or performance regressions and resolve git merge or rebase conflicts.
designengineeringArchitect deep modules, maintain domain models (CONTEXT.md and docs/adr/), and build throwaway prototypes.
diff-reviewengineeringVerification-artifact-first code review and concise PR summaries.
explain-codeproductivityGive the reader a working mental model of code and the evidence behind why it was built that way.
grillproductivityInterview the user relentlessly until every branch of the design tree is settled.
jev-searchproductivitySearch the web where result relevance matters, ranked by TypeSafe Jev.
skill-hygieneengineeringCreate, audit, deduplicate, or prune skills, tool descriptions, and system prompts.
ui-designengineeringDesign flows, states, and interactions with prototypes, set concrete visual tokens (type, color, theme), and tune animation and gesture physics by observed behavior.
verify-artifactsengineeringProduce Layer 3 runtime, browser, CLI, and visual verification artifacts, or done-check claimed work.
writingproductivityWriting workflow from raw fragments through grounded beats to shaped prose.

Skills live in three buckets: engineering, productivity, and skills/in-progress/ (beta, skipped by install.sh).

What goes where across hosts

PrimitiveSource in kitClaude CodeCodexOpenCodePiGemini / Antigravity
Global instructionsAGENTS.md~/.claude/CLAUDE.md imports ~/.agents/AGENTS.md~/.codex/AGENTS.mdopencode.json instructions, else ~/.config/opencode/AGENTS.md~/.pi/agent/AGENTS.mdnot wired
Skillsskills/<bucket>/*~/.claude/skills/*~/.agents/skills/*~/.agents/skills/*~/.agents/skills/*~/.gemini/config/skills -> ~/.agents/skills
Deny gateguard/policy.jsonhook runs guard.pyhook runs guard.pyplugin uses core.mjsextension uses core.mjsnot wired
Ask gateguard/policy.jsonsame hook (ask)~/.codex/rules/agent-kit.rulesplugin permission hook (ask) + opencode.jsonextension confirm dialognot wired
Verifier subagentadapters/*~/.claude/agents/verifier.md~/.codex/agents/verifier.toml~/.config/opencode/agents/verifier.md/verify runs a fresh pi -pnot wired
Code modeharness nativeCLAUDE_CODE_EXPERIMENTAL_CODE_MODE=1features.code_mode = trueMCP & plugin tools in executecodemode.mode = "only"not wired

Not shipped here

A few things live outside this repo on purpose:

  • Machine- or project-specific skills: keep them in your own repo and symlink them into ~/.agents/skills/ next to the kit's.
  • MCP server configs stay per host because config formats differ; keep each host under ~30 loaded tool definitions.
  • Project-level instructions: copy AGENTS.md into a repo root and put repo-local skills in .agents/skills/ (with .claude/skills/ symlinked if needed).

Guard & tools

The guard is a seatbelt, not a sandbox: it pattern-matches tool calls to catch an agent's honest mistakes, and it will not stop a determined attacker. Keep your host's own sandbox and permission settings on.

Every guard refusal names the rule in guard/policy.json and states the way forward. Do not work around a rule or edit guard/ without asking the user. Code mode scripts are scanned as shell text while string values of data keys (content, oldText, text, body, message, summary, prompt, markdown) are treated as prose.

Tools in bin/

  • cm: per-session code-mode helper (see CODEMODE.md).
  • git-stop-warn.sh (Claude Stop): one line when the repo is dirty or has unpushed commits; never blocks.
  • milestone-run.sh <plan-file> --check '<cmd>': one headless Claude stage that runs the check and commits on a clean tree.

Make it yours

See SCOPE.md: skills change only for a failure observed in a real session.

Private overlay. AGENTS.md here holds only rules that fit anyone. Put your own version at ~/.config/agent-kit/AGENTS.md (start from a copy) and ./install.sh links every host to it instead, so machine names, paths, and personal rules never enter the repo. ~/.config/agent-kit/CLAUDE.md does the same for the Claude Code rules. Set AGENT_KIT_LOCAL to use another folder.

  1. New skill: add a folder under skills/<bucket>/<name>/ with SKILL.md and agents/openai.yaml, list it in the bucket README.md, the top README.md and ask-kit, run python3 scripts/sync_listings.py and ./scripts/verify, then run ./install.sh.
  2. New hard rule: add a regex to guard/policy.json (and mirror ask rules in adapters/codex/rules/agent-kit.rules), add a test case to CASES in guard/guard.py, and run ./guard/check.sh.
  3. New global instruction: only add to AGENTS.md if it is true for every task; otherwise make it a skill.
  4. Verify before pushing: ./scripts/verify runs guard checks, skill validation, unit tests, prose linting, and shellcheck.

Contributions: see CONTRIBUTING.md.

License

MIT