build-loop
Skill16 starsChanged 44 days agoMITView on GitHub
Add a self-healing loop to a new engine using the house methodology (sensor/authority/gate, fault demo, never-invents tests). Use when asked to build a loop for an engine that doesn't have one.
3 other projects use a version of this.
Adopted by
Most recently taken up by
- Jaxsbr/sabstheir own version, first seen Oct 20, 2026
- Aznatkoiny/plugin-forgetheir own version, first seen Oct 20, 2026
- justEstif/pi-shelftheir own version, first seen Oct 13, 2026
Other versions3 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 3
- Aznatkoiny/plugin-forge★ 1same name
- Jaxsbr/sabs★ 0same name
- justEstif/pi-shelf★ 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 repository15 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- apSkill
- atlasSkill
- brainSkill
- brand-graphicsSkill
- closeSkill
- linkedin-postSkill
- loopsSkill
- reconSkill
- shipSkill
- site-updateSkill
- surplusSkill
- tax-1065Skill
- triangulateSkill
- validateSkill
The file
We split this skill into the rules it gives an agent
1 rule. 0 are common, 0 are distinctive, and 1 is very specific to this project.
0
Common
Most of the 3 edited versions we read keep these.
0
Distinctive
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 18
Run the package suite AND the full portfolio (python -m pytest per package, like CI) before pushing.
“Common” is measured: kept by at least 6 in 10 of the 3 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
How to Build a Loop (house methodology)
Reference implementations: surplus_engine/loop.py (human-gated), close_engine/loop.py (autonomous+quarantine), recon_engine/loop.py (materiality), brain_engine/loop.py (verbatim-or-refuse), triangulate/loop.py (arithmetic-vs-judgment).
Recipe
- Scout the engine first: find the SENSOR (an existing independent check that yields named breaks) and the AUTHORITY (a deterministic re-derivation from the seeded source of record). If no sensor exists (brain case), build one that compares stored state to source.
- Pick the gate policy from the domain's discipline — never copy another engine's. Ask: what is this system entitled to decide on its own? What must it refuse to touch (quarantine/halt/escalate)?
- Loop core: while breaks remain and turns < budget: pick the EARLIEST failing scope (period/category/account/meeting/cell), resync it to authority, book every field change as an Adjustment, re-run the sensor. Frozen dataclasses ->
dataclasses.replace; mutable -> setattr. - Demo faults: 3-5 realistic drift injectors, each with a root-cause story, targeting scopes chosen dynamically from the baseline (don't hardcode IDs). Include at least one fault the loop must REFUSE to fix.
- Deterministic journal (frozen dataclasses): faults, initial findings, turns (before/after counts, adjustments), quarantined/held items, verdict.
render_markdown(journal)must be byte-stable. - CLI:
--demo,--budget,--out; verdict doubles as exit code (match the engine's existing convention — e.g. brain refusal=3). - Tests (~10-12, mirror
tests/test_loop.pyfiles): drift trips the sensor; loop converges; NEVER-INVENTS (settled state equals clean authority run exactly); the refusal boundary holds; clean input = zero turns; budget exhaustion fails; exit codes; determinism (two runs render identical markdown); CLI smoke with tmp_path. - README section: what/why, the five-stage loop line, verdict table with exit codes,
--democommand + real output excerpt. - Run the package suite AND the full portfolio (
python -m pytestper package, like CI) before pushing.
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.

