rag-patterns

Implement RAG pipelines with chunking, embeddings, retrieval, reranking, and RAGAS evaluation.

6|2|Updated Jan 22, 2026
One-click install
npx skills add https://github.com/fgarofalo56/Suppercharge_Microsoft_Fabric --skill rag-patterns-fgarofalo56
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: rag-patterns
Source: https://github.com/fgarofalo56/Suppercharge_Microsoft_Fabric/tree/main/.github/skills/rag-patterns
Command: npx skills add https://github.com/fgarofalo56/Suppercharge_Microsoft_Fabric --skill rag-patterns-fgarofalo56

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires openai, sentence-transformers, chromadb, langchain, nltk, rank-bm25, cohere, ragas, and includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill provides expert guidance and practical code examples for building robust Retrieval-Augmented Generation (RAG) systems, enabling more accurate and context-aware AI applications.

Core Features & Use Cases

  • RAG Pipeline Implementation: Demonstrates end-to-end RAG workflows from data ingestion to response generation.
  • Advanced Chunking Strategies: Offers various methods like fixed-size, semantic, sentence-based, and document structure chunking.
  • Embedding Techniques: Explores hybrid and multi-vector embedding approaches for better semantic understanding.
  • Retrieval & Reranking: Implements query expansion, HyDE, and cross-encoder reranking for precise information retrieval.
  • Generation & Evaluation: Covers context compression, citation generation, and RAGAS for performance measurement.
  • Use Case: Integrate these patterns to build a Q&A system over your company's internal documentation, ensuring answers are grounded in factual information and properly cited.

Quick Start

Use the rag-patterns skill to index a list of documents and then query them to generate an answer.

Frequently Asked Questions about rag-patterns

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I build a RAG pipeline for question answering over internal documents?

You can implement a RAG pipeline using provided patterns for data chunking, embedding, retrieval, reranking, and generation. It covers document ingestion through to final cited answer output using frameworks like LangChain and ChromaDB.

What are the best chunking strategies for semantic search in a RAG system?

Effective chunking strategies for semantic search include fixed-size, semantic, sentence-based, and document structure chunking. These approaches segment text to optimize embedding quality and retrieval accuracy.

How does cross-encoder reranking improve retrieval augmented generation?

Cross-encoder reranking enhances RAG by reordering initially retrieved documents to maximize semantic relevance. This ensures the generation step receives only the most precise context, reducing hallucinations.

Can I evaluate RAG performance using RAGAS with LangChain and OpenAI?

Yes, you can evaluate RAG performance using RAGAS alongside LangChain and OpenAI. The Skill provides evaluation methods to measure retrieval accuracy and generation fidelity.

Does this Skill support hybrid and multi-vector embedding approaches?

Yes, this Skill supports hybrid and multi-vector embedding approaches to improve semantic understanding. These methods enhance document representation within the vector database for more precise retrieval.

When should I use HyDE for query expansion in a vector database?

Use HyDE for query expansion in a vector database when standard semantic search yields low relevance. It generates hypothetical documents to bridge the semantic gap between queries and stored vectors.