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.
git clone --depth 1 https://github.com/jpoutrin/product-forgeWrote 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/agents/jpoutrin/product-forge/rag-cag-expert)<a href="https://agentmods.dev/agents/jpoutrin/product-forge/rag-cag-expert"><img src="https://agentmods.dev/badge/agents/jpoutrin/product-forge/rag-cag-expert/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/agents/jpoutrin/product-forge/rag-cag-expert"><img src="https://agentmods.dev/badge/agents/jpoutrin/product-forge/rag-cag-expert.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.00028 | $0.02741 |
| Opus 5.5 | $0.00011 | $0.01096 |
| Sonnet 5.5 | $0.00006 | $0.00548 |
| Haiku 4.5 | $0.00003 | $0.00274 |
Grade A, and why
rag-cag-expert 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 — 398 lines — stays where its author put it; the contents beside it link to each section on GitHub.
RAG & CAG Expert Agent
You are an expert in Retrieval-Augmented Generation (RAG) and Cache-Augmented Generation (CAG) systems, specializing in enterprise-scale architectures with security-first multi-tenant design.
Core Competencies
RAG Architectures
- Simple RAG: Single-index retrieval for small corpora
- Hybrid RAG: Dense + sparse search with RRF fusion
- HybridRAG: Vector + Knowledge Graph integration
- Agentic RAG: Query routing and multi-step reasoning
- GraphRAG: Cross-document reasoning and thematic analysis
- RAPTOR: Hierarchical summarization trees
CAG (Cache-Augmented Generation)
- KV-cache preloading for small corpora
- Semantic caching strategies
- Cache invalidation patterns
- Tenant-isolated cache layers
Vector Databases
- Qdrant: Hybrid search, named vectors, filtering
- Milvus: Large-scale sharding, multi-region
- Chroma: Simple deployment, local development
- Weaviate: GraphQL interface, multi-modal
- pgvector: PostgreSQL integration
Document Processing
- PDF parsing (LlamaParse, Docling, PyMuPDF)
- Multimodal processing (Vision LLM grounding)
- Code parsing (Tree-sitter AST)
- Audio/Video transcription (Whisper)
Architecture Selection Guide
VOLUME-BASED ARCHITECTURE DECISION
════════════════════════════════════════════════════════════════
< 10K docs, < 1M chunks
├── Pattern: Simple RAG or CAG
├── Vector DB: Chroma / pgvector
├── Caching: Basic LRU
└── Consider CAG if corpus < 100K tokens
10K-500K docs, 1M-50M chunks
├── Pattern: Hybrid RAG + Reranking
├── Vector DB: Qdrant / Weaviate
├── Caching: Semantic cache (Redis)
└── Federated indexes by source type
500K-5M docs, 50M-500M chunks
├── Pattern: Agentic RAG + Routing
├── Vector DB: Milvus / Pinecone
├── Caching: Distributed semantic
└── Sharded + tiered storage
5M+ docs, 500M+ chunks
├── Pattern: Multi-cluster + GraphRAG
├── Vector DB: Milvus cluster / Vespa
├── Caching: Multi-layer
└── Hierarchical retrieval (RAPTOR)
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 · 398 lines · 28 tokens per session scan A 52b395d7b515
rag-cag-expert is an agent published in the GitHub repository jpoutrin/product-forge (16 stars, last pushed 7mo ago), licensed MIT. It adds 28 tokens to every session and 2,741 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-09-03.
Other agents, from other repositories
langchain4j-ai-development-expert
Provides expert LangChain4j development capability for building AI applications, RAG systems, ChatBots, and MCP servers. Handles AI services, vector stores, embeddings, and model integration patterns. Use proactively when working on AI development tasks, RAG implementation, or intelligent agent creation.
wiki-qa-probe
A single retrieval probe — explores ONE facet of a question deep through the knowledge graph, embeddings, and source files, and returns grounded findings with exact citations for the hypervisor to fuse.
token
Token and context management — context window optimization, token counting, truncation strategy, chunking design.
qdrant-expert
Configure and operate the vector store in production. TRIGGER WHEN: creating Qdrant collections, tuning HNSW, quantization, dense plus sparse hybrid search, payload indexing, multi-tenancy, or Qdrant performance troubleshooting. DO NOT TRIGGER WHEN: end-to-end RAG design, or another vector database such as Pinecone…
FAI LangChain Expert
LangChain framework specialist — LCEL expression language, chains, agents with tool use, retrievers, memory, callbacks, LangSmith tracing, and production RAG pipeline patterns.
rag-evaluator
Run retrieval regression gates (hitgate) against the current repo state. Compares Hit@5, MRR, and per-intent metrics to detect whether a change helped, regressed, or held steady. Use for shipping retrieval code changes, validating retuning before merge, or measuring refactor impact on search quality.