mira_live2d
Click on "Deploy 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., "@mira_live2dMake the mascot wave and say hello to the user"
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.
mira_live2d · DSH Mascot Plugin
Ports xhqm-live2d (WordPress plugin) to a native DSH plugin: the mascot appears as a floating overlay in the conversation interface, and the model can speak, switch expressions, switch models, and play motions via MCP tools, with expressions automatically switching based on "thinking / awaiting confirmation / idle" states.
Installation (any DSH web profile)
This plugin is a dependency-free pure ESM package: the host side only uses Node built-in modules, and the browser-side runtime library is bundled in assets/lib/.
1. Install the package
dsh plugin --profile web add github:xhqm-xyz/mira_live2dYou can also clone it and install from a local path:
git clone https://github.com/xhqm-xyz/mira_live2d.git
dsh plugin --profile web add ./mira_live2d2. Register it in the profile
Append to the insert list in ~/.dsh/profiles/web/cordis.patch.yml:
- id: mira_live2d
name: 'mira_live2d'
config:
model: StellaMira # 初始模型(model 目录名)
position: right
tts:
enabled: false
provider: openai # 或 alibaba;base 可覆盖为任意 OpenAI 兼容端点
keyEnv: 'OPENAI_API_KEY' # 建议用环境变量;或用 key 填字面量(仅本机私有配置)For the API key, use
tts.keyEnv(environment variable name) ortts.key(private config file on this machine only). Never commit it to the repository.
3. Restart
dsh webAfter refreshing the page, the mascot appears in the bottom-right corner of the conversation interface.
Related MCP server: live2d-to-agent
Models
Models go in the model/ directory, one subdirectory per model, and each directory must contain a *.model3.json file (see model/README.md). mira_list_models scans automatically.
Frontend Interaction
Drag to move: mouse / single-finger drag (position remembered in localStorage)
Zoom: mouse wheel (desktop) / pinch (mobile), 0.25× ~ 3× (zoom remembered); on mobile, scales by
mobileScaleby defaultMenu: right-click (desktop) / long-press (mobile) to bring up the expression / motion menu
Expression stacking: expression items in the menu are stacking toggles; click to turn on/off (active items are marked with
✓); "Default expression" clears all expressions and stacksBubble:
mira_speak/mira_bubble/ thinking-waiting prompts are displayed here
MCP Tools (callable by the model, prefixed with mira_)
Tool | Description |
| Online status, visibility, current model/expression/motion/utterance, expression/motion lists, toggles, thinking-waiting config, switchable models |
| Lists all models in the model folder |
| Parses model3.json and returns the expression/motion list |
| Switches the displayed model |
| Switches/stacks expressions (empty string restores default; |
| Plays a motion group |
| TTS speech synthesis + bubble (makes the model speak) |
| Shows only a bubble without speaking |
| Show / hide |
| Enables/disables the expression system |
| Enables/disables motion playback |
| Manually sets thinking / awaiting / idle |
| Sets thinking/awaiting expressions, bubbles, and idle clear delay |
| Reads the current config (TTS key is never returned in plaintext) |
Expressions: Mutually Exclusive and Stacking
By default,
mira_set_expression(name)is a mutually exclusive replacement: the new expression fades out the previous one.mira_set_expression(name, stack=true)is a stacking toggle: adds the expression to the stack, where it can coexist with the current exclusive expression and other stacked expressions (relies onBlend:Addin exp3.json).Expression items in the right-click / long-press menu are always stacking toggles (
✓means enabled); click once to turn on, click again to turn off.mira_set_expression("")(empty string) restores the default: clears the exclusive expression + all stacked expressions.
Configuration Options
All optional; defaults are in DEFAULTS in lib/index.js:
Key | Default | Description |
|
| Master switch |
|
| Initial model (model directory name) |
| plugin | Model directory override |
|
| Canvas internal resolution |
|
| Initial |
|
| Mobile zoom percentage |
|
| Show operation hint on first display |
|
| Command polling interval |
|
| Expression/bubble while thinking (empty by default) |
|
| Expression/bubble while awaiting confirmation (empty by default) |
|
| Delay before clearing the expression when idle |
|
| TTS switch |
|
|
|
| provider default | API base URL |
|
| API Key (literal) |
|
| Environment variable name holding the API Key |
| provider default | Model / voice |
How Thinking / Awaiting Expressions Are Triggered
Model starts generating (agent enters
running) →mood: thinkingModel calls
ask_user_question→mood: awaitingModel finishes the turn (agent returns to
idle) →mood: idle, and the default expression is restored afteridleClearMsYou can also set it manually with
mira_set_mood
Third-Party Components
assets/lib/ bundles PixiJS (MIT), pixi-live2d-display (MIT), and Live2D Cubism Core (proprietary, Live2D Software License Agreement). The full copyright and license texts for each component are in THIRD-PARTY-NOTICES.md.
This server cannot be deployed
Maintenance
Related MCP Connectors
AI voice generation: text-to-speech and voice cloning from any MCP client.
MCP server for AI dialogue using various LLM models via AceDataCloud
MCP server exposing the AceDataCloud Fish Audio API (text-to-speech with voice conditioning)
MCP server for Text-to-Speech
Related MCP Servers
AlicenseNot gradedqualityCmaintenanceEnables chatting with an AI waifu character through MCP tools, with user management and dialog history.4MIT No Attribution- AlicenseNot gradedqualityBmaintenanceEnables AI agents to control a Live2D desktop pet's expressions and actions via MCP protocol.MIT
- FlicenseNot gradedqualityBmaintenanceEnables AI assistants to show, animate, and control a VRM character on the desktop, including posing and motion installation via MCP tools.1-
- AlicenseNot gradedqualityBmaintenanceEnables AI assistants to control a desktop virtual character (VRM) by playing animations, showing/hiding the character, and checking runtime status through the MCP protocol.479,6752MIT