MiMo Code Quickstart

This guide gets you from zero to productive with MiMo Code β€” Xiaomi's terminal-native AI coding agent β€” in under 5 minutes.

Prerequisites

Step 1: Install

curl -fsSL https://mimo.xiaomi.com/install | bash

This installs the mimo CLI to /usr/local/bin. Verify it worked:

mimo --version
# mimo-cli v0.1.0

Step 2: Configure API Key

Sign up at platform.xiaomimimo.com and create an API key. Then configure:

mimo config set api_key=miMo-sk-your-key-here

Optionally set your preferred model:

mimo config set model=mimo-v2-flash

Step 3: Launch

cd your-project
mimo

MiMo Code reads your project structure and starts a session. The first load may take 10-20 seconds for large projects as it indexes your codebase.

Basic Commands

CommandWhat It DoesExample
/askReads code and answers questions/ask "How does the routing work?"
/editGenerates and applies code changes/edit "Add pagination to the user list endpoint"
/runExecutes a command and interprets output/run "Find all TypeScript errors"
/debugAnalyzes error output and suggests fixes/debug "Tests fail with: [paste output]"
/architectDesigns architecture and plans refactors/architect "Design a caching layer"

Multi-Agent Switching

MiMo Code uses specialized agents for different task types. You don't need to do anything special β€” just use the right command prefix:

Agents share context and memory, so information discovered by one agent is available to others.

Git Integration

MiMo Code automatically detects your Git repository. Before making edits, it checks if your working tree is clean and can create branches for changes. By default, it creates a backup branch before applying modifications:

# MiMo automatically:
# 1. Checks git status
# 2. Creates branch mimo-edit-{timestamp} if needed
# 3. Applies changes
# 4. Shows a diff before committing

Memory System

MiMo Code maintains persistent memory in .mimo/memory.json. This file records:

The memory persists across sessions. You can commit .mimo/memory.json to Git for team-wide context sharing.

Advanced Tips

Next Steps