Xiaomi logo

MiMo-V2-Flash

MiMov-V2-FlashDeprecated
byXiaomiXiaomi(enterprise)
Released December 14, 2025

Deprecated June 29, 2026

Context262.1K tokens
Price (In / Out)$0.09/M / $0.29/M
CategoryLarge Language Model
Max Output65.5K tokens

About MiMo-V2-Flash

MiMo-V2-Flash is a large language model from Xiaomi. Supports up to 262,144 token context window. Available from $0.09/M input tokens.

Capabilities

textcode

Input Modalities

text

Output Modalities

text

Technical Details

API Identifier
xiaomi/mimo-v2-flash
Category
Large Language Model
Context Window
262,144 tokens
Max Output Tokens
65,536 tokens

Tags

budget-friendlylong-context

Run this model yourself

Local and cloud setup for MiMo-V2-Flash, with exact configurations, sources and clear evidence limits.

Find a model for your hardware
Local hardwareDocumented setupSources checked Oct 16, 2026

Run MiMo V2 Flash Q4_K_M on a 256 GiB Xeon workstation

Serve the complete four-shard Unsloth quantization with the exact native MiMo template, one CPU sequence and a bounded non-thinking text check. The 256 GiB RAM allocation is a planning choice; actual fit and speed are unknown.

Hardware
Intel Xeon w5-2465X / ASUS W790E-SAGE SE,256GiB RAM,400GiB free disk
Runtime
llama.cpp v0.7.0 (620d2225cc436ab0b001e3200e590e3b286ef9ab) · CPU
Model format
GGUF · GGUF Q4_K_M mixed quantization · Unsloth Q4_K_M mixed quantization of the complete named MiMo-V2-Flash core
Workload
4,096 token context · 1 concurrent

Based on source documentation; this setup has not been executed by OpenTools. Memory: unknown. No compatible measurement available.

Read the complete setup guide

Before you start

  • Use an existing Intel Xeon w5-2465X workstation on ASUS Pro WS W790E-SAGE SE with Ubuntu24.04 x86_64. The CPU has16cores/32threads and supports up to2TB; the board lists the processor family and ECC registered DDR5 memory. Require256GiB actually installed and visible to the OS, plus400GiB free disk. Verify exact CPU support, BIOS, DIMM QVL and channel population before following the guide; a platform maximum does not validate particular installed DIMMs.
  • Allocate16 inference threads. RAM and disk selections exceed the serialized files but do not establish peak-memory fit, startup success or useful speed. Build natively and run on the same host.
  • Read the model and derivative MIT declarations and the separately pinned publisher source repository Apache License2.0. Preserve both applicable notice sets; no equivalence or replacement is inferred. This is an Unsloth quantization, not a Xiaomi-published GGUF.
  • This is ordinary autoregressive text generation using the complete named four-shard core artifact. Speculative MTP acceleration is disabled; actual MTP tensor presence in these derivative files is unknown. No alternative model, partial expert subset or conversion is substituted.
  • The native model is a309B total/15B active,48-layer hybrid-attention MoE with256 routed experts and eight selected per token. It is not MiMo Base, VL or V2.5.

Exact model and requirements

Artifact:
Unsloth (GGUF derivative); Xiaomi MiMo (native checkpoint) / MiMo-V2-Flash Q4_K_M, four-shard Unsloth derivative · checkpoint unsloth/MiMo-V2-Flash-GGUF
Publisher revision:
04c761fbebcf4f3239b1cfdafec85533dcc0dea3
Artifact digest:
Four separately hashed files form this split GGUF; no whole-composition digest is published or invented.
Download size:
173.97 GiB
Memory requirement (unknown):
Unknown — Exact MiMo CPU process peak and full working-memory fit have not been measured.
System RAM / disk:
Unknown / Unknown
Placement:
single device. Four split GGUF files are one model on one CPU host, not tensor or pipeline sharding. One CPU host with --device none and zero GPU layers; no accelerator or distributed offload.
KV cache:
F16 attention K/V cache selected explicitly; hybrid sliding/global allocation and other working tensors are not measured.
Workload:
4,096 token context; Unknown; Unknown; concurrency 1; batch 1; cache unknown; repetitions Unknown.
Tokenizer:
MiMo-V2-Flash GGUF tokenizer with separately extracted exact native template · 04c761fbebcf4f3239b1cfdafec85533dcc0dea3; native template 1afd314a2406c282e0956375c34a676501c78649
Sampling / reasoning:
Native general writing preset temperature0.8 and top-p0.95. Top-k disabled, min-p0, presence/frequency penalties0 and repeat penalty1 select a neutral penalty baseline. Explicit enable_thinking=false selects bounded non-thinking generation. Explicit native MiMo non-thinking mode via enable_thinking=false and reasoning off. Long reasoning and MTP acceleration remain separate unqualified workflows.
Runtime prerequisites:
Ubuntu 24.04 x86_64; See prerequisites above.

