rag-system-builder

Build Retrieval-Augmented Generation (RAG) Q&A systems with Codex or OpenAI. Use for creating AI assistants that answer questions from document collections, technical libraries, or knowledge bases.

5 stars

Best use case

rag-system-builder is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Build Retrieval-Augmented Generation (RAG) Q&A systems with Codex or OpenAI. Use for creating AI assistants that answer questions from document collections, technical libraries, or knowledge bases.

Teams using rag-system-builder should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/rag-system-builder/SKILL.md --create-dirs "https://raw.githubusercontent.com/vamseeachanta/workspace-hub/main/.agents/skills/data/documents/rag-system-builder/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/rag-system-builder/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How rag-system-builder Compares

Feature / Agentrag-system-builderStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Build Retrieval-Augmented Generation (RAG) Q&A systems with Codex or OpenAI. Use for creating AI assistants that answer questions from document collections, technical libraries, or knowledge bases.

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

SKILL.md Source

# Rag System Builder

## Overview

This skill creates complete RAG (Retrieval-Augmented Generation) systems that combine semantic search with LLM-powered Q&A. Users can ask natural language questions and receive accurate answers grounded in your document collection.

## Quick Start

```python
from sentence_transformers import SentenceTransformer
import anthropic

# Setup
model = SentenceTransformer('all-MiniLM-L6-v2')
client = anthropic.Anthropic()

# Retrieve context (simplified)
query = "What are the safety requirements?"
query_embedding = model.encode(query, normalize_embeddings=True)
# ... search for similar chunks ...

# Generate answer
response = client.messages.create(
    model="Codex-sonnet-4-6",
    max_tokens=1024,
    messages=[{"role": "user", "content": f"Context: {context}\n\nQuestion: {query}"}]
)
print(response.content[0].text)
```

## When to Use

- Building AI assistants for technical documentation
- Creating Q&A systems for standards libraries
- Developing chatbots with domain expertise
- Enabling natural language queries over knowledge bases
- Adding AI-powered search to existing document systems

## Prerequisites

- Knowledge base with extracted text (see `knowledge-base-builder`)
- Vector embeddings for semantic search (see `semantic-search-setup`)
- API key: `ANTHROPIC_API_KEY` or `OPENAI_API_KEY`

## Related Skills

- `knowledge-base-builder` - Build the document database first
- `semantic-search-setup` - Generate vector embeddings
- `pdf/text-extractor` - Extract text from PDFs
- `document-rag-pipeline` - Complete end-to-end pipeline

## Version History

- **1.2.0** (2026-01-02): Added Quick Start, Execution Checklist, Error Handling, Metrics sections; updated frontmatter with version, category, related_skills
- **1.1.0** (2025-12-30): Added hybrid search (BM25+vector), reranking, streaming responses
- **1.0.0** (2025-10-15): Initial release with basic RAG implementation

## Sub-Skills

- [Best Practices](best-practices/SKILL.md)

## Sub-Skills

- [Execution Checklist](execution-checklist/SKILL.md)
- [Error Handling](error-handling/SKILL.md)
- [Metrics](metrics/SKILL.md)
- [Dependencies](dependencies/SKILL.md)

## Sub-Skills

- [Architecture](architecture/SKILL.md)
- [Step 1: Vector Embeddings Table (+4)](step-1-vector-embeddings-table/SKILL.md)
- [System Prompt Template (+1)](system-prompt-template/SKILL.md)
- [1. Cache Embeddings (+2)](1-cache-embeddings/SKILL.md)
- [Example Usage](example-usage/SKILL.md)
- [Advanced: Hybrid Search (BM25 + Vector)](advanced-hybrid-search-bm25-vector/SKILL.md)
- [Advanced: Reranking](advanced-reranking/SKILL.md)
- [Streaming Responses](streaming-responses/SKILL.md)

Related Skills

repo-ecosystem-hygiene

5
from vamseeachanta/workspace-hub

Interpret the daily read-only repo ecosystem hygiene audit and route remediation through approved workflows.

provider-session-ecosystem-audit-and-exporters

5
from vamseeachanta/workspace-hub

Build and maintain cross-provider session-log audits for Codex, Codex, Hermes, and Gemini, including exporter design, normalization, and behavioral verification.

ecosystem-terminology

5
from vamseeachanta/workspace-hub

Canonical names, abbreviations, and relationship vocabulary for the workspace-hub ecosystem. Load this when naming repos, modules, machines, files, or expanding acronyms to ensure consistency across humans and agents. type: reference

llm-wiki-ecosystem-gap-to-issues

5
from vamseeachanta/workspace-hub

Review the workspace-hub LLM-wiki/document-intelligence ecosystem, identify high-leverage gaps, and create grounded GitHub feature issues without duplicating existing work.

hermes-ecosystem-integration

5
from vamseeachanta/workspace-hub

Wire Hermes into workspace-hub ecosystem — multi-repo skills, config sync, session export to learning pipeline, memory cross-pollination, skill patch tracking, and cross-machine health checks.

systematic-debugging

5
from vamseeachanta/workspace-hub

Use when encountering any bug, test failure, or unexpected behavior. 4-phase root cause investigation — NO fixes without understanding the problem first.

mcp-builder

5
from vamseeachanta/workspace-hub

Guide for building high-quality Model Context Protocol (MCP) servers that allow LLMs to interact with external services. Use when creating new MCP integrations, tools, or servers for Codex or other AI systems.

knowledge-base-builder

5
from vamseeachanta/workspace-hub

Build searchable knowledge bases from document collections (PDFs, Word, text files). Use for creating technical libraries, standards repositories, research databases, or any large document collection requiring full-text search.

interactive-dashboard-builder

5
from vamseeachanta/workspace-hub

Create self-contained HTML/JavaScript dashboards with Chart.js, filters, and professional styling

skill-ecosystem-curation

5
from vamseeachanta/workspace-hub

Class-level skill ecosystem curation: housekeeping, deduplication/collision reconciliation, archival, and consolidation governance.

provider-session-ecosystem-audit

5
from vamseeachanta/workspace-hub

Audit Codex/Codex/Hermes/Gemini session logs, normalize provider-specific quirks, and wire recurring exports/reporting for ongoing ecosystem health checks.

periodic-skill-ecosystem-housekeeping-audit

5
from vamseeachanta/workspace-hub

Maintain a deterministic recurring skill ecosystem housekeeping audit covering skill content quality, grouping/taxonomy drift, size, waivers, baselines, and local-only GitHub payloads.