Run frontier MoE models on hardware you already own — pure C, zero deps, experts streamed from disk. Tiny engine, immense model. 🐦
C
st.h: index I32/U32 tensors (token ids in the qwen-image reference dumps)
JustVugga0060ac57b43
diff --git a/c/st.h b/c/st.hindex 286cfd75..2fc8b895 100644--- a/c/st.h+++ b/c/st.h@@ -95,6 +95,9 @@ static int st_dtype_code(const char *s) {!strcmp(s, "float8_e4m3fn")) return 4;if (!strcmp(s, "F8_E8M0") || !strcmp(s, "F8_E8M0FNU")) return 5;if (!strcmp(s, "I64") || !strcmp(s, "U64")) return 6;+ /* I32/U32: token ids in reference dumps (tools/make_qwenimage_tiny.py). Same+ * rule as the fp8 codes above: a new number, read raw, refused by the float readers. */+ if (!strcmp(s, "I32") || !strcmp(s, "U32")) return 7;fprintf(stderr, "unsupported dtype: %s\n", s); exit(1);}@@ -106,6 +109,7 @@ static inline int st_dtype_esz(int dtype) {case 2: return 4; /* F32 */case 3: case 4: case 5: return 1; /* U8/I8, F8_E4M3, F8_E8M0 */case 6: return 8; /* I64/U64 */+ case 7: return 4; /* I32/U32 */default: return 2; /* BF16, F16 */}}@@ -115,7 +119,7 @@ static inline const char *st_dtype_name(int dtype) {switch (dtype) {case 0: return "BF16"; case 1: return "F16"; case 2: return "F32";case 3: return "U8/I8"; case 4: return "F8_E4M3"; case 5: return "F8_E8M0";- case 6: return "I64"; default: return "?";+ case 6: return "I64"; case 7: return "I32"; default: return "?";}}