Human-Controlled MCP Server

Human-Controlled MCP Server

Connects Claude to a human operator through a web interface, allowing Claude to ask questions, request searches, or seek decisions that are answered by a human in real-time. Instead of automated tools, Claude gets responses directly from you through a beautiful web dashboard.

Category
访问服务器

README

Human-Controlled MCP Server 🎮

A Model Context Protocol (MCP) server where you are the backend! Claude makes requests, and you respond through a beautiful web interface in real-time.

What Does This Do?

Instead of connecting Claude to APIs, databases, or automated tools, this MCP server connects Claude to you. When Claude needs information, wants to make a decision, or needs human judgment, it sends a request to your web dashboard where you can respond.

Features

  • 🌐 Web Interface: Beautiful single-page dashboard to see and respond to Claude's requests
  • Real-time: Requests appear instantly in your browser
  • 🎨 Clean UI: Modern, responsive interface with no frameworks needed
  • 🔧 Multiple Tools: Ask questions, request searches, or get decisions from humans
  • ⏱️ Timeout Handling: Automatic 5-minute timeout for pending requests

Architecture

Claude Desktop
    ↓ (MCP Protocol)
Python MCP Server
    ↓ (HTTP)
Web Interface (You!)

Setup Instructions

1. Install Dependencies

pip install -r requirements.txt

2. Configure Claude Desktop

Edit your Claude Desktop configuration file:

macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json

Add this configuration:

{
  "mcpServers": {
    "human-controlled": {
      "command": "python",
      "args": [
        "/absolute/path/to/human_mcp_server.py"
      ]
    }
  }
}

Important: Replace /absolute/path/to/human_mcp_server.py with the actual full path to the Python file.

3. Start the Server

You have two options:

Option A: Via Claude Desktop (Recommended)

  • Just restart Claude Desktop after configuring
  • The server starts automatically when Claude Desktop launches
  • Open your browser to http://localhost:5000

Option B: Standalone Testing

python human_mcp_server.py

Then connect via Claude Desktop or test with an MCP client.

4. Open the Web Interface

Navigate to: http://localhost:5000

You'll see the Human MCP Control Panel where you can respond to Claude's requests.

Usage

In Claude Desktop

Once configured, Claude will have access to three tools:

  1. ask_human: Ask you a question
  2. human_search: Request you to search for information
  3. human_decision: Ask you to make a decision

Example Conversation

You: "Claude, can you ask me what I want for dinner?"

Claude: Uses ask_human tool

[Your Web Interface Shows]:

Tool: ask_human
Parameters:
{
  "question": "What would you like for dinner tonight?",
  "context": "The user asked me to ask them this question."
}

You: Type "I'd like pasta with marinara sauce" in the web interface and click Submit

Claude: "Based on your response, you'd like pasta with marinara sauce for dinner tonight!"

Available Tools

1. ask_human

Ask the human operator any question.

Parameters:

  • question (required): The question to ask
  • context (optional): Additional context

Example Use: "What's your email address?" "Do you approve this change?" "What are your thoughts on this approach?"

2. human_search

Request the human to search for information.

Parameters:

  • query (required): What to search for
  • sources (optional): Where to look

Example Use: "Can you search for the latest news on AI?" "Look up our company's Q3 revenue numbers"

3. human_decision

Ask the human to make a decision.

Parameters:

  • decision_needed (required): What needs to be decided
  • options (required): Available options
  • recommendation (optional): AI's recommendation

Example Use: "Should we use approach A or B for this feature?" "Which design do you prefer?"

Technical Details

  • Protocol: Model Context Protocol (MCP) over stdio
  • Server: Python with Flask for web interface
  • Transport: Standard input/output for MCP, HTTP for web UI
  • Timeout: 5 minutes per request
  • Port: 5000 (web interface)

Troubleshooting

Server won't start

  • Check that port 5000 isn't already in use
  • Verify Python dependencies are installed: pip list | grep -E "flask|mcp"

Claude can't connect

  • Verify the path in claude_desktop_config.json is absolute and correct
  • Restart Claude Desktop after configuration changes
  • Check Claude Desktop logs for errors

Web interface not accessible

  • Make sure the server is running: lsof -i :5000
  • Try accessing http://127.0.0.1:5000 instead of localhost
  • Check your firewall settings

Requests timing out

  • Default timeout is 5 minutes - increase max_wait in the code if needed
  • Make sure your web interface is open and polling

Customization

Change the port

Edit app.run() in the code:

app.run(host='0.0.0.0', port=8080, debug=False, use_reloader=False)

Add more tools

Add new tools in the handle_list_tools() function following the MCP Tool schema.

Modify timeout

Change max_wait in the handle_call_tool() function (currently 300 seconds).

Customize the UI

Edit the HTML_TEMPLATE string - it's a single self-contained HTML file with embedded CSS and JavaScript.

Security Notes

  • This server binds to 0.0.0.0, making it accessible on your local network
  • For localhost-only access, change to host='127.0.0.1'
  • Add authentication if exposing over a network
  • Responses are stored in memory only (not persistent)

Use Cases

  • Personal Assistant: Claude asks you about your schedule, preferences, or decisions
  • Research Helper: Claude requests you to look up information it can't access
  • Code Review: Claude asks for your approval or input on code changes
  • Creative Collaboration: Claude asks for your creative input or direction
  • Teaching Tool: Demonstrate how MCP servers work with manual responses

Credits

Built with:

License

MIT License - feel free to modify and use as you wish!

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选