Cover image
Try Now
2024-12-22

MCP server for RAG-based document search and management

3 years

Works with Finder

1

Github Watches

1

Github Forks

6

Github Stars

RagDocs MCP Server

A Model Context Protocol (MCP) server that provides RAG (Retrieval-Augmented Generation) capabilities using Qdrant vector database and Ollama/OpenAI embeddings. This server enables semantic search and management of documentation through vector similarity.

Features

  • Add documentation with metadata
  • Semantic search through documents
  • List and organize documentation
  • Delete documents
  • Support for both Ollama (free) and OpenAI (paid) embeddings
  • Automatic text chunking and embedding generation
  • Vector storage with Qdrant

Prerequisites

  • Node.js 16 or higher
  • One of the following Qdrant setups:
    • Local instance using Docker (free)
    • Qdrant Cloud account with API key (managed service)
  • One of the following for embeddings:
    • Ollama running locally (default, free)
    • OpenAI API key (optional, paid)

Available Tools

1. add_document

Add a document to the RAG system.

Parameters:

  • url (required): Document URL/identifier
  • content (required): Document content
  • metadata (optional): Document metadata
    • title: Document title
    • contentType: Content type (e.g., "text/markdown")

2. search_documents

Search through stored documents using semantic similarity.

Parameters:

  • query (required): Natural language search query
  • options (optional):
    • limit: Maximum number of results (1-20, default: 5)
    • scoreThreshold: Minimum similarity score (0-1, default: 0.7)
    • filters:
      • domain: Filter by domain
      • hasCode: Filter for documents containing code
      • after: Filter for documents after date (ISO format)
      • before: Filter for documents before date (ISO format)

3. list_documents

List all stored documents with pagination and grouping options.

Parameters (all optional):

  • page: Page number (default: 1)
  • pageSize: Number of documents per page (1-100, default: 20)
  • groupByDomain: Group documents by domain (default: false)
  • sortBy: Sort field ("timestamp", "title", or "domain")
  • sortOrder: Sort order ("asc" or "desc")

4. delete_document

Delete a document from the RAG system.

Parameters:

  • url (required): URL of the document to delete

Installation

npm install -g @mcpservers/ragdocs

MCP Server Configuration

{
  "mcpServers": {
    "ragdocs": {
      "command": "node",
      "args": ["@mcpservers/ragdocs"],
      "env": {
        "QDRANT_URL": "http://127.0.0.1:6333",
        "EMBEDDING_PROVIDER": "ollama"
      }
    }
  }
}

Using Qdrant Cloud:

{
  "mcpServers": {
    "ragdocs": {
      "command": "node",
      "args": ["@mcpservers/ragdocs"],
      "env": {
        "QDRANT_URL": "https://your-cluster-url.qdrant.tech",
        "QDRANT_API_KEY": "your-qdrant-api-key",
        "EMBEDDING_PROVIDER": "ollama"
      }
    }
  }
}

Using OpenAI:

{
  "mcpServers": {
    "ragdocs": {
      "command": "node",
      "args": ["@mcpservers/ragdocs"],
      "env": {
        "QDRANT_URL": "http://127.0.0.1:6333",
        "EMBEDDING_PROVIDER": "openai",
        "OPENAI_API_KEY": "your-api-key"
      }
    }
  }
}

Local Qdrant with Docker

docker run -d --name qdrant -p 6333:6333 -p 6334:6334 qdrant/qdrant

Environment Variables

  • QDRANT_URL: URL of your Qdrant instance
    • For local: "http://127.0.0.1:6333" (default)
    • For cloud: "https://your-cluster-url.qdrant.tech"
  • QDRANT_API_KEY: API key for Qdrant Cloud (required when using cloud instance)
  • EMBEDDING_PROVIDER: Choice of embedding provider ("ollama" or "openai", default: "ollama")
  • OPENAI_API_KEY: OpenAI API key (required if using OpenAI)
  • EMBEDDING_MODEL: Model to use for embeddings
    • For Ollama: defaults to "nomic-embed-text"
    • For OpenAI: defaults to "text-embedding-3-small"

License

Apache License 2.0

相关推荐

  • NiKole Maxwell
  • I craft unique cereal names, stories, and ridiculously cute Cereal Baby images.

  • Andris Teikmanis
  • Latvian GPT assistant for developing GPT applications

  • Joshua Armstrong
  • Confidential guide on numerology and astrology, based of GG33 Public information

  • https://suefel.com
  • Latest advice and best practices for custom GPT development.

  • Emmet Halm
  • Converts Figma frames into front-end code for various mobile frameworks.

  • https://cantaspinar.com
  • Summarizes videos and answers related questions.

  • Khalid kalib
  • Write professional emails

  • Elijah Ng Shi Yi
  • Advanced software engineer GPT that excels through nailing the basics.

  • https://tovuti.be
  • Oede knorrepot die vasthoudt an de goeie ouwe tied van 't boerenleven

  • Gil kaminski
  • Make sure you are post-ready before you post on social media

  • ShrimpingIt
  • Micropython I2C-based manipulation of the MCP series GPIO expander, derived from Adafruit_MCP230xx

  • huahuayu
  • A unified API gateway for integrating multiple etherscan-like blockchain explorer APIs with Model Context Protocol (MCP) support for AI assistants.

  • deemkeen
  • control your mbot2 with a power combo: mqtt+mcp+llm

  • zhaoyunxing92
  • 本项目是一个钉钉MCP(Message Connector Protocol)服务,提供了与钉钉企业应用交互的API接口。项目基于Go语言开发,支持员工信息查询和消息发送等功能。

  • apappascs
  • Discover the most comprehensive and up-to-date collection of MCP servers in the market. This repository serves as a centralized hub, offering an extensive catalog of open-source and proprietary MCP servers, complete with features, documentation links, and contributors.

  • OffchainLabs
  • Go implementation of Ethereum proof of stake

    Reviews

    3 (1)
    Avatar
    user_883HJyMq
    2025-04-16

    I've been using the Unity MCP Package by HuangChILun for a few months now, and I'm thoroughly impressed. The integration is seamless, and it has significantly streamlined my development process. The documentation is clear and the support has been top-notch. Highly recommend this package to anyone looking to enhance their Unity projects!