plano/demos/integrations/xiaomi_mimo/README.md
2026-04-02 13:04:13 -07:00

1.5 KiB

Xiaomi MiMo via Plano

This demo configures Plano to call Xiaomi MiMo as a standard LLM upstream using the OpenAI-compatible API surface.

Prerequisites

  1. Ensure the prerequisites are installed correctly.
  2. Export your MiMo API key:
export MIMO_API_KEY=your_mimo_api_key

Start the demo

sh run_demo.sh

Plano will start a model listener on http://localhost:12000.

First API call through Plano

curl --location --request POST 'http://localhost:12000/v1/chat/completions' \
  --header "Content-Type: application/json" \
  --data-raw '{
    "model": "mimo-v2-pro",
    "messages": [
      {
        "role": "system",
        "content": "You are MiMo, an AI assistant developed by Xiaomi. Today is Tuesday, December 16, 2025. Your knowledge cutoff date is December 2024."
      },
      {
        "role": "user",
        "content": "please introduce yourself"
      }
    ],
    "max_completion_tokens": 1024,
    "temperature": 1.0,
    "top_p": 0.95,
    "stream": false
  }'

Optional: OpenAI Python SDK against Plano

from openai import OpenAI

client = OpenAI(
    api_key="unused-when-calling-plano",
    base_url="http://localhost:12000/v1",
)

resp = client.chat.completions.create(
    model="mimo-v2-pro",
    messages=[{"role": "user", "content": "please introduce yourself"}],
)

print(resp.model_dump_json(indent=2))

Stop the demo

sh run_demo.sh down