safe-debug

safe-debug is a skill for Codex from sutchan/Agent-Skills-Hub. It costs 44 tokens per session (474 once invoked), scanned A, a copy of safe-debug, MIT.

A careful debugging guide for deep-learning training and inference work. It focuses on finding the local cause of errors, crashes, or numerical problems before changing code.

In plain words
What is it for?
Investigating tracebacks, training failures, inference failures, unusual numerical values, and reproduction problems in research code.
Why use it?
It reduces the risk of making unnecessary changes while investigating a failed experiment or hard-to-reproduce result. It keeps diagnosis separate from proposing a fix.

Skill for Codex

Written for Codex: agents/openai.yaml present.

Good fit Investigating tracebacks, training failures, inference failures, unusual numerical values, and reproduction problems in research code.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/sutchan/agent-skills-hub/safe-debug
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.

Any agent
npx skills add sutchan/Agent-Skills-Hub --skill safe-debug
Clone the repo
git clone --depth 1 https://github.com/sutchan/Agent-Skills-Hub

Made for: 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 safe-debug

README.md
[![agentmods](https://agentmods.dev/badge/skills/sutchan/agent-skills-hub/safe-debug.svg)](https://agentmods.dev/skills/sutchan/agent-skills-hub/safe-debug)
Your own site
<a href="https://agentmods.dev/skills/sutchan/agent-skills-hub/safe-debug"><img src="https://agentmods.dev/badge/skills/sutchan/agent-skills-hub/safe-debug.svg" alt="Measured on agentmods" height="20"></a>
Per session 44 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 474 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin 92% copy Near-identical to another mod 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.1 $0.00044 $0.00474
Opus 5 $0.00022 $0.00237
Sonnet 5 $0.00009 $0.00095
Haiku 4.5 $0.00004 $0.00047

Measured 3d ago against content hash 1545ed98db84, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-07, from the pricing page.

Security

Grade A, and why

safe-debug 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 3d ago.

The scan reads SKILL.md. This mod also ships 1 executable file (scripts/safe_debug.py), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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.

Origin

This is a copy

92% identical to safe-debug — 10 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

skills/safe-debug/SKILL.md · 50 lines

What it actually says

safe-debug

Use this as the Rigor Debug / Rigor Audit skill. The installed slug remains safe-debug for compatibility.

Use the shared operating principles in ../../references/agent-operating-principles.md; this skill should guide conservative diagnosis without blocking the model from finding the local root cause.

When to apply

  • The user provides a traceback, terminal error, or concrete training or inference failure symptom.
  • The user wants diagnosis, root-cause narrowing, and minimal patch suggestions before code is changed.
  • The user wants a safe debug flow with explicit human approval before mutation.

When not to apply

  • When the user wants a broad repository walkthrough without an active failure.
  • When the task is speculative experimentation or code adaptation.
  • When the user is asking for a large refactor or readability rewrite.

Clear boundaries

  • Diagnose first.
  • Do not modify repository code by default.
  • If a patch is needed, propose the smallest fix and require explicit approval first.
  • Escalate savepoint or branch creation before medium-risk or high-risk changes.
  • A debug fix is not automatically a research contribution; if it changes experiment meaning or comparability, say so explicitly.

Output expectations

  • debug_outputs/DIAGNOSIS.md
  • debug_outputs/PATCH_PLAN.md
  • debug_outputs/status.json

Notes

Use references/debug-policy.md, ../../references/research-rigor-principles.md, and the shared ../../references/research-pitfall-checklist.md.

Files

What ships with it

3 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. 3d ago First seen · 50 lines · 44 tokens per session scan A 1545ed98db84

Subscribe to this mod's changes

safe-debug is a skill published in the GitHub repository sutchan/Agent-Skills-Hub (2 stars, last pushed today), licensed MIT. It adds 44 tokens to every session and 474 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. It is 92% identical to safe-debug, differing in 10 lines, and is treated as a copy.

Related

Other skills, from other repositories

systematic-debugging

Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.

obra/superpowers · 21 tokens

experiment-craft

Use this skill when the user wants to debug, diagnose, or systematically iterate on an experiment that already exists, or when they need a structured experiment log for tracking runs, hypotheses, failures, results, and next steps during active research. Apply it to underperforming methods, training that will not…

EvoScientist/EvoSkills · 172 tokens

error-resilience-expert

Expert guide for error handling patterns, resilience engineering, retry strategies, circuit breakers, and graceful degradation across React, Next.js, and Node.js / Panduan ahli pola penanganan error, rekayasa ketahanan, strategi retry, circuit breaker, dan degradasi anggun di React, Next.js, dan Node.js.

roedyrustam/vibes-plug · 72 tokens

logging-error-tracking-expert

Expert guide for structured logging (Pino, Winston), error tracking (Sentry), log aggregation (Axiom, Datadog), request correlation, and GDPR-compliant log management / Panduan ahli untuk logging terstruktur (Pino, Winston), pelacakan error (Sentry), agregasi log, korelasi request, dan manajemen log sesuai GDPR.

roedyrustam/vibes-plug · 81 tokens

dependency-upgrade-migrator

Expert guide for dependency upgrades, breaking change migrations, codemod automation, and package audit remediation / Panduan ahli untuk upgrade dependensi, migrasi breaking change, otomasi codemod, dan remediasi audit paket.

roedyrustam/vibes-plug · 52 tokens

app-analyzer-optimizer

Deeply analyzes application architecture and structure to perform audit, bottleneck detection, and code/performance optimization / Mempelajari arsitektur dan struktur aplikasi secara mendalam untuk melakukan audit, deteksi bottleneck, serta optimasi performa dan kode.

roedyrustam/vibes-plug · 56 tokens