mimo-vision-mcp: Instructions file for Claude Code

CLAUDE.md

mimo-vision-mcp CLAUDE.md is an instructions file for Claude Code from jack4862/mimo-vision-mcp. It costs 1,359 tokens per session, scanned A, original, MIT.

A set of project instructions for Claude Code, covering a multimodal MCP server that sends images to Xiaomi’s MiMo vision model and returns text descriptions. MCP is a standard way for an AI assistant to call external tools.

In plain words
What is it for?
Use it when developing, testing, configuring, or registering the mimo-vision-mcp server with Claude Code.
Why use it?
It records the project’s commands, configuration, architecture, tests, and important constraints so code changes follow the repository’s expected setup.

Instructions file for Claude Code

Written for Claude Code: the file is CLAUDE.md. Also seen: mentions CLAUDE.md; mentions Claude Code.

This is jack4862/mimo-vision-mcp's own configuration. It tells Claude Code how to work on mimo-vision-mcp itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything mimo-vision-mcp configures →

Reuse

Borrowing it

Nothing to install: this file belongs to jack4862/mimo-vision-mcp. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/jack4862/mimo-vision-mcp/main/CLAUDE.md
Clone the repo
git clone --depth 1 https://github.com/jack4862/mimo-vision-mcp

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for mimo-vision-mcp CLAUDE.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/jack4862/mimo-vision-mcp/claude-md.svg)](https://agentmods.dev/instructions/jack4862/mimo-vision-mcp/claude-md)
Your own site
<a href="https://agentmods.dev/instructions/jack4862/mimo-vision-mcp/claude-md"><img src="https://agentmods.dev/badge/instructions/jack4862/mimo-vision-mcp/claude-md.svg" alt="Measured on agentmods" height="20"></a>
Per session 1,359 This file is loaded in full into every session.
When invoked 1,359 The same file — it is already loaded in full.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.01359 $0.01359
Opus 5 $0.00679 $0.00679
Sonnet 5 $0.00272 $0.00272
Haiku 4.5 $0.00136 $0.00136

Measured 6d ago against content hash c4d2af8f916e, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

mimo-vision-mcp CLAUDE.md scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 6d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

CLAUDE.md · 61 lines

How it starts

The opening of the file, as written. The whole thing — 61 lines — stays where its author put it; the contents beside it link to each section on GitHub.

CLAUDE.md

This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.

项目概览

mimo-vision-mcp 是一个 MCP Server:用小米 MiMo v2.5 多模态模型,为纯文本主模型(如 deepseek-v4-flash)补齐图像识别。主模型遇到图片时调用本 Server 的工具,Server 读图转 base64 调 MiMo OpenAI 兼容接口,返回纯文本描述。

常用命令

uv sync --dev                                          # 安装依赖(含 dev/pytest)
uv run python server.py                                # 启动 Server(stdio 传输,阻塞等待)
uv run --env-file .env pytest                          # 跑全部测试(离线 + 集成)
uv run --env-file .env pytest tests/test_image_utils.py -k test_too_large   # 单个测试
uv run --env-file .env pytest tests/test_api.py        # 真实 MiMo API 集成测试(无 key 自动 skip)

注册到 Claude Code(全局 user scope;--env-fileclaude mcp add 不兼容,必须用 -e 显式传 env):

claude mcp add mimo-vision -s user `
  -e "MIMO_API_KEY=<key>" -e "MIMO_BASE_URL=https://api.xiaomimimo.com/v1" `
  -e "MIMO_VISION_MODEL=mimo-v2.5" -e "MIMO_MAX_TOKENS=2048" `
  "$PWD\.venv\Scripts\python.exe" "$PWD\server.py"

配置:复制 .env.example.envMIMO_API_KEY。普通 Key(sk-)走 https://api.xiaomimimo.com/v1;Token Plan(tp-)需把 MIMO_BASE_URL 改为 https://token-plan-cn.xiaomimimo.com/v1。视觉模型必须用 mimo-v2.5mimo-v2.5-pro 是纯文本)。

架构

数据流:主模型 → MCP 工具(server.py)→ api_client.MimoClient.prepare_image() 读图 → POST /chat/completions → 文本返回。

四模块分层(每层职责单一,勿交叉):

  • config.py — 环境变量 → Config frozen dataclass;MIMO_API_KEY 必填(缺失时中文报错,不泄漏 token)。入口处 load_dotenv() 保证本地直接运行时也能读 .env
  • api_client.py唯一发 HTTP 的层MimoClient(httpx async、Authorization: Bearer、指数退避重试、错误映射为 MimoError);build_vision_message() 构造视觉消息;prepare_image() 调 image_utils。
  • image_utils.py — 图片输入归一化:本地路径 / http(s) URL(下载转 base64,不透传任意 URL 给官方)/ file:// / data URL → data:image/...;base64,...;格式白名单 + 10MB 校验 + 魔数兜底。
  • server.py — FastMCP 实例 + 4 工具(describe_image / analyze_images / extract_text_from_image / read_image_info)+ 1 资源(mimo://config)。工具层不直接碰 httpx。

Read the full file on GitHub · 61 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 6d ago First seen · 61 lines · 1,359 tokens per session scan A c4d2af8f916e

Subscribe to this mod's changes

mimo-vision-mcp CLAUDE.md is an instructions file published in the GitHub repository jack4862/mimo-vision-mcp (1 stars, last pushed 1mo ago), licensed MIT. It adds 1,359 tokens to every session, about $0.0068 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other instructions, from other repositories

next.js AGENTS.md

AGENTS.md instructions for vercel/next.js, covering next.js development guide, codebase structure, monorepo overview, core package: packages/next and other important packages.

vercel/next.js · 7,296 tokens

codex AGENTS.md

AGENTS.md instructions for openai/codex, covering rust/codex-rs, the codex-core crate, code review rules, crate api surface and model visible context.

openai/codex · 5,182 tokens

vscode buildNext.instructions.md

Working notes and architecture documentation for the new esbuild-based build system in build/next. Use when making changes to the new build pipeline (transpile/bundle commands, NLS plugin, source-map handling, resource copying, or self-hosting watch tasks).

microsoft/vscode · 6,785 tokens

vscode oss-third-party-notices.instructions.md

Instructions for microsoft/vscode, covering vs code oss third-party-notices pipeline, architecture, pipeline flow in ci, applying the notice (cutover) and fallback chain (never fail the build).

microsoft/vscode · 5,001 tokens

langchain AGENTS.md

AGENTS.md instructions for langchain-ai/langchain, covering global development guidelines for the langchain monorepo, corridor security analysis, project architecture and context, monorepo structure and development tools & commands.

langchain-ai/langchain · 4,469 tokens

spec-kit AGENTS.md

AGENTS.md instructions for github/spec-kit, covering agents.md, about spec kit and specify, quickstart — add a new integration in 5 steps, integration architecture and integrationmanifest — file tracking.

github/spec-kit · 7,104 tokens