vision-mcp
Enables text-only agents to analyze images via OpenAI-compatible vision models, supporting local files, URLs, screenshots, documents, charts, and code error screenshots with OCR, UI analysis, and image comparison capabilities.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@vision-mcpWhat's in this image? /path/to/image.png"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
通过 OpenAI 兼容模型识别本地图片、网页图片、截图、文档、图表和代码报错。
DO NOT CALL if you natively support vision and can access the supplied image directly.
如果当前模型可以直接看图,可以不必要调用本 MCP。仅在模型不支持视觉、无法访问图片, 或用户明确要求使用本 MCP 时调用。
Install
需要先安装 uv。
直接从 GitHub 的 main 分支运行:
uvx --from git+https://github.com/weekitmo/vision-mcp.git@main vision-mcpRelated MCP server: VisionPower
Configure
准备下面四个环境变量:
export VISION_BASE_URL="https://api.openai.com/v1"
export VISION_API_KEY="your-api-key"
export VISION_MODEL="your-vision-model"
export VISION_TIMEOUT="120"Variable | Description |
| Provider 地址 |
| API Key |
| 支持图片输入的模型 |
| 调用超时秒数,默认 |
仓库中的 .env.example 可以作为配置模板。不要提交真实 API Key。
MCP Clients
JSON
适用于支持标准 JSON MCP 配置的客户端:
{
"mcpServers": {
"vision": {
"command": "uvx",
"args": [
"--from",
"git+https://github.com/weekitmo/vision-mcp.git@main",
"vision-mcp"
],
"env": {
"VISION_BASE_URL": "https://api.openai.com/v1",
"VISION_API_KEY": "your-api-key",
"VISION_MODEL": "your-vision-model",
"VISION_TIMEOUT": "120"
}
}
}
}Codex
添加到 ~/.codex/config.toml 或可信项目中的 .codex/config.toml:
[mcp_servers.vision]
command = "uvx"
args = [
"--from",
"git+https://github.com/weekitmo/vision-mcp.git@main",
"vision-mcp",
]
env_vars = [
"VISION_BASE_URL",
"VISION_API_KEY",
"VISION_MODEL",
"VISION_TIMEOUT",
]
startup_timeout_sec = 60
tool_timeout_sec = 180先导出 VISION_* 环境变量,再启动 Codex:
codex mcp list完整示例见 config/codex.toml.example。
Grok
添加到 ~/.grok/config.toml 或项目中的 .grok/config.toml:
[mcp_servers.vision]
command = "uvx"
args = [
"--from",
"git+https://github.com/weekitmo/vision-mcp.git@main",
"vision-mcp",
]
enabled = true
startup_timeout_sec = 60
tool_timeout_sec = 180先导出 VISION_* 环境变量,再启动 Grok:
grok mcp list完整示例见 config/grok.toml.example。
Inspector
一条命令启动 MCP Inspector:
./scripts/test-ui.sh脚本固定使用 @modelcontextprotocol/inspector@2.1.0。
在 Inspector 中:
打开
vision-local。在
Environment Variables中填写四个VISION_*配置。连接 Server。
打开
Tools。选择
analyze_image或understand_image。填写图片路径和问题,运行工具。
Inspector 的本地配置保存在 .inspector/mcp.json,该文件不会被 Git 提交。
mcporter
初始化项目配置:
./scripts/setup-mcporter.sh查看工具:
mcporter list vision --schema --all-parameters识别一张图片:
mcporter call vision.analyze_image \
image=/absolute/path/to/screenshot.png \
prompt="提取图片中的所有文字" \
mode=ocr \
detail=high \
--timeout 120000比较多张图片:
mcporter call vision.understand_image \
--args '{
"images": [
"/absolute/path/before.png",
"/absolute/path/after.png"
],
"prompt": "比较两张图片的差异",
"mode": "compare"
}' \
--timeout 120000 \
--output json查看内置使用说明:
mcporter resource vision
mcporter resource vision vision://docs/quickstart
mcporter resource vision vision://docs/toolsTools
analyze_image
用于识别单张图片,适合 Inspector、mcporter 和命令行调用。
image 本地路径、HTTP(S) URL 或 data URL
prompt 希望模型回答的问题
mode 识别模式
ascii_mode 是否使用 ASCII 表达布局
detail 图片解析精度
max_tokens 最大输出长度understand_image
用于多图识别、图片比较,以及需要兼容不同图片参数格式的客户端。
images 图片列表
prompt 希望模型回答的问题
mode 识别模式
ascii_mode 是否使用 ASCII 表达布局
detail 图片解析精度
max_tokens 最大输出长度可用模式:
auto · describe · ocr · document · ui · chart · compare ·
spatial · code
支持 PNG、JPEG、WEBP 和 GIF。单次最多识别 10 张图片。
From Source
需要修改或调试时:
git clone https://github.com/weekitmo/vision-mcp.git
cd vision-mcp
uv sync --frozen
uv run vision-mcp在 MCP 客户端中从源码启动:
{
"mcpServers": {
"vision": {
"command": "uv",
"args": [
"--directory",
"/absolute/path/to/vision-mcp",
"run",
"--frozen",
"vision-mcp"
],
"env": {
"VISION_BASE_URL": "https://api.openai.com/v1",
"VISION_API_KEY": "your-api-key",
"VISION_MODEL": "your-vision-model",
"VISION_TIMEOUT": "120"
}
}
}
}License
MIT
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseAqualityDmaintenanceEnables AI agents to analyze images, extract text, compare images, and analyze video through any OpenAI-compatible vision model.435819MIT
- FlicenseAqualityBmaintenanceVisionPower enables AI agents to analyze images, read text from screenshots, and interpret charts using any OpenAI-compatible vision model. It supports local images, URLs, base64, and multiple images with order preservation.12
- Alicense-qualityCmaintenanceEnables AI agents to analyze images using any OpenAI-compatible vision API, providing tools for image analysis, OCR, error diagnosis, diagram understanding, and chart analysis.MIT
- Alicense-qualityBmaintenanceMulti-backend AI vision for MCP agents. Analyze images, screenshots, and documents using local Ollama models or cloud APIs like OpenAI, Google Gemini, and OpenRouter.MIT
Related MCP Connectors
OCR, transcription, file extraction, and image generation for AI agents via MCP.
Free public MCP for AI agents — 193 tools, 44 workflows. No API key.
Hosted MCP with 91 agent tools: X, domains, SEO, Maps, Trends, Search, YouTube, TikTok, and more.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/weekitmo/vision-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server