mirofish-mcp-server
MCP server that connects AI clients to a local MiroFish instance for document-driven multi-agent simulations and prediction report generation.
README
mirofish-mcp-server
MCP (Model Context Protocol) server for MiroFish — the AI-powered multi-agent prediction engine. Connect Claude Code (or any MCP-compatible AI client) directly to your local MiroFish instance.
What this does
MiroFish lets you upload documents, build a knowledge graph, spin up thousands of autonomous AI agents, and simulate future scenarios. This MCP server exposes all of that as tools Claude can call directly from a conversation.
┌─────────────┐ stdio ┌───────────────────┐ HTTP ┌──────────────────┐
│ Claude Code │ ◄────────────► │ mirofish-mcp- │ ────────────► │ MiroFish Backend │
│ │ │ server (Node.js) │ │ (Flask on :5001) │
└─────────────┘ └───────────────────┘ └──────────────────┘
Prerequisites
- Node.js 18+
- MiroFish running locally — clone and start it first:
git clone https://github.com/666ghj/MiroFish.git
cd MiroFish
cp .env.example .env
npm run setup:all
npm run dev # starts backend at http://localhost:5001
Using Claude as MiroFish's LLM — MiroFish accepts any OpenAI-compatible API. To use Claude, set these in your MiroFish .env:
LLM_API_KEY=sk-ant-api03-... # your Anthropic API key
LLM_BASE_URL=https://api.anthropic.com/v1
LLM_MODEL_NAME=claude-sonnet-4-6
ZEP_API_KEY=... # still required for the knowledge graph
MiroFish's LLM client passes base_url directly to the OpenAI SDK, so Claude handles all internal AI work — ontology extraction, agent profiling, simulation decisions, report generation — with no code changes.
Installation
git clone https://github.com/thisisaman408/mirofish-mcp-server.git
cd mirofish-mcp-server
npm install
npm run build
Connect to Claude Code
Create a .mcp.json file in the directory where you run Claude Code (or your project root):
{
"mcpServers": {
"mirofish": {
"command": "node",
"args": ["/absolute/path/to/mirofish-mcp-server/dist/index.js"],
"env": {
"MIROFISH_BASE_URL": "http://localhost:5001"
}
}
}
}
Replace /absolute/path/to/ with the actual path where you cloned this repo. Then restart Claude Code — the MiroFish tools will appear automatically.
Custom backend URL
If MiroFish runs on a different host or port, change MIROFISH_BASE_URL:
"env": {
"MIROFISH_BASE_URL": "http://192.168.1.10:5001"
}
Available Tools (40 total)
Health
| Tool | Description |
|---|---|
mirofish_health_check |
Check if the MiroFish backend is running |
Projects
| Tool | Description |
|---|---|
mirofish_list_projects |
List all projects |
mirofish_get_project |
Get project details by ID |
mirofish_delete_project |
Delete a project |
mirofish_reset_project |
Reset project state to rebuild graph |
Knowledge Graph
| Tool | Description |
|---|---|
mirofish_generate_ontology |
Upload documents and generate entity/edge ontology |
mirofish_build_graph |
Build a Zep knowledge graph from a project (async) |
mirofish_get_graph_data |
Get all nodes and edges from a graph |
mirofish_delete_graph |
Delete a graph |
Tasks
| Tool | Description |
|---|---|
mirofish_get_task |
Poll an async task's progress |
mirofish_list_tasks |
List all background tasks |
Simulation
| Tool | Description |
|---|---|
mirofish_create_simulation |
Create a new simulation from a project |
mirofish_prepare_simulation |
Generate agent profiles + config (async) |
mirofish_prepare_status |
Check preparation progress |
mirofish_start_simulation |
Start running the simulation |
mirofish_stop_simulation |
Stop a running simulation |
mirofish_get_simulation |
Get simulation details and status |
mirofish_list_simulations |
List all simulations |
mirofish_simulation_run_status |
Get real-time run status |
mirofish_simulation_run_status_detail |
Get detailed round/agent progress |
mirofish_get_simulation_profiles |
Get generated agent profiles |
mirofish_get_simulation_config |
Get simulation config |
mirofish_simulation_history |
Get history of all simulations |
Simulation Results
| Tool | Description |
|---|---|
mirofish_get_entities |
Get all entities from the knowledge graph |
mirofish_get_entity_detail |
Get a specific entity's context |
mirofish_get_entities_by_type |
Get entities filtered by type |
mirofish_get_simulation_actions |
Get all agent actions during the run |
mirofish_get_simulation_timeline |
Get chronological event timeline |
mirofish_get_agent_stats |
Get agent behavior statistics |
mirofish_get_simulation_posts |
Get posts generated by agents |
mirofish_get_simulation_comments |
Get comments/replies generated by agents |
Interview
| Tool | Description |
|---|---|
mirofish_interview_agent |
Chat with a specific simulated agent |
mirofish_interview_batch |
Ask multiple agents the same question |
mirofish_interview_all |
Ask all agents a question |
mirofish_interview_history |
Get conversation history with an agent |
Reports
| Tool | Description |
|---|---|
mirofish_generate_report |
Generate prediction report (async) |
mirofish_report_generate_status |
Check report generation progress |
mirofish_get_report |
Get full report content |
mirofish_get_report_by_simulation |
Get report by simulation ID |
mirofish_list_reports |
List all reports |
mirofish_delete_report |
Delete a report |
mirofish_get_report_progress |
Real-time section-by-section progress |
mirofish_get_report_sections |
Get all completed sections |
mirofish_get_report_section |
Get a single section by index |
mirofish_check_report_status |
Check if a simulation has a report |
mirofish_chat_with_report_agent |
Chat with the AI Report Agent about results |
Debug Tools
| Tool | Description |
|---|---|
mirofish_search_graph |
Semantic search over the knowledge graph |
mirofish_graph_statistics |
Get node/edge counts and entity distribution |
mirofish_env_status |
Check simulation environment status |
mirofish_close_env |
Shut down a simulation environment |
Example conversation with Claude
Once connected, you can talk to Claude naturally:
"List my MiroFish projects"
"Create a simulation about public opinion on climate policy using project proj_abc123"
"Interview agent Li Wei — ask her what she thinks about the new carbon tax"
"Generate a prediction report for simulation sim_xyz789 and show me the executive summary"
"Search the knowledge graph for anything about social media sentiment"
Workflow
The typical end-to-end flow in MiroFish:
1. Generate ontology → mirofish_generate_ontology (upload docs)
2. Build graph → mirofish_build_graph (async, poll with get_task)
3. Create simulation → mirofish_create_simulation
4. Prepare simulation → mirofish_prepare_simulation (async, generates agent profiles)
5. Start simulation → mirofish_start_simulation
6. Monitor / results → get_posts, get_actions, get_timeline
7. Generate report → mirofish_generate_report (async)
8. Interview agents → mirofish_interview_agent
9. Chat about results → mirofish_chat_with_report_agent
Development
# Edit src/index.ts, then rebuild
npm run build
# Run directly (requires MiroFish backend)
node dist/index.js
The server uses stdio transport — Claude Code launches it as a subprocess and communicates over stdin/stdout.
License
MIT
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。