From Live Code to Sound: Building a Ruby Live Coding Engine
summary
Built a Ruby live‑coding engine called Studier RB that ports Studier/TidalCycles patterns into the terminal, uses Parslet to parse mini notation, and reuses last year’s Groovebox Ruby audio engine to output via PortAudio. Timing uses rational positions and a scheduler that queries patterns in 128‑frame subchunks inside a 2048‑frame buffer, avoiding drift. Randomness is deterministic by hashing event start times. Live reload uses the listen gem and keeps the last good pattern on error; tracks can be muted with underscore track, and recording exports WAV.
AI-written summary · about
chapters (16)
- 0:00Introduction
- 1:18Introducing Studier RB
- 2:22First Ruby sound demo
- 3:48How patterns work
- 8:48Time and hops explained
- 10:59Scheduling and playback
- 13:33Effects and output
- 13:58Recap with demo
- 14:41Adding harmony and arpeggio
- 17:19Live coding in action
- 18:49Error handling principle
- 20:14Silence is the worst
- 21:00Live coding pitfalls
- 22:08Deterministic randomness
- 22:51Where to try Studier RB
- 23:56Hidden track demo