Official artifact · License

The exact native model card/API declare MIT, and the named Unsloth derivative declares MIT with explicit native-base linkage. The native snapshot has no LICENSE file; its404 response is preserved. The separately pinned publisher repository LICENSE is Apache License2.0, not MIT; do not infer it replaces the model metadata declaration. Preserve applicable MIT copyright/permission notices and Apache source license, attribution, notices and modification requirements. Both licenses disclaim warranties. No license equivalence or legal clearance is asserted.

  • All four GGUF shards total 186,798,293,696 bytes. Fifteen billion active parameters does not reduce the 309B total model to a 15B storage or RAM footprint.
  • Hybrid attention uses distinct sliding and global layers; no dense cache formula or active-parameter memory estimate is substituted. Runtime overhead, operating system and setup files are additional.

One-time setup and hardware

hardware
Unknown — Existing desktop purchase price and incremental hardware cost depend on the reader; unknown.
Existing desktop purchase price and incremental hardware cost depend on the reader; unknown. Tax: unknown.
setup
Unknown — Initial provisioning/build time and labor cost are unknown.
Initial provisioning/build time and labor cost are unknown. Tax: unknown.

Recurring costs

electricity
Unknown — Actual wall power, electricity rate and powered hours are unknown; no TDP-to-wall-power conversion.
Actual wall power, electricity rate and powered hours are unknown; no TDP-to-wall-power conversion. Tax: unknown.
storage
Unknown — Incremental cost of local disk capacity is unknown. The 400 GiB free-disk walkthrough allocation is an author choice, not a measured requirement.
Incremental local400GiB available disk cost is unknown; this is an allocation, not a measured minimum. Tax: unknown.
egress
Unknown — Data transfer price, allowances and traffic volume are unknown.
Data transfer price, allowances and traffic volume are unknown. Tax: unknown.
administration
Unknown — Maintenance labor rate and hours are unknown.
Maintenance labor rate and hours are unknown. Tax: unknown.

Install the runtime

  1. 1. Build the exact CPU runtime

    Build official pinned llama.cpp on this same CPU. CPU dispatch and the model-specific mimo2 implementation are source-qualified; this does not establish executed compatibility or fit.

    Command
    set -e
    sudo apt-get update
    sudo apt-get install -y build-essential cmake git curl ca-certificates openssl python3
    mkdir -p "$HOME/mimo-v2-flash-hosting/models"
    cd "$HOME/mimo-v2-flash-hosting"
    git clone https://github.com/ggml-org/llama.cpp.git
    cd llama.cpp
    git checkout --detach 620d2225cc436ab0b001e3200e590e3b286ef9ab
    test "$(git rev-parse HEAD)" = 620d2225cc436ab0b001e3200e590e3b286ef9ab
    cmake -S . -B build -DCMAKE_BUILD_TYPE=Release -DGGML_METAL=OFF -DGGML_NATIVE=ON
    cmake --build build --config Release -j 16
    ./build/bin/llama-server --version

    Expected result: Checkout and build succeed. Stop on any failure; save version/build logs for actual execution.

Download the model

  1. 1. Download and verify all four shards and native template

    All four hashed shards are required in the same directory. The server opens the first shard and discovers the split set. The explicit template is extracted verbatim from the independently pinned original tokenizer configuration; derivative template fixes are not silently inherited.

    Command
    set -e
    cd "$HOME/mimo-v2-flash-hosting"
    curl --fail --location --output models/MiMo-V2-Flash-Q4_K_M-00001-of-00004.gguf 'https://huggingface.co/unsloth/MiMo-V2-Flash-GGUF/resolve/04c761fbebcf4f3239b1cfdafec85533dcc0dea3/Q4_K_M/MiMo-V2-Flash-Q4_K_M-00001-of-00004.gguf'
    curl --fail --location --output models/MiMo-V2-Flash-Q4_K_M-00002-of-00004.gguf 'https://huggingface.co/unsloth/MiMo-V2-Flash-GGUF/resolve/04c761fbebcf4f3239b1cfdafec85533dcc0dea3/Q4_K_M/MiMo-V2-Flash-Q4_K_M-00002-of-00004.gguf'
    curl --fail --location --output models/MiMo-V2-Flash-Q4_K_M-00003-of-00004.gguf 'https://huggingface.co/unsloth/MiMo-V2-Flash-GGUF/resolve/04c761fbebcf4f3239b1cfdafec85533dcc0dea3/Q4_K_M/MiMo-V2-Flash-Q4_K_M-00003-of-00004.gguf'
    curl --fail --location --output models/MiMo-V2-Flash-Q4_K_M-00004-of-00004.gguf 'https://huggingface.co/unsloth/MiMo-V2-Flash-GGUF/resolve/04c761fbebcf4f3239b1cfdafec85533dcc0dea3/Q4_K_M/MiMo-V2-Flash-Q4_K_M-00004-of-00004.gguf'
    curl --fail --location --output models/tokenizer_config.json 'https://huggingface.co/XiaomiMiMo/MiMo-V2-Flash/resolve/1afd314a2406c282e0956375c34a676501c78649/tokenizer_config.json'
    sha256sum --check <<'SHA256'
    50dc7766a8364b0f97055d8620a72a318c0b5c3d2f851c3b296cae157fc52296  models/MiMo-V2-Flash-Q4_K_M-00001-of-00004.gguf
    9af01fdef6281988e7ff6423035a326ab556ed834e30e58d7da9b6f4c2304bb0  models/MiMo-V2-Flash-Q4_K_M-00002-of-00004.gguf
    a52d3727be9d5abbf440225d9c327b6d475c50f66bc082d62091060fd562d863  models/MiMo-V2-Flash-Q4_K_M-00003-of-00004.gguf
    8085a7e5c56cdb14a143f640961bd2dfccbe90b6d797b566298163d664113fd6  models/MiMo-V2-Flash-Q4_K_M-00004-of-00004.gguf
    866769c8cc9df227d5a77a16270adfefae994618ba2dce071a82fa2b221e8492  models/tokenizer_config.json
    SHA256
    python3 - <<'PYTEMPLATE'
    import json,pathlib,hashlib
    p=pathlib.Path('models/tokenizer_config.json')
    b=json.loads(p.read_text())['chat_template'].encode('utf-8')
    assert hashlib.sha256(b).hexdigest() == '4beaf0261e25552e9f1d6a0bd98a18aa171ba6206f5c025ed404951564d007d7'
    pathlib.Path('models/native-chat-template.jinja').write_bytes(b)
    PYTEMPLATE

    Expected result: All five downloaded files report OK and the derived native template hash matches. No model-bearing file was downloaded while authoring this guide.

