MCP.so
登录

MCP LLM Bridge

@virajsharma2000

关于 MCP LLM Bridge

A Simple bridge from Ollama to a fetch url mcp server

基本信息

分类

AI 与智能体

许可证

MIT license

运行时

python

传输方式

stdio

发布者

virajsharma2000

配置

使用下面的配置,将此服务器添加到你的 MCP 客户端。

{
  "mcpServers": {
    "simple-mcp-ollama-bridge": {
      "command": "uv",
      "args": [
        "venv"
      ]
    }
  }
}

工具

未检测到工具

工具是从 README 中自动提取的。维护者可以在 ## Tools 标题下列出工具,即可填充这部分内容。

概览

What is MCP LLM Bridge?

MCP LLM Bridge connects Model Context Protocol (MCP) servers to OpenAI‑compatible LLMs such as Ollama. It is intended for developers who want to use local or remote LLMs with MCP‑based tooling.

How to use MCP LLM Bridge?

Clone the repository, set up a Python virtual environment with uv, install the package, then edit src/mcp_llm_bridge/main.py to configure the MCP server parameters and LLM connection (API key, model, base URL). The bridge supports any endpoint implementing the OpenAI API specification, including Ollama running locally.

Key features of MCP LLM Bridge

  • Connects MCP servers to OpenAI‑compatible LLMs
  • Works with any OpenAI‑compliant endpoint (e.g., Ollama, GPT‑4o)
  • Configured via a single Python file (main.py)
  • Supports local LLM models for privacy and offline use
  • Uses uv for dependency management and installation

Use cases of MCP LLM Bridge

  • Run MCP‑enabled tools with a local Ollama model instead of a cloud API
  • Bridge existing MCP servers to OpenAI‑compatible LLMs for sampling or tool use
  • Test MCP integrations against a local LLM before deploying to a production endpoint

FAQ from MCP LLM Bridge

What does MCP LLM Bridge do?

It bridges any MCP server to an OpenAI‑compatible LLM, allowing the LLM to use MCP resources, prompts, and tools.

What dependencies are required?

Python, uv, and an LLM endpoint that implements the OpenAI API (e.g., Ollama). No additional runtime beyond the Python environment.

How do I configure the bridge?

Edit src/mcp_llm_bridge/main.py to set mcp_server_params (pointing to your MCP server) and llm_config (API key, model, base URL). Example configurations for Ollama and GPT‑4o are shown in the file.

Does it work with cloud LLMs?

Yes, the bridge can connect to any OpenAI‑compatible API, including GPT‑4o, by setting the appropriate api_key and model.

What is the transport mechanism?

The MCP server communicates over stdio (via StdioServerParameters), while the LLM is accessed via HTTP using the OpenAI API format.

评论

AI 与智能体 分类下的更多 MCP 服务器