TROT

Transparent Rust ONNX Trainer

A tiny MLP written from scratch in Rust — forward pass, backward pass, weight update — compiled to WebAssembly. Train it here, trace a prediction number by number, then export the result to ONNX. Nothing is hidden behind a library call.

1 · Train

loading…

step0
loss—
train acc—
test acc—

2 · Export

A real ONNX file written by the Rust core: four nodes (Gemm → Tanh → Gemm → Sigmoid), opset 13, IR 8, initializers named after the struct fields. Open it in Netron.

not exported yet

Loads the exported bytes into onnxruntime-web (CDN, this view only) and compares every test-set prediction with the in-browser model.

3 · Data

4 · Weights

W1 is H × V — one row per hidden unit, one column per vocabulary token. Cells flash when they move.

5 · Trace a prediction

train the model, then trace a sentence.