MCP cover image
See in Github
2025-04-14

20

Github Watches

3

Github Forks

20

Github Stars

Dive MCP Host

Dive MCP Host is a language model host service based on the Model Context Protocol (MCP), providing a unified interface to manage and interact with various language models.

Purpose of the Program

Dive MCP Host offers the following features:

  • A unified language model interaction interface, supporting multiple models (such as OpenAI, Anthropic, Google, etc.)
  • Conversation management and persistent storage
  • HTTP API and WebSocket support
  • Command-line tools for quick testing and interaction
  • Support for multi-threaded conversations and user management

This project uses LangChain and LangGraph to build and manage language model workflows, providing a standardized way to interact with different language models.

How to Run

Environment Setup

  1. Ensure you have Python 3.12 or higher installed
  2. Clone this repository
  3. Install dependencies:
# Using pip
pip install -e .

# Or using uv pip
uv pip install -e .

# Or using uv sync (recommended, will respect uv.lock file)
uv sync --frozen
  1. Activate the virtual environment
source .venv/bin/activate

Starting the HTTP Service

Use the following command to start the HTTP service:

dive_httpd

The server will start on:

  • Host: 0.0.0.0
  • Port: 61990
  • Log Level: INFO (configurable in the service config)

Using the Command Line Tool

You can use the command line tool for quick testing:

# General chat
dive_cli "Hello"

# Resume a chat with a specific thread
dive_cli -c CHATID "How are you?"

Using in Code

from dive_mcp_host.host.conf import HostConfig
from dive_mcp_host.host import DiveMcpHost

# Initialize configuration
config = HostConfig(...)

# Use async context manager
async with DiveMcpHost(config) as host:
    # Start or resume a conversation
    async with host.chat(thread_id="123") as chat:
        # Send a query and get a response
        async for response in chat.query("Hello, how can you help me today?"):
            print(response)

Development

Install development dependencies:

pip install -e ".[dev]"

or

uv sync --extra dev --frozen

(Optional) Start local PostgreSQL

./scripts/run_pg.sh

Run tests:

pytest

or with uv, (no need to activate enviroment)

uv run --extra dev --frozen pytest

License

This project is licensed under the MIT License. See the LICENSE file for details.

相关推荐

  • Aurity Ltd
  • Create and Publish Business Websites in seconds. AI will gather all the details about your website and generate link to your website.

  • Convincible Ltd
  • You're in a stone cell – can you get out? A classic choose-your-adventure interactive fiction game, based on a meticulously-crafted playbook. With a medieval fantasy setting, infinite choices and outcomes, and dice!

  • John Rafferty
  • Text your favorite pet, after answering 10 questions about their everyday lives!

  • Ian O'Connell
  • Provide players' names or enter Quickstart to start the game!

  • analogchat.com
  • Efficient Spotify assistant for personalized music data.

  • seabiscuit.ai
  • Discover A More Robust Business: Craft tailored value proposition statements, develop a comprehensive business model canvas, conduct detailed PESTLE analysis, and gain strategic insights on enhancing business model elements like scalability, cost structure, and market competition strategies. (v1.18)

  • Matthieu Savioux
  • Evaluates language quality of texts, responds with a numerical score between 50-150.

  • n8n-io
  • 具有本机AI功能的公平代码工作流程自动化平台。将视觉构建与自定义代码,自宿主或云相结合,400+集成。

  • WangRongsheng
  • 🧑‍🚀 llm 资料总结(数据处理、模型训练、模型部署、 o1 模型、mcp 、小语言模型、视觉语言模型)|摘要世界上最好的LLM资源。

  • metorial
  • 数百个MCP服务器的容器化版本📡📡

  • av
  • 毫不费力地使用一个命令运行LLM后端,API,前端和服务。

  • langgenius
  • Azure
  • 该存储库用于开发Azure MCP服务器,将Azure的功能带给您的代理商。

  • alibaba
  • 1Panel-dev
  • 🔥1Panel提供了直观的Web接口和MCP服务器,用于在Linux服务器上管理网站,文件,容器,数据库和LLMS。

  • superiorlu
  • 🤖在AI上收集实用的AI存储库,工具,网站,论文和教程。 实用的ai百宝箱百宝箱

  • caio-moliveira
  • 创建该项目是为了证明我们如何与不同的模型上下文协议(MCP)连接。

  • Byaidu
  • PDF科学纸翻译带有保留格式的pdf -基于ai完整保留排版的pdf文档全文双语翻译

  • rulego
  • ⛓️Rulego是一种轻巧,高性能,嵌入式,下一代组件编排规则引擎框架。

    Reviews

    2.8 (5)
    Avatar
    user_kiSo5hyk
    2025-04-23

    I've been using dive-mcp-host by OpenAgentPlatform for a while now and it has significantly improved my workflow. The platform is intuitive and user-friendly, making it easy to manage and deploy multiple projects simultaneously. The seamless integration and robust features have made it an invaluable tool for my needs. Highly recommend for anyone looking to streamline their project management process.

    Avatar
    user_D2bLLKa7
    2025-04-23

    As a loyal user of dive-mcp-host by OpenAgentPlatform, I can confidently say this product has transformed my workflow. Its robust feature set and seamless integration make it an essential tool for managing and deploying multi-cloud applications. Highly recommended for anyone in need of a reliable and efficient cloud management solution!

    Avatar
    user_cLtuaIAc
    2025-04-23

    As a dedicated user of dive-mcp-host by OpenAgentPlatform, I am thoroughly impressed with its seamless integration and performance. This tool has significantly streamlined our processes, offering robust solutions in an efficient manner. The user-friendly interface and welcoming onboarding experience make it accessible for all team members. Highly recommended for anyone looking to enhance their MCP applications!

    Avatar
    user_EwAoLBho
    2025-04-23

    I recently started using dive-mcp-host by OpenAgentPlatform, and I am thoroughly impressed. The seamless integration and intuitive interface make it stand out. The product's comprehensive features cater perfectly to my needs, and the helpful welcome information streamlined the setup process smoothly. Highly recommended for anyone seeking robust and user-friendly MCP applications!

    Avatar
    user_710Rr9Dg
    2025-04-23

    As a loyal user of dive-mcp-host, I am continually impressed by its seamless integration and user-friendly design. OpenAgentPlatform has done an outstanding job in creating a reliable and efficient tool that enhances my workflow. The welcome information on the starting URL is clear and informative, making it easy to get started. Highly recommended for anyone looking for a robust MCP application!