sdd-monitor
Skill0 starsChanged 8 months agoMITView on GitHub
Performs gap analysis, convergence tracking, and drift detection for SDD projects. Compares specs against implementation, checks Ralph loop convergence, identifies stale work, and flags non-convergent tasks. Use to check project health or diagnose stalled loops.
In this repository13 other files it gives its agents.
- AGENTS.mdAGENTS.md
- sdd-adrSkill
- sdd-implementSkill
- sdd-initSkill
- sdd-iterateSkill
- sdd-planSkill
- sdd-reviewSkill
- sdd-runSkill
- sdd-specSkill
- sdd-standupSkill
- sdd-statusSkill
- sdd-triageSkill
- sdd-ux-validateSkill
The file
We split this skill into the rules it gives an agent
11 rules. About 0 are common, 4 are distinctive, and 7 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈4
Distinctive · estimate
This author's own choices. Worth a look.
7
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 18
Use MCP tool sdd_convergence_check to analyze Ralph loop metrics.
- Distinctive: line 21
Test pass-rate has been flat for 3 consecutive iterations, AND
- Distinctive: line 32
Test pass-rate trending up
- Very specific: line 43
Use MCP tool sdd_query_tasks (filter: all) and sdd_query_specs (field: requirements) to cross-reference:
- Very specific: line 51
Read context/impl/backprop-log.json for unverified backpropagation entries
- Very specific: line 52
Check for recent commits classified as manual-fix that haven't been through /sdd-iterate
- Very specific: line 53
Look for modified files in context/specs/ without corresponding Backprop-From trailers
- Distinctive: line 55
ADR conformance drift: check that no Accepted ADR has been silently contradicted by recent commits (best-effort.
- Very specific: line 61
Read the tool's response and branch on threshold_breach:
- Very specific: line 68
If status is no_log or parse_error, report NONE with a note that the cluster check could not run.
- Distinctive: line 122
Read-only analysis (no file modifications)
≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
SDD Monitor
Continuous health check for SDD projects.
Arguments
$ARGUMENTS — optional: "convergence" (focus on Ralph metrics), "gaps" (focus on spec coverage), or "drift" (focus on spec-vs-code alignment). If omitted, runs all checks.
Process
1. Convergence check (multi-signal halt rule)
Use MCP tool sdd_convergence_check to analyze Ralph loop metrics. Replace the old single-signal 4/delta heuristic with the multi-signal halt rule:
HALT signal (loop is not making progress; stop and escalate):
- Test pass-rate has been flat for 3 consecutive iterations, AND
- Diff-similarity between consecutive iterations exceeds 80% (the agent is making the same change repeatedly), AND
- The same error message has appeared in the last 3 iterations
WARN signals (concerning, but loop may still recover):
- Files-changed-per-iteration is increasing (diverging trend) — specs may be too vague
- Any story at HIGH convergence risk (attempts > 70% of maxAttempts)
- Escalated stories that haven't been triaged
HEALTHY signals:
- Files-changed-per-iteration decreasing or stable
- Test pass-rate trending up
- Diff-similarity dropping (the agent is exploring genuinely different solutions)
Root-cause hints when DIVERGING: print one of the following based on signal mix:
- "Specs may be too vague." — when banned-vague-verb count in referenced specs > 0
- "Validation may be too weak." — when test count per spec requirement < 1
- "Story may be too large." — when complexity budget was exceeded in ≥2 attempts
- "Try /sdd-iterate to harden specs." — default fallback
2. Spec coverage gaps
Use MCP tool sdd_query_tasks (filter: all) and sdd_query_specs (field: requirements) to cross-reference:
- For each spec requirement: is it covered by at least one story?
- For each story: does it reference valid spec requirement IDs?
- Are there code files not traced to any spec? (check recent commits without
Spec-Reftrailers)
3. Drift detection
Compare specs against current implementation:
- Read
context/impl/backprop-log.jsonfor unverified backpropagation entries - Check for recent commits classified as
manual-fixthat haven't been through/sdd-iterate - Look for modified files in
context/specs/without correspondingBackprop-Fromtrailers - Regression corpus health: count entries where
regression_corpus_pass: false. Any non-zero value is CRITICAL drift. - ADR conformance drift: check that no Accepted ADR has been silently contradicted by recent commits (best-effort; flags only obvious cases).
4. Methodology risk (clustered-backprop)
Use MCP tool sdd_cluster_check to surface cumulative-amendment pressure on individual specs. Methodology risk is a distinct dimension from drift: drift says "a specific change slipped past the spec — fix it"; methodology risk says "this spec keeps getting amended — iteration is unlikely to converge, consider stepping back to characterization." Keep the two signals separate in the report.
Read the tool's response and branch on threshold_breach:
none— no warn or hard-stop specs; reportNONE.warn— one or more specs have 3-4 cumulative amendments. Surface them by name. Recommendation: "consider whether further iteration is productive."hard-stop— one or more specs have 5+ cumulative amendments. Surface them by name, and for each include theplan_presentindicator frombreaching_specs[]. Recommendation depends onoverride_active:- Hard-stop without characterization plan (
override_active: false): "iteration is currently halted by/sdd-iteratecluster check; create a characterization plan or step back." - Hard-stop with characterization plan (
override_active: true): "override active — iteration may proceed but the methodology signal stands."
- Hard-stop without characterization plan (
If status is no_log or parse_error, report NONE with a note that the cluster check could not run.
5. Staleness check
- Specs with no activity in >7 days (no related commits)
- Stories with
attempts > 0but no commits in >3 days (stalled implementation) - Backpropagation entries with
verified_via_ralph: falseolder than 3 days
6. Report
## SDD Health Report
### Convergence: {HEALTHY | WARNING | HALT}
- HALT signal: {triggered | not triggered} ({which conditions met})
- Trend: {decreasing | stable | diverging}
- Iterations analyzed: {N}
- Avg diff/iteration: {N} lines
- Test pass-rate trend: {up | flat | down}
- Diff-similarity (last 2 iters): {N}%
- Recurring error: {message or "none"}
- Root-cause hint (if diverging): {one of the four}
- At-risk stories: {list or "none"}
### Spec Coverage: {COMPLETE | PARTIAL | GAPS}
- Requirements covered: {N}/{total}
- Uncovered requirements: {list or "none"}
- Orphan stories (no spec link): {list or "none"}
- Untraced code changes: {N} commits without Spec-Ref
### Drift: {CLEAN | DRIFT_DETECTED | CRITICAL}
- Manual fixes not backpropagated: {N}
- Unverified backpropagation entries: {N}
- Spec modifications without Backprop-From: {N}
- Regression corpus failures: {N} (any non-zero = CRITICAL)
- Possible ADR contradictions: {list or "none"}
### Methodology risk: {NONE | WARN | HALT}
- Specs at warn (3-4 cumulative amendments): {list or "none"}
- Specs at hard-stop (5+ cumulative amendments): {list with plan_present indicator or "none"}
- Halt status: {iteration halted | override active | not applicable}
- Recommendation: {one of the three above based on state}
### Staleness: {ACTIVE | STALE}
- Stale specs: {list or "none"}
- Stalled stories: {list or "none"}
### Recommended Actions
1. {highest priority action}
2. {second priority action}Output contract
- Read-only analysis (no file modifications)
- Uses MCP tools for structured data
- Multi-signal halt rule replaces 4/delta heuristic
- Surfaces actionable recommendations with root-cause hints
- Quantifies health across 4 dimensions including regression corpus health
- Methodology risk surfaced as a distinct dimension from drift, sourced from
sdd_cluster_check
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.

