Skip to main content

Integrate RAG into AI Agents via MCP Server. Supports multiple Vector database technologies.

Project description

Vector Database MCP Server

PyPI - Version PyPI - Downloads GitHub Repo stars GitHub forks GitHub contributors PyPI - License GitHub

GitHub last commit (by committer) GitHub pull requests GitHub closed pull requests GitHub issues

GitHub top language GitHub language count GitHub repo size GitHub repo file count (file type) PyPI - Wheel PyPI - Implementation

Version: 0.0.5

This is an MCP Server implementation which allows for a standardized collection management system across vector database technologies.

This was heavily inspired by the RAG implementation of Microsoft's Autogen V1 framework, however, this was changed to an MCP server model instead.

AI Agents can:

  • Create collections with documents stored on the local filesystem or URLs
  • Add documents to a collection
  • Utilize collection for retrieval augmented generation (RAG)
  • Delete collection

Supports:

  • ChromaDB - 95% Tested
  • PGVector - 90% Tested
  • Couchbase - 80% Tested
  • Qdrant - 80% Tested
  • MongoDB - 80% Tested

This repository is actively maintained - Contributions and bug reports are welcome!

Usage:

Using as an MCP Server:

Creating Collection

AI Prompt:

Create a collection called zapdos with the documents in this directory:
/home/user/Documents/Chroma

AI Response:

The collection named "zapdos" has been successfully created or retrieved from the vector database
using the documents in the directory /home/user/Documents/Chroma.
Let me know if you'd like to perform any further actions, such as querying the collection or adding more documents!

Retrieving from Collection

AI Prompt:

Create a collection called zapdos with the documents in this directory:
/home/user/Documents/Chroma

AI Response:

The collection named "zapdos" has been successfully created or retrieved from the vector database
using the documents in the directory /home/user/Documents/Chroma.
Let me know if you'd like to perform any further actions, such as querying the collection or adding more documents!

Deleting Collection

AI Prompt:

Delete the collection called memory

AI Response:

The collection named "memory" has been successfully deleted.
Let me know if you'd like to create a new collection or perform any other actions!
Example:

Use in CLI

Short Flag Long Flag Description
-h --help See Usage
-h --host Host of Vector Database
-p --port Port of Vector Database
-d --path Path of local Vector Database
-t --transport Transport Type (https/stdio)
vector-mcp

Use with AI

Deploy MCP Server as a Service

docker pull knucklessg1/vector-mcp:latest

Modify the compose.yml

services:
  vector-mcp-mcp:
    image: knucklessg1/vector-mcp:latest
    volumes:
      - development:/root/Development
    environment:
      - HOST=0.0.0.0
      - PORT=8001
    ports:
      - 8001:8001

Configure mcp.json

{
  "mcpServers": {
    "repository_manager": {
      "command": "vector-mcp",
      "env": {
        "DATABASE_TYPE": "chromadb",                   // Optional
        "COLLECTION_NAME": "memory",                   // Optional
        "DOCUMENT_DIRECTORY": "/home/user/Documents/"  // Optional
      },
      "timeout": 300000
    }
  }
}
Installation Instructions:

Install Python Package

python -m pip install vector-mcp

PGVector dependencies

python -m pip install vector-mcp[pgvector]

All

python -m pip install vector-mcp[all]
Repository Owners:

GitHub followers GitHub User's stars

Special shoutouts to Microsoft Autogen V1 ♥️

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

vector_mcp-0.0.5.tar.gz (48.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

vector_mcp-0.0.5-py3-none-any.whl (67.5 kB view details)

Uploaded Python 3

File details

Details for the file vector_mcp-0.0.5.tar.gz.

File metadata

  • Download URL: vector_mcp-0.0.5.tar.gz
  • Upload date:
  • Size: 48.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.2

File hashes

Hashes for vector_mcp-0.0.5.tar.gz
Algorithm Hash digest
SHA256 c6df935d2c550271a37eed887a32fc9e1814a2025547b34e7a661340bd1ca155
MD5 2e2835a59f77f95353b60c6e93efdadd
BLAKE2b-256 a222300cd706d25bfba94093cad572b7cb92a68656414044e85a5fca33bc139e

See more details on using hashes here.

File details

Details for the file vector_mcp-0.0.5-py3-none-any.whl.

File metadata

  • Download URL: vector_mcp-0.0.5-py3-none-any.whl
  • Upload date:
  • Size: 67.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.2

File hashes

Hashes for vector_mcp-0.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 061b829c401c44bf8b4450dd350cb8b9f1cf9354056f0975864348eb68f54104
MD5 9a1cd1f103b9fd57c2db3a14bad5c20d
BLAKE2b-256 b40d6b9cf7d2a0b676a3d7687f2a3e8b07c510fc019b5183ce64b0eb24b5c4de

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page