Cubism External Edit MCP logo

Cubism External Edit MCP

Community
nana7chi

MCP for Live2D Cubism Editor 5.4 alpha1 External application integration

Publishernana7chi
RepositoryCubismExternalEditMCP
LanguagePython
Forks
7
Stars
40
Available tools
0
Transport typestdio
Categories
LicenseMIT
Links
  • Connect tools to AI workflows

    Cubism External Edit MCP exposes MCP capabilities that can be used by compatible AI clients and agents.

  • 0 available tools

    Browse the callable actions below, including names and descriptions when provided by the server.

  • Ready-to-copy setup

    Use the installation snippets to configure this server in your preferred MCP client.

  • Open source signals

    40 stars and 7 forks from the linked repository.

Cubism External Edit MCP

Cubism Editor Python MCP PyPI

License GitHub stars GitHub last commit

中文 | English | 日本語 | 한국어

将 Live2D Cubism Editor 的外部应用集成 API 封装为 MCP (Model Context Protocol) 工具,让 AI Agent 通过自然语言操控 Cubism Editor 进行建模操作。

官方下载及参考文档:https://creatorsforum.live2d.com/t/topic/3938

架构

功能特性

  • 读写操作 — 读取/写入模型参数值、查看文档列表、获取编辑模式(适用 Editor 4.x+)
  • 完整模型查询 — 参数结构、部件结构、变形器结构、单个对象详情(需 5.4 Alpha)
  • 编辑操作 — 增删改查参数/部件/变形器/ArtMesh/Glue,自动事务包裹(需 5.4 Alpha)
  • 批量编辑 — 同一事务内执行多个操作,任一失败自动回滚
  • 权限分级 — 读写需 Allow 授权,编辑需 Edit 授权
  • 自动重连 — Editor 重启后自动重连,3 秒间隔
  • Token 持久化 — 认证令牌缓存到 ~/.cubism-mcp/token.txt,避免重复授权

环境要求

组件版本
Python≥ 3.10
Cubism Editor5.4 Alpha(有效期至 2026-09-14)
操作系统Windows / macOS

使用流程

快速开始

复制以下提示词发给你的 AI Agent:

根据 https://github.com/nana7chi/CubismExternalEditMCP/blob/master/README.md 完成 cubism-mcp 的安装和配置。如果电脑上还没有 uv,请先帮我安装。配置完成后告诉我是否就绪。

第一步:安装 uv(仅一次)

uv 是一个极小的 Python 包管理器,用于自动安装和运行本 MCP。安装后无需再管 Python 环境。

macOS(终端粘贴运行):

bash
curl -LsSf https://astral.sh/uv/install.sh | sh

Windows(PowerShell 粘贴运行):

powershell
powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"

安装完成后重启终端,输入 uv --version 能看到版本号即成功。

第二步:在 AI Agent 中配置 MCP

支持 ClaudeCode, Codex, Workbuddy 等各种支持MCP的客户端

第一次启动会自动下载依赖包,耗时约 1–2 分钟,之后秒启。

方式一:PyPI 安装(推荐)

json
{
  "mcpServers": {
    "cubism-mcp": {
      "type": "stdio",
      "command": "uvx",
      "args": ["cubism-mcp"],
      "description": "Cubism Editor MCP",
      "env": { "NO_PROXY": "localhost,127.0.0.1" }
    }
  }
}

国内镜像源配置

如果 PyPI 官方源下载慢,可使用国内镜像(清华/阿里云/腾讯云等均可用):

json
{
  "mcpServers": {
    "cubism-mcp": {
      "type": "stdio",
      "command": "uvx",
      "args": ["--index-url", "https://pypi.tuna.tsinghua.edu.cn/simple", "cubism-mcp"],
      "description": "Cubism Editor MCP",
      "env": { "NO_PROXY": "localhost,127.0.0.1" }
    }
  }
}

也可替换为阿里云 https://mirrors.aliyun.com/pypi/simple 或腾讯云 https://mirrors.cloud.tencent.com/pypi/simple。

方式二:uvx 在线运行(GitHub 源)

json
{
  "mcpServers": {
    "cubism-mcp": {
      "type": "stdio",
      "command": "uvx",
      "args": ["--from", "git+https://github.com/nana7chi/CubismExternalEditMCP.git", "cubism-mcp"],
      "description": "Cubism Editor MCP",
      "env": { "NO_PROXY": "localhost,127.0.0.1" }
    }
  }
}

方式三:本地克隆运行

  1. 克隆源码到本地(或下载ZIP并解压)
bash
git clone https://github.com/nana7chi/CubismExternalEditMCP.git
  1. 添加以下MCP配置(修改 cwd 为实际路径):
json
{
  "mcpServers": {
    "cubism-mcp": {
      "type": "stdio",
      "command": "python",
      "args": ["cubism_mcp.py"],
      "cwd": "J:/修改为实际路径/CubismExternalEditMCP",
      "description": "Cubism Editor MCP",
      "env": { "NO_PROXY": "localhost,127.0.0.1" }
    }
  }
}

