npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

pi-xiaomi-mimo-provider

v1.2.0

Published

Xiaomi Mimo provider extension for pi coding agent — registers mimo-v2-pro, mimo-v2-omni, and mimo-v2-tts models

Readme

pi-xiaomi-mimo-provider

Xiaomi Mimo provider extension for the pi coding agent. Registers Xiaomi Mimo models using the OpenAI-compatible API.

Models

| Model | Context (default) | Max Context | Max Output | Reasoning | Input | Input $/MTok | Output $/MTok | | --- | --- | --- | --- | --- | --- | --- | --- | | MiMo V2 Pro | 128K | 1M | 16K | ✅ | Text, Image | $1.00 | $3.00 | | MiMo V2 Omni | 128K | 1M | 16K | ✅ | Text, Image | $1.00 | $3.00 | | MiMo V2 TTS | 128K | 1M | 16K | ❌ | Text | Free | Free |

Installation

# From GitHub
pi install git:github.com/ulusoyomer/pi-xiaomi-mimo-provider

# From npm
pi install npm:pi-xiaomi-mimo-provider

Setup

After installing, authenticate with your Xiaomi Mimo API key:

/login xiaomi-mimo

Get your API key at: https://platform.xiaomimimo.com/#/console/plan-manage

Alternative: Environment Variable

You can also set your API key via environment variable:

export XIAOMI_MIMO_API_KEY="your-api-key-here"

Or add it to ~/.pi/agent/models.json:

{
  "providers": {
    "xiaomi-mimo": {
      "baseUrl": "https://token-plan-sgp.xiaomimimo.com/v1",
      "api": "openai-completions",
      "apiKey": "YOUR_API_KEY",
      "models": [
        { "id": "mimo-v2-pro" },
        { "id": "mimo-v2-omni" },
        { "id": "mimo-v2-tts" }
      ]
    }
  }
}

Usage

Switch to a Xiaomi Mimo model:

/model mimo-v2-pro

API Endpoints

| Protocol | Base URL | | --- | --- | | OpenAI Compatible | https://token-plan-sgp.xiaomimimo.com/v1 | | Anthropic Compatible | https://token-plan-sgp.xiaomimimo.com/anthropic |

This extension uses the OpenAI-compatible endpoint.

Context Window

The default context window is 128K (131072 tokens) to keep credit usage low. You can increase or change it at any time.

Runtime Command

Use /mimo-context to view or change the context window without restarting:

/mimo-context           # Show current value
/mimo-context 256k      # Set to 256K
/mimo-context 512k      # Set to 512K
/mimo-context 1m        # Set to 1M (maximum)
/mimo-context 131072    # Set with a plain number

Environment Variable

Set the context window at startup via environment variable:

export XIAOMI_MIMO_CONTEXT_WINDOW="256k"

Supported formats: 64k, 128k, 256k, 512k, 1m, or a plain number (max 1048576).

Reasoning Control

Toggle reasoning on/off with pi's thinking commands:

/thinking off       # Reasoning OFF
/thinking minimal   # Minimal reasoning
/thinking low       # Low reasoning
/thinking medium    # Medium reasoning
/thinking high      # Max reasoning

Applies to mimo-v2-pro and mimo-v2-omni only. mimo-v2-tts does not support reasoning.

Notes

  • The API returns reasoning_content in responses, which pi handles natively for reasoning models
  • Default context window is 128K tokens (131072) — configurable via XIAOMI_MIMO_CONTEXT_WINDOW env var or /mimo-context command
  • Maximum supported context window is 1M tokens (1048576)
  • Cost values based on official Xiaomi pricing: $1/$3 per MTok (up to 256K context), $2/$6 (256K-1M context)
  • Cache write is currently free per Xiaomi's pricing page

License

MIT