landing
Skill17 starsChanged 17 days agoMITView on GitHub
Let many agents write to one repository at once without collisions: a per-repository landing contract, path leases claimed before work starts, one queue that is the only writer to trunk, and a machine-wide slot governor for builds and tests. Use for 'landing', 'land this', 'merge queue', 'many agents on one repo', 'where does this work land', or before any coordinator (brigade, Orchestrate, Autopilot, swarm) delegates writing work in parallel.
- Deletes or force-pushes
We split this skill into the rules it gives an agent
4 rules. 0 are common, 0 are distinctive, and 4 are very specific to this project.
0
Common
Most of the 7 edited versions we read keep these.
0
Distinctive
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 8
Read the pstack-t3 runtime before spawning workers, choosing models, scheduling, or isolating work.
- Very specific: line 50
Every command takes --help.
- Very specific: line 85
Land: Run land. When it prints queue busy, run land again, at most 3 more times, waiting 5 seconds before each try.
- Very specific: line 99
Before you drive an entry's PR in merge or human mode, read Pull request lifecycle.
“Common” is measured: kept by at least 6 in 10 of the 7 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Landing
Read the pstack-t3 runtime before spawning workers, choosing models, scheduling, or isolating work. It maps those steps onto T3's orchestrator tools.
Writing scales. Integration does not. Landing makes integration a property of the repository, decided once, so no coordinator asks where work lands and no two writers collide.
The rules:
- One trunk per repository. Every change lands there through the queue.
- A writer claims a lease on the paths it will change before it starts. Overlapping claims are refused.
- Writers never integrate. A worker commits in its own worktree and stops. It never merges, rebases a shared branch, or pushes trunk.
- The queue is the only writer to trunk. It is a lock, not a process. Whoever runs
landwhile the lock is free drains the queue. Everyone else gets "queue busy". - A review verdict holds only for the exact change reviewed. The queue lands the pinned SHA, and bounces it when the rebased change differs from the reviewed one.
- Builds and tests run under a governor slot, so the machine is not overrun.
The script
<skills>/landing/scripts/land.py, where <skills> is the directory holding this skill. Run it from any checkout of the repository, or pass --repo <path>. State lives in SQLite under ${XDG_STATE_HOME:-~/.local/state}/pstack-t3/landing/, one store per repository.
L="python3 <skills>/landing/scripts/land.py --repo <checkout>"
$L init --trunk main --mode human|merge|push|local --check "<cmd>" [--check ...] [--setup "npm ci"] [--batch 4] [--timeout 1800] [--merge-method merge|squash|rebase] [--author-policy any|configured|credited] [--pr-item-line on|off] [--heartbeat-ms 3600000] [--merge-heartbeat-ms 900000] [--base <commit>] [--cap 4] [--generated <paths>] [--rebuild "<cmd>"]
$L mode merge [--merge-method squash] # change the mode while the queue is empty. --merge-method may change while entries await merge
$L cap 4 # most changes in flight on the repository at once; 0 clears it
$L lease claim --holder <restaurant>/<dish> --paths src/engine,package.json [--owner <restaurant>/@<generation>] # prints L<n>, who holds the overlap, or the cap and its holders
$L lease check --holder <restaurant>/<dish> --paths src/engine # what a claim would answer now, with no lease claimed and no reservation armed: free, the overlapping leases, or the cap
$L lease renew L3 [--if-live] [--owner ...] ; $L lease release L3 [--owner ...] ; $L lease list
$L submit --holder <restaurant>/<dish> --branch <b> --sha <reviewed sha> --lease L3 --reviewer <provider/model> [--owner ...] [--title "..." --body-file pr.md] # prints E<n>
$L owner --prefix <restaurant>/ --generation 2 # raise a holder prefix's floor; it never lowers
$L lease reserve --for <restaurant>/ --paths a.md,docs --ruling R<n> [--ttl-hours 2] --owner .admin/@<generation> # prints S<n>; refuses other holders' claims on those paths
$L lease unreserve S<n> --owner .admin/@<generation> # lift a reservation
$L share --for <restaurant>/ <n> [--clear] --owner .admin/@<generation> # that prefix's share of the cap; --clear takes 0
$L contest --holders <a>,<b> --owner <restaurant>/@<generation> # prints C<n>; land holds both holders' entries
$L contest --settle C<n> --first <holder> --owner .admin/@<generation> # the first holder lands, then the other
$L contest --cancel C<n> --owner .admin/@<generation> # remove the hold or the order
$L land # drain the queue; prints what landed, bounced, or is still queued
$L status [E3] ; $L resume
$L status --holder <restaurant>/<dish> # that holder's entries with their SHAs; a value ending in / matches every holder under it
$L status --holder <restaurant>/<dish> --sha <sha> # only its entries at exactly that commit
$L slot -- npm test # run a heavy command under a governor slot
$L slot --exclusive -- npm run bench # hold every slot: nothing else heavy runs while it measures
$L slot --slots 2 -- npm test # take 2 worker slots in one admissionEvery command takes --help.
A coordinator replaced by another thread must not write again. owner --prefix docs/ --generation 2 raises the floor for holders under docs/ and never lowers it, so a rerun changes nothing and a lower generation exits 1. lease claim, lease renew, lease release, and submit take --owner <prefix>@<generation>, whose prefix the holder must start with. Inside the write's transaction each refuses a generation below the prefix's floor with land: owner docs/@1 is stale; docs/ is at generation 2, and refuses a holder under a floored prefix that passes no --owner. A prefix with no floor works without --owner. brigade's set --thread --replace raises its restaurant's floor before it records the new thread.
Rulings
The executive admin carries out its rulings from rulings.md.
Set up a repository once
Run init the first time any coordinator writes to a repository. The mode decides whether the user stays a gate on landing, so it is the user's choice. brigade asks it when a restaurant opens. Any other coordinator asks once per repository with the host's question tool, unless the user already said.
The stored-contract rules live in contract.md.
| Mode | Landing does | The user |
merge | Opens a PR and merges it, per Pull request lifecycle. | Reviews after the fact. Nothing waits on them. |
human | Opens a PR and keeps it open for the user to merge, per Pull request lifecycle. | Merges every PR. |
push | Rebases, runs the checks, and pushes trunk only if the remote is still at the tested base. No PRs. | Reviews after the fact, in the commit history. |
local | Lands on refs/landing/<trunk>, which no checkout uses. Pass --base. | Merges the lane into a branch when ready. |
merge and push let reviewed changes reach trunk with no human gate. When the PR needs an approving review, or when it has changes requested, the queue pauses and names the PR and that requirement. It does not run gh pr merge --auto. The user then either relaxes the rule for the queue or switches to human.
Checks are the repository's own test, type check, and lint gates. In push and local mode there is no pull request or CI behind the queue, so the checks are the only gate. land.py init and land.py status print a warning while those modes have none. The warning is advice only and never changes an exit code. --setup installs dependencies, because the queue's worktree is cleaned with git clean -ffdx before every attempt. land.py mode switches between merge, human, and push once nothing is queued, landing, or awaiting merge. land.py mode --merge-method changes the method the next gh pr merge uses, and it may run while entries are queued, landing, or awaiting merge. Changing trunk or remote, or moving to or from local, needs a new contract.
Run writers through it
The runtime's Modes section sets the mode lines of every brief this skill writes and how its spawns run in light mode.
For every unit of writing work:
- Claim.
lease claimthe files and directories the unit will change, before delegating. When the claim is refused, fold the unit into the holder's work or hold it until that lease is released. A cap refusal names every holder in flight. Hold the unit until one of them releases. Never claim.unless the unit really touches everything.lease renewextends a live lease. Renewing an expired lease is a new claim on its paths. It is refused when another holder's lease now overlaps or the cap is full, and the refusal names which.--if-liverefuses an expired lease instead, so admitting it again is always a separate step taken after the old worker stopped. - Brief. A writer is a worktree thread from
t3_thread_launchwhen it runs long or the user should see it, and adelegate_taskchild otherwise. Isolate a delegated writer per the runtime's Isolation section. Use the required landing base, which can differ from the parent's current commit. Tell the worker to work only in its own worktree branched from<remote>/<trunk>(orrefs/landing/<trunk>in local mode), change only the leased paths, keep history linear with no merge commits, run builds and tests throughland.py slot --and every benchmark or timing measurement throughland.py slot --exclusive --, commit, and report the branch and head SHA. Put rule 3 in the brief unchanged. - Review the exact SHA with a verifier from another model family, or a same-family seat when only the author's family has a runnable seat, per the coordinator's own review step.
- Submit that SHA with the lease and the reviewer. In
mergeandhumanmode, pass--titleand--body-fileso the PR says what changed and how it was verified. The queue sends the submitted title unchanged. It sends the body unchanged unless the contract sets prItemLine to on, which adds the item's Kind and Goal line when it has one. The line follows body text after one blank line or is the whole body when the body holds only whitespace. With no--body-file, the body is the reviewed commit's body. The reviewer stays in the queue's local store. A submit that changes paths outside the lease is refused. Widen the lease or split the change. - Land. Run
land. When it printsqueue busy, runlandagain, at most 3 more times, waiting 5 seconds before each try. - Settle. Read
status E<n>.landed: the lease is released. Record it in the coordinator's tables, then remove the worker's worktree withgit worktree removeand delete its branch.bounced: the lease is active again for the fix. Resubmitting prints a new entry id. Callunwatch_pull_requeston the bounced PR. Fire a fresh worker with the original brief, the bounce reason, and trunk. For a size bounce, read File size limit. A conflict or a changed rebase needs a new review after the fix. A reason that readscommit <sha12> has author <name> <<email>>, not the configured <name> <<email>>; recommit it as the configured authorsays the entry has a foreign commit author. The contract'sauthorPolicydecides this check.anynever bounces on authorship.configuredandcreditedcompare each commit between the entry's base and its reviewed commit withgit config user.nameandgit config user.email, and they run only when both have a value.configuredbounces an entry with a reviewed commit whose author is not that identity.creditedbounces it too unless every such commit carries aCo-authored-bytrailer equal to its author asname <email>and the body has a line that readsBased on #<n> by @<login>with an optional trailing period. The body is the--body-filetext, or the reviewed commit message body when that text is empty or absent.awaiting-merge(mergeandhumanmode): the PR is open. Pull request lifecycle says what the nextlanddoes with it.
Keep the queue moving
While any entry you submitted is queued or awaiting-merge, keep the queue moving. Drains from other coordinators on the same repository are harmless, because the queue lock runs one at a time. land prints every holder's entries. Act only on lines whose holder is this coordinator's own, and call watch_pull_request only on those PRs. A sibling's PR is the sibling's to watch. When a sibling's land opens your PR, read its URL from your own status --holder <restaurant>/<dish>, which brigade's watch prints as awaiting merge <pr url>.
In merge and human mode, once land has opened a PR, this thread calls watch_pull_request on that PR per Pull request watching. This thread owns the PR. A worker child cannot watch. On each wake, run land and act on what it prints. When that wake's land prints queue busy, retry as step 5 of Run writers through it says before ending the turn. The passed-checks wake is spent, so this thread would otherwise notice the merge only from the hourly heartbeat. In merge mode land merges PRs in the order of the line. An entry whose status E<n> shows waiting for E<m> to merge first needs nothing from this thread. When land prints rebuilt E<n> (<holder>) <url> for your entry, keep the watch, because land pushed a new candidate to the same PR. Never merge a queue PR by hand in merge mode, and never turn on auto-merge for one, because a later PR of the line holds the commits of the entries ahead of it. Keep the watch while the entry is queued or awaiting merge. An interim status reply keeps the watch. Call unwatch_pull_request only when this thread stops driving that PR or hands the queue back to the user. Driving stops when that PR closes, when the queue bounces its entry, or when this thread stops owning the queue. A bounce of an unmerged PR tries to close it when it is open and delete remote landing/e<n>. Both cleanup steps run even if one fails, and each failure prints a warning. In merge mode, a bounce for failed posted checks first tries to turn off auto-merge when the check read's autoMergeRequest is not null. If that attempt fails, the queue pauses instead of bouncing. A rebuild bounce does not try to turn off auto-merge.
Keep one schedule_task heartbeat for a queued entry that has no open PR yet, and beside every watch. Create that heartbeat only if none is running, and reuse it across frontiers. The heartbeat exists because a PR with no posted check never wakes the watch, and because a merge never wakes the watch. In merge mode on a repository with required checks, when the PR is not in a merge queue, use {"type": "interval", "everyMs": <fallback>} where <fallback> is the everyMs number land.py status names. When it names none use 3600000. While an entry is awaiting-merge in human mode, or gh api graphql reports that PullRequest.isInMergeQueue is true for that PR, the heartbeat is required and uses {"type": "interval", "everyMs": <merge wait>} where <merge wait> is the merge wait number land.py status names. When it names none use 900000. That interval is the exception in Pull request watching. The prompt is "Run python3 <skills>/landing/scripts/land.py --repo <checkout> land and act on what it prints per the landing skill." If the running heartbeat has the other interval, delete it with delete_scheduled_task and create it again. Do not drop the heartbeat in merge mode. Delete it with delete_scheduled_task when status shows nothing queued or awaiting merge. A crashed run is recovered by the next one. It asks git whether the last attempt was published before it retries. The contract refuses a fallback below 3600000 and a merge wait below 900000.
Before you drive an entry's PR in merge or human mode, read Pull request lifecycle. When the queue pauses or a command refuses the repository's core.worktree setting, read When the queue pauses.
Capacity
The slot counts live in capacity.md.
Other versions9 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 9
- Magerko/landing-skill★ 44same name
- Hassaan146/claude-skills★ 18same name
- Hussain-Elfalah/Agentic-Skills★ 2same name
- F0rger123/CLAUDE-DESIGN-GOD-MODE★ 1same name
- ian-pascoe/skills★ 1same name
- mahiunfiltered/claude-code-skills★ 1same name
- 0xtinylabs/samterminal★ 0same name
- akachandan1/proofstack★ 0same name
- marcus-at-localhost/market-context-kit★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository63 other files it gives its agents.
- AGENTS.mdAGENTS.md
- architectSkill
- arenaSkill
- automate-meSkill
- benchmark-checklistSkill
- blast-radiusSkill
- brigade-adminSkill
- brigadeSkill
- broSkill
- correctSkill
- create-formal-verification-skillSkill
- create-verification-skillSkill
- figure-it-outSkill
- howSkill
- interrogateSkill
- in-your-own-wordsSkill
- ketchupSkill
- ketchup-videoSkill
- maintain-formal-verification-skillSkill
- maintain-verification-skillSkill
- make-bot-uiSkill
- no-commentsSkill
- poteto-helpSkill
- poteto-modeSkill
- principle-attack-the-premiseSkill
- principle-boundary-disciplineSkill
- principle-build-the-leverSkill
- principle-encode-lessons-in-structureSkill
- principle-exhaust-the-design-spaceSkill
- principle-experience-firstSkill
- principle-explain-the-numberSkill
- principle-fix-root-causesSkill
- principle-foundational-thinkingSkill
- principle-guard-the-context-windowSkill
- principle-laziness-protocolSkill
- principle-make-operations-idempotentSkill
- principle-migrate-callers-then-delete-legacy-apisSkill
- principle-minimize-reader-loadSkill
- principle-model-the-domainSkill
- principle-never-block-on-the-humanSkill
- principle-outcome-oriented-executionSkill
- principle-prove-it-worksSkill
- principle-redesign-from-first-principlesSkill
- principle-separate-before-serializing-shared-stateSkill
- principle-sequence-verifiable-unitsSkill
- principle-subtract-before-you-addSkill
- principle-test-behavior-not-implementationSkill
- principle-type-system-disciplineSkill
- pstack-author-skillSkill
- pstack-runtimeSkill
- recallSkill
- reflectSkill
- setup-pstackSkill
- sharpenSkill
- show-me-your-workSkill
- statechartSkill
- swarmSkill
- tddSkill
- teachSkill
- technical-writingSkill
- The first 60 shown.
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.

