Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add commands/marcusgoll/spec-flow/workflow-repairgit clone --depth 1 https://github.com/marcusgoll/Spec-FlowWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/commands/marcusgoll/spec-flow/workflow-repair)<a href="https://agentmods.dev/commands/marcusgoll/spec-flow/workflow-repair"><img src="https://agentmods.dev/badge/commands/marcusgoll/spec-flow/workflow-repair.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00027 | $0.03043 |
| Opus 5 | $0.00014 | $0.01522 |
| Sonnet 5 | $0.00005 | $0.00609 |
| Haiku 4.5 | $0.00003 | $0.00304 |
Grade A, and why
workflow-repair scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 444 lines — stays where its author put it; the contents beside it link to each section on GitHub.
/workflow repair - State Recovery Command
Use when:
/feature continueor/epic continuefails unexpectedly- state.yaml has invalid phase or status
- domain-memory.yaml has stale locks
- Workflow appears stuck with no clear error
- Need to reset to a known good state
Active Workflows:
!find specs epics -name "state.yaml" -exec dirname {} \; 2>/dev/null | head -5
Recent State Files:
!find specs epics -name "state.yaml" -mmin -60 2>/dev/null | head -3
Locked Features (potential stale locks):
!grep -l "locked_by:" specs/*/domain-memory.yaml epics/*/domain-memory.yaml epics/*/sprints/*/domain-memory.yaml 2>/dev/null | head -5
auto (Default)
Automatically diagnose and fix common issues:
- Detect workflow type and location
- Run all diagnostic checks
- Apply safe fixes automatically
- Report what was fixed
diagnose
Only diagnose - don't fix anything:
- Check state.yaml validity
- Check domain-memory.yaml consistency
- Check artifact presence vs phase claims
- Report issues found
reset-phase <phase_name>
Reset workflow to specific phase:
- Update state.yaml to specified phase
- Clear phase completion markers after that phase
- Preserve artifacts from completed phases
clear-locks
Clear all stale locks in domain-memory.yaml:
- Find all locked features
- Remove lock metadata
- Reset feature status to previous state
rebuild-state
Rebuild state.yaml from artifacts:
- Scan for existing artifacts (spec.md, plan.md, tasks.md)
- Infer completed phases from presence
- Generate new state.yaml
Step 1: Detect Active Workflow
# Find most recent active workflow
WORKFLOW_INFO=$(bash .spec-flow/scripts/utils/detect-workflow-paths.sh 2>/dev/null)
if [ -z "$WORKFLOW_INFO" ]; then
echo "No active workflow detected."
echo "Looking for any workflow with state.yaml..."
# Fallback: find any state.yaml
STATE_FILE=$(find specs epics -name "state.yaml" -type f 2>/dev/null | head -1)
if [ -z "$STATE_FILE" ]; then
echo "No workflows found. Nothing to repair."
exit 0
fi
WORKFLOW_DIR=$(dirname "$STATE_FILE")
else
WORKFLOW_DIR=$(echo "$WORKFLOW_INFO" | jq -r '"\(.base_dir)/\(.slug)"')
fi
echo "Repairing workflow at: $WORKFLOW_DIR"
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 4d ago First seen · 444 lines · 27 tokens per session scan A ea094e3df0c3
workflow-repair is a command published in the GitHub repository marcusgoll/Spec-Flow (92 stars, last pushed 4mo ago), licensed MIT. It adds 27 tokens to every session and 3,043 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other commands, from other repositories
tidy
Consistency check for non-code repos with INDEX.md hierarchy. Verifies INDEX.md accuracy, MEMORY.md references, orphaned files, stale dates, and WAITING markers.
new
Завести новый проект в памяти. Аргумент: $ARGUMENTS.
tails
Разбудить текущую сессию — перечитать, показать недоделанные хвосты и предложить добить их одной командой.
go
Старт сессии. Опциональный аргумент — номер проекта. Аргумент: $ARGUMENTS.
save
Выполни workflow "сохранись" из MEMORY.md (раздел «сохранись / save» — единственный источник шагов; здесь НЕ дублируем детали формата).
r-util-claudemd-review
Analyze recent conversations to find improvements for CLAUDE.md files, and audit existing CLAUDE.md content for prose drift and memory-bound state contamination. Read-only report — no modifications.