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 skills/fcakyon/phd-skills/debugnpx skills add fcakyon/phd-skills --skill debuggit clone --depth 1 https://github.com/fcakyon/phd-skillsWhat 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.00097 | $0.01281 |
| Opus 5 | $0.00048 | $0.00641 |
| Sonnet 5 | $0.00019 | $0.00256 |
| Haiku 4.5 | $0.00010 | $0.00128 |
Grade A, and why
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 2d 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 — 126 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Debug: evidence-before-action investigation
The most expensive class of mistake in ML debugging is asserting a cause based on plausibility, then attempting a "fix" that masks the real problem. This skill enforces the discipline of probe → hypothesis → smoke → controls → claim, in that order.
The agentic Stop hook routes here from reason when an assistant claims a cause without backing tool output.
When to run
The user just said any of:
- "why is X failing / diverging / NaN / OOM / hung / slow / crashed"
- "the loss is going up", "metrics look weird", "GPU util is 0"
- "debug this", "diagnose", "troubleshoot", "investigate this run"
- pasted a log excerpt asking what's wrong
Five-step protocol
Step 1: cheap probes
Before forming any hypothesis, gather the cheap evidence. None of these cost more than a few seconds:
Process state:
ps aux | grep -E '(python|train|torchrun|accelerate)' | grep -v grep
Is the process still running? Zombie? Defunct? Multiple instances?
Kernel / system events:
dmesg | tail -100 # OOM kills, hardware errors, NFS errors
journalctl -xe --since "1 hour ago" | tail -50
GPU state:
nvidia-smi
nvidia-smi --query-gpu=utilization.gpu,memory.used,temperature.gpu --format=csv
Is the GPU even being used? Idle GPU during "training" means the process is blocked on data loading or has died.
Disk / filesystem:
df -h /path/to/run-dir
du -sh /path/to/run-dir/*
Out of disk? Checkpoints not being written?
Log scrollback: Read the last few hundred lines of the training log. Don't trust the user's summary, they may have skimmed. Look for:
- exception tracebacks
- repeated "loss=NaN" or "grad_norm=Inf"
- early-stop announcements (the run may have completed normally)
- the last successful epoch / step (where did progress stop)
Checkpoint state:
ls -la /path/to/run-dir/checkpoints/
When was the last checkpoint written? What does its size suggest? An empty .pt is different from a 2GB one cut short.
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.
- 2d ago First seen · 126 lines · 97 tokens per session scan A 4577b9681f1c
debug is a skill published in the GitHub repository fcakyon/phd-skills (380 stars, last pushed 2mo ago), licensed MIT. It adds 97 tokens to every session and 1,281 once invoked, about $0.0005 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 skills, from other repositories
explore-recent-papers
Downloads and deeply analyzes the full text of recent papers from an academic journal using markitdown to convert PDFs to Markdown. Use when recent-papers context is missing or needs refreshing before a paper review.
generate-pdf
Converts a Markdown review report to a professionally formatted PDF using pandoc with XeLaTeX. Use after the final review report Markdown has been compiled to produce the PDF deliverable.
review-paper
Run the Agentic Reviewer academic paper review pipeline for a paper and target journal or conference.
convert-paper
Converts non-Markdown papers (PDF, DOCX, PPTX, XLSX, HTML, etc.) to Markdown using markitdown. Use when a paper file needs to be converted before the review pipeline can process it.
lc_arxiv
ArXiv 学术论文搜索.
review-writing-style
Reviews writing quality, clarity, structure, grammar, argumentation, and content-level style compliance of an academic paper in Markdown format. Use when assessing the writing and style dimension of a paper under review.