Two days ago we shipped
@huggingface/kernels. Now here's the deep dive.
Why we publish Jinja templates instead of WGSL files, how the browser compiles the fastest kernel for your GPU, and what that unlocks:
โ attention in 20 lines of JS, running on the GPU
โ 1M+ pixels animated by a single matmul, 400 fps vs 6 fps in plain JS
โ Fleet: benchmark your GPU, help us tune the kernels for every device out there
Full video โ