rag-evaluation
暂无简介
- License 许可
- MIT
- 最近更新
- 2026-11-10
- Stars
- ★ 6
- Forks
- 0
03 SKILL.md 正文
RAG Evaluation
Goal
Determine whether the answer is truly grounded in retrieved evidence.
When to use
- Assessing RAG pipeline output quality
- Checking if answers are grounded in sources
- Diagnosing retrieval vs synthesis failures
- Evaluating chunking and ranking effectiveness
- Measuring hallucination risk in grounded systems
When not to use
- Non-retrieval chatbot prompts
- General prompt quality assessment
- Model fine-tuning decisions
- Infrastructure or deployment changes
- Use hallucination-debugging for diagnosing specific unsupported outputs
Inputs to collect
- User query
- Retrieved chunks or documents
- Final answer
- Citation behavior
- Retriever and reranker settings
Process
- Check relevance of retrieved context.
- Check for missing evidence.
- Compare answer against retrieved evidence only.
- Identify unsupported claims and overreach.
- Diagnose likely failure source.
- Recommend targeted fixes and eval cases.
Retrieval quality metrics
| Metric | Definition | Target |
|---|---|---|
| Precision@K | Relevant docs in top-K results | >0.7 |
| Recall@K | Relevant docs retrieved / total relevant | >0.8 |
| MRR | Mean Reciprocal Rank of first relevant result | >0.6 |
| NDCG | Normalized Discounted Cumulative Gain | >0.7 |
| Hit Rate | % of queries with at least 1 relevant result | >0.9 |
Grounding failure taxonomy
| Failure Type | Description | Detection |
|---|---|---|
| Hallucination | Model generates fact not in context | Compare output to retrieved docs |
| Contradiction | Model says X, context says not-X | Semantic similarity check |
| Irrelevance | Model answers different question | Question-answer alignment |
| Insufficiency | Context doesn't contain answer | Check if context has required info |
| Staleness | Context is outdated | Timestamp comparison |
Evaluation template
query: "What is the refund policy?"
context:
- doc1: "30-day refund policy for all products"
- doc2: "No refunds after 30 days"
expected_answer: "30-day refund policy for all products"
expected_docs: ["doc1"]
metrics:
precision@1: 1.0
recall@1: 0.5
faithfulness: 1.0
Inspection checklist
- [ ] Query matches user intent (not just keywords)
- [ ] Retrieved docs are relevant (not just containing keywords)
- [ ] Answer is grounded in retrieved docs (not from memory)
- [ ] Answer doesn't contradict retrieved docs
- [ ] Answer addresses the full question (not partial)
- [ ] Citation is accurate (doc actually says what's claimed)
Output format
- Retrieval quality
- Grounding quality
- Risks
- Likely failure source
- Fixes
- Eval suggestions
04 同仓库更多 Skills
invoice-organizer
Automatically organizes invoices and receipts for tax preparation by reading messy files, extracting key information, renaming them consistently, and sorting them into logical folders. Turns hours of manual bookkeeping into minutes of automated organization.
file-organizer
Intelligently organizes your files and folders across your computer by understanding context, finding duplicates, suggesting better structures, and automating cleanup tasks. Reduces cognitive load and keeps your digital workspace tidy without manual effort.
developer-growth-analysis
Analyzes your recent Claude Code chat history to identify coding patterns, development gaps, and areas for improvement, curates relevant learning resources from HackerNews, and automatically sends a personalized growth report to your Slack DMs.
connect
暂无简介
twitter-algorithm-optimizer
暂无简介
tailored-resume-generator
暂无简介