Skip to main content
Glama

GLM Vision MCP Server

基于 智谱 GLM-4.6V-Flash 模型的图像识别 MCP 工具。

安装

方式一:PyPI 安装

pip install glm-vision-mcp

方式二:本地安装

git clone <repo-url>
cd glm-vision-mcp
pip install -e .

Related MCP server: Vision MCP

前置条件

  1. 注册 智谱开放平台 账号

  2. 获取 API Key

配置

在 MCP Client 配置文件中添加(如 claude_desktop_config.json.mcp.json):

{
  "mcpServers": {
    "glm-vision": {
      "command": "uv",
      "args": ["run", "--directory", "<项目路径>", "glm-vision-mcp"],
      "env": {
        "ZHIPU_API_KEY": "your-api-key-here"
      }
    }
  }
}

或 PyPI 安装后:

{
  "mcpServers": {
    "glm-vision": {
      "command": "python",
      "args": ["-m", "glm_vision_mcp.server"],
      "env": {
        "ZHIPU_API_KEY": "your-api-key-here"
      }
    }
  }
}

使用

analyze_image

分析图片内容,支持 URL 和本地文件路径。

参数:

参数

类型

必填

说明

image

string

图片 URL(https://...)或本地文件路径

prompt

string

自定义分析指令,默认"请详细描述这张图片"

示例:

  • 描述图片:{"image": "https://example.com/photo.jpg"}

  • OCR 提取:{"image": "C:\\screenshots\\receipt.png", "prompt": "提取图中的所有文字"}

  • 图表分析:{"image": "/data/chart.png", "prompt": "分析这个图表的趋势和关键数据"}

Available Tools

1 tool
analyze_imageA

分析图片内容。支持传入图片URL或本地文件路径,可附带自定义分析指令。

ParametersJSON Schema
NameRequiredDescriptionDefault
imageYes图片URL(以http://或https://开头)或本地文件路径
promptNo对图片的分析指令,默认为'请详细描述这张图片'

TDQS

A3.7/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden of behavioral disclosure. It mentions input types and custom prompts but does not disclose whether the operation is read-only, any side effects, output format, or security implications of accessing local file paths. This is a significant gap for a tool with no annotation support.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is two short sentences, front-loaded with the primary action ('分析图片内容'), and contains no redundant or filler words. Every phrase adds useful information about input handling and customization.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The tool is simple with two parameters and no output schema, but the description still omits any mention of what the tool returns or the format of the analysis result. For a tool with no output schema, the description should compensate by explaining return behavior, which it does not fully do. However, the input handling is well covered, so the description is minimally adequate.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema provides 100% parameter coverage with detailed descriptions for both 'image' and 'prompt'. The description adds minimal semantic value beyond what the schema already states, merely reiterating the prompt capability. Thus the baseline of 3 is appropriate because the schema does the heavy lifting.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states '分析图片内容' (analyze image content), a specific verb and resource, and lists supported input types (URL or local path) and optional custom instructions. Since there are no sibling tools, it fully distinguishes the tool's purpose.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides clear usage context by explaining that images can be passed via URL or local file path and that an optional custom prompt can be supplied. As there are no sibling tools or alternatives, explicit when/when-not guidance is not needed, but the context is sufficiently clear.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

TDQS

A4/5.0
Disambiguation5/5

With only one tool, there is no possibility of confusion or overlap. The tool's purpose is clearly defined as image analysis, so an agent can unambiguously select it for any image-related task.

Naming Consistency5/5

The single tool 'analyze_image' follows a clean verb_noun pattern, which is consistent with common API naming conventions. While there are no other tools to compare, the name is descriptive and predictable.

Tool Count4/5

The server has only one tool, which is slightly below the typical 3-15 range, but it is tailored specifically for vision-based image analysis. The single tool is reasonably scoped for this narrow purpose, and adding more tools could dilute its focus.

Completeness5/5

The tool covers the core and likely only operation needed for image analysis: accepting an image URL or local path and allowing custom instructions. There are no obvious gaps or dead ends for this domain, as the tool provides a complete workflow for its intended use.

Maintenance

ActivityMaintained
ResponsivenessSyncing

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Connectors

Related MCP Servers

Latest Blog Posts

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/SongY1021/glm-vision-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server