Wiki 🔍 Search

Qiiub Loops

The agent pipeline that turns an idea into merged code, and the rules that decide what a machine may do without a human reading. This page explains the ten loops, who runs each one, how far each is automated today, and where a human still stands.

Snapshot as of 68ae8bf8 (2026-09-11) — not maintained. Live data: docs/registry/LOOPS.md (the registry wins when they disagree), docs/registry/hard-stop-globs.md (INT-0006), and the ruling record under docs/brainstorm/.
Created: 2026-09-11  |  Last Updated: 2026-10-12

What a loop is, and what is not one

A loop is an agent that runs the same kind of task repeatedly and can tell whether it made progress. The test is the verifier: every loop declares a machine-checkable Done = that can come back false because the work was not done. No verifier, no loop — it is a command.

In the registry

  • Declares its verifier before its architecture.
  • Every checker is shown red against a mutant before it is trusted — a pass that cannot fail proves nothing.
  • Selects its own work, or walks a queue. Reports what it saw: N seen · N admitted · N skipped ….
  • Fails closed: an unreadable input means "treat everything as blocked", never "treat nothing as".
  • Never merges. The merge is a human act, always.

Deliberately outside it

  • Drivers a human steers end to end: qiiub-work (the engine that builds), qiiub-pr-open, qiiub-pr-merge, qiiub-pr-review (the gate).
  • Deterministic checks — a lint reports the state of a corpus, not whether a run did work. That wants a script.
  • Utilities — qiiub-doctor, qiiub-qa-sweep, qiiub-module-scorecard (consistency is not progress).

The pipeline

Idea to merged code, left to right. Solid boxes are loops or drivers; dashed boxes are the steps a human takes today. Select any box to read what it does, who runs it and what gates it.

runs on its own runs when a person invokes it, with gates built, but report-only or propose-only a human act

Select a box above.

Two side paths are not drawn. The Assembler (LOOP-07) carries an admission straight to PRs without issues, when a piece of work should not be split. The loop-design coach (LOOP-02) designs new loops and reads this registry to avoid building one that exists.

The ten loops

Canonical names follow qiiub-<object>-<action>; friendly names are for prose. Automation is what runs on main today, not what is designed.

#CanonicalFriendlyDoesRuns asAutomation todayHuman gates
01qiiub-intent-new
qiiub-intent-new --import
WorkshopTurns a raw idea, or an existing document, into a filed intent under docs/brainstorm/. Research fan-out with a contrarian, decision batches, then two fresh-agent verifiers: grounding (every claim is true) and buildability (a reader of the intent alone can plan a build).a person, on demandon demanddecision batches · design pick · the publish PR
08qiiub-intent-promotepromoteCopies a filed intent into docs/admission/NNNN-slug/. Refuses unless the filing PR carries both verifier verdicts. A zero-information-loss verifier checks the copy.a personon demandthe Greenlight PR — its human merge is the admission (R-0002)
10qiiub-admission-compileDrafterCompiles an admitted pitch into its Build Sheet: requirements, acceptance-criteria, golden-assertions, guardrails. A second pass emits seed bodies — only after a human writes seed-plan.yml. Writes files in a working tree and nothing else.a person, pointed at one admissionon demandevery emission is reviewed before it is stamped or merged
06qiiub-intent-decomposeSeederFiles the Drafter's seeds as GHES issues after an adversarial coverage check and one human yes for the whole set. Does not decompose — that is the human's seed-plan.yml. --release reports which Blocked by #N tickets could be released.a personseeding on demand release report-onlythe filing yes · the ledger PR
07qiiub-intent-assembleAssemblerCarries an admission straight to PRs without issues. Batched interview, one plan approval, then parallel builders in isolated worktrees (cap 3) and an adversarial reviewer that diffs the tests. Coverage lives in qiiub-work and is cited, not copied.a personon demandinterview · plan · PR-open
05qiiub-issue-classifyRouterSweeps the open backlog and classifies each issue: VALID, ALREADY RESOLVED, NEEDS RE-SCOPE, DISPUTED, INCONCLUSIVE, with a refuter. Every VALID row names its engine. Emits a ledger and an apply script by PR; writes to no ticket.a person; --sweep existsclassify on demand dispatch report-onlyone yes per verdict class · the ledger PR
03pr-inspect (workflow)InspectorReviews a PR at its head: cheap gates, then a two-pass FINDER → VERIFIER over a checkout, then one stamped comment (INT-0001) with a four-value verdict. Advisory: cannot approve or merge.GitHub Actionsautomatic on open, ready, and push when labelled inspect:failedthe merge
09qiiub-pr-sweep—A tick that puts every open PR in exactly one bucket and dispatches the Inspector on the five kinds of head no automatic trigger reaches (green then pushed, never stamped, …). Its only outward act is workflow_dispatch.vmiller's session on vm-qiiub-dev-lnx-001running session-scoped; stops when the session endsGate A (self-test per classifier version) · Gate B (R-0019)
04qiiub-pr-fixFixerReads the Inspector's stamp, prepares a fix for every current blocker on a local branch, self-reviews with a second adversarial agent. --all walks the queue serially. A 2-bounce stop rule caps the fix loop.a personpropose-only — never pushesevery outward act
02qiiub-loop-designthe coachDesigns other loops. Socratic, verifier before architecture; files a one-page spec and scaffolds the skill only after approval. Reads this registry so it does not rebuild an existing loop.a personon demandthe spec approval · the PR

