Back to MCP directory
publicPublicdnsLocal runtime

Typesense

一个基于Typesense的模型上下文协议(MCP)服务器,提供集合管理、文档操作和搜索功能。

article

README

🚀 类型感知 MCP 服务器

这是一个与 Typesense(https://github.com/modelcontextprotocol/python-sdk)(MCP)协议接口的 MCP 服务器,能为相关操作提供支持。

🚀 快速开始

📦 安装指南

  1. 安装 uv,在 Mac 上可以使用 homebrew 进行安装:
brew install uv
  1. 克隆包:
git clone git@github.com:avarant/typesense-mcp-server.git ~/typesense-mcp-server
  1. 更新你的 .cursor/mcp.json 以在 Cursor 中使用:
{
  "mcpServers": {
    "typesense": {
      "command": "uv",
      "args": ["--directory", "~/typesense-mcp-server", "run", "mcp", "run", "main.py"],
      "env": {
        "TYPESENSE_HOST": "",
        "TYPESENSE_PORT": "", 
        "TYPESENSE_PROTOCOL": "",
        "TYPESENSE_API_KEY": ""
      }
    }
  }
}

✨ 主要特性

Typesense MCP Server 提供了丰富的工具,涵盖服务器管理、集合管理、文档操作和搜索功能等方面,具体如下:

服务器管理

  • check_typesense_health:检查配置的 Typesense 服务器的健康状态。
  • list_collections:获取 Typesense 服务器中所有集合的列表。

集合管理

  • describe_collection:获取特定集合的架构和元数据。
  • export_collection:导出特定集合中的所有文档。
  • create_collection:使用提供的架构创建新集合。
  • delete_collection:删除特定集合。
  • truncate_collection:通过删除所有文档但保留架构来截断集合。

文档操作

  • create_document:在特定集合中创建单个新文档。
  • upsert_document:上插入(创建或更新)特定集合中的单个文档。
  • index_multiple_documents:批量插入(创建、上插入或更新)多个文档。
  • delete_document:根据其 ID 从特定集合中删除单个文档。
  • import_documents_from_csv:从 CSV 数据导入文档到集合。

搜索功能

  • search:在特定集合上执行关键字搜索。
  • vector_search:在特定集合上执行向量相似性搜索。
help

Runtime guide

cloud

Hosted runtime

Hosted servers run from a provider-managed environment. You usually connect the MCP client to the hosted endpoint or follow the provider's authorization flow, without keeping a local process alive

  1. Open provider connection page
  2. Authorize or copy endpoint
  3. Connect from your MCP client
terminal

Local runtime / other methods

Local servers run on your own machine or infrastructure. You normally copy the server_config into your MCP client, install the required package, and provide env variables from env_schema when needed

  1. Copy server_config
  2. Install required package
  3. Fill env variables and restart client