Configure

  1. 1. Preserve a private service key

    Create only when absent; an existing empty key fails rather than silently rotating access. This is your local service credential, not a paid provider key.

    Command
    set -e
    cd "$HOME/mimo-v2-flash-hosting"
    umask 077
    if [ ! -e .api-key ]; then openssl rand -hex 32 > .api-key; fi
    test -s .api-key
    chmod 600 .api-key

    Expected result: Private nonempty key exists without printing it.

Start the model

  1. 1. Start bounded ordinary autoregressive generation

    Run one sequence and16 allocated CPU threads with4096 total context and a512 response cap. The native template explicitly closes thinking when enable_thinking is false. Speculative type none selects the runtime ordinary AR path; it does not prove that the GGUF includes every optional MTP tensor. No tool parser, tool execution or remote access is enabled.

    Command
    set -e
    cd "$HOME/mimo-v2-flash-hosting"
    export MIMO_SERVICE_KEY="$(cat .api-key)"
    ./llama.cpp/build/bin/llama-server -m models/MiMo-V2-Flash-Q4_K_M-00001-of-00004.gguf --alias mimo-v2-flash --host 127.0.0.1 --port 8080 --api-key "$MIMO_SERVICE_KEY" --device none -ngl 0 -t 16 -c 4096 -np 1 --cache-type-k f16 --cache-type-v f16 --jinja --chat-template-file models/native-chat-template.jinja --chat-template-kwargs '{"enable_thinking":false}' --reasoning off --reasoning-format none --skip-chat-parsing --spec-type none --temp 0.8 --top-p 0.95 --top-k 0 --min-p 0 --presence-penalty 0 --frequency-penalty 0 --repeat-penalty 1

    Expected result: Listener initializes only after successful model loading. Command-line key may be visible to privileged local users; a trusted host is required.

Connect to your endpoint

http://127.0.0.1:8080/v1

Same workstation loopback only, on a trusted host.

Access: loopback. Chat requires the private service key in the Authorization Bearer header. Health is public on loopback. Protect the key; privileged host users can inspect processes. No provider inference credential is required.