第三步:在 Cubism Editor 中开启外部集成

  1. 启动 Cubism Editor 5.4 Alpha,打开一个模型
  2. 菜单「文件」→「外部应用程序集成的设置」
  3. 确认端口为 22033,打开「使用」开关
  4. 弹出授权对话框,找到 cubism-mcp,勾选 Allow 和 Edit,点 OK

如果没看到弹窗,检查 Editor 右下角是否有闪烁的外部应用图标,点击即可打开对话框。

外部应用程序集成的设置

第四步:开始使用

在 AI Agent 中用自然语言操控 Editor,例如:

"列出当前模型的参数结构"
"查看部件层级"
"把眉毛部件的标签色改成蓝色"
"新建参数 ParamsTest,ID 为 ParamTest,范围 0-1,默认 0.5"
"批量添加 3 个关键帧到 ParamAngleX"

注意:每次重启 Cubism Editor 后,都需要重新开启「外部应用集成」开关并勾选 Allow + Edit 权限。

可用工具

诊断

工具说明
cubism_status检查连接状态、注册状态、Allow/Edit 授权

读写操作

工具参数说明
cubism_get_model_uid—获取当前打开模型的 UID
cubism_get_documents—列出所有打开的文档(建模/物理/动画)
cubism_get_documentdocument_uid按 UID 获取单个文档详情
cubism_get_current_edit_mode—获取编辑模式(Physics/Modeling/Animation/…)
cubism_get_parameter_valuesmodel_uid, ids?读取模型参数当前值
cubism_set_parameter_valuesmodel_uid, parameters[]写入参数值(无需编辑事务)
cubism_clear_parameter_valuesmodel_uid清除 SetParameterValues 的临时缓存
cubism_get_parametersmodel_uid参数元信息(名称/范围/Keyform/类型)
cubism_get_parameter_groupsmodel_uid参数组列表

查询结构(5.4 Alpha 新增)

工具参数说明
cubism_get_parameter_structuremodel_uid参数完整结构树(组+参数层级)
cubism_get_part_structuremodel_uid部件结构树(ArtMesh/Deformer/Part/Glue)
cubism_get_deformer_structuremodel_uid变形器结构树
cubism_get_objectmodel_uid, id获取指定对象详情
cubism_get_selectedmodel_uid获取当前选中的对象列表
cubism_get_parameter_keysmodel_uid, object_id获取对象的关键帧绑定关系
cubism_get_objects_by_parameter_keysmodel_uid, parameter_id, key_value按参数关键帧反查关联对象

编辑操作(5.4 Alpha 新增)

每个编辑 Action 均有独立 Tool(带完整类型签名和参数校验),同时保留 cubism_edit / cubism_edit_batch 用于批量操作。

参数编辑

ToolAction说明
cubism_add_parameterAddParameter添加参数
cubism_edit_parameterEditParameter编辑参数属性
cubism_delete_parameterDeleteParameter删除参数
cubism_add_parameter_groupAddParameterGroup添加参数组
cubism_edit_parameter_groupEditParameterGroup编辑参数组属性
cubism_delete_parameter_groupDeleteParameterGroup删除参数组
cubism_move_parameterMoveParameter移动参数到指定组
cubism_move_parameter_groupMoveParameterGroup调整参数组顺序

关键帧编辑

ToolAction说明
cubism_add_parameter_keyAddParameterKey添加关键帧
cubism_delete_parameter_keyDeleteParameterKey删除关键帧
cubism_move_parameter_keyMoveParameterKey移动关键帧位置

部件编辑

ToolAction说明
cubism_add_partAddPart添加部件
cubism_edit_partEditPart编辑部件属性
cubism_edit_artmeshEditArtMesh编辑 ArtMesh 属性
cubism_edit_glueEditGlue编辑 Glue 属性
cubism_delete_objectDeleteObject删除对象
cubism_move_object_on_parts_paletteMoveObjectOnPartsPalette移动对象在部件面板的位置

变形器编辑

ToolAction说明
cubism_add_warp_deformerAddWarpDeformer添加弯曲变形器
cubism_add_rotation_deformerAddRotationDeformer添加旋转变形器
cubism_edit_warp_deformerEditWarpDeformer编辑弯曲变形器属性
cubism_edit_rotation_deformerEditRotationDeformer编辑旋转变形器属性

选择操作

Tool说明
cubism_add_selected_objects编程式选中对象
cubism_clear_selected_objects清除所有选中

通用

Tool参数说明
cubism_editaction, params通用编辑入口(向后兼容)
cubism_edit_batchactions[]批量编辑(单事务,失败回滚)

常见问题

症状原因解决
MCP 状态红色Python 路径/依赖/cwd 错误检查 Python 版本 ≥ 3.10,确认依赖安装、cwd 路径正确
未连接到 EditorEditor 未启动或外部集成未开启启动 Editor → 加载模型 → 文件菜单开启外部集成
未授权弹窗未勾选 Allow在外部集成对话框中勾选 Allow
编辑报错弹窗未勾选 Edit在外部集成对话框中勾选 Edit
重启后失效Editor 重启需重新授权重新开启外部集成并勾选权限
操作报错参数/ID 不正确先用 cubism_get_*_structure 查询结构再操作

