borch

Embeddable · no server

Live ML you can put on any page.

Each widget below trains in your browser, on your GPU. Press Run to see it; press Copy to take the one line that drops it into your blog, your docs, your course — no server, no sign-up. Like a Gradio demo, minus the server.

Watch a network learn a boundary Copy embed code

An MLP bends a boundary to fit two moons · open the lesson →

Attention, live Copy embed code

The causal-attention matrix as a heatmap · open the lesson →

A conv layer's kernels Copy embed code

Six 3×3 filters, drawn at initialisation · open the lesson →

A loss curve falling Copy embed code

Adam training a tiny problem · open the lesson →

Learning rate matters Copy embed code

Three rates, three fates: diverge, converge, crawl · open the lesson →

Why depth needs a skip Copy embed code

The gradient shrinking with depth · open the lesson →

Batch norm, drawn Copy embed code

Activations before and after · open the lesson →

Dropout's mask Copy embed code

The random mask that regularises · open the lesson →

The singular-value spectrum Copy embed code

The SVD's singular values, plotted · open the lesson →

Softmax as probabilities Copy embed code

Logits turned into a distribution · open the lesson →

Vectors & dot products Copy embed code

Two vectors and the angle between them · open the lesson →

Broadcasting, drawn Copy embed code

How shapes stretch to meet · open the lesson →

A training loop Copy embed code

Loss coming down over steps · open the lesson →

Gradients, flowing Copy embed code

A gradient read straight off the graph · open the lesson →

Layer norm, drawn Copy embed code

Each row centred on its own · open the lesson →

Attention weights Copy embed code

Which positions attend to which · open the lesson →

The FFT Copy embed code

A signal and its frequencies · open the lesson →

Curve fitting Copy embed code

A curve learned to fit points · open the lesson →

Autoencoder Copy embed code

An image squeezed through a bottleneck · open the lesson →

Adversarial example Copy embed code

A tiny change that flips the label · open the lesson →

Character RNN Copy embed code

Text, one character at a time · open the lesson →

A batch, drawn Copy embed code

Samples stacked into a batch · open the lesson →

Quickstart Copy embed code

The smallest end-to-end run · open the lesson →

How it embeds

One line, and it runs on your reader's GPU

The Copy button on each card hands you an <iframe> — nothing else to install or host. It trains in the reader's browser; on a browser without WebGPU it says so in a sentence rather than breaking. Want one of your own? Write a cell in the playground, or start from a lesson and embed its code.

<iframe src="https://playidea-lab.github.io/borch/site/embed/embed.html?lesson=mini-transformer&cell=4"
        width="100%" height="480" style="border:0"></iframe>

Two honest notes: the reader needs WebGPU (Chrome/Edge 113+, Firefox 141+, Safari 26+) — without it the widget says so, it does not break. And a host page that is itself cross-origin-isolated (rare; most blogs are not) will block the frame — ordinary pages are fine.

Open the playground → Browse the lessons