diagnose

diagnose is a skill for Claude Code, Codex from SetraTheXX/Codex-Engineering-Workflow-Pack. It costs 48 tokens per session (1,135 once invoked), scanned A, original, MIT.

A structured debugging process for finding the cause of bugs, regressions, flaky behavior, or unexpected slowness before changing code.

In plain words
What is it for?
Use it to investigate broken features, failures, intermittent problems, performance surprises, or behavior that has changed.
Why use it?
It replaces guesswork with a reproducible symptom, a quick pass-or-fail check, narrowed causes, and a regression check after the fix.

Skill for Claude CodeCodex

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 skills/setrathexx/codex-engineering-workflow-pack/diagnose
Any agent
npx skills add SetraTheXX/Codex-Engineering-Workflow-Pack --skill diagnose
Clone the repo
git clone --depth 1 https://github.com/SetraTheXX/Codex-Engineering-Workflow-Pack

Made for: Claude Code, Codex.

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 diagnose

README.md
[![agentmods](https://agentmods.dev/badge/skills/setrathexx/codex-engineering-workflow-pack/diagnose.svg)](https://agentmods.dev/skills/setrathexx/codex-engineering-workflow-pack/diagnose)
Your own site
<a href="https://agentmods.dev/skills/setrathexx/codex-engineering-workflow-pack/diagnose"><img src="https://agentmods.dev/badge/skills/setrathexx/codex-engineering-workflow-pack/diagnose.svg" alt="Measured on agentmods" height="20"></a>
Per session 48 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,135 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.00048 $0.01135
Opus 5 $0.00024 $0.00567
Sonnet 5 $0.00010 $0.00227
Haiku 4.5 $0.00005 $0.00113

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

Security

Grade A, and why

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.

.agents/skills/diagnose/SKILL.md · 200 lines

How it starts

The opening of the file, as written. The whole thing — 200 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Diagnose

Diagnose bugs by building a reliable feedback loop, proving the symptom, narrowing the cause, fixing the smallest responsible behavior, and leaving a regression check behind.

Do not jump straight to a fix. A plausible fix without a reproduced symptom is guesswork.

Read First

Before changing code, inspect project setup:

  • docs/agents/test-commands.md
  • docs/agents/domain.md
  • CONTEXT.md
  • relevant ADRs under docs/adr/
  • package scripts or equivalent task definitions

If setup docs are missing, infer commands from the repo. If commands remain unclear, ask the user one focused question.

Use the repo's domain language when describing the failure and suspected modules.

Workflow

1. State The Symptom

Restate the user-visible failure in one or two sentences.

Capture:

  • What is expected.
  • What actually happens.
  • Where it happens.
  • Whether it is deterministic, flaky, or performance-related.

If the symptom is ambiguous, ask for the missing observation before changing code.

2. Build A Pass/Fail Feedback Loop

Create or identify the fastest command or action that can prove the bug exists.

Prefer this order:

  1. Focused failing test.
  2. Existing test command that already fails for the right reason.
  3. CLI command with fixture input.
  4. HTTP request against local dev server.
  5. Browser automation for UI bugs.
  6. Small throwaway harness near the relevant code.
  7. Replayed payload, log, trace, or fixture.
  8. Repeated stress loop for flaky behavior.

The loop must be:

  • Runnable by Codex.
  • Specific to the user's symptom.
  • Deterministic when possible.
  • Fast enough to repeat.

If no loop can be built, stop and explain what was tried. Ask for a log, fixture, repro steps, recording, environment access, or permission to add temporary instrumentation.

See references/feedback-loop-patterns.md for options.

3. Reproduce

Run the loop and verify it fails for the same reason the user reported.

Record:

  • Command or action used.
  • Exact failure text, wrong output, timing, or visible behavior.
  • Whether the failure repeated.

Read the full file on GitHub · 200 lines

Files

What ships with it

2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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 · 200 lines · 48 tokens per session scan A 32174628352d

Subscribe to this mod's changes

diagnose is a skill published in the GitHub repository SetraTheXX/Codex-Engineering-Workflow-Pack (1 stars, last pushed 4d ago), licensed MIT. It adds 48 tokens to every session and 1,135 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.

Related

Other skills, from other repositories

hns-lsel-curator

Local Self-Evolution Loop (LSEL) curator — the CLUSTER + drain engine for the GOOS-local PROPOSE→APPLY seam closure (SPEC-LSEL-LOCAL-EVOLUTION-001). Companion-offset drain of .moai/lessons-inbox.jsonl with a drain-side severity filter that drops the 65% Bash-timeout/sandbox noise, eventkey clustering with a frequency…

modu-ai/moai-adk · 135 tokens

hns-workflow-ci-loop

Unified CI watch + auto-fix loop skill. Polls gh pr checks after /moai sync PR creation, classifies required vs auxiliary failures, attempts safe automated patches (max 3 iterations), and escalates semantic failures to the user. Use for CI loop workflow — NOT for general loop iteration patterns (see…

modu-ai/moai-adk · 76 tokens

moai-kanban-foreman

One unattended kanban foreman iteration: watch the backlog queue, dispatch the next operator-picked card to an isolated worker, collect completion evidence on read (not on claims), and report. This is the body the project's loop.md driver invokes each iteration of a bare /loop; it can also be invoked directly to test…

modu-ai/moai-adk · 76 tokens

moai-harness-learner

Harness learning subsystem coordinator. Produces Tier 4 auto-update proposal payloads consumed by the orchestrator (which surfaces them via AskUserQuestion) and orchestrates Apply/Rollback flows. Triggers when harness learning proposals are pending or learning lifecycle management is needed.

modu-ai/moai-adk · 61 tokens

moai-workflow-thinking

Sequential Thinking MCP for structured step-by-step analysis via --deepthink flag. Separate from UltraThink which is Claude's native extended reasoning mode. Use for multi-step analysis or architecture decisions.

modu-ai/moai-adk · 43 tokens

hns-oss-docs-readme-sync

README 4-file synchronization procedure for the oss-docs harness: Korean README.ko.md as primary source, en/ja/zh derivation, the shared language-switcher header contract, section-order parity checklist, and the manual verification recipe (no linter exists for READMEs). Loaded by the content-author and…

modu-ai/moai-adk · 83 tokens