ragie mcp server
An MCP server that enables AI models to retrieve information from Ragie's knowledge base through a simple 'retrieve' tool.
An MCP server that enables AI models to retrieve information from Ragie's knowledge base through a simple 'retrieve' tool.
A Model Context Protocol (MCP) server that provides access to Ragie's knowledge base retrieval capabilities.
This server implements the Model Context Protocol to enable AI models to retrieve information from a Ragie knowledge base. It provides a single tool called "retrieve" that allows querying the knowledge base for relevant information.
The server requires the following environment variable:
RAGIE_API_KEY
(required): Your Ragie API authentication keyThe server will start and listen on stdio for MCP protocol messages.
Install and run the server with npx:
RAGIE_API_KEY=your_api_key npx @ragieai/mcp-server
The server supports the following command line options:
--description, -d <text>
: Override the default tool description with custom text--partition, -p <id>
: Specify the Ragie partition ID to queryExamples:
# With custom description
RAGIE_API_KEY=your_api_key npx @ragieai/mcp-server --description "Search the company knowledge base for information"
# With partition specified
RAGIE_API_KEY=your_api_key npx @ragieai/mcp-server --partition your_partition_id
# Using both options
RAGIE_API_KEY=your_api_key npx @ragieai/mcp-server --description "Search the company knowledge base" --partition your_partition_id
To use this MCP server with Cursor:
Save a file called mcp.json
For tools specific to a project, create a .cursor/mcp.json
file in your project directory. This allows you to define MCP servers that are only available within that specific project.
~/.cursor/mcp.json
file in your home directory. This makes MCP servers available in all your Cursor workspaces.Example mcp.json
:
{
"mcpServers": {
"ragie": {
"command": "npx",
"args": [
"-y",
"@ragieai/mcp-server",
"--partition",
"optional_partition_id"
],
"env": {
"RAGIE_API_KEY": "your_api_key"
}
}
}
}
Save a file called ragie-mcp.sh
on your system:
#!/usr/bin/env bash
export RAGIE_API_KEY="your_api_key"
npx -y @ragieai/mcp-server --partition optional_partition_id
Give the file execute permissions: chmod +x ragie-mcp.sh
Add the MCP server script by going to Settings -> Cursor Settings -> MCP Servers in the Cursor UI.
Replace your_api_key
with your actual Ragie API key and optionally set the partition ID if needed.
To use this MCP server with Claude desktop:
Create the MCP config file claude_desktop_config.json
:
For MacOS: Use ~/Library/Application Support/Claude/claude_desktop_config.json
%APPDATA%/Claude/claude_desktop_config.json
Example claude_desktop_config.json
:
{
"mcpServers": {
"ragie": {
"command": "npx",
"args": [
"-y",
"@ragieai/mcp-server",
"--partition",
"optional_partition_id"
],
"env": {
"RAGIE_API_KEY": "your_api_key"
}
}
}
}
Replace your_api_key
with your actual Ragie API key and optionally set the partition ID if needed.
The Ragie retrieval tool will now be available in your Claude desktop conversations.
The server provides a retrieve
tool that can be used to search the knowledge base. It accepts the following parameters:
query
(string): The search query to find relevant informationThe tool returns: - An array of content chunks containing matching text from the knowledge base
This project is written in TypeScript and uses the following main dependencies:
- @modelcontextprotocol/sdk
: For implementing the MCP server
- ragie
: For interacting with the Ragie API
- zod
: For runtime type validation
Running the server in dev mode:
RAGIE_API_KEY=your_api_key npm run dev -- --partition optional_partition_id
Building the project:
npm run build
MIT License - See LICENSE.txt for details.
[
{
"description": "Look up information in the Knowledge Base. Use this tool when you need to:n - Find relevant documents or information on specific topicsn - Retrieve company policies, procedures, or guidelinesn - Access product specifications or technical documentationn - Get contextual information to answer company-specific questionsn - Find historical data or information about projects",
"inputSchema": {
"$schema": "http://json-schema.org/draft-07/schema#",
"additionalProperties": false,
"properties": {
"query": {
"description": "The query to search for data in the Knowledge Base",
"type": "string"
}
},
"required": [
"query"
],
"type": "object"
},
"name": "retrieve"
}
]