Knowledge Base MCP Server

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
FAISS_INDEX_PATHNoThe path to the FAISS index.$HOME/knowledge_bases/.faiss
HUGGINGFACE_API_KEYYesAPI key for the Hugging Face Inference API, which is used to generate embeddings for the knowledge base content.
HUGGINGFACE_MODEL_NAMENoThe Hugging Face model to use for generating embeddings.sentence-transformers/all-MiniLM-L6-v2
KNOWLEDGE_BASES_ROOT_DIRNoThe directory where the knowledge base subdirectories are located.$HOME/knowledge_bases

Schema

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

Tools

Functions exposed to the LLM to take actions

NameDescription
list_knowledge_bases

Lists the available knowledge bases.

retrieve_knowledge

Retrieves similar chunks from the knowledge base based on a query. Optionally, if a knowledge base is specified, only that one is searched; otherwise, all available knowledge bases are considered. By default, at most 10 documents are returned with a score below a threshold of 2. A different threshold can optionally be provided.