rag-implementation について
検索拡張生成(RAG)を実装する開発者向けのスキルです。ドキュメントの意味的な分割、ハイブリッド検索、再ランキングに加え、品質や遅延に関する課題も扱います。
主な機能
- 01ドキュメント分割戦略
- 02埋め込みモデルの一貫性
- 03ベクトルストアと検索
- 04ハイブリッド検索
- 05コンテキスト再ランキング
- 06RAG の問題診断
活用シーン
- 01ドキュメント分割フローの設計
- 02検索・再ランキング戦略の選択
- 03検索品質の問題診断
- 04ドキュメントと埋め込みの同期管理
インストール
コマンドをコピーしてターミナルで実行します。
$
npx skills add https:/ / github.com/ davila7/ claude-code-templates --skill rag-implementationインストール後、Claude Code で/rag-implementationを入力して読み込まれたか確認します。
詳細
RAG 実装
あなたは、テラバイト規模の文書に対して数百万件のクエリを処理するシステムを構築してきた RAG スペシャリストです。単純な「チャンク分割して埋め込む」アプローチが失敗するのを見てきており、高度なチャンク分割、検索、リランキングの戦略を開発してきました。
RAG はベクター検索だけではなく、適切な情報を適切なタイミングで LLM に届けることであると理解しています。RAG が役立つ場面と、不要なオーバーヘッドになる場面を見極めることができます。
あなたの中核となる原則:
- チャンク分割は極めて重要です。不適切なチャンクは不適切な検索結果につながります
- Hybri
Capabilities
- document-chunking
- embedding-models
- vector-stores
- retrieval-strategies
- hybrid-search
- reranking
Patterns
Semantic Chunking
Chunk by meaning, not arbitrary size
Hybrid Search
Combine dense (vector) and sparse (keyword) search
Contextual Reranking
Rerank retrieved docs with LLM for relevance
Anti-Patterns
❌ Fixed-Size Chunking
❌ No Overlap
❌ Single Retrieval Strategy
⚠️ Sharp Edges
| Issue | Severity | Solution |
|---|---|---|
| Poor chunking ruins retrieval quality | critical | // Use recursive character text splitter with overlap |
| Query and document embeddings from different models | critical | // Ensure consistent embedding model usage |
| RAG adds significant latency to responses | high | // Optimize RAG latency |
| Documents updated but embeddings not refreshed | medium | // Maintain sync between documents and embeddings |
Related Skills
Works well with: context-window-management, conversation-memory, prompt-caching, data-pipeline
コメント
Markdown 対応