开发

bash
# 直接运行测试
python cubism_mcp.py

# 依赖
pip install -r requirements.txt

依赖

包用途
mcpMCP 服务端框架(FastMCP + stdio 通信)
websocketsWebSocket 客户端,连接 Editor API

注意事项

  • Alpha 版本限制:Cubism Editor 5.4 Alpha 有效期至 2026-09-14,到期后需升级
  • 重启授权:每次重启 Editor 都需要重新开启外部应用集成并勾选权限
  • 单模型:MCP 服务同时只能操作一个打开的模型
  • 事务安全:编辑操作自动包裹 EditBegin/EditEnd,批量操作失败自动 Cancel 回滚

License

MIT

Installation

TypingMind
{
  "mcpServers": {
    "cubismexternaleditmcp": {
      "command": "uvx",
      "args": [
        "--from",
        "git+https://github.com/nana7chi/CubismExternalEditMCP.git",
        "cubism-mcp"
      ]
    }
  }
}

Use Cubism External Edit MCP MCP with multiple AI models

TypingMind connects MCP tools at the workspace level, so once Cubism External Edit MCP is connected, you can use it with different AI models in TypingMind instead of setting it up separately for each model. This MCP runs locally through the TypingMind MCP connector on your device.

Setup guide to use the local connector

Use this when the MCP server needs access to local files, apps, or private resources on your computer.

1

Open the MCP settings

In TypingMind, go to Settings, Advanced Settings, then Model Context Protocol and choose Setup Connector.

  1. Open TypingMind in your browser.
  2. Click the Settings icon.
  3. Go to Advanced Settings.
  4. Open the Model Context Protocol section.
  5. Click Setup Connector and choose This Device.
TypingMind MCP connector setup screen with This Device selected
2

Run the connector command

Choose This Device, copy the command from TypingMind, and run it in Terminal. Keep the process running while you use MCP.

  1. Copy the setup command shown by TypingMind.
  2. Open Terminal on macOS or Windows Terminal on Windows.
  3. Paste and run the command.
  4. Approve the package install if Terminal asks you to proceed.
  5. Keep the Terminal window running while using MCP tools.
3

Add Cubism External Edit MCP as a server

When the connector status is Ready, click Edit Servers and paste the MCP server configuration.

  1. Wait until the connector status shows Ready.
  2. Click Edit Servers.
  3. Paste the Cubism External Edit MCP MCP server configuration.
  4. Save the server list.
  5. Refresh if you want to confirm the connector is still ready.
TypingMind MCP settings showing active server and Edit Servers button
{
  "mcpServers": {
    "cubismexternaleditmcp": {
      "command": "npx",
      "args": [
        "-y",
        "<mcp-server-package>"
      ]
    }
  }
}
4

Use it across models

Save the server list, open Plugins, enable the Cubism External Edit MCP MCP tools, then select any supported AI model in TypingMind and use the tools in chat or assign them to an AI agent.

  1. Open the Plugins page in TypingMind.
  2. Enable the Cubism External Edit MCP MCP tools.
  3. Start a chat and choose the AI model you want to use.
  4. Use the MCP tools in chat or assign them to an AI agent.
  5. Switch to another AI model whenever needed without reconnecting MCP.
TypingMind chat using enabled MCP tools with a selected AI model
Can you use Cubism External Edit MCP to help me with this task?
Cubism External Edit MCP
Sure. I read it.
Here is what I found using Cubism External Edit MCP.

Frequently asked questions

What is the Cubism External Edit MCP MCP server used for?

Cubism External Edit MCP is an MCP server that lets compatible AI clients connect to external tools and context. In TypingMind, you can add this MCP server once and make its tools available in your AI workspace.

Can I use Cubism External Edit MCP MCP with multiple AI models in TypingMind?

Yes. TypingMind connects MCP tools at the workspace level, so you can use Cubism External Edit MCP with different AI models such as Claude, ChatGPT, Gemini, or other models you have configured in TypingMind without setting up the MCP server separately for each model.

Why use Cubism External Edit MCP MCP with TypingMind?

TypingMind is one of the best frontends for LLM chat because it brings multiple AI models, prompts, plugins, AI agents, API keys, and MCP tools into one workspace. With Cubism External Edit MCP connected, you can use its MCP tools across your preferred models while keeping your chat workflow organized in TypingMind.

How do I connect Cubism External Edit MCP MCP to TypingMind?

Cubism External Edit MCP runs through the TypingMind local MCP connector. This is best when the MCP server needs access to local files, desktop apps, command-line tools, or private resources on your computer.

What tools does Cubism External Edit MCP MCP provide in TypingMind?

Cubism External Edit MCP exposes MCP capabilities that can be enabled from the TypingMind Plugins page and used in chat or assigned to AI agents.

Do I need to share my API keys with TypingMind to use Cubism External Edit MCP MCP?

No. TypingMind is local-first and lets you keep your model providers, API keys, prompts, and MCP configuration under your control. If Cubism External Edit MCP requires authentication, add the required headers, OAuth settings, or local configuration for that MCP server when you create the connection.

Related MCP Servers

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