MCP.so
Sign In

MCPHost 🤖

@mark3labs

About MCPHost 🤖

A CLI host application that enables Large Language Models (LLMs) to interact with external tools through the Model Context Protocol (MCP).

Overview

What is MCPHost?

MCPHost is a CLI host application that enables Large Language Models (LLMs) to interact with external tools through the Model Context Protocol (MCP). It runs on any system with Go 1.23+ and supports Anthropic Claude 3.5 Sonnet, Ollama models, Google Gemini, and any OpenAI-compatible model with function-calling support.

How to use MCPHost?

Install with go install github.com/mark3labs/mcphost@latest. Configure MCP servers in ~/.mcp.json (or pass a custom path with --config). Run mcphost with an optional -m flag to choose a model (e.g., mcphost -m ollama:qwen2.5:3b). Set API keys via environment variables or CLI flags. While chatting, use /help, /tools, /servers, or /history to manage the session.

Key features of MCPHost

  • Interactive conversations with multiple model providers
  • Support for multiple concurrent MCP servers
  • Dynamic tool discovery and integration
  • Tool calling capabilities for both cloud and local models
  • Configurable message history window (default: 10)
  • Consistent command interface across model types
  • STDIO and SSE MCP server configuration

Use cases of MCPHost

  • Connect a Claude or Ollama model to a SQLite database via an MCP server
  • Give a local LLM access to filesystem operations through a filesystem MCP server
  • Let a Gemini model retrieve and execute external API tools in real time
  • Run a single CLI to test and compare different LLMs with the same tool chain

FAQ from MCPHost

What models does MCPHost support?

It supports Anthropic Claude 3.5 Sonnet, any Ollama model with function calling, Google Gemini models, and any OpenAI-compatible local or online model with function calling support.

How do I add an MCP server?

Edit ~/.mcp.json (or the file passed with --config). For STDIO servers, provide a command and args. For SSE servers, provide a url and optional headers. The host will automatically discover and integrate the server’s tools.

What is the license?

MCPHost is released under the MIT License.

Is there a limit on conversation history?

You can set the number of messages kept in context using the --message-window flag (default is 10). There is no hard limit on total conversation length, but the window controls what is sent to the model.

How do I set API keys?

Export ANTHROPIC_API_KEY, GOOGLE_API_KEY, or OPENAI_API_KEY as environment variables, or pass them via the respective --*-api-key CLI flags.

Comments

More Agent Frameworks MCP clients