Skip to content

Add knowledge-rag — Production RAG with hybrid search + cross-encoder reranking #129

@lyonzin

Description

@lyonzin

knowledge-rag

GitHub: https://github.com/lyonzin/knowledge-rag
PyPI: pip install knowledge-rag
Author: Lyon.

A production-ready local RAG system implementing several advanced techniques from this repo:

  • Hybrid Search: Semantic (FastEmbed ONNX) + BM25 keyword with Reciprocal Rank Fusion
  • Cross-Encoder Reranking: ms-marco-MiniLM-L-6-v2 post-retrieval
  • Context-Aware Chunking: Markdown-aware splitting by section headers
  • Query Expansion: Dictionary-based synonym expansion for technical terms
  • Evaluation: Built-in MRR@5 and Recall@5 metrics via MCP tool

Designed as an MCP server for Claude Code with 12 tools including CRUD operations, URL ingestion, similarity search, and retrieval evaluation. Zero external dependencies.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions