Verba/Rapida

Experiments #110

The existing fused expert reduce extended to Gemma 4's prefill shape (`transformer.zig:45185` engages only...

not

What was tested

The existing fused expert reduce extended to Gemma 4's shape (`transformer.zig:45185` engages only for two other models): bit-exact against take, multiply and sum

Model and setup

the best

Expected gain

at most about -0.2 s per 8k first (-2%; traffic estimate inside row 109's 1.45 s gap, not additive if 109 fuses the reduce; row 106)

Where the idea came from

row 107

Outcome

not started; premise confirmed in Lesto 2026-11-02: `expertReduceApply` (`src/transformer.zig:43757` at strip-4) accepts only (top_k, hidden) = (10, 2560) or (8, 4096), so Gemma 4 's (8, 2816) declines and its prefill runs the unfused reduce; to be stacked with rows 109, 111 and 105c as one lossless prefill pair; code done 2026-11-02: LESTO row/110 `8a6a7dc` (from strip-4) admits (8, 2816) behind `MLX_SERVE_R110_OFF`, the config cache key now includes hidden (), and the bit-identity test passed on the M4 at four shapes up to an 8192-token chunk (row110build, 2/2 tests); waits for the stacked pair

Want to see what these experiments produced? Lesto, the Gemma 4 inference engine for Apple silicon Macs, is on lestoengine.com

Made by Federico Andrioli, @fedeandri on X A research lab's own measurements, generated from its files. Data built