LLM + RoboticsModule 04 · Edge AI & data flywheels

Big teacher, small student: distilling fast on-device models for apps and robots

Use a large model to label your real data, then fine-tune a tiny one that matches it on your task at a fraction of the size and latency. This is the recipe behind every fast model on a robot.

Source: Maxime Rivest, 19 Oct 2026 · X post · own-voice-stt repo (README plus the evaluation, pitfalls and next-steps docs, all saved in sources/)

In this module
  1. Summary
  2. Why this matters for robotics
  3. Deep dive: teacher–student distillation
  4. Deep dive: reading the results honestly
  5. Deep dive: latency is a safety number (interactive)
  6. Deep dive: evaluation that doesn't fool you
  7. Deep dive: pitfalls that transfer to robots
  8. Playbook
  9. Self-check
  10. Glossary & further reading

1. Summary

TL;DR

Rivest's five-step recipe:

  1. Find repeatable tasks.
  2. Use whatever model gets them done well.
  3. Log the runs.
  4. Fine-tune the smallest open model that reaches the accuracy you need.
  5. Get near state-of-the-art quality at high speed on tiny compute.

His demonstration: 2.5 months of his own speech, transcribed live by NVIDIA Parakeet (627M parameters), used to fine-tune a 32M-parameter FastConformer. The small model tied the big one on his voice (11.1% vs 11.0% word error rate) at 1/20 the size, and replies in ~85 ms instead of ~1,060 ms on a 2019 laptop CPU.

2. Why this matters for robotics

This is the most directly robotic link so far. Robots live under the exact constraints the recipe targets:

3. Deep dive: teacher–student distillation

Knowledge distillation trains a small student model to reproduce a large teacher's outputs. Rivest uses the simplest form, pseudo-labelling: the teacher's transcripts become the training targets. No human labels are needed for training.

record ─► teacher labels ─► hand-correct a sample ─► splits ─► fine-tune ─► evaluate ─► export
(weeks)    (big model)        (= your test set)        (by day)   (minutes)    (honest)    (CPU/phone)

Why it works: a general model has to be good at everyone's speech. Your task is narrower: one voice, one microphone, a known vocabulary. A small model fine-tuned on that narrow distribution has enough capacity for it. You trade generality, which you weren't using, for speed.

Key consequences:

Robotics version: privileged teacher → deployable student

In simulation, you can give a teacher policy information no real robot has, such as exact ground friction, terrain height maps and contact forces. It learns to walk well. Then a student policy, which sees only what real sensors provide (joint encoders, IMU, maybe a depth camera), is trained to imitate the teacher's actions. The student is what ships. Same recipe, but the teacher's advantage is information rather than size.

4. Deep dive: reading the results honestly

Results on 459 hand-corrected clips that were never trained on. Brackets are 95% bootstrap intervals.

ModelParamsWER, allWER, commandsExactly right
Parakeet 0.6B v3 (teacher)627M11.0% (8.7–13.9)8.0%80%
Student, before fine-tune32M23.7% (21.0–26.6)20.8%46%
Student, fine-tuned32M11.1% (8.8–13.7)7.7%76%

"A tie" is the correct claim, not "better". The paired difference (student minus teacher on the same clips) is +0.1 points, with a 95% interval of −1.9 to +2.0. That interval crosses zero.

Note the exactly-right column. For commands, one wrong word means a wrong command, and WER hides that. The student is 76% exactly right vs the teacher's 80%. For a robot, that's the column that matters.

The chart in the tweet (one RTX 3090) shows the same story against Whisper large-v3 (1,550M) and Whisper large-v3 turbo (809M). The Whispers reach lower WER on one-minute clips (~6%), but take hundreds of ms to ~3 s per recording. The tuned 32M model sits at ~10–11% across clip lengths in tens of ms. Different points on a Pareto frontier.

5. Deep dive: latency is a safety number

Measured "wait after speech" (end of speech to text):

ModelHardwareWait
Parakeet 0.6B2019 laptop CPU, 4 threads~1,060 ms
32M student, PyTorchsame laptop~150 ms
32M student, sherpa-onnx int8 (43 MB)same laptop, 2 threads~85 ms
32M studentone RTX 3090~50 ms

A laptop CPU is a fair stand-in for robot compute. Now turn those milliseconds into metres:

Interactive: how far does the robot travel after you say "stop"?