Verify the setup

  1. 1. Check health, private completion and denied unauthenticated access

    Run from a second server terminal. Update the explicit system date to the actual date when using the guide. The parser checks shape, nonempty output and completion rather than length truncation; then manually compare all library hours and Sunday closure with the source. Incorrect or extended-thinking output fails the check. Exact wording is not prescribed.

    Command
    set -e
    cd "$HOME/mimo-v2-flash-hosting"
    export MIMO_SERVICE_KEY="$(cat .api-key)"
    curl --fail http://127.0.0.1:8080/health
    curl --fail http://127.0.0.1:8080/v1/chat/completions -H "Authorization: Bearer $MIMO_SERVICE_KEY" -H 'Content-Type: application/json' --data-binary @- > response.json <<'REQUEST'
    {"model":"mimo-v2-flash","messages":[{"role":"system","content":"You are MiMo, an AI assistant developed by Xiaomi.\n\nToday's date: 2026-10-16 Friday. Your knowledge cutoff date is December 2024."},{"role":"user","content":"Summarize only this passage in one sentence: The community library opens at 9am on weekdays and closes at 6pm. On Saturday it opens at 10am and closes at 4pm. It is closed on Sunday."}],"max_tokens":512,"temperature":0.8,"top_p":0.95,"top_k":0,"min_p":0,"presence_penalty":0,"frequency_penalty":0,"repeat_penalty":1,"stream":false,"chat_template_kwargs":{"enable_thinking":false}}
    REQUEST
    python3 - <<'PYRESPONSE'
    import json,pathlib
    x=json.loads(pathlib.Path('response.json').read_text()); c=x['choices'][0]
    assert c['finish_reason'] == 'stop'
    s=c['message']['content']; assert isinstance(s,str) and s.strip()
    assert '<think>' not in s.replace('<think></think>','')
    print(s)
    PYRESPONSE
    status=$(curl --silent --output /dev/null --write-out '%{http_code}' http://127.0.0.1:8080/v1/chat/completions -H 'Content-Type: application/json' --data '{"model":"mimo-v2-flash","messages":[{"role":"user","content":"Hello"}]}')
    test "$status" = 401

    Expected result: Health200, authenticated nonempty complete response with accurate weekday/Saturday hours and Sunday closure, and unauthenticated401. Structural checks do not prove factual accuracy.

Performance evidence

No compatible measurement available. Documented support and estimated memory do not establish response speed.

Limits and troubleshooting

  • Source-documented configuration; no build, weights, inference, fit or performance measurement was performed.
  • The complete four-shard derivative totals 186,798,293,696 bytes; all routed-expert files must remain present. Active parameters are not a hardware sizing shortcut.
  • Native context is262144 text positions; this guide allocates4096 total prompt plus response, one sequence and a512 response cap. Prompt/output counts remain unmeasured.
  • Non-thinking native template mode is selected for a useful bounded summary check. Long reasoning, long context, tool calling and multi-turn reasoning-history persistence need separate complete recipes.
  • MTP is optional speculative acceleration in this selected runtime, explicitly disabled here. Derivative MTP tensor composition is unknown. No MTP speedup or full MTP workflow is claimed.
  • The native model has distinct sliding-window and global attention dimensions, learnable sliding attention sinks and routed experts. F16 cache flags do not establish a full working-memory formula or benchmark.
  • The native sampler recommends temperature0.8/top-p0.95 for writing; this guide disables unrelated top-k/min-p/penalty defaults rather than inheriting another model family preset.
  • A loopback listener and service key require a trusted host and do not provide multi-user isolation or a production public service.
  • Installed package/tool resolution and actual CPU compatibility remain reader execution checks; save logs and stop on failures. RAM/disk allocations do not guarantee startup or throughput.
Hash or split-file error
Stop. Check all four exact shard names, byte hashes and pinned revision. Keep the first-shard naming pattern and every shard in the same directory; never use a partial set.
Architecture or template load failure
Confirm the pinned runtime, mimo2 architecture and exact derived native template. Do not substitute Base, VL, V2.5 or an older binary. Preserve logs and stop.
Out of memory or slow response
Stop the foreground server. Inspect actual available RAM and full logs; the selected allocation is not measured fit. Additional capacity or altered context changes the configuration. Do not interpret15B active as15B stored.
HTTP401 or connection refused
Use the same private key, loopback port8080 and correct SSH host. Wait for successful initialization; never open the service port to fix a private connection.
Thinking trace, truncation or wrong summary
Confirm native template hash, enable_thinking=false, reasoning off and finish reason. Stop on length truncation; manually check every source fact. A parser pass is not a correctness guarantee.

Stop the model

  1. 1. Stop the foreground server

    Press Ctrl+C in the server terminal, then unset the key in each shell. Verify localhost no longer serves.

    Command
    unset MIMO_SERVICE_KEY
    if curl --silent --max-time 2 http://127.0.0.1:8080/health >/dev/null; then echo 'Still serving; stop the foreground process.'; exit 1; fi

    Expected result: No service remains on loopback8080.

Uninstall

  1. 1. Remove the dedicated walkthrough files

    After stopping, back up wanted logs, confirm the dedicated directory and remove only it. Shared apt packages can remain.

    Command
    rm -r -- "$HOME/mimo-v2-flash-hosting"

    Expected result: Dedicated model, build, responses and key removed; shared packages remain.

Sources and verification

Sources checked Oct 16, 2026. Verification source

Related guides

Compare this configuration
Cloud serverDocumented setupSources checked Oct 16, 2026

Run MiMo V2 Flash Q4_K_M on an AWS r7i.8xlarge CPU host

Serve the complete four-shard Unsloth quantization with the exact native MiMo template, one CPU sequence and a bounded non-thinking text check. The 256 GiB RAM allocation is a planning choice; actual fit and speed are unknown.

Hardware
AWS r7i.8xlarge CPU,256GiB RAM,400GiB gp3,16 allocated threads
Runtime
llama.cpp v0.7.0 (620d2225cc436ab0b001e3200e590e3b286ef9ab) · CPU
Model format
GGUF · GGUF Q4_K_M mixed quantization · Unsloth Q4_K_M mixed quantization of the complete named MiMo-V2-Flash core
Workload
4,096 token context · 1 concurrent

Based on source documentation; this setup has not been executed by OpenTools. Memory: unknown. No compatible measurement available.

Read the complete setup guide

Before you start

  • Use your existing AWS r7i.8xlarge Linux host in us-east-1, Ubuntu24.04 x86_64,32vCPU and256GiB RAM with a400GiB gp3 root allocation. Keep TCP8080 closed; connect with your existing SSH identity. No provisioning is performed by this guide.
  • Allocate16 inference threads. RAM and disk selections exceed the serialized files but do not establish peak-memory fit, startup success or useful speed. Build natively and run on the same host.
  • Read the model and derivative MIT declarations and the separately pinned publisher source repository Apache License2.0. Preserve both applicable notice sets; no equivalence or replacement is inferred. This is an Unsloth quantization, not a Xiaomi-published GGUF.
  • This is ordinary autoregressive text generation using the complete named four-shard core artifact. Speculative MTP acceleration is disabled; actual MTP tensor presence in these derivative files is unknown. No alternative model, partial expert subset or conversion is substituted.
  • The native model is a309B total/15B active,48-layer hybrid-attention MoE with256 routed experts and eight selected per token. It is not MiMo Base, VL or V2.5.

Exact model and requirements

Artifact:
Unsloth (GGUF derivative); Xiaomi MiMo (native checkpoint) / MiMo-V2-Flash Q4_K_M, four-shard Unsloth derivative · checkpoint unsloth/MiMo-V2-Flash-GGUF
Publisher revision:
04c761fbebcf4f3239b1cfdafec85533dcc0dea3
Artifact digest:
Four separately hashed files form this split GGUF; no whole-composition digest is published or invented.
Download size:
173.97 GiB
Memory requirement (unknown):
Unknown — Exact MiMo CPU process peak and full working-memory fit have not been measured.
System RAM / disk:
Unknown / Unknown
Placement:
single device. Four split GGUF files are one model on one CPU host, not tensor or pipeline sharding. One CPU host with --device none and zero GPU layers; no accelerator or distributed offload.
KV cache:
F16 attention K/V cache selected explicitly; hybrid sliding/global allocation and other working tensors are not measured.
Workload:
4,096 token context; Unknown; Unknown; concurrency 1; batch 1; cache unknown; repetitions Unknown.
Tokenizer:
MiMo-V2-Flash GGUF tokenizer with separately extracted exact native template · 04c761fbebcf4f3239b1cfdafec85533dcc0dea3; native template 1afd314a2406c282e0956375c34a676501c78649
Sampling / reasoning:
Native general writing preset temperature0.8 and top-p0.95. Top-k disabled, min-p0, presence/frequency penalties0 and repeat penalty1 select a neutral penalty baseline. Explicit enable_thinking=false selects bounded non-thinking generation. Explicit native MiMo non-thinking mode via enable_thinking=false and reasoning off. Long reasoning and MTP acceleration remain separate unqualified workflows.
Runtime prerequisites:
Ubuntu 24.04 x86_64; See prerequisites above.

Official artifact · License

The exact native model card/API declare MIT, and the named Unsloth derivative declares MIT with explicit native-base linkage. The native snapshot has no LICENSE file; its404 response is preserved. The separately pinned publisher repository LICENSE is Apache License2.0, not MIT; do not infer it replaces the model metadata declaration. Preserve applicable MIT copyright/permission notices and Apache source license, attribution, notices and modification requirements. Both licenses disclaim warranties. No license equivalence or legal clearance is asserted.

  • All four GGUF shards total 186,798,293,696 bytes. Fifteen billion active parameters does not reduce the 309B total model to a 15B storage or RAM footprint.
  • Hybrid attention uses distinct sliding and global layers; no dense cache formula or active-parameter memory estimate is substituted. Runtime overhead, operating system and setup files are additional.

One-time setup and hardware

hardware
Not applicable — AWS hardware acquisition is included in compute rental; no purchased GPU required. Any separate hardware cost is not applicable.
AWS hardware acquisition is included in compute rental; no purchased GPU required. Any separate hardware cost is not applicable. Tax: unknown.
setup
Unknown — Initial provisioning/build time and labor cost are unknown.
Initial provisioning/build time and labor cost are unknown. Tax: unknown.

Recurring costs

compute
$2.12 / hour
Exact AWS published us-east-1 Linux On-Demand row: USD2.1168 per billed instance-hour. Eight hours USD16.9344;24 hours USD50.8032 compute. Idle running hours bill. Storage, transfer, taxes and administration are separate; capacity unknown. Region: us-east-1. SKU: r7i.8xlarge Linux On-Demand. Tax: excluded. Price dated Oct 15, 2026. Price source
storage
$0.08 / GB month
Existing dated us-east-1 gp3 quote USD0.08 per GB-month, with GB defined as1024^3 bytes. Selected400GiB costs USD32 per full month, prorated by provisioned duration, at baseline3000IOPS/125MB/s. Retained resources and snapshots bill separately. Region: us-east-1. SKU: EBS gp3 baseline 3000 IOPS / 125 MB/s. Tax: excluded. Price dated Oct 16, 2026. Price source
egress
Unknown — Data transfer price, allowances and traffic volume are unknown.
Data transfer price, allowances and traffic volume are unknown. Tax: unknown.
administration
Unknown — Maintenance labor rate and hours are unknown.
Maintenance labor rate and hours are unknown. Tax: unknown.

Install the runtime

  1. 1. Build the exact CPU runtime

    Build official pinned llama.cpp on this same CPU. CPU dispatch and the model-specific mimo2 implementation are source-qualified; this does not establish executed compatibility or fit.

    Command
    set -e
    sudo apt-get update
    sudo apt-get install -y build-essential cmake git curl ca-certificates openssl python3
    mkdir -p "$HOME/mimo-v2-flash-hosting/models"
    cd "$HOME/mimo-v2-flash-hosting"
    git clone https://github.com/ggml-org/llama.cpp.git
    cd llama.cpp
    git checkout --detach 620d2225cc436ab0b001e3200e590e3b286ef9ab
    test "$(git rev-parse HEAD)" = 620d2225cc436ab0b001e3200e590e3b286ef9ab
    cmake -S . -B build -DCMAKE_BUILD_TYPE=Release -DGGML_METAL=OFF -DGGML_NATIVE=ON
    cmake --build build --config Release -j 16
    ./build/bin/llama-server --version

    Expected result: Checkout and build succeed. Stop on any failure; save version/build logs for actual execution.

Download the model

  1. 1. Download and verify all four shards and native template

    All four hashed shards are required in the same directory. The server opens the first shard and discovers the split set. The explicit template is extracted verbatim from the independently pinned original tokenizer configuration; derivative template fixes are not silently inherited.

    Command
    set -e
    cd "$HOME/mimo-v2-flash-hosting"
    curl --fail --location --output models/MiMo-V2-Flash-Q4_K_M-00001-of-00004.gguf 'https://huggingface.co/unsloth/MiMo-V2-Flash-GGUF/resolve/04c761fbebcf4f3239b1cfdafec85533dcc0dea3/Q4_K_M/MiMo-V2-Flash-Q4_K_M-00001-of-00004.gguf'
    curl --fail --location --output models/MiMo-V2-Flash-Q4_K_M-00002-of-00004.gguf 'https://huggingface.co/unsloth/MiMo-V2-Flash-GGUF/resolve/04c761fbebcf4f3239b1cfdafec85533dcc0dea3/Q4_K_M/MiMo-V2-Flash-Q4_K_M-00002-of-00004.gguf'
    curl --fail --location --output models/MiMo-V2-Flash-Q4_K_M-00003-of-00004.gguf 'https://huggingface.co/unsloth/MiMo-V2-Flash-GGUF/resolve/04c761fbebcf4f3239b1cfdafec85533dcc0dea3/Q4_K_M/MiMo-V2-Flash-Q4_K_M-00003-of-00004.gguf'
    curl --fail --location --output models/MiMo-V2-Flash-Q4_K_M-00004-of-00004.gguf 'https://huggingface.co/unsloth/MiMo-V2-Flash-GGUF/resolve/04c761fbebcf4f3239b1cfdafec85533dcc0dea3/Q4_K_M/MiMo-V2-Flash-Q4_K_M-00004-of-00004.gguf'
    curl --fail --location --output models/tokenizer_config.json 'https://huggingface.co/XiaomiMiMo/MiMo-V2-Flash/resolve/1afd314a2406c282e0956375c34a676501c78649/tokenizer_config.json'
    sha256sum --check <<'SHA256'
    50dc7766a8364b0f97055d8620a72a318c0b5c3d2f851c3b296cae157fc52296  models/MiMo-V2-Flash-Q4_K_M-00001-of-00004.gguf
    9af01fdef6281988e7ff6423035a326ab556ed834e30e58d7da9b6f4c2304bb0  models/MiMo-V2-Flash-Q4_K_M-00002-of-00004.gguf
    a52d3727be9d5abbf440225d9c327b6d475c50f66bc082d62091060fd562d863  models/MiMo-V2-Flash-Q4_K_M-00003-of-00004.gguf
    8085a7e5c56cdb14a143f640961bd2dfccbe90b6d797b566298163d664113fd6  models/MiMo-V2-Flash-Q4_K_M-00004-of-00004.gguf
    866769c8cc9df227d5a77a16270adfefae994618ba2dce071a82fa2b221e8492  models/tokenizer_config.json
    SHA256
    python3 - <<'PYTEMPLATE'
    import json,pathlib,hashlib
    p=pathlib.Path('models/tokenizer_config.json')
    b=json.loads(p.read_text())['chat_template'].encode('utf-8')
    assert hashlib.sha256(b).hexdigest() == '4beaf0261e25552e9f1d6a0bd98a18aa171ba6206f5c025ed404951564d007d7'
    pathlib.Path('models/native-chat-template.jinja').write_bytes(b)
    PYTEMPLATE

    Expected result: All five downloaded files report OK and the derived native template hash matches. No model-bearing file was downloaded while authoring this guide.

Configure

  1. 1. Preserve a private service key

    Create only when absent; an existing empty key fails rather than silently rotating access. This is your local service credential, not a paid provider key.

    Command
    set -e
    cd "$HOME/mimo-v2-flash-hosting"
    umask 077
    if [ ! -e .api-key ]; then openssl rand -hex 32 > .api-key; fi
    test -s .api-key
    chmod 600 .api-key

    Expected result: Private nonempty key exists without printing it.

Start the model

  1. 1. Start bounded ordinary autoregressive generation

    Run one sequence and16 allocated CPU threads with4096 total context and a512 response cap. The native template explicitly closes thinking when enable_thinking is false. Speculative type none selects the runtime ordinary AR path; it does not prove that the GGUF includes every optional MTP tensor. No tool parser, tool execution or remote access is enabled.

    Command
    set -e
    cd "$HOME/mimo-v2-flash-hosting"
    export MIMO_SERVICE_KEY="$(cat .api-key)"
    ./llama.cpp/build/bin/llama-server -m models/MiMo-V2-Flash-Q4_K_M-00001-of-00004.gguf --alias mimo-v2-flash --host 127.0.0.1 --port 8080 --api-key "$MIMO_SERVICE_KEY" --device none -ngl 0 -t 16 -c 4096 -np 1 --cache-type-k f16 --cache-type-v f16 --jinja --chat-template-file models/native-chat-template.jinja --chat-template-kwargs '{"enable_thinking":false}' --reasoning off --reasoning-format none --skip-chat-parsing --spec-type none --temp 0.8 --top-p 0.95 --top-k 0 --min-p 0 --presence-penalty 0 --frequency-penalty 0 --repeat-penalty 1

    Expected result: Listener initializes only after successful model loading. Command-line key may be visible to privileged local users; a trusted host is required.

Connect to your endpoint

http://127.0.0.1:8080/v1

VM loopback only. Run verification over existing SSH; optional tunnel: ssh -N -L 8080:127.0.0.1:8080 ubuntu@HOST. Replace HOST with the existing instance host.

Access: loopback. Chat requires the private service key in the Authorization Bearer header. Health is public on loopback. Protect the key; privileged host users can inspect processes. No provider inference credential is required.

Verify the setup

  1. 1. Check health, private completion and denied unauthenticated access

    Run from a second server terminal. Update the explicit system date to the actual date when using the guide. The parser checks shape, nonempty output and completion rather than length truncation; then manually compare all library hours and Sunday closure with the source. Incorrect or extended-thinking output fails the check. Exact wording is not prescribed.

    Command
    set -e
    cd "$HOME/mimo-v2-flash-hosting"
    export MIMO_SERVICE_KEY="$(cat .api-key)"
    curl --fail http://127.0.0.1:8080/health
    curl --fail http://127.0.0.1:8080/v1/chat/completions -H "Authorization: Bearer $MIMO_SERVICE_KEY" -H 'Content-Type: application/json' --data-binary @- > response.json <<'REQUEST'
    {"model":"mimo-v2-flash","messages":[{"role":"system","content":"You are MiMo, an AI assistant developed by Xiaomi.\n\nToday's date: 2026-10-16 Friday. Your knowledge cutoff date is December 2024."},{"role":"user","content":"Summarize only this passage in one sentence: The community library opens at 9am on weekdays and closes at 6pm. On Saturday it opens at 10am and closes at 4pm. It is closed on Sunday."}],"max_tokens":512,"temperature":0.8,"top_p":0.95,"top_k":0,"min_p":0,"presence_penalty":0,"frequency_penalty":0,"repeat_penalty":1,"stream":false,"chat_template_kwargs":{"enable_thinking":false}}
    REQUEST
    python3 - <<'PYRESPONSE'
    import json,pathlib
    x=json.loads(pathlib.Path('response.json').read_text()); c=x['choices'][0]
    assert c['finish_reason'] == 'stop'
    s=c['message']['content']; assert isinstance(s,str) and s.strip()
    assert '<think>' not in s.replace('<think></think>','')
    print(s)
    PYRESPONSE
    status=$(curl --silent --output /dev/null --write-out '%{http_code}' http://127.0.0.1:8080/v1/chat/completions -H 'Content-Type: application/json' --data '{"model":"mimo-v2-flash","messages":[{"role":"user","content":"Hello"}]}')
    test "$status" = 401

    Expected result: Health200, authenticated nonempty complete response with accurate weekday/Saturday hours and Sunday closure, and unauthenticated401. Structural checks do not prove factual accuracy.

Performance evidence

No compatible measurement available. Documented support and estimated memory do not establish response speed.

Limits and troubleshooting

  • Source-documented configuration; no build, weights, inference, fit or performance measurement was performed.
  • The complete four-shard derivative totals 186,798,293,696 bytes; all routed-expert files must remain present. Active parameters are not a hardware sizing shortcut.
  • Native context is262144 text positions; this guide allocates4096 total prompt plus response, one sequence and a512 response cap. Prompt/output counts remain unmeasured.
  • Non-thinking native template mode is selected for a useful bounded summary check. Long reasoning, long context, tool calling and multi-turn reasoning-history persistence need separate complete recipes.
  • MTP is optional speculative acceleration in this selected runtime, explicitly disabled here. Derivative MTP tensor composition is unknown. No MTP speedup or full MTP workflow is claimed.
  • The native model has distinct sliding-window and global attention dimensions, learnable sliding attention sinks and routed experts. F16 cache flags do not establish a full working-memory formula or benchmark.
  • The native sampler recommends temperature0.8/top-p0.95 for writing; this guide disables unrelated top-k/min-p/penalty defaults rather than inheriting another model family preset.
  • A loopback listener and service key require a trusted host and do not provide multi-user isolation or a production public service.
  • Installed package/tool resolution and actual CPU compatibility remain reader execution checks; save logs and stop on failures. RAM/disk allocations do not guarantee startup or throughput.
Hash or split-file error
Stop. Check all four exact shard names, byte hashes and pinned revision. Keep the first-shard naming pattern and every shard in the same directory; never use a partial set.
Architecture or template load failure
Confirm the pinned runtime, mimo2 architecture and exact derived native template. Do not substitute Base, VL, V2.5 or an older binary. Preserve logs and stop.
Out of memory or slow response
Stop the foreground server. Inspect actual available RAM and full logs; the selected allocation is not measured fit. Additional capacity or altered context changes the configuration. Do not interpret15B active as15B stored.
HTTP401 or connection refused
Use the same private key, loopback port8080 and correct SSH host. Wait for successful initialization; never open the service port to fix a private connection.
Thinking trace, truncation or wrong summary
Confirm native template hash, enable_thinking=false, reasoning off and finish reason. Stop on length truncation; manually check every source fact. A parser pass is not a correctness guarantee.

Stop the model

  1. 1. Stop the foreground server

    Press Ctrl+C in the server terminal, then unset the key in each shell. Verify localhost no longer serves. Stopping the process does not stop EC2 billing.

    Command
    unset MIMO_SERVICE_KEY
    if curl --silent --max-time 2 http://127.0.0.1:8080/health >/dev/null; then echo 'Still serving; stop the foreground process.'; exit 1; fi

    Expected result: No service remains on loopback8080.

Uninstall

  1. 1. Remove the dedicated walkthrough files

    After stopping, back up wanted logs, confirm the dedicated directory and remove only it. Shared apt packages can remain.

    Command
    rm -r -- "$HOME/mimo-v2-flash-hosting"

    Expected result: Dedicated model, build, responses and key removed; shared packages remain.

Shut down cloud resources

  1. 1. End cloud billing resources

    In EC2 us-east-1, stop for later reuse or terminate this exact VM. Review Delete on termination for its root volume. Delete unwanted detached EBS volumes, snapshots and reserved/Elastic/public IP resources. Stopped VM storage and retained resources may still bill. Check Bills/Cost Explorer later for final usage.

    Expected result: Exact instance is stopped/terminated as intended; no unwanted attached/retained billed resources remain. Instance compute stops only after its lifecycle transition, not when llama-server stops.

Sources and verification

Sources checked Oct 16, 2026. Verification source

Related guides

Compare this configuration

Benchmarks

Performance scores for MiMo-V2-Flash across standard benchmarks.

GPQA DiamondArtificial Analysis
65.6%
Terminal-Bench 2.1Artificial Analysis
61.8%
AIME 2025Artificial Analysis
67.7%

Pricing

Token pricing for MiMo-V2-Flash API usage.

Input Tokens

$0.09/M

per million tokens

Output Tokens

$0.29/M

per million tokens

Cache read: $0.0450/M tokens

Xiaomi logo
Xiaomienterprise

Innovation for everyone.

4 ModelsFounded 2010Beijing, China
View full profile

AI Models by Xiaomi

AI models from the same organization.

ModelContext WindowPrice (In / Out per M)
MiMo-V2.6-FlashCurrent1.0M$0.14 / $0.28
MiMo-V2-OmniDeprecated262KDeprecated
MiMo-V2-ProDeprecated1.0MDeprecated

Related News

Latest coverage and updates.