f-setup
Skill14 starsChanged 20 days agoMITView on GitHub
Install Topping Out into a repo, or upgrade an existing install, then fill in the repo profile, the names files and the test adapter, and prove the install. Use when the user runs /f-setup, says "set up Topping Out here", "install the method", "upgrade Topping Out", "update Topping Out", "is there a new version", or points at the package and asks to install it. Never pushes; commits an upgrade only on the owner's word; never overwrites a file the repo already has, except an unadapted one during an upgrade.
- Reads credentials
- Installs packages
In this repository32 other files it gives its agents.
- AGENTS.mdAGENTS.md
- docs/llms-full.txtllms.txt
- docs/llms.txtllms.txt
- adjudicateSkill
- agent-councilSkill
- converseSkill
- f-archive-searchSkill
- f-archiveSkill
- f-blueprintSkill
- f-boardSkill
- f-cardSkill
- f-catchupSkill
- f-complySkill
- f-contextSkill
- f-distillSkill
- f-dreamSkill
- f-greploopSkill
- f-inspectSkill
- f-night-shiftSkill
- f-plancheckSkill
- f-scheduleSkill
- f-searchSkill
- f-shiftSkill
- f-signoffSkill
- f-sketchSkill
- f-statusSkill
- f-surveySkill
- model-councilSkill
- orca-pi-connectSkill
- pack-reviewSkill
- speakSkill
- xreviewSkill
The file
We split this skill into the rules it gives an agent
7 rules. About 0 are common, 2 are distinctive, and 5 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
5
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 17
First run, before the skill is installed: start a session in the repo and say Read <package>/skills/f-setup/SKILL.md and follow it.
- Distinctive: line 21
Find out before asking: Read the repo for every profile field it can answer.
- Very specific: line 23
Secrets: read the names of keys in .env files, never their values.
- Very specific: line 46
Builders that read
.agents/skills/: instead of .claude/: if the repo has an .agents/ folder or the owner names such a builder, mirror … - Very specific: line 66
A newer package mid-job: never upgrade then. The foreman's site walk runs --check and only reports it.
- Very specific: line 81
Write foreman/REPO-PROFILE-<product>.md from foreman/method/templates/REPO-PROFILE.md: every row filled, none left with a template blank.
- Distinctive: line 129
Run each, read its exit code (a crash is not a pass), and report the line:
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill 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.
Files
Topping Out: Setup
One command from an empty repo to a repo ready for its first job: the files installed, the repo profile written from what the repo actually has, the names files, the test adapter proved, and the checks run.
First run, before the skill is installed: start a session in the repo and say Read <package>/skills/f-setup/SKILL.md and follow it. The install copies this skill too, so every later run (an upgrade, a re-check) is just /f-setup.
The contract:
- Copy only what's missing; never overwrite. A file the repo already has may carry its adaptations (
SETUP.md§1 "Adapt"). The installer's upgrade mode is the only path that replaces a file, and only one unchanged since the last install. - Find out before asking. Read the repo for every profile field it can answer; ask the owner only what it can't, in one batch.
- Git custody: setup never pushes, and never stages or commits on its own. An install ends with the list of files for the owner's commit. An upgrade, on the owner's word, stages exactly the installer's
== to commitlist and commits it (Step 1b); pushing, or a PR, stays the owner's. - Secrets: read the names of keys in
.envfiles, never their values; never print a value. Never echo the names kept out of records (Step 3) into chat or a tracked file. - Ends with one line:
F-SETUP: READY <profile path>orF-SETUP: HALTED <specific reason>.
Step 0 · Where things are
- The repo: the current working repo. If it isn't a git repo, HALT:
not a git repo. - The package: a folder holding
METHOD.mdandskills/:- the path the owner gave, or the folder this file sits in (
<package>/skills/f-setup/); - an installed copy (
.claude/skills/f-setup/) is not the package. If no package folder is at hand (the skills came from a skills installer, or this is an upgrade), clone it:git clone <the package's repo URL> scratch/topping-out-package(the URL the owner gives, or the one in the receipt'spackage:line). Use a full clone, not--depth 1: an upgrade diffs against the receipt's old revision.
- the path the owner gave, or the folder this file sits in (
- Mode:
foreman/INSTALL-RECEIPT.txtexists → upgrade (Step 1b).- No receipt, but
foreman/method/or Topping Out skills in.claude/skills/already present → an install from before receipts. Don't run install mode (it would stamp today's revision over older files). Ask the owner for the package revision it came from, write a receipt with thatrevision:line, then upgrade. If nobody knows it, upgrade by hand (SETUP.md§1, "Upgrade by hand"). - Neither → install (Step 1a).
- The one question asked first: "Is this product an AI agent built on LangChain, LangGraph or Deep Agents?" (yes / no / not sure; the repo's
requirements.txt,pyproject.tomlorpackage.jsonnamingdeepagents,langgraphorlangchainmakes yes the default; "not sure" is answered from those files, and none of them naming one means no). Yes adds the Deep Agents add-on (Step 1c); no skips it, and the profile's framework check isnoneunless the owner names another. - Prerequisites:
git,node(18 or later),python(3.9 or later), and a Bash shell (Git Bash on Windows): work orders run in Bash (templates/REPO-PROFILE.md, "Shell for work orders"). Check each with--version; a missing one is a HALT naming it. - Required tools, checked and warned about (never a HALT): Pi (
pi --version), Orca (orca --version), the Greptile app on the repo (the repo's installed GitHub apps, or ask the owner once), and an OpenRouter key (the nameOPENROUTER_API_KEYin.env, never its value). Each one missing gets one loud line,REQUIRED BUT MISSING: <tool>: <what it costs you>(Pi or Orca: work orders carried by hand, no autonomous run or night shift; Greptile: no review rounds on PRs; OpenRouter: no plan-check readers from other model families), repeated in the final report. Setup still finishes.
Step 1a · Install
node <package>/skills/f-setup/install.mjs --repo <repo> --dry-run: show the owner the count and thekept …lines (files the repo already has, which are never replaced; a skill kept under the same name may be the repo's own, so say which).node <package>/skills/f-setup/install.mjs --repo <repo>: copies what's missing, creates theforeman/folders, writesforeman/INSTALL-RECEIPT.txtwith theinstalled …lines, and addsscratch/to.gitignoreunless git already ignores it. Exit 2 with "uncommitted changes" means the package checkout is dirty: report it and HALT (the receipt would name a revision that doesn't match the files).- Builders that read
.agents/skills/instead of.claude/: if the repo has an.agents/folder or the owner names such a builder, mirror.claude/skills/there the same way (copy only what's missing).
Step 1b · Upgrade (also: "update Topping Out")
The owner types /f-setup; everything below is this skill's work. Say what each step found in one line.
- A clean point: the repo on its main branch (
git branch --show-current), no job worktree open (git worktree listshows only the main checkout, or worktrees the owner says aren't jobs), no tracked changes in the files the upgrade touches. Not clean: say what's open and HALT. - The package on this machine: the receipt's
package:path if it exists here and is a git checkout of the receipt's URL; otherwisescratch/topping-out-package(clone it from the receipt's URL, full clone, if it isn't there). - Is there anything new?
node <package>/skills/f-setup/install.mjs --repo <repo> --pkg <package> --check(read-only: it fetches the package's remote).UP TO DATE: say so and stop withF-SETUP: READY. - The plan, with the newest package:
node <package>/skills/f-setup/install.mjs --repo <repo> --pkg <package> --upgrade --pull. It fast-forwards the package checkout, then prints the plan and what's new (theCHANGELOG.mdlines this install hasn't seen), writing nothing in the repo.- Exit 1: a job is open (
foreman/jobs/JOB_*.md) or an end game is owed (foreman/ENDGAME-PENDING.md, or a lane'sforeman/ENDGAME-PENDING-<lane>.md). Report it and HALT. - Lane mode (the repo profile has a "Lanes" row): the installer sees only this machine's files, so before applying also read the board through
snippets/board_pull.sh <remote> <board path>for every board onforeman-lanes, and runendgame.mjs check --all. Any job in progress on either lane, or any lock open: report it and HALT. Upgrade only when both lanes are idle. - Exit 2: report the installer's line. A diverged package checkout: clone a fresh one into
scratch/. A receipt without a git revision, or a package without that revision: upgrade by hand (SETUP.md§1, "Upgrade by hand"). - Run the package's installer, never the installed copy in
.claude/skills/f-setup/: the package's is the new one.
- Exit 1: a job is open (
- Show the owner what's new in plain words, then the plan's counts (added, replaced, kept for a hand merge, removed). On the owner's yes:
… --upgrade --apply. - Adapted files (changed here and in the package): for each, diff the repo's copy against the package's and merge the package's change into the adaptation by hand. Show each merge before writing it. Gone from the package but adapted here: ask the owner, keep or delete. Added back: a file listed under "add" that the repo once had and deleted on purpose (the voice trio, say): ask before keeping it.
- Any repo-profile row that names a path the upgrade removed: update it. Re-read the profile against the current
templates/REPO-PROFILE.mdand add any row the template gained since (e.g. "Test time", "Parallel workers", "Runs on"), found out the same way as Step 2. Then the names-file check (Step 3.3) and Step 5. - Commit, on the owner's word: stage exactly the paths under the installer's
== to commit(git add -A -- <each path>, so new files and removals are included), plus the files steps 6 and 7 changed; thengit status --shortmust show none of those paths unstaged or untracked. Commit with a subject only, no trailer (Topping Out <old> to <new>: <what's new, in a few words>). Pushing, or opening a PR where the repo merges through PRs, is the owner's word. - New switches the update brought: offer each that applies, one line each, never run without a yes. Today: the parallel test proof when the adapter is pytest and the profile's "Parallel workers" row isn't proven on this machine (
bash foreman/method/snippets/parallel_proof.sh <adapter> <cores minus 1, at most 6> <test paths>, 20 to 30 minutes, between jobs; only on PROVED write the number into the git-ignoredforeman/.test-workersand record the line in the profile).
A newer package mid-job: never upgrade then. The foreman's site walk runs --check and only reports it; the upgrade waits for the end of the job.
Step 1c · The Deep Agents add-on (only on yes)
- Needs Python 3.11 or later (deepagents requires it). On an existing install, upgrade first (Step 1b): the installer refuses an add-on while the receipt's revision is older than the package's, since the add-on's files would then look adapted at the next upgrade.
node <package>/skills/f-setup/install.mjs --repo <repo> --addon deep-agentsadds/deep,deepagents-ref/and.mcp.json(only if the repo has none; otherwise add itsdocs-langchainentry to the existing file and show the owner the edit). The receipt'saddons:line records it, so later upgrades include it.- A new agent project (no product code yet): offer the running skeleton too,
… --addon deep-agents --starter(src/agent/, tests,langgraph.json,requirements.txt, a CI workflow, anAGENTS.mdto fill in). It copies only missing files and is never upgraded: from here on it's product code. python deepagents-ref/scripts/setup_sources.pyfetches what the wiki cites (thedeepagentspackage at the pinned version, the live docs). Needs network and pip. The lint it runs may report STALE pages or missing sources: that's drift since the wiki was last checked, not a failure; say how many, and point todeepagents-ref/MAINTAINING.md. Exit 1 means the package couldn't be fetched, or no docs page arrived at all: report the line it printed (pip, network, the Python version) and HALT the add-on step; pages that fail one by one are reported as drift and don't fail it.- The profile's framework check row:
/deep. A Pi builder reads.agents/skills/: mirrordeepthere too. - With the skeleton:
python -m venv .venv, then install with the venv's own Python (.venv/Scripts/python -m pip install -r requirements.txt; macOS/Linux.venv/bin/python). After Step 4, the tests through the adapter must show 6 passed;.envgetsOPENROUTER_API_KEYfrom the owner, never from chat (they paste it into the file).
See addons/deep-agents/README.md in the package for what each part does.
Step 2 · The repo profile
Write foreman/REPO-PROFILE-<product>.md from foreman/method/templates/REPO-PROFILE.md: every row filled, none left with a template blank. A row nothing can answer yet says not recorded and why.
Find out first (read-only):
| Row | Where to look |
| Method root | the installed foreman/method/ (absolute path) |
| Records repo, single or two repos | single-repo is the default: this repo holds both, records under foreman/. Ask only if the product lives in another repo |
| Constitution | AGENTS.md or CLAUDE.md at the root (or none yet) |
| Measurement / eval harness | package.json scripts named eval/bench, an evals/ or benchmarks/ folder; else none |
| Target repo, remote, main branch | git remote -v, git symbolic-ref refs/remotes/origin/HEAD (fall back to main/master) |
| Worktree tool | orca on PATH → orca; else git worktree, root beside the repo |
| Gates and test runner | package.json scripts (test, lint, typecheck, build), pyproject.toml/pytest.ini/setup.cfg, go.mod, Cargo.toml, Makefile targets, CI workflow files (.github/workflows/*: the commands CI runs are the gates) |
| Dirty-file allowlist | after the dependency install the gates need, git status --porcelain in a fresh worktree: the files that show up and are never staged (an untracked lockfile, say); else none |
| CI runner shape | the CI workflow's runs-on and install steps (system packages it adds); else not recorded |
| Paid keys to strip | key names in .env, .env.example, the code's environment reads (process.env.X, os.environ["X"]) that look like provider keys (*_API_KEY, *_TOKEN) |
| Database change paths | migrations/, db/, alembic/, prisma/, supabase/migrations/ |
| Disposable databases | docker-compose*.yml services and ports |
| PR review bot | .greptile* config, or a Greptile comment on a recent PR (gh pr list --state merged -L 5, then its comments) |
| Host merge strategy | gh repo view --json mergeCommitAllowed,squashMergeAllowed,rebaseMergeAllowed |
| Builder delivery | orca and pi on PATH → pane link; else hand-carried pointer (the fallback; Step 0 already warned) |
| Max work orders per job | 9 (the default) unless the owner names another |
Cutting a plan (/f-schedule v2) | noise files: CHANGELOG.md and README.md where they exist, plus any docs test every job appends to (tests/test_docs.py); hot files: none until a job finds one; re-proof allowance 2 |
| Foreman launch command | the command running this session (claude, with the flags the owner uses) |
| Runs on | uname -s (or the platform this session reports): Windows, macOS or Linux; on Linux with no desktop session ($DISPLAY and $WAYLAND_DISPLAY empty) and Orca running as a service (systemctl --user is-active orca-serve), a Linux server through Orca (SETUP.md §8b) |
| Framework check | /deep when the add-on went in (Step 1c); otherwise none, or a skill the owner names that checks plans against their framework |
Then ask the owner, in one batch, only what's left; typically: the product name (for the file name), ticket mode (local unless they use a tracker), board publish mode (local or artifact), the plan check seats (or leave to the first plan check), the three budgets (repair work orders, default 3 per task; wall time; foreman tokens), the builders' names for Step 3, and anything the reading left ambiguous (two candidate gate commands, say). Offer the found answer as the default in each question.
Step 3 · The names files
The records never name the builders' model, vendor or tool (RULES.md). The names live in a git-ignored file the records push checks against (METHOD.md §10 step 9), where an empty or unreadable file is exit 2, never a pass.
- Write
scratch/names-kept-out.txt(the profile's default path): the names the owner gave, one plain name per line, no regex characters. Never leave it empty: if the owner names none, seed it from the builders the profile andforeman/method/BUILDER-PROFILES.mdname, as/f-signoffdoes, and say so. Writescratch/names-allowed.txttoo: contexts that contain a name by design, such as a builder tool's own folder (.pi/); empty is fine. Confirmgit check-ignore scratch/names-kept-out.txtsucceeds. node .claude/skills/f-signoff/names-check.mjs --self-testmust printok scan ok clean ok cli.- The real file:
node .claude/skills/f-signoff/names-check.mjs --names scratch/names-kept-out.txt --allow scratch/names-allowed.txt foreman/method/RULES.mdmust exit 0 or 1 (1 only means the file mentions a name; report the count, never the hit lines). Exit 2 is a broken names file (empty, or a regex line): fix it and run again. - The profile holds only the paths, never the names.
Step 4 · The test adapter
- From
foreman/method/templates/TEST-ADAPTERS.md, copy the block for the profile's runner intoforeman/test-adapter.sh; set its paid-key list from the profile. - Line endings:
git check-attr eol -- foreman/test-adapter.sh. If it isn'tlfand the machine hascore.autocrlf=true, a checkout turns the script CRLF and Bash breaks on it: propose*.sh text eol=lfin.gitattributes(for the owner's commit) and say why (SETUP.md§8). - Prove it (the two-fixture check the template asks for): two folders holding the same test file, placed where the runner collects tests (jest
roots/testMatchand Go packages may not look inscratch/), with tests A, B and C. In the base folder A and C fail; in the head folder B and C fail. Run each from its own folder under the money guard (( cd <base> && env -u <each paid key> bash -c 'source foreman/test-adapter.sh; run_tests …' ), the same for head), checkran_okon both, thencomm -13 <(failed_ids <base output>) <(failed_ids <head output>)must print only B: C proves a shared failure isn't reported, and the same file in both proves the IDs are stable. Delete the fixtures after. - In the profile's "Test adapter" row record the runner, the proof (command, date, the line
commprinted), the branch-coverage command and how new tests run against the previous commit's code (defaults for each runner:TEST-ADAPTERS.md, "Coverage and the old-code check"). - A runner with no block in the template: write the three functions (
run_tests,failed_ids,ran_ok) to the same contract and prove them the same way; say so in the report.
Step 5 · The checks
Run each, read its exit code (a crash is not a pass), and report the line:
| Check | Pass | ||||||
python .claude/skills/f-board/test_render_board.py | OK | ||||||
node .claude/skills/f-signoff/names-check.mjs --self-test | ok scan ok clean ok cli | ||||||
node .claude/skills/f-setup/install.mjs --self-test | every line ok | ||||||
node .claude/skills/f-setup/install.mjs --repo . --pkg <package> --dry-run | 0 file(s) would be installed (a file the repo deleted on purpose shows here: name it, it isn't a failure) | ||||||
| no template blank left in the profile | `grep -nF -f <(grep -o '<[^>]*>' foreman/method/templates/REPO-PROFILE.md | sort -u | grep -vxE '<(remote | main | records | product | nn)>') foreman/REPO-PROFILE-<product>.mdprints nothing (the five left out are the template's own wording, e.g.<remote>/<main>`, not blanks) |
| the gates named in the profile run | each gate command once, under the money guard; a red gate is recorded as the repo's starting state, not a setup failure |
Step 6 · Report
- What was installed or upgraded (counts, and any adapted files merged or left).
- The profile path and the rows marked
not recorded. - The optional add-ons and what each still needs (
SETUP.md§1: voice,f-comply), and everyREQUIRED BUT MISSINGline from Step 0 again. - For the owner's commit: the exact paths setup created or changed (never
scratch/). Setup doesn't commit. - Next: the first job (
SETUP.md§7):/f-sketchfor an idea,/f-schedulefor a big plan, or the first-job opener.
Then the terminal line: F-SETUP: READY foreman/REPO-PROFILE-<product>.md.
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
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.

