Skip to content

Instantly share code, notes, and snippets.

@skeptrunedev
Created January 1, 2025 21:50
Show Gist options
  • Save skeptrunedev/6ec999937eb1cfcccb07b1c9d75d5444 to your computer and use it in GitHub Desktop.
Save skeptrunedev/6ec999937eb1cfcccb07b1c9d75d5444 to your computer and use it in GitHub Desktop.
feat: add Trieve MCP server

Description

MCP Server for Trieve to support usage of Trieve in agentic workflows from Model Context Protocol clients. Ideally, this is built in a way where it's really exposing the set of tools/prompts/resources that could be consumed, with MCP as one possible shape.

Offering tools enables agents to intelligently consume Trieve's APIs.

I think an initial version of Trieve would look like:

  • MCP server with create-mcp-server (there are multiple starters) connecting to Claude over stdio json-rpc. SSE exists but can be added later and is only recommended if the mechanics are actually needed between the client and the server
  • Add config for Trieve's SDK lib
  • Tools available that map Trieve's OpenAPI specification https://api.trieve.ai/redoc for descriptions oriented for LLMs, then wire up the tool calls to the SDK. These are things that the user has authority over executing for
  • Resources that map to Trieve's API, but for anything that the user would potentially want to bring into context (in the attach a file sense), NOT call out and get a tool. These don't pass through the LLM, and can be used for bringing in files for datasets, etc.

Initially, just having the pipeline of - I'm in Claude Desktop, and I want to call a tool to hit the Chunk endpoint and get the results, that's a good springboard project to continue fleshing out an agent.

Target(s)

  • New MCP server (TS and Python have official clients, but it's a separate process)

Community channels

Matrix is preferred. Reach out on discord or Matrix for further assistance.

@skeptrunedev
Copy link
Author

image

@skeptrunedev
Copy link
Author

image

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