Skip to content

A 2.78-trillion-parameter Kimi K3 running inference on a single CPU in 8.24 GB of RAM. Portable C99: no BLAS, no framework, no GPU.

589 B
Raw Blame
flowchart LR
    F["prompt from a FILE<br/>never argv"] --> B["raw UTF-8 bytes"]
    B --> BPE["byte-level BPE<br/>163,584 ranks"]
    BPE --> IDS["token ids"]
    IDS --> CHK{"decode back<br/>byte-exact?"}
    CHK -->|"45 of 45"| PASS["matches tiktoken"]
    style F fill:#ECE8E0,stroke:#8C8477,color:#3B372F
    style B fill:#E4ECF3,stroke:#5C7C9B,color:#3B372F
    style BPE fill:#F2E9D4,stroke:#C0913E,color:#3B372F
    style IDS fill:#E7ECDD,stroke:#6E9160,color:#3B372F
    style CHK fill:#EAE4F1,stroke:#7E6E9C,color:#3B372F
    style PASS fill:#DDEBE7,stroke:#4E8E86,color:#3B372F