Expand description
Ferric web — proves the SAME pure-Rust kernels (ferric-core) run in the browser on WebGPU. The matmul WGSL, the Context, the readback — all identical to native; only the target changes.
Functions§
- ferric_
lm_ demo - Runs the full Ferric transformer LM in the browser on WebGPU: greedy-generates
stepstokens from a comma-separated prompt of token ids, and validates the prefill logits against the in-wasm CPU reference. Returns a JSON string {backend, prompt, generated, layers, logit_diff, ms}. - ferric_
matmul_ demo - Runs the Ferric matmul on the browser’s WebGPU and validates against the CPU reference. Returns “backend|maxdiff|first6”.