MCP server for multimodal image analysis using GLM-4.5V vision models. Provides unified image analysis tool for analyzing images, sketches, architecture diagrams, and extracting textual information.
Single tool 'analyze_image_with_context' has reasonable naming and acceptable descriptions, but lacks critical output schema documentation and error guidance. The tool definition is directly visible in src/visual_mcp/server.py with explicit Pydantic model registration via FastMCP decorator, so no inference penalty applies. Description is 179 chars (within 10-1024 baseline), addressing WHAT the tool does and WHEN to use it. All three input parameters have type definitions and descriptions meeting baseline standards (avg param description ~65 chars). However, the tool lacks documented output schema, no error classification or recovery guidance, and no handling for edge cases like API timeouts or invalid API keys. The server does not implement tool annotations (readOnlyHint is appropriate for this READ_ONLY tool but missing), and no pagination or result-limiting pattern despite the max_tokens parameter suggesting large responses are possible.
Upload an image and get comprehensive analysis based on your specific needs. The AI will figure out the best approach (description, text extraction, diagram analysis, etc.) based on your context.
Missing documented output schema. Tool description and FastMCP registration lack any specification of what fields/structure are returned to the LLM. Without this, downstream tool calls and error detection are hindered.
No error classification or recovery guidance. The tool may fail with API errors (GLM_API_KEY not set, invalid base64, API rate limits, network timeouts) but the code provides no actionable error messages for the LLM to understand whether to retry, ask the user, or abandon the request.
No tool annotations. The tool is READ_ONLY (risk declared correctly in metadata) but the MCP schema does not include readOnlyHint annotation. This forces the LLM to infer safety from the tool name and description alone.
Inferred effective spec: <=2025-11-25.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-22 | F | 49 | <=2025-11-25 | v2 |
| 2026-03-09 | F | 39 | - | v1 |
Ambiguous parameter 'image_data' accepts three formats (file path, base64, data URL) but the description does not clarify precedence or behavior when multiple formats could apply. The prepare_image_for_api() function checks os.path.exists() first, which could cause confusion if a user passes a base64 string that happens to match a file path.
Hardcoded API credentials via environment variables with no fallback or validation. The code raises ValueError if GLM_API_KEY is missing, but this is caught by generic exception handling in the async retry loop, potentially returning unclear errors to the LLM.
Retry logic lacks transparency. The call_glm_vision_api() function retries up to 5 times with a 2-second delay, but the LLM receives no visibility into retry attempts, backoff behavior, or final failure reason. This prevents the agent from understanding whether a failure is transient or permanent.