Borrowing it
Nothing to install: this file belongs to brifl/coding-agent-orchestration. 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/brifl/coding-agent-orchestration/main/.codex/skills/rag-index/SKILL.mdgit clone --depth 1 https://github.com/brifl/coding-agent-orchestrationWrote 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/brifl/coding-agent-orchestration/rag-index)<a href="https://agentmods.dev/skills/brifl/coding-agent-orchestration/rag-index"><img src="https://agentmods.dev/badge/skills/brifl/coding-agent-orchestration/rag-index/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/brifl/coding-agent-orchestration/rag-index"><img src="https://agentmods.dev/badge/skills/brifl/coding-agent-orchestration/rag-index.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.00017 | $0.00594 |
| Opus 5.5 | $0.00007 | $0.00238 |
| Sonnet 5.5 | $0.00003 | $0.00119 |
| Haiku 4.5 | $0.00002 | $0.00059 |
Grade A, and why
rag-index 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 2mo 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 — 61 lines — stays where its author put it; the contents beside it link to each section on GitHub.
rag-index
Purpose
Prototype utilities for building a repo index used by retrieval-augmented prompts. The workflow is scan -> index -> retrieve, with a one-shot pipeline for ad-hoc use.
Scripts
scanner.py— recursive directory scanner that emits deterministic JSON manifestsindexer.py— chunk-aware SQLite index builder and lexical search (build,search)retrieve.py— prompt-context formatter that consumes chunk-level search results (retrieve,pipeline)
How to use
- Generate a manifest (scanner):
python3 scanner.py <path1> <path2> --output manifest.json- Common options:
--file-types .py .md--max-depth 2--exclude "*.venv*" "*.git*"--statsto print exclusion counts
- Build/update an index (indexer):
python3 indexer.py build --manifest manifest.json --output index.db- Incremental behavior:
- unchanged files are skipped
- changed files update only changed chunks
- removed files/chunks are deleted
- Search the index (indexer):
python3 indexer.py search "query" --index index.db --top-k 5- Returns chunk-level records (
path,rel_path,start_line,end_line,chunk_id,snippet)
- Retrieve prompt-ready context (retrieve):
python3 retrieve.py "query" --index index.db --top-k 5- Useful options:
--max-context-chars 8000hard output budget--max-per-file 3diversity cap--mode lex|sem|hybrid(semuses TF-IDF cosine;hybridblends lexical + semantic scores)
- One-shot pipeline (retrieve):
python3 retrieve.py pipeline "query" --dirs <path1> <path2>- Optional:
--index /tmp/rag.dbto persist index--max-depth 2--file-types .py .md
- This runs scan -> build -> retrieve in one command.
When to use RAG
Use RAG when:
- the question depends on repository-specific behavior or contracts
- the answer needs exact symbols, paths, config keys, or line ranges
- the agent is uncertain and needs grounded evidence from code/docs
What ships with it
5 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
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.
- 2mo ago First seen · 61 lines · 17 tokens per session scan A 7d936234ad52
rag-index is a skill published in the GitHub repository brifl/coding-agent-orchestration (22 stars, last pushed 15d ago), licensed MIT. It adds 17 tokens to every session and 594 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
embeddings
Vector embeddings with HNSW indexing, sql.js persistence, and hyperbolic support. 75x faster with agentic-flow integration. Use when: semantic search, pattern matching, similarity queries, knowledge retrieval. Skip when: exact text matching, simple lookups, no semantic understanding needed.
agent-platform-rag-engine-management
Manage and query Agent Platform RAG Engine Corpora and retrieve grounded contexts using the Google GenAI SDK. Use when listing RAG corpora or files, inspecting a corpus, retrieving contexts, or generating content grounded in a RAG corpus. Do not use for standard database queries (use SQL/Spanner skills), Google…
llm-app-patterns
Production-ready patterns for building LLM applications. Covers RAG pipelines, agent architectures, prompt IDEs, and LLMOps monitoring. Use when designing AI applications, implementing RAG, building agents, or setting up LLM observability.
9router-embeddings
Generate vector embeddings via 9Router /v1/embeddings using OpenAI / Gemini / Mistral / Voyage / Nvidia / GitHub embedding models for RAG, semantic search, similarity. Use when the user wants embeddings, vectors, RAG, semantic search, or to embed text.
embedding-strategies
Select and optimize embedding models for semantic search and RAG applications. Use when choosing embedding models, implementing chunking strategies, or optimizing embedding quality for specific domains.
similarity-search-patterns
Implement efficient similarity search with vector databases. Use when building semantic search, implementing nearest neighbor queries, or optimizing retrieval performance.