Skip to content

Add Knowledge Fabric - Fast, multi-tenant hybrid RAG server on PostgreSQL - #4766

Open
sagarv48 wants to merge 1 commit into
modelcontextprotocol:mainfrom
sagarv48:add-knowledge-fabric
Open

Add Knowledge Fabric - Fast, multi-tenant hybrid RAG server on PostgreSQL#4766
sagarv48 wants to merge 1 commit into
modelcontextprotocol:mainfrom
sagarv48:add-knowledge-fabric

Conversation

@sagarv48

@sagarv48 sagarv48 commented Sep 6, 2026

Copy link
Copy Markdown

Summary

Add Knowledge Fabric to the community MCP servers and frameworks list.

Description

Knowledge Fabric is a vendor-neutral, multi-tenant hybrid RAG evidence retrieval engine built natively on PostgreSQL with pgvector HNSW indexes and full-text search (tsvector) fused via Reciprocal Rank Fusion (RRF, k=60). It provides sub-10ms retrieval latency, HIPAA/SOC 2 Row-Level Security (RLS) tenant isolation, and FastMCP server compliance.

Exposed Tools

  • retrieve_evidence: Execute hybrid RRF retrieval across ingested documents and return structured evidence with citations.
  • get_document: Fetch raw content and metadata for a specific document URI.
  • explain_retrieval: Return detailed ranking diagnostics, lexical scores, and vector distances for a query.
  • health_check: Verify database connectivity, embedding provider status, and row counts.
  • list_sources: List distinct ingested source types and document counts.

Server Configuration Schema for Registry

{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "name": "knowledge-fabric",
  "description": "High-performance hybrid RAG evidence retrieval on PostgreSQL (pgvector + BM25 RRF)",
  "repository": "https://github.com/sagarv48/knowledge-fabric",
  "license": "Apache-2.0",
  "packages": [
    {
      "registry": "pypi",
      "package": "knowledge-fabric"
    }
  ],
  "command": "uvx",
  "args": ["knowledge-fabric-mcp"],
  "env": {
    "DATABASE_URL": {
      "type": "string",
      "description": "PostgreSQL connection string (e.g. postgresql://user:pass@localhost:5432/knowledge_fabric)"
    },
    "EMBEDDING_PROVIDER": {
      "type": "string",
      "default": "ollama",
      "enum": ["ollama", "openai", "cohere", "mock"]
    },
    "RERANKER": {
      "type": "string",
      "default": "passthrough",
      "enum": ["passthrough", "cross_encoder", "cohere"]
    }
  },
  "tools": [
    {
      "name": "retrieve_evidence",
      "description": "Execute hybrid RRF retrieval across ingested documents and return structured evidence with citations."
    },
    {
      "name": "get_document",
      "description": "Fetch raw content and metadata for a specific document URI."
    },
    {
      "name": "explain_retrieval",
      "description": "Return detailed ranking diagnostics, lexical scores, and vector distances for a query."
    },
    {
      "name": "health_check",
      "description": "Verify database connectivity, embedding provider status, and row counts."
    },
    {
      "name": "list_sources",
      "description": "List distinct ingested source types and document counts."
    }
  ]
}

Checklist

  • Alphabetically sorted under ### For servers in ADDITIONAL.md
  • Open-source (Apache 2.0)
  • FastMCP compatible and runnable via uvx / Docker

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant