agentsclimarketplace

Spec

Skill thedull/agentic-loop/skills/spec

Turn an idea into a factory spec: triage its size, grill the user with one-question-at-a-time interrogation (adaptive depth), emit a single spec file with a machine-checkable done-condition, and gate it through a fresh-context spec review before it enters the build queue. Use when the user hands over an idea (or a list of ideas) for the factory to build unattended. Interactive — run it while the user is present.From its SKILL.md

Install
npx -y skills add thedull/agentic-loop --skill spec

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

2 things to look at

  • no licenseNo license file was found in the repository. Code published without one is not open source by default, so using it at work is a question for whoever answers licensing questions where you are.
  • 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

SKILL.md

8.7 KB, as published. Nobody here has run it

agentic-loop:spec — idea → reviewed spec

You are the spec stage of the factory. Your output is ONE file per idea in factory/specs/ (template: templates/factory-spec.md in the plugin root; already copied to the project by init). Everything downstream runs unattended — the questions you don't ask now become wrong guesses at build time, but every question costs the user's morning. Adaptive depth resolves the tension.

Token discipline (non-negotiable): one spec file per idea — never generate constitution/research/data-model/contract documents. Look up facts in the repo yourself (grep/read); only DECISIONS go to the user. Never inline file contents into the spec — paths only.

Grill flag — read once per run:

jq -r '[(.grill.enabled // false), (.grill.deep // false)] | join(" ")' \
  .agentic/config.json 2>/dev/null || echo "false false"
  • enabled true: raise the interview depth one notch above what triage suggests — the user has opted into more questions up front in exchange for fewer wrong guesses downstream. The flag never lowers depth.

  • deep true: for ideas triaged large, OR whose objective introduces new domain vocabulary (entities/invariants the codebase has no words for yet — grep first to check), escalate to a deep interview:

    1. If Matt Pocock's skills collection is installed (claude plugin list shows mattpocock-skills), run its grill-with-docs flow: a /grilling session using the /domain-modeling skill. Save the artifacts it produces (glossary, ADRs) under factory/specs/<id-slug>/ — a subdirectory next to the spec file, invisible to the tracker's *.md glob — and list them in the spec's input_paths so build-stage workers inherit the vocabulary.
    2. If not installed and the grill entry has no install_declined: offer the install ONCE (/agentic-loop:config owns the consent flow and records a decline); then proceed per the answer.
    3. Fallback (not installed or declined): run the native grilling below with the ~5-question cap LIFTED — depth bounded by the decision tree reaching shared understanding, not by the question budget.

    Whichever mode ran, the artifact that advances the tracker is still the ONE spec file — deep-interview outputs are referenced input_paths, never replacements. Deep mode is interactive-only by construction (it needs the user's answers); it changes nothing for unattended stages.

Steps per idea

If the user gave a list of ideas, capture each as a file with status: queued first (id from scripts/lib/tracker.sh next-id, one-line objective), then process them one at a time through the steps below. Never interleave the grilling of two ideas.

Dependencies between ideas. If an idea builds on another's output — it consumes a module, API, or artifact another spec produces (in this batch or already in the queue) — record depends_on: <ids> in its frontmatter. The tracker will not claim it until every listed spec is done (merged), which prevents the observed field failure: a dependent built against a base that never contained its dependency, or blocked wastefully discovering it mid-run. (A dependency is also satisfied by a superseded spec whose citation verifies — the work landed some other way. Nothing else counts.) When coupling is plausible but not certain, ask — one question, "does B need A's <thing> to exist first?" — rather than guessing either way. Independent ideas get no depends_on line at all.

  1. Triage effort_budget FIRST — cheap questions before deep ones: does it touch one seam or several? Is it easily reversible? Answer them yourself from the codebase where possible.

    • trivial/small (one seam, reversible): ask ONE confirmation question restating the idea + proposed check command, then emit the spec directly.
    • medium/large (multiple seams, hard-to-reverse, real trade-offs): full grilling, capped at ~5 user-facing questions (prefer informed, stated assumptions over a sixth question).
  2. Grill (when depth warrants) — one question at a time; wait for each answer; never batch. Walk the decision tree, not a checklist: each answer determines the next question. Explore the relevant code BETWEEN questions so you never ask what you can read.

  3. Emit the spec from the template:

    • the 6-field brief (user_intent_verbatim = their actual words, uncut);
    • acceptance as RFC-2119 SHALL + Given/When/Then, each one step from a test;
    • check_cmd — a single command whose exit status decides done-ness. If the acceptance references UI behavior and the project has a runnable web UI, note that so the review stage runs browser verification;
    • a Notes entry ONLY if a decision is hard-to-reverse + surprising + a real trade-off (1–3 sentences);
    • profile: hardened only if the user explicitly asked for correctness-critical treatment.

3b. Self-consistency gate — run BEFORE spending the reviewer. scripts/lib/spec_check.sh <file>:

  • exit 2 → the spec contradicts itself on a decidable fact (an acceptance naming a path input_paths does not declare; a duplicated acceptance number; a Notes entry citing an acceptance that does not exist). Fix it and re-run. Do NOT advance, and do NOT invoke the reviewer — spending a fresh-context review on a spec that disagrees with itself wastes the cheapest moment in the pipeline.
  • exit 0 → consistent. Any candidate — lines it printed are NOT verdicts: they are readings to narrow. Pass them into the reviewer's payload alongside the spec path (see below).

The split is the routing rule this repo uses everywhere: a gate refuses on decidable facts, a reviewer judges. Paths and integers are set operations, so they block. Vocabulary drift and boundary clashes need reading, so they become candidates.

  1. Spec review gate (skip for trivial) — delegate to the loop-reviewer subagent with the spec file path AND the candidate list from step 3b (blind, fresh context). This is a declared amendment to the former "ONLY the spec file path" contract: candidates are derived from the spec itself, never from the author's reasoning, so blindness is preserved. Brief it to find: ambiguous language, missing edge cases, implicit assumptions, contradictions, and a check_cmd that could pass vacuously. Fix findings now — with the user if a finding needs a decision. This is the cheapest moment in the whole pipeline to fix a spec flaw.

    Once the spec file exists, tag the gate work: scripts/observe.sh context set --phase spec --spec-id <spec file> — the review-gate subagent's events then carry the spec they vetted (silent no-op when observability is off).

4b. Irreversibility gate. scripts/lib/tracker.sh irreversible <file>:

  • 0 reversible → carry on.
  • 7 irreversible → the spec CANNOT reach specd whole. Run scripts/lib/tracker.sh split <file> to emit the expand and contract halves (both profile: hardened, joined by depends_on so the contract is unclaimable until the expand is done), fill in their Briefs, and grill each. The advance will refuse otherwise.
  • 2 refused → the signal list is missing or empty. Fix templates/irreversible-signals.txt; do NOT advance, because a spec that passes through unclassified is the outcome the gate exists to prevent.

Classification reads only the spec's own objective, output_spec and input_paths — no branch or database exists yet. Signals live in one editable list; adding one is editing that file and no code. There is no "uncertain" outcome by design.

A human may override with an explicit line in the spec's Notes: - **irreversible-override**: <name> — <reason>. Never add this on the user's behalf without them saying so — silence is not consent.

  1. Advance: scripts/lib/tracker.sh advance <file> specd, run scripts/observe.sh context clear, then tell the user the id, effort_budget, and check command, and move to the next idea.

What NOT to do

  • Do not start building. Building is the build stage's job.
  • Do not regenerate a spec on later feedback — append deltas to its Revision log.
  • Do not ask the user anything you can answer with grep.

Keep looking

Skills are one crate of 607,533. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.