Western Cyber Society
A model that composes. Now it takes direction.
MAiSTRO is an LSTM trained on Mozart, Beethoven and Chopin. It could always write music. What it could not do was write it differently twice, take a request, or tell you whether it had improved.
repetition 0.172 · The decoder MAiSTRO shipped with. One path out of any passage, so it keeps returning to material it has already played.
repetition 0.024 · Same model, same seed, same 300 notes. Nine more pitches in play, and it stops circling.
Nothing was retrained between these two. The only change is how the next note gets chosen — and by note 300 the two decoders disagree on 61% of the model's decisions.
Where it started
Eight students, one LSTM
AI was writing essays and painting pictures, and music composition sat strangely untouched. A team of eight set out to see whether a network could learn the shape of classical piano from the notation itself.
It worked. A bidirectional LSTM with an attention layer, trained on 200 MIDI files, produced pieces you would happily leave playing. That model is still here, still the default, and the story of building it is worth reading first.
What follows is what happened when it stopped being a model and started being a tool.
What changed
Six problems, six answers
Each of these began as something that annoyed someone using it.
The decoder was never asked
It always played the likeliest next note, so it looped.
Temperature, top-k and nucleus sampling, calibrated against this model's own confidence rather than borrowed from text generation.
You couldn't ask for anything
Generation started from a random passage. If you disliked it, you re-rolled.
Ask for a key, a scale, a tempo, a mood. The bias is applied as the note is chosen, so nothing needed retraining.
Loss cannot hear
A lower validation loss does not mean a better piece of music.
Two models compose the same brief and you judge them blind. Elo ratings, the same system chess uses, settle the argument.
One model, no comparison
The original network spends 175M of its parameters on a single output layer.
A plain LSTM and a 3.9M-parameter transformer now share the dataset and decoder, so the architecture is the only variable.
Hearing it meant installing Fluidsynth
The model emits MIDI. Turning that into sound needed a soundfont and a C library.
Tone.js synthesises the notes in your browser, and a canvas piano roll draws them as they play.
A piano cannot play every genre
No arrangement of piano notes means 'dusty Rhodes through a tape delay'.
MusicGen generates audio from a text prompt; Magenta continues a melody entirely in your browser.
Measured, not estimated
What it bought
- 0.95
- Mean top probability
- 0.151 → 0.024
- Repetition rate
- 0.79 → 0.93
- Notes in the asked-for key
- 46×
- Fewer parameters
Why textbook sampling defaults do nothing here
Greedy against temperature 1.9, over 4 seeds
Unconditioned against C major
Transformer against the original network
Every figure comes from running the trained model, averaged across four random seeds. The workings, including where the numbers are less flattering than they look, are in how it works.
The model is trained and waiting
Pick a key, pick a mood, move the creativity dial, and hear what a network trained on three dead composers does with the request.
Compose something