sdlc-diagnose

sdlc-diagnose is a command for coding agents from saitarrun/Devforge-ai. It costs 30 tokens per session (495 once invoked), scanned A, original, Apache-2.0.

A root-cause analysis and targeted-fix command for very large software projects. It traces an error from logs or a stack trace through the code and builds a test that reproduces the failure before changing anything.

In plain words
What is it for?
Use it to investigate failed calculations, server errors, or slow business rules; follow calls across services and database queries; create a reproducing test; and apply a minimal verified fix.
Why use it?
It narrows a problem to the responsible service or module instead of requiring a blind search through the whole codebase. It also checks the proposed fix against regression tests, which are tests that protect previously working behavior.

Command

Part of the devforge-ai plugin — 48 skills, 17 commands, 13 agents shipped together

Install

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.

agentmods
npx agentmods add commands/saitarrun/devforge-ai/sdlc-diagnose
Clone the repo
git clone --depth 1 https://github.com/saitarrun/Devforge-ai

Or install devforge-ai, the plugin that ships this one along with the rest of its 48 skills, 17 commands, 13 agents.

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

agentmods badge for sdlc-diagnose

README.md
[![agentmods](https://agentmods.dev/badge/commands/saitarrun/devforge-ai/sdlc-diagnose.svg)](https://agentmods.dev/commands/saitarrun/devforge-ai/sdlc-diagnose)
Your own site
<a href="https://agentmods.dev/commands/saitarrun/devforge-ai/sdlc-diagnose"><img src="https://agentmods.dev/badge/commands/saitarrun/devforge-ai/sdlc-diagnose.svg" alt="Measured on agentmods" height="20"></a>
Per session 30 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 495 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5 $0.00030 $0.00495
Opus 5 $0.00015 $0.00247
Sonnet 5 $0.00006 $0.00099
Haiku 4.5 $0.00003 $0.00049

Measured 4d ago against content hash dc4d15612e11, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

sdlc-diagnose 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.

commands/sdlc-diagnose.md · 45 lines

What it actually says

Automated Root Cause Analysis & Surgical Fix Command

This command conducts automated bisection, AST call-graph backtracking, and surgical remediation on massive, multi-million-file enterprise codebases without token bloat or blind file scans.

Usage

/sdlc-diagnose "Claim deductible calculation failed on policy renewal"
/sdlc-diagnose "500 Internal Error on /claims/payout" --service claims-engine
/sdlc-diagnose "Underwriting rule timeout on high-risk auto policies" --auto-fix

Process

  1. Domain & Subsystem Isolation:
    • Isolates the responsible service/module out of 1.5M+ files using stack traces, logs, and package boundaries.
  2. AST & Call-Graph Traversal:
    • Queries code-review-graph to build a structural execution chain from ingress controller down to the business calculation and database query.
  3. Reproducing Test Harness Construction:
    • Synthesizes a deterministic failing test case matching the exact error conditions before any code is modified.
  4. Surgical Remediation (Ralph Loop):
    • Formulates ranked hypotheses, instruments the failure point, executes minimal patch updates, and verifies the fix against the regression suite.
  5. Blast-Radius Verification:
    • Checks all dependent downstream modules to guarantee zero unintended side effects.

Output Format

### 🔍 Root Cause Analysis & Remediation Report

**Target Domain**: `apps/claims-engine/services/calculation.service.ts`
**Root Cause**: Precision truncation on line 142 during deductible calculation under high-deductible policy schema.

#### 🛠️ Surgical Remediation Applied
- **Test Harness**: `tests/unit/claims/deductible-calculation.spec.ts` (Reproduced & Passed)
- **Code Changes**: Modified `calculateNetPayout()` to use `BigNumber` decimal precision.
- **Blast-Radius Check**: Verified 6 dependent insurance services (Underwriting, Ledger, Billing).
- **Status**: ✅ All regression and contract tests passing.
Changes

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.

  1. 4d ago First seen · 45 lines · 30 tokens per session scan A dc4d15612e11

Subscribe to this mod's changes

sdlc-diagnose is a command published in the GitHub repository saitarrun/Devforge-ai (5 stars, last pushed 21d ago), licensed Apache-2.0. It adds 30 tokens to every session and 495 once invoked, about $0.0002 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-31.