Total = distance during (speech recognition wait + 50 ms control reaction) + braking distance v²/2a. Speech duration isn't counted because it's the same for every model. Reference speeds: a warehouse AMR travels ~1.5–2 m/s, a jogging human ~3 m/s.

Two more latency lessons from the repo:

Safety note: real robots never rely on speech recognition alone for emergency stops. Hardware e-stop buttons and safety-rated sensors do that job. A voice "stop" is a convenience layer on top, and the maths above is why it should be as fast as possible anyway.

6. Deep dive: evaluation that doesn't fool you

The repo's evaluation doc is a great general checklist. It extends the method from Module 01:

7. Deep dive: pitfalls that transfer to robots

What broke in voiceRobot equivalent
WAVs were 44.1/48 kHz, not the 16 kHz the docs claimedCamera or IMU rates and units differ from the spec sheet. Read the data, not the docs.
280 h recorded, only 19 h had speechMost robot logs are idle time. Filter, but keep some "nothing happening" examples.
Teacher answered in Cyrillic on 12 English commandsTeacher labels can be confidently wrong. Drop bad targets, don't "fix" them.
Other voices (and a robot vacuum!) in the roomOther people and robots in the scene contaminate demonstrations. Filter by operator or source.
Data augmentation masked most of a 1-second "yes"Augmentations tuned for long sequences destroy short ones. Check them on your shortest examples.
Streaming export dropped the last word unless fed ~1.2 s of trailing silenceExported or compiled models can behave differently at the edges. Re-validate on the device, against the original.
int8 was smaller but not faster on x86; 8 threads were slower than 2Quantisation and threading gains depend on the hardware. Measure on the robot's own board.
Push-to-talk cut off words; the phone app swallowed errors silentlyInterfaces need margins and visible state. Show what the robot heard or saw, and every error.

8. Playbook

  1. Pick one repeatable, narrow task on your robot (or your desk): voice commands, a specific object detector, grasp success prediction.
  2. Run the best big model you can, and log every input and output with a timestamp.
  3. Hand-correct a few hundred examples as your test set, including the hard slices (short, rare, new conditions).
  4. Split by day or episode, plus a cutoff date for drift.
  5. Fine-tune the smallest open model. Start small and only go up if you miss your minimum bar (Module 01).
  6. Compare paired against the teacher, with intervals. Report exactly-right rates for commands.
  7. Export (ONNX, int8), re-validate on the target device, and measure end-to-end latency there.
  8. Keep the flywheel turning: targeted top-ups for weak spots, and a few new corrections each week.

9. Self-check

The student matches the teacher on the test set. Is it as accurate as the teacher in general?

No. It ties only on this person's voice, microphone and mostly command-style speech. It's almost certainly worse on other speakers. The claim is narrow, and that's fine.

Why shouldn't you score the student against the teacher's transcripts?

That only measures "agrees with the teacher". The teacher has ~11% WER itself. Hand corrections are the ground truth.

At 2 m/s, roughly how much farther does a robot travel with the 1,060 ms model than with the 85 ms one?

About (1.06 − 0.085) × 2 ≈ 1.95 m before braking even starts. That's the length of a person.

Why split by whole days instead of randomly by clip?

Clips from one day are near-duplicates (same room, mic, topic). A random split leaks them across train and test and inflates scores.

Training longer stopped helping. What helped instead?

Targeted data: 90 takes of the command words, mixed in at 3%, raised exactly-right commands from 88% to 93% in 2.5 minutes of training.

How is the locomotion "privileged teacher" different from Rivest's teacher?

Rivest's teacher is better because it's bigger. The locomotion teacher is better because it sees more information (simulator state). In both, the student imitates the teacher using only what will be available at deployment.

10. Glossary & further reading

TermMeaning
DistillationTraining a small student model to reproduce a large teacher's outputs
Pseudo-labelsTeacher outputs used as training targets in place of human labels
WERWord error rate: (substitutions + deletions + insertions) / words in the reference
Exactly-right rateShare of utterances transcribed with zero errors. This is what matters for commands.
Data flywheelDeploy → log → label → retrain → redeploy, improving with use
Distribution driftChange in data over time or place that degrades a trained model
Bootstrap intervalUncertainty range from resampling the test set with replacement
int8 quantisationStoring weights as 8-bit integers: smaller, sometimes faster, slightly less accurate
ONNX / sherpa-onnxPortable model format, and a runtime for speech models on CPUs and phones
Privileged teacherA policy trained with information (e.g. simulator state) unavailable to the deployed student