Who may approve what

Two rulings signed in September 2026 fix the authority model. The short form: every act up to the merge is delegable to a machine; the merge is human; and whether a machine may be the reviewer of record depends on which paths a PR touches.

Outside the hard-stop list

Product code — apps/, packages/, most of src/. The verification stack's verdict is the review: an Inspector pass at the PR head plus the gate at APPROVE-READY on the same SHA, with every required check green. The machine may post that approval as a machine. The human act is the merge, and the merger reads the verdict, not the diff.

Not mechanical yet. Branch protection requires a CODEOWNER approval and no bot is a CODEOWNER, so today this tier works only through the interim carrier below.

Inside the hard-stop list (INT-0006)

47 path entries: money math, tenancy, security, migrations, tests, workflows, CODEOWNERS, the skills, the registries, the signed rulings, the gates' own controls. A human CODEOWNER reads the diff and approves in their own hand. The gate posts a comment, never an approval — its Guard 3 refuses. A mixed PR is hard-stop.

The membership test: a path belongs when a wrong merge on it would change what decides the machine's authority.

Identity is the rule that never bends. A review composed by a machine and posted under a person's credential is not that person's review. Every machine post opens with a disclosure line saying it is a machine. Until a bot identity exists (ticket #1765), the gate may approve under a human credential only outside INT-0006 and only with that line — and that carrier expires 2026-09-30. The gate enforces the date itself: after it, the gate approves nothing until the identity exists.

The gate's three guards, in order

GuardReadsApproves only ifOtherwise
1 · Carrier expirytoday's date (UTC) against 2026-09-30the date has not passedcomment only, on every path
2 · Required checksthe required contexts from branch protection, every row for eachall are SUCCESS — none pending, none failingcomment naming the pending or failing checks
3 · Hard-stophard-stop-globs.md from origin/main, via the shared matcherno changed file matches; the list was readablecomment naming the hard-stop paths; a human CODEOWNER approves

All three are re-evaluated immediately before the approval fires, because a push during the wait can change what the review saw. Each guard has a control shown red against a mutant; an approval is possible only when all three clear.

The brake

F5 is a ledger of blind human reads against Inspector stamps on PRs outside the hard-stop list. It is not the entry gate to the machine tier — it is the demotion instrument. One false pass (Inspector pass, human fail) or one merge that has to be reverted returns the tier to human review the same day; coming back needs thirty clean rows. The bet is bounded because it can be taken back by one row.

How far it is automated

The adoption ladder, as the registry measures it. Nothing here is a task list — the items that move a stage are GHES issues.

0
Admission convention
docs/admission/ exists and both signers cite it.
met
1
The Workshop
Elicitation → two verifiers → a filed intent that survived both.
met
2
Inspector upgrade
Three of four additions shipped. The fourth — an intent-anchored test plan — is a decision nobody has taken, not a build.
3 of 4
3
Fixer propose-only, 2-bounce breaker
One full volley watched end to end including the breaker.
met
4
Status board + labels
Labels and publishing are met. The third — a drift check that gates in CI — is unmet: R-0034 ruled that gates means required in branch protection, and status-board-drift.yml is advisory and never runs per-PR. The registry's Stage-4 re-grade to that reading is still owed.
2 of 3
5
Seeder + Router with dispatch
Seeder complete. The dispatch surface exists, fail-closed, and reports what it would dispatch. Activation is a recorded decision nobody has recorded.
dispatch ungranted
6
Continuous operation
The runner-wrappable modes exist (--all, --release, the sweep). What is missing is authority: the release leg writes to no ticket, the Fixer waits on the R-0005 cage, and a quiet tick that acts on nothing is not success.
modes exist, authority does not
One rule binds every stage. Nothing is wrapped in a recurring runner until its single-item failure path has been watched end to end by a human. It has been broken once, on the record, and the observation was taken afterwards.

Running one spec end to end, today

What actually happens when a product spec goes through the pipeline right now — with the four places a person steps in. The example is POS-SALE-024, a small v1 spec with no open questions; any spec follows the same shape.

  1. Import the spec as an intent. qiiub-intent-new --import docs/design/pos/sale/POS-SALE-024-item-not-found-sound.md. The Workshop runs grounding and buildability; both must pass. It opens the filing PR only on an explicit yes.
    Anyone with the skill · the Inspector reviews the PR
  2. Promote. qiiub-intent-promote reads the filing PR's verdicts and emits docs/admission/0005-…/. It opens the Greenlight PR.
    Anyone with the skill
  3. Merge the Greenlight PR. That merge is the admission. docs/admission/ is hard-stop, so a human CODEOWNER approves and the merge is a principal's.
    mgandia signs
  4. Compile the Build Sheet. qiiub-admission-compile 0005-… emits requirements, acceptance criteria, golden assertions and guardrails from the pitch alone. A human reviews the emission before it is stamped.
    Anyone with the skill
  5. Write seed-plan.yml. How the work splits into issues is a human judgment and appears in no compiled surface. This is the one creative step in the middle.
    mgandia or vmiller
  6. Second pass, then seed. The Drafter emits seed bodies from the plan; qiiub-intent-decompose refutes coverage, asks one yes for the set, files the issues and reads each one back.
    Anyone with the skill · one yes
  7. Route. qiiub-issue-classify classifies the new issues VALID and names qiiub-work as the engine. It reports what it would dispatch.
    Anyone with the skill
  8. Run the engine by hand. Dispatch is report-only, so a person runs /qiiub-work <issue> for each issue. The engine plans, builds in a worktree, tests, and opens the PR.
    vmiller
  9. Review. The Inspector stamps the head. The gate runs its three guards. POS-SALE-024 touches src/QIIUB.Api/Features/, which is hard-stop — so the gate comments and a human CODEOWNER approves in their own hand. A frontend-only PR would go through the machine tier instead.
    Inspector and gate · jflores or jmolina read
  10. Fix. If the Inspector found blockers, qiiub-pr-fix prepares the fix on a local branch and self-reviews it. It does not push; a person applies it.
    Fixer proposes · vmiller applies
  11. Merge. Squash-only. Always a person.
    mgandia or jflores

Each step leaves an artifact the next one reads — the filed intent, the admission folder, the Build Sheet, the issues, the stamp, the proposal. Nothing passes between steps by memory.

The same run, as a chat

The eleven steps above, as they actually read in a session. Purple turns are you typing; dashed turns are something happening without anyone asking; the four bordered turns are the places the pipeline stops and waits for a person.

Illustrative. The commands, the order, the gates and who acts are real — they are the table and the walkthrough above. The spec's contents, the counts, the decision questions and the issue numbers are invented so the shape is legible. No run is being reported here.
Idea → filed intent
you
/qiiub-intent-new --import docs/design/pos/sale/POS-SALE-024-item-not-found-sound.md
Workshop
LOOP-01

Read the spec. Fanned out research with a contrarian. Two decisions are yours before I draft:

1 · Does the sound play on every failed scan, or only on an unknown barcode?
2 · Does it respect the terminal's mute setting?

you

Unknown barcode only. And yes — mute wins.

Workshop
LOOP-01

Drafted. Two fresh agents checked it, each shown red against a mutant first:

GROUNDING pass every factual claim re-verified.
BUILDABILITY pass a reader of the intent alone produced a build plan.

Publish?

you

yes

Workshop
LOOP-01

Filing PR open. Both verdicts are in the squash message — promote reads them from there.

Intent → admission
you
/qiiub-intent-promote 2026-09-11-pos-item-not-found-sound
promote
LOOP-08

Filing PR carries both verdicts — proceeding. Censused the next free number myself: 0005. Emitted docs/admission/0005-item-not-found-sound/, byte-identical to the source apart from the header rewrite. zero-information-loss pass

Greenlight PR open. I do not merge it.

HUMAN
gate 1 of 4

Merging the Greenlight PR is the admission. docs/admission/ is on the hard-stop list, so the gate could not approve it — jflores read the diff and approved in his own hand, and mgandia squash-merged.

ADM-0005 now exists. Nothing before this point was binding.

Admission → Build Sheet → issues
you
/qiiub-admission-compile 0005-item-not-found-sound
Drafter
LOOP-10

Compiled from intent.md alone: 6 requirements, 9 acceptance criteria, 4 golden assertions, 3 guardrails. Anchor coverage checked both directions — no requirement without a criterion, no criterion without a requirement.

No seed-plan.yml, so I emitted no seed bodies. That file is yours.

HUMAN
gate 2 of 4

You write seed-plan.yml. How the work splits into issues is a judgment that appears in no compiled surface, and two implementations of one slicing rule would drift. Three seeds: the sound asset, the scan-failure trigger, the mute check.

you
/qiiub-admission-compile 0005-item-not-found-sound

(pass two — selected by the plan being there, not by a flag)

Drafter
LOOP-10

Three seed bodies written to the worktree. I have taken no outward act.

you
/qiiub-intent-decompose 0005-item-not-found-sound
Seeder
LOOP-06

A fresh refuter went at the three seeds against the Build Sheet looking for a dropped, doubled or invented requirement. It found none.

File all three? One yes covers the set.

you

yes

Seeder
LOOP-06

Filed, and read each one back from GHES: headings, ownership, part:pos, priority:P2 all present on all three. Ledger PR open.

Issues → a PR
you
/qiiub-issue-classify --sweep
Router
LOOP-05

All three VALID; a refuter failed to overturn any. Engine for each: qiiub-work.

Would dispatch 3. Dispatch is report-only, so I invoked nothing. Ledger and apply script are in the PR.

HUMAN
gate 3 of 4

Somebody runs the engine. Nothing mechanical is missing here — the dispatch surface exists and is fail-closed. What is missing is a recorded decision granting it. Until then vmiller types it.

/qiiub-work 1803
qiiub-work
driver

Premise still true against main. Plan posted on the issue. Built in an isolated worktree, tests first, house gates green. Coverage found file-level evidence for every requirement in the seed.

PR open with its evidence pack.

Review
Inspector
LOOP-03

Fired on opened, nobody asked. Cheap gates, then FINDER → VERIFIER over a checkout. Stamp INT-0001 posted at reviewed_sha: CHANGES-NEEDED 2 blockers. I cannot approve or merge — the verdict is advisory.

you
/qiiub-pr-fix 1806
Fixer
LOOP-04

Read the stamp. Prepared both fixes on a local branch. Verifier ladder green, and a second adversarial agent confirmed no test was weakened and no Inspector comment edited.

Proposal drafted as INT-0002. I am not pushing — propose-only until the cage exists. Apply it yourself.

Inspector
LOOP-03

New head pushed. Re-stamped: pass. (Had this been a green PR that was then pushed, no trigger would have reached it — pr-sweep exists for exactly that hole.)

the gate
driver

Three guards, re-evaluated right before the approval would fire:

1 carrier 2026-09-30 has not passed.
2 checks every required context SUCCESS.
3 hard-stop this PR touches src/QIIUB.Api/Features/.

Guard 3 refuses. I am posting a comment, not an approval — and the comment opens with the line saying a machine composed it.

HUMAN
gate 4 of 4

jflores reads the diff — on a hard-stop path the human is the reviewer of record, not a reader of a verdict — and approves in his own hand. mgandia squash-merges.

Had this been a frontend-only PR, the machine tier would have applied: the gate's approval would have stood, and the merger would have read the verdict instead of the diff. The merge itself is human either way.

Eleven steps, four stops. Everything between the stops is a machine reading an artifact another machine wrote and leaving one behind — and every one of those machines is willing to come back and say the work was not done.

Glossary

TermMeaning
Verifier / Done =The machine-checkable condition a loop must satisfy. It must be able to come back false because the work was not done.
Mutant · negative controlA deliberately broken copy of the thing under test. Every checker is shown red against one before it is trusted; a check that has never failed has proven nothing.
Vacuous passA check that reports success without having examined its subject — zero files scanned, an empty list treated as clean. The most common failure class in this repo. Every check must report what it actually checked.
Fail closedWhen an input is missing or unreadable, treat everything as blocked rather than nothing.
Report-only · propose-onlyThe loop computes the outcome and shows it — a dispatch it would fire, a fix it would push — but takes no outward act. A person does.
Hard-stop · INT-0006The registered path list (hard-stop-globs.md, 47 entries) where a human must be the reviewer of record. Read from origin/main by every consumer, so a PR cannot clear itself against a list it edited.
T1 / T2T1: the Inspector's verdict is advisory and a human reads. T2: the verdict is load-bearing and stands unread. R-0037 rules T2 active outside hard-stop paths, mechanical once a machine approval can satisfy branch protection.
F5The blind-read ledger measuring how often the Inspector passes something a human fails. The demotion instrument for T2.
INT-0001 · stampThe Inspector's one comment per PR head, with reviewed_sha and a four-value verdict. Everything downstream reads it.
Gate A · Gate BThe two human grants a loop needs before it acts outward: a per-version self-test grant, and a signed ruling for the class of act.
The cage · R-0005The pre-receive hook plus bot identity that would let the Fixer push to a scoped ref space. Installed, enforcement=disabled.
Ruling · R-NNNNA signed decision, filed as a vehicle under docs/brainstorm/ with a row in the ruling record. Signed text is never edited; corrections are appended.
GrantNamed, one-time, bounded permission for one outward act — a push, a PR, an issue. Consumed on use. A machine takes no outward act without one.

Sources