Borrowing it
Nothing to install: this file belongs to TakaGoto/rag-learning-academy. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/TakaGoto/rag-learning-academy/main/.claude/skills/debug-rag/SKILL.mdgit clone --depth 1 https://github.com/TakaGoto/rag-learning-academyWrote 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/skills/takagoto/rag-learning-academy/debug-rag)<a href="https://agentmods.dev/skills/takagoto/rag-learning-academy/debug-rag"><img src="https://agentmods.dev/badge/skills/takagoto/rag-learning-academy/debug-rag/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/takagoto/rag-learning-academy/debug-rag"><img src="https://agentmods.dev/badge/skills/takagoto/rag-learning-academy/debug-rag.svg" alt="Reviewed on agentmods" width="80" 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.1 | $0.00013 | $0.01413 |
| Opus 5.5 | $0.00005 | $0.00565 |
| Sonnet 5.5 | $0.00003 | $0.00283 |
| Haiku 4.5 | $0.00001 | $0.00141 |
Grade A, and why
debug-rag 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 1mo 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 — 114 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Debug RAG: Diagnose and Fix Pipeline Issues
Scope: This skill teaches debugging through guided diagnosis and explanation. For a fast fix without the teaching, use
/fix.
An interactive debugging workflow that helps learners identify and resolve common RAG failure modes. This skill builds debugging intuition alongside technical problem-solving.
Language awareness: See
.claude/LANGUAGE_AWARENESS.md.
Step 1: Identify the Symptom
Ask the learner to describe the problem they are seeing. Common symptoms include:
- Hallucination: The model generates information not in the retrieved context
- Irrelevant retrieval: The retrieved documents do not match the query
- Missing context: Relevant information exists in the corpus but is not retrieved
- Incomplete answers: The answer is partially correct but missing key details
- Contradictory answers: The answer contradicts the source documents
- Repetitive or generic responses: The model ignores context and gives generic answers
- Wrong format: The answer is correct but not in the expected format
- High latency: The pipeline is too slow
If the learner is not sure, ask them to share an example query, the expected answer, and the actual answer.
Step 2: Follow the Diagnostic Tree
Based on the symptom, walk through the appropriate diagnostic path:
For Retrieval Issues (irrelevant results, missing context)
Start by inspecting what the retriever actually returns:
Provide diagnostic code in the learner's chosen language that retrieves results and prints scores, sources, and text previews.
- Check the query: Is the query well-formed? Try rephrasing it.
- Inspect chunks: Look at the actual chunks in the vector store. Are they the right size? Do they contain the expected information?
- Test embedding similarity: Compute the similarity between the query embedding and the expected chunk embedding. Is it above the retrieval threshold?
- Check top-k: Are you retrieving enough documents? Try increasing top-k.
- Examine metadata filters: Are any filters accidentally excluding relevant results?
- Compare search methods: Try keyword search alongside vector search to see if the issue is in the embeddings.
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.
- 1mo ago First seen · 114 lines · 13 tokens per session scan A 197c76bc06c6
debug-rag is a skill published in the GitHub repository TakaGoto/rag-learning-academy (24 stars, last pushed 6mo ago), licensed MIT. It adds 13 tokens to every session and 1,413 once invoked, about $0.0001 per session on Opus 5.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
autorag-doctor
Diagnose and repair a broken or half-working AutoRAG install so every configured source is both indexed and searchable. Checks AutoRAG, MinSync, Jikji, the embedding backend, and every CLI-backed datasource (lazykatok, discrawl, slacrawl, wacrawl, telecrawl, notcrawl, mailcrawl, rclone, Spotlight), then fixes orphan…
browserwing-admin
Manage and operate BrowserWing — an intelligent browser automation platform. Install dependencies, configure LLM, create/manage/execute automation scripts, use AI-driven exploration to generate scripts, browse the script marketplace, and troubleshoot issues.
profile-vllm-performance
Profile vLLM and RT-VLM inference to identify and remove GPU-idle gaps, underfilled batches, transfer stalls, serialized multimodal work, scheduler gaps, or KV pressure. Use this skill when GPU utilization is unexpectedly low or bursty, capacity trails another runtime, TTFT or ITL regresses, or multimodal prefill and…
rag-architecture-review
Review an existing Retrieval-Augmented Generation system and find why it underperforms. Use when asked to review or audit a RAG pipeline, diagnose wrong/ungrounded answers from a 'chat with your docs' feature, or improve an already-built knowledge assistant. Produces a staged review — ingestion, chunking, retrieval…
rag-index-decisions
After making a non-obvious architectural decision, solving a novel bug, agreeing on a coding standard, or reaching a conclusion worth remembering, index it back into the knowledge base so the next occurrence is one search away. Uses adddocument or addfromurl. Closes the feedback loop that makes a RAG-backed team…
rag-blueprint
NVIDIA RAG Blueprint — deploy, configure, troubleshoot, and manage. Handles any RAG action: deploy, install, start, enable, disable, toggle, change, configure, troubleshoot, debug, fix, shutdown, stop, or tear down any RAG feature or service (Agentic RAG, VLM, guardrails, query rewriting, models, search, ingestion…