agentleFS
ExploitaciousExploitacious/OPS/AGENTS.md

OPS

AGENTS.md0 starsChanged 13 days agoMITView on GitHub

This repo is a copy of OPS, the Claude Code harness published as the Exploitacious/OPS template: the context layer (CONTEXT/), the skills library (SKILLS/), the deployers and hooks (.claude-config/), the git-synced memory pools (.claude-memory/), handoff batons, and the projects it manages (PROJECTS/). In the Operator's private copy it holds their identity and work; in the public template it holds only generic mechanics. This file is about working in this repo. The rules that bind every session (role, lane contract, landing,…

  • Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about code style.

    Of the AGENTS.md files we read, the 35,337 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.

  • In this repositoryOne other file it gives its agents.

The file

We split this AGENTS.md into the rules it gives an agent

7 rules. About 0 are common, 0 are distinctive, and 7 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈0

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 7

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  • could be automatic: a setting could enforce it
  1. Very specific:

    Run the ones covering what you changed.

    line 42
  2. Very specific:

    Every shell script you touch passes bash -n.

    line 46
  3. Very specific:

    Never write ~/.claude/settings.json: on a linuxploitacious host it is a symlink into that tracked checkout, and a local edit fails its next …

    line 93
  4. Very specific:

    Never publish a private copy or anything from CONTEXT/, .claude-memory/, .claude-handoffs/, NOTES/, DELIVERABLES/, or PROJECTS/: they hold …

    line 96
  5. Very specific:

    No root CLAUDE.md. With one present, Claude Code reads it instead of this file and skips every AGENTS.md in the repos under PROJECTS/.

    line 103
  6. Very specific:

    Never race the shared checkout.

    line 105
  7. Very specific:

    Never kill by pattern. No pkill -f, pgrep -f or killall on a name: your own shell and sibling lanes carry the same strings in their …

    line 110

≈ “Common” is an estimate: at least 1 in 5 of the 45,344 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
AGENTS.md

OPS

This repo is a copy of OPS, the Claude Code harness published as the Exploitacious/OPS template: the context layer (CONTEXT/), the skills library (SKILLS/), the deployers and hooks (.claude-config/), the git-synced memory pools (.claude-memory/), handoff batons, and the projects it manages (PROJECTS/). In the Operator's private copy it holds their identity and work; in the public template it holds only generic mechanics. This file is about working in this repo. The rules that bind every session (role, lane contract, landing, writing, memory) are in CONTEXT/core.md, and the main thread's (intake, delegation, review, merge, models, rhythm) in CONTEXT/foreman.md; nothing here restates them.

Read first

CONTEXT/core.md should already be in your startup context: deploy.sh links it into ~/.claude/rules/ops-core.md. If it is not (no "# Core" in what you were given), read it now, then proceed, and tell the Operator to re-run .claude-config/deploy.sh. If you are the main thread and no # Foreman doctrine block arrived at startup (the foreman-context hook prints it for foreman sessions), read CONTEXT/foreman.md too; a spawned lane never reads it. Everything else in CONTEXT/ loads on demand through the core's "Where to look" table; do not read those files as a startup ritual.

First launch: if CONTEXT/.bootstrapped does not exist, this copy has never met its Operator. Do not start normal work: read BOOTSTRAP.md and run it; on a fresh copy the bootstrap is the session. If the marker exists, its stage= value says which optional stages remain; offer the next one when the current task allows.

Build, test, land

  • Gate: bash .claude-config/bin/verify-ops.sh after any harness change. It checks ~/OPS; set OPS_DIR to check another checkout. Its host checks (the core link, the Stage-1 settings) still read $HOME, so for a checkout other than the deployed one, or on a machine with no deployed OPS, run it in a throwaway HOME (DEPLOYMENT.md, "Testing a deploy under a throwaway HOME").
  • Tests: .claude-config/bin/tests/*-test.{sh,py}, .claude-config/bin/*-selftest.*, .claude-config/hooks/*-selftest.sh, and .claude-config/hooks/*-test.py. Run the ones covering what you changed. A suite that runs a tool that deletes or moves files starts with the sandbox guard and runs only inside .claude-config/bin/sandbox-run (exit 97 elsewhere); the command line is in .claude-config/bin/README.md. Every shell script you touch passes bash -n; every workflow script parses (plain node --check is unreliable for them; CONTRIBUTING.md has the command CI uses). In the template repository, CI (.github/workflows/gate.yml) runs the syntax checks, every suite, a fresh-install smoke test with verify-ops.sh, and a secrets scan on each push and pull request; CONTRIBUTING.md has the same commands for a local run.
  • CHANGELOG.md gets a dated entry for every notable change.
  • Several sessions can share this checkout. Before pushing, run git log --oneline origin/main..main; if it shows commits that are not yours, push and reconcile with a merge, never a rebase over another session's commits.
  • This copy pushes only to its own private origin. The git-guard hook runs .claude-config/bin/origin-private-check on the agent pushes it can parse here and blocks one it cannot verify, or one to another remote. It is a seatbelt, not a sandbox: DEPLOYMENT.md, "What Stage 2 does" step 8 ("The push gate"), lists its limits.
  • Contributions to the public template go by PR and follow CONTRIBUTING.md: port the mechanic, never paste the file, keep your private-term list out of every PR and commit, and push the PR branch with GIT_GUARD=off (the git guard blocks an unverified push by design).

Conventions

  • SKILLS/ is the single source for the template's skills, deployed through the ~/.claude/skills/ symlink; edit them here, never in ~/.claude/skills/. An organization's shared skills are delivered separately by that organization, not through this repo.
  • .claude-config/, .claude-memory/, and .claude-handoffs/ are literal names; do not rename them.
  • Personalization lives only in the files the template sync never touches: USER.md, voice.md, standing-orders.md, the work-tracking.md, team.md, and tools.md slots, .bootstrapped, and CONTEXT/projects/. The doctrine files (core.md, foreman.md, how-i-work.md, model-roles.md, project-kata.md) stay generic, so a template sync can update them; an Operator ruling goes to standing-orders.md instead of an edit there.
  • The template adds and offers; it never takes away what a copy's owner chose (CONTEXT/how-i-work.md, "The template and a copy's owner"). A change to deploy, the template sync, or a gate that would delete, cap, or block an owner's content (a plugin, a memory pool, a retired skill, a hook, a pin, a remote, a backup) ships as a warning or an offer, never a FAIL, a block, or an automatic removal. Only an unsafe thing is overruled. One stated exception: the drift gate FAILs on a banned or retired model id (checks 15 and 15b) and edits nothing.

Invariants and bans

  • Never write ~/.claude/settings.json: on a linuxploitacious host it is a symlink into that tracked checkout, and a local edit fails its next git pull --ff-only whenever upstream changed the same file.
  • Never publish a private copy or anything from CONTEXT/, .claude-memory/, .claude-handoffs/, NOTES/, DELIVERABLES/, or PROJECTS/: they hold the Operator's identity and work.
  • CONTEXT/core.md stays under 15,360 bytes (verify-ops.sh check 16): every session and lane pays for it on every turn. CONTEXT/foreman.md stays under 8,192 bytes: the foreman-context hook prints a larger file as nothing, so the main thread would fall back to reading it by hand.
  • No root CLAUDE.md. With one present, Claude Code reads it instead of this file and skips every AGENTS.md in the repos under PROJECTS/.
  • Never race the shared checkout. ~/OPS is one working tree that every session on the box uses, and memory and batons are committed to its trunk all day. A git checkout, stash, reset or rebase there rewrites files under another session. Branch work goes in a worktree; in the shared tree you only add, commit your own paths, and fast-forward.
  • Never kill by pattern. No pkill -f, pgrep -f or killall on a name: your own shell and sibling lanes carry the same strings in their arguments, and in the harness OPS is ported from this killed the caller over a hundred times. Kill a PID you recorded, or use .claude-config/bin/safe-pkill.

Every surface

The most common harness defect is a change that works in the session that made it and is missing everywhere else. Before calling a harness change done, say which of these applied:

  • Deployers. deploy.sh and deploy.ps1 install the same harness; a deploy change lands in both, or says why one host type is out.
  • Copies. A template change reaches each copy only at its next template sync, and the sync never overwrites a file the owner changed. A change that needs every copy to move says so in CHANGELOG.md and DEPLOYMENT.md.
  • The Stage-1 settings. They live in the shared linuxploitacious checkout and nothing here writes them; a hook or model change that needs a settings entry is not done until Stage-1 carries it.
  • T3 versions. T3 moves between stable and nightly builds; a version pattern or a schema read written for one line needs the other in its tests.
  • Tests and the gate. A hook or script change ships its selftest, and CI picks it up by glob; a check that passes only on a quiet box is a flaky check.
  • Docs and the way back. DEPLOYMENT.md, .claude-config/bin/README.md, and the skill that names the changed thing; and if you added a way to turn something on, the way to turn it off.

Where to look

NeedHome
What exists, the folder treeREADME.md
Deploy (Stage 1 and 2), migration, T3 Code hostsDEPLOYMENT.md
First launchBOOTSTRAP.md
Template sync from upstream.claude-config/bin/harness-update-scan.sh (.claude-config/bin/README.md)
Scripts, tests, and the gate.claude-config/bin/README.md
Porting rules, the CI gate, local test commandsCONTRIBUTING.md, .github/workflows/gate.yml
Licenses of adapted third-party workSKILLS/THIRD_PARTY_NOTICES.md
HistoryCHANGELOG.md, git log

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.