agentleFS
ksed8ksed8/cc-loopkit/.claude/skills/loop-verify/SKILL.md

loop-verify

Skill1 starsChanged 4 months agoMITView on GitHub

Outer-loop verification step for run.sh — checks the repo against PROMPT.md and .claude/IMPLEMENTATION_PLAN.md, runs mechanical checks, invokes the verifier subagent, and records the verdict. Invoked externally as `/loop-verify` by run.sh, once per outer-loop iteration. Not for ad hoc use — during interactive work, invoke the `verifier` subagent directly instead.

3 other projects use a version of this.

Adopted by

Most recently taken up by

  • Other versions3 projects use a version of this.

    Word for word · 0

    None found.

    Edited · 0

    None found.

    Wrote their own version · 3

    1. erp-mafia/accounted★ 403same name
    2. cbdreamer11/CB-loop-kit-claude-plugin★ 8same name
    3. manastalukdar/ai-devstudio★ 1same 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 repository10 other files it gives its agents.

The file

We split this skill into the rules it gives an agent

8 rules. 0 are common, 2 are distinctive, and 6 are very specific to this project.

  • 0

    Common

    Most of the 3 edited versions we read keep these.

  • 2

    Distinctive

    This author's own choices. Worth a look.

  • 6

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    If PROMPT.md (project root) or .claude/IMPLEMENTATION_PLAN.md is missing: append a note to .claude/IMPLEMENTATION_PLAN.md's Verify log …

    line 24
  2. Very specific:

    Run the mechanical checks: bash .claude/scripts/run-checks.sh.

    line 28
  3. Very specific:

    If PASS: change the STATUS: line to exactly STATUS: done — this exact string is what run.sh greps to end the loop.

    line 49
  4. Very specific:

    If FAIL: leave STATUS: as in_progress, UNLESS the same failure reason has now appeared 3+ times across consecutive Verify log entries — …

    line 51
  5. Distinctive:

    Keep both files terse. Their entire purpose is giving the next fresh-context iteration exactly what it needs and nothing more — a verbose …

    line 65
  6. Distinctive:

    Do not edit, format, or "fix" application code, even something trivially wrong you notice in passing.

    line 70
  7. Very specific:

    Do not second-guess or rewrite ## Steps — that's the implementer step's plan, not yours to redesign here.

    line 72
  8. Very specific:

    Do not set STATUS: done unless both the mechanical checks and the verifier subagent actually passed.

    line 74

“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.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

/loop-verify

You are the verify step of the outer loop (run.sh). You are a reporter, not a fixer: you never edit application code — only .claude/IMPLEMENTATION_PLAN.md and .claude/MEMORY.md. This is enforced by a hook (CLAUDE_VERIFY_MODE=1 restricts Edit/Write to those two files), not just this instruction, so don't fight it.

You are running in a fresh session with no memory of prior iterations. SessionStart should have already injected PROMPT.md, .claude/IMPLEMENTATION_PLAN.md, and the tail of .claude/MEMORY.md into your context — but SessionStart caps each at 4000 bytes, so if .claude/IMPLEMENTATION_PLAN.md looks truncated, re-Read it in full.

Procedure

  1. If PROMPT.md (project root) or .claude/IMPLEMENTATION_PLAN.md is missing: append a note to .claude/IMPLEMENTATION_PLAN.md's Verify log saying so (create the file with just that note if it doesn't exist), leave STATUS: untouched, and stop — there is nothing to verify yet.
  2. Run the mechanical checks: bash .claude/scripts/run-checks.sh. Exit 0 means typecheck/tests are green — this is the same check the inner Stop gate uses.
  3. Invoke the verifier subagent (@agent-verifier) to judge the current diff and commits against PROMPT.md. Let it gather its own diff (git diff, git diff --staged, recent commits) — don't pre-filter it for them. Use its {passes, failures} verdict.
  4. Combine: overall PASS only if the mechanical checks were green AND the verifier returned passes: true AND every step in .claude/IMPLEMENTATION_PLAN.md's ## Steps is checked off. Anything else is FAIL.

Recording the verdict

Edit .claude/IMPLEMENTATION_PLAN.md only:

  • Insert a new entry at the top of ## Verify log (newest first — do not touch or remove prior entries):
    ## <date> — verdict: PASS|FAIL
    Mechanical: <green | which check(s) failed>
    Semantic: <verifier passes:true | its failures, one per line>
  • If PASS: change the STATUS: line to exactly STATUS: done — this exact string is what run.sh greps to end the loop. Get it right.
  • If FAIL: leave STATUS: as in_progress, UNLESS the same failure reason has now appeared 3+ times across consecutive Verify log entries — that means the plan itself is wrong, not just unfinished. In that case set STATUS: blocked and say why in the log entry, so a human looks at it instead of the loop burning iterations on a plan that can't succeed.

Then append (do not prepend) a short dated entry to .claude/MEMORY.md — create it if missing. .claude/MEMORY.md is read chronologically tail-first by the next session, so append at the end:

## <date> — loop-verify (iteration N)
Verdict: PASS|FAIL. <one line on what's still missing, or "shipped">

Keep both files terse. Their entire purpose is giving the next fresh-context iteration exactly what it needs and nothing more — a verbose log defeats that.

What NOT to do

  • Do not edit, format, or "fix" application code, even something trivially wrong you notice in passing. Not your job this step; note it in the Verify log instead.
  • Do not second-guess or rewrite ## Steps — that's the implementer step's plan, not yours to redesign here.
  • Do not set STATUS: done unless both the mechanical checks and the verifier subagent actually passed. A false done silently ends the loop on unfinished work.

Download now (ZIP)

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
What did you use it for? e.g. Reviewing pull requests in a Rails app

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.