Import reusable instruments, patterns and helpers, then adapt them to your own songs.
What it is#
A curated set of reusable patches, effect chains, and rhythm patterns that ship with Volta as plain .volta source. They live under a served /lib/ tree and are pulled into a song with ordinary imports, so a newcomer can reach for a tuned kick, acid bass, or hall reverb instead of hand-spelling every voice. The library needs no compiler support of its own — it is built entirely on Reuse sounds and patterns with imports, and it composes the primitive DSP builtins (sine/saw, reverb, pingpong, …) rather than replacing them.
Surface#
Library modules group reusable sounds and tools, each importable by name. A song imports the bindings it needs and wires them with play, |>, and pattern literals:
import "drums" (kick, snare, hat)
import "bass" (acid)
import "keys" (pad)
import "fx" (hall)
import "rhythm" (fourFloor, backbeat, offbeat)
kickTrack = play kick fourFloor
padTrack = play pad (!"c3 ab2 f2 g2" |> slow 2) |> hall
The modules and their public bindings (as shipped):
| Module | Bindings | Kind |
|---|---|---|
drums | kick, snare, clap, hat, rim, ride | instrument patches (plus priv body, an unexported helper) |
mod | vibrato, triggeredVibrato, tremoloGain, duckGain, followerGain, psuSag, wobble, filterOpen, filterEnv, scoop, flutter, humanizePatch, duckedPatch | Control recipes and patch transforms — Modulation recipes |
bass | sub, reese, acid | instrument patches |
creator_foundations | anchorKick, pocketSnare, linenHat, gatherClap, rootSub, relayBass, velvetKeys, willowPluck, contourPoly, haloPad, ribbonLead, weatherTexture | 60 original parameterized instruments, each exposing .voice and four independent knobs; the twelve pilot constructors listed here plus 48 additions, a complete dry tour and 12 Dance Fugues — Ready-made instruments |
keys | pad, pluck, ep | instrument patches |
pads | 31 pad presets across 7 families — warmAnalog, supersaw, pwm, hollowSquare, unisonWide, octaveStack, filterSweep, resonantSweep (analog) · stringMachine, cinematicStrings, octaveStrings (strings) · choir, vowelMorph, whisperAir (vocal) · glass, crystalShimmer, softBell, metallic (bell/FM) · synthBrass, softBrass (brass) · wavetableScan, multiLfoMotion, drone, ambientWash, noiseAir, perlinOrganic, chaos, swirl, granularPad (texture) · tapeLofi, darkSinister (character) | pad-archetype instrument patches; shared bright/space/air knobs. granularPad is a note-pitched grains cloud (C1); a few pads carry a per-preset @knobs { … } snapshot (C6) restored on audition. Auditioned by the padtour preset. |
leads | 30 synth-lead presets across 8 families — analog/subtractive (sawLead, squareLead, pwmLead, pulseReed, octaveLead, brassLead) · supersaw/trance (superLead, hoover, tranceLead, wideStab) · acid/resonant (acidLead, squelch, resoPluck, dirtyAcid) · FM/digital (fmLead, bellLead, metalLead, digiLead) · plucks (pluck, glassPluck, arpLead) · aggressive (screamLead, growlLead, fuzzLead, razor) · vocal/soft (fluteLead, vocalLead, softLead) · air (whistleLead, windLead) | mono/topline instrument patches; shared bite/grit/wide knobs; mono/acid leads use glide + glideMode/glideCurve. The melodic counterpart to pads; auditioned by the leadtour preset. |
circuits | 35 analog-character presets across 8 families — basses (modelD, acid303, rubber101, fmStab) · pads/strings (junoWash, solina, deckard, prophet5, airwave, warmChoir) · leads (luckyLead, moogLead, ms20, chime) · keys/plucks (fullTines, rhodesMk1, nylon, glassBell, grandStretch) · brass (obStab, jumpBrass) · circuit drums (boom808, punch909, snap808, hats606, handClap, analogTom) · fx/textures (filterOcean, sciZap, chaosDrone, tapeGhost) · hybrid (neoBass, grainPad, bowLead, morphPoly) | classic-hardware emulations built on the "fatness stack" (as3340 chip character, soften, drift, tol, hiss, asymmetric drive bias, tube) + the era-correct filter topology (ladder/diode/korg35/svf) and chorus (bbd Juno modes / ensemble / the ensembleChorus triple-BBD wash on solina). Shared tone/warmth/age (the Vintage/Slop) knobs. as3340 character, adsr punch, tol, bbd modes and the circuit drums all render through the one engine on every target; the deeper, circuit-modeled cousin of vintage. Auditioned by the circuittour preset. |
modal | 17 measured mode tables + a patch on each, across 5 families — struck metal (bell, handbell, tubular, gong, bronze — named so because plate is the built-in plate reverb) · tuned bars (marimba, xylophone, vibraphone, tine) · glass (glass, crystal, bowl) · membranes (membrane, timpani) · wood & pan (woodblock, claves, steelpan). Each body also exports its raw table as <name>Modes (bellModes, gongModes, …) | a data library: [[ratio, T60, amp], …] tables from the acoustics literature (Fletcher & Rossing), ratio relative to the PLAYED pitch — so a bell's hum note is 0.5 and a tubular chime starts at 2 (its strike note is a missing fundamental). The tables are ordinary list values, so they compose with src |> body (freq pitch) gongModes; modalOf (sample "…") fits one from a recording instead. Shared hit/tone knobs. Auditioned by the modaltour preset. |
kernels | Classic DSP laws as user-kernel recipes — softclip, diode, crossover, wavefold, crush, cheb2, cheb3 (waveshapers) · adaaClip, adaaTanh, clipAD, lncosh (anti-aliased clippers) · onepoleLp, onepoleHp, biquadLp, biquadHp, biquadBp (filters, RBJ cookbook via sampleRate) · dcblock, slewLim (utilities) · logistic (chaos) · fastExp, fastExp2, fastLn, fastLog2, fastSin, fastCos, fastTan, fastTanh (fast math) · polyBlep, polyBlep4, polyBlamp, blep4Mag, blamp4Mag, blPhasor, blSaw, blSquare, blPulse, blTri, syncSaw, oscStep, oscNext (band-limited oscillator helpers) | apply with process / process2 (+ partial application: process2 (biquadLp 1200.0 0.9)); auditioned by the kernellab preset. Write a custom audio processor § The kernel stdlib. |
dsplib | effect declarations written in the language — slew2, linkedComp, linkedComp2, darkEcho, fdnRoom, onePole, tptSvf, envFilter, zdfLadder, diffuser, dattorro, chorusLine, flangeLine, phase90, compressor, compressor2, fbComp, optoComp, brickLimit, transients, tapeSat, bitcrusher, bitcrusher2, ringer | each takes a configuration record with literal defaults (darkEcho { feedback = 0.6 }, {} for all defaults); a macro passed for a parameter rides live in the kernel law |
dspfast | linkedCompFast, compressorFast, transientsFast, phase90Fast | the dsplib laws of the same name on kernels' fast math instead of per-sample libm calls |
spectrallib | robotize, whisperize, binShift, binShiftLocked, pitchShiftPV, pitchShiftLocked, specComp, specGateK, tiltK, freezeK, blurK, sustainK | effect … on track over spectralMap / spectralPolar per-bin STFT laws — Write a spectral effect |
osclib | polySaw, polyPulse, polyTri, syncLead, fmPair, folder, ksPluck, noiseDrum | oscillator declarations: a named source whose subject is the frequency, called polySaw (freq pitch) {} or piped freq pitch |> polySaw {} |
vintage | minimoog, juno, dx, hammond, jupiter, prophet, cs80 | classic-synth emulation patches |
fx | hall, room, plate, pingDelay, dub; filterMotion, autoWah, tremoloMotion, panMotion, velocityColor, filteredDuck, transientColor, delayMotion, grainMotion, colorGesture | Track transforms plus reusable audio effects — Modulation recipes |
pedals | spaceEcho, spring, slapback (bus) · grit, warmth, dimension, phase90, flange, crush (voice) | classic-effect emulations |
kits | drumKit(punch, tone), pop4(key) | parameterized modules (a kit / a key-voiced progression) |
machines | tr808(tune, decay) — kick, snare, hat (per-note open), ohat, tomLo/tomMid/tomHi, rim, cowbell, clap, cymbal · tr909(punch, tone) — kick, snare, hat, ohat, clap, ride, crash · skins(tension, damping) — tom, timpani, gong, tabla | the analog drum machines as parameterized modules over the circuit-modeled drum voices (Design a drum kit) — tuned defaults, gain staging, per-instance drive/snappy/tone macros (box.drive). skins wraps the mesh membranes, the one pitch-tracked kit. No sample anywhere. Auditioned by the machinetour preset. |
harmony | Chord/Quality/Interval types · transpose, parallelMinor, parallelMajor, invert, parallel, relative, leadingTone · choraleVoicing, openVoicing (voicing settings records) · canon | first-class chord types + Chord -> Chord operators; canon delay semitones p stacks p with an imitated copy |
rhythm | fourFloor, backbeat, offbeat, sixteenths, clave, tresillo · rhythmKit(shift) | pattern literals (all on c2) + a parameterized module re-triggering the same six at any register |
devices | device presets for external gear (minilogue, …) | MIDI-out device table — see Send MIDI to instruments |
mira | 59 factory patches of MIRA, the modulation-first wavetable synth in synthtoys, by category — pad (miraRising, glassChoir, supernova, halo, lighthouse, dayForNight, tideTable, paperChoir) · pluck (droppedMarble, mothWings, wireHarp, cutGlass, kalimba, koto) · bass (tidalBass, eventHorizon, rubberBand, rubberAcid, reese, deepEnd) · lead (copperLead, vowelMachine, brassSection, acidRain, slideRule, theremin, whistler) · keys (sympathetic, reedOrgan, tapeWobble, feltPress, drawbars, funkClav) · texture (threeBodyProblem, aurora, deepField, windUp, cicadas) · sequence (clockwork, pulsar, staircase, morse, gatekeeper) · bell (bellTower, sonar, glassRain, gamelan, musicBox) · perc (kickLab, tinCan, hatTrick, snareWires, talkingDrum, laserTom) · fx (riser, radioDial, siren, weather, powerDown) | each preset is a patch plus <preset>Fx : Track -> Track, its master chain (play droppedMarble p |> droppedMarbleFx). GENERATED by scripts/import-mira.mjs from MIRA's own patch list and signal chain, routes compiled in (LFOs, ORBIT, BOUNCE, step lane, envelopes, velocity, key, randomPerNote). Every knob stays live as on MIRA's panel: mira.<preset>.<key> under MIRA's keys (fCut, e1A, aPos, … — table in the module header), route depths mira.<preset>.depth.<src>.<key> (0.5 = none), steps …step1–step16, named macros mira.<preset>.<name> — 2 206 in all, defaulting to the patch. Module-wide mira.wheel, mira.press, mira.morph (the four two-scene patches). A switched-off block has no knob and glide time is fixed, as without a recompile in MIRA. Synced clocks and delays count cycles/beats, so they follow the song's tempo. Poly presets keep MIRA's 8 voices. Auditioned by the miratour preset. |
electric_guitars | glasscoil, porchlight, hotwire, foundry, mercury, prism, switchblade, ferroglass; electricGuitar with .voice; five signal stages guitarHand, guitarWire, guitarPickup, guitarAmp, guitarCab; three settings records (glasscoilSettings, porchlightSettings, foundrySettings); the factory knobs themselves (leadHeat, leadWah, …) and the prismWireModes / prismGlassModes tables are exported too | Eight native guitar instruments: clean/neck/lead/baritone, bowed, coupled glass, pulsar and tuned nonlinear feedback. Factory instances own five knobs; note parameters supply mute, harmonic and bend. The Pickup Test and five String / Current songs demonstrate them. Recipe, controls and measured acceptance: String Current 2026 09 09. |
valve_guitar | afterburn; valveGuitar with .voice; afterburnSettings, edgeSettings; stringTap, magneticPickup, valveRail, valveSag, valvePreamp, valvePower, closedBackCab | Singing electric guitar: plucked waveguide, spatial pickup coloration, asymmetric tube stages, signal-responsive sag and a filtered cabinet. Five independent knobs and per-note bend, scoop, mute and vibrato; an optional active sustainer drives the string. Behavioral models, not calibrated hardware replicas. The Afterburn test and One Note Past Midnight demonstrate dry stages and selective tape echo. Afterburn 2026 09 09. |
pulsars | vowel mouth, choir mouth, chrome edge, rubber jaw, glass fracture, particles rate | Six portable Pulsar synthesis instruments with live controls and explicit safety ceilings; no sample banks |
bowstrings | violin, viola, cello, bass (legato) and per instrument …Section, …Tremolo, …Tasto, …Ponticello, …Harmonic, …Sordino, …Spiccato, …ColLegno, …Pizz, …Portamento; the deluxe tier violinDeluxe … bassDeluxe and per instrument …DeluxeTutti, …DeluxeSection, …DeluxeTremolo, …DeluxeTasto, …DeluxePonticello, …DeluxeHarmonic, …DeluxeSordino, …DeluxePizz, …DeluxeColLegno, …DeluxeSpiccato; chamber, glassbow, undertow, ironbow; violinRing/violaRing/celloRing/bassRing, openStrings, …Open lists; bowedString and bowedDeluxe with .voice, offString, bowDefaults, the four …Settings and four …DeluxeSettings records and the tremolo/tasto/ponticello/harmonic/portamento/sordino/practiceMute/tutti transforms and seated | Synthesized strings: slurs and alternating bow strokes, a pressure-bite attack, one force-ratio dynamics control (knob, (dyn=…), (cresc=…)), touched harmonics ((touch=…)), articulations, pizzicato through each body, sympathetic open strings; the deluxe tier adds stereo high-detail bodies, stiffness, late humanised vibrato, smooth per-note glides, the left hand's finger noise, a per-note mute ((mute=…)), orchestral seats on the stereo pair and three-player sections. Auditions: bowlight, bowlight-deluxe; Strings, bells and resonating objects § The bowstrings library. |
bowedobjects | musicalSaw, glassHarmonica, wineGlass, bowedVibes, bowedCymbal, bowedBell, singingBowl (bowedModal) · bowedFilter, bowedBank, bowedComb, bowedWire (stickSlip in a feedback loop) · tables sawModes, harmonicaModes; every patch takes bowForce / bowSpeed (0..1, default 0.5) | The string bow on things that are not strings (Strings, bells and resonating objects §1.13): a bent-blade saw whose bend follows the pitch (mono, legato glide, a blooming vibrato), a wet finger on glass, bows on the modal library's bar, plate and bell tables, and bows on resonant loops. Imports modal. |
bowstrings | violin, viola, cello, bass (legato) and per instrument …Section, …Tremolo, …Tasto, …Ponticello, …Harmonic, …Sordino, …Spiccato, …ColLegno, …Pizz, …Portamento; the deluxe tier violinDeluxe … bassDeluxe and per instrument …DeluxeTutti, …DeluxeSection, …DeluxeTremolo, …DeluxeTasto, …DeluxePonticello, …DeluxeHarmonic, …DeluxeSordino, …DeluxePizz, …DeluxeColLegno, …DeluxeSpiccato; chamber, glassbow, undertow, ironbow; violinRing/violaRing/celloRing/bassRing, openStrings, …Open lists; bowedString and bowedDeluxe with .voice, offString, bowDefaults, the four …Settings and four …DeluxeSettings records and the tremolo/tasto/ponticello/harmonic/portamento/sordino/practiceMute/tutti transforms and seated; the pattern transforms ensemble (with ensembleDefaults), phraseArch (phraseArchDefaults), durationContrast and finalRitard (finalRitardDefaults); the hall seats violinStage, secondViolinStage, violaStage, celloStage, bassStage, soloistStage, staged and onStage (for stage / hallTail) | Synthesized strings: slurs and alternating bow strokes, a pressure-bite attack, one force-ratio dynamics control (knob, (dyn=…), (cresc=…)), touched harmonics ((touch=…)), articulations, pizzicato through each body, sympathetic open strings; the deluxe tier adds stereo high-detail bodies, stiffness, late humanised vibrato, smooth per-note glides, the left hand's finger noise, a per-note mute ((mute=…)), orchestral seats on the stereo pair and three-player sections that follow a leader (per-stroke lateness and intonation draws; ensemble the full phase-correction model), with KTH phrasing rules; seats on a hall's stage (onStage). Auditions: bowlight, bowlight-deluxe, hall-seats; Strings, bells and resonating objects § The bowstrings library. |
lantern-score | subject1/subject2, subjectSulG1/subjectSulG2, answer1/answer2, counter1/counter2, inversion1/inversion2; the five fugal voices v1, v2, va, vc, cb (records of per-section bar lists) and their per-bar …Dyn loudness lists; texture layers (haloBars, wallBars, stopsBars, muteBars, pizzBars, subBars, gongBars, choirPat, …); helpers bars, rests, r, dynBars, up, whole | The notes of a 52-bar D-minor fugue, data only (no instruments): each bar a 16-sixteenth !"…" cycle in the bowstrings bowing grammar. Shared by black-lantern-fugue (strings) and black-lantern-circuit (strings and electronics); the header carries the subject, answer and bar map. |
folkstrings | hurdyGurdy (the keyed chanterelle), hurdyDrone (bourdon and mouche), trompette (the buzzing drone: one crank stroke per note, (coup=…) accents), violaDamore, hardanger, erhu, morinKhuur; folkFiddle and hurdyWheel with .voice, folkPath, damoreSettings, hardangerSettings, erhuSettings, morinSettings | Folk bowed strings on bowed: a hurdy-gurdy wheel (crank, tirant, coup knobs) with tangent-stopped chanterelle and a trompette whose dog buzzes on crank accents; the viola d'amore and Hardanger fiddle with ringing sympathetic strings (ring knob); the erhu's wide glides and membrane body; the morin khuur's horsehair. Demo: ashwheel; Strings, bells and resonating objects § The folkstrings library. |
impossiblestrings | morphingFiddle, cellistFiddle, fiddleMorph turn; giantString; electricViolin, electricCello, magneticViolin, electricViolinFx, electricCelloFx; breathingString, glassString, roomCello | Bowed instruments no workshop can build, on bowed's Stage 24 options: a violin whose body morphs into a cello's during a held stroke (bodyTo/bodyMorph), a 20 m string drone sounding three octaves below the written note (scale = "giant", a written A1 is 6.9 Hz), bridge-piezo and magnetic-pickup electrics with drive, chorus and a ping-pong delay chain (pickup), and resized bodies from a toy to a room (bodySize). Audition: the-twenty-metre-string; Strings, bells and resonating objects § The impossible strings. |
worldbank | 61 Kontakt 8 world instruments autosampled into keymapped banks — plucked/struck (sitar, santur, oud, kanun, saz, tanbur, kora, balafon, ngoni, bolon, kalimba, tunedGongs, steelDrums, musicBox, harp, tornadoChimes, steelHandDrum, tumbi; …Soft velocity layers for sitar santur oud kanun kora balafon harp) · winds/bowed (bansuri, ney, persianNey, duduk, shakuhachi, kaval, zurna, shehnai, fulaFlute, kemence) · sustained (tanpura, harmonium, meStrings, meEnsemble, choir, choirMorph, strings, cellos, horns, brass, bowedCymbals, gongScrape) · percussion keyed twins (tablaKeys, dholKeys, darbukaKeys, dafKeys, riqKeys, djembeKeys, dununKeys, taikosKeys, timpaniKeys, …) + the iqa'at bool patterns maqsum/ayyub/malfuf | sample-backed instrument patches (sample "wb…" |> pitched ~C4); the plain hit form is sound "wbtabla:N". Needs the wb* banks in runtime/public/samples/ (recipe + hit tables: World Banks 2026 09 07). Auditioned by the worldtour preset; the live Kontakt twins are pluginPreset "wb <name>". |
vis-materials | ink, phosphor, glass, contour, paper (types InkCfg, PhosphorCfg, GlassCfg, ContourCfg, PaperCfg) | visual materials: image or coverage → image, two or three named controls each, one feedback memory — Visual synthesis § Library. Auditioned by the vis-survey starter |
vis-instruments | glassDrum, inkLine, phosphorScope (types GlassDrumCfg, InkLineCfg, ScopeCfg) | paired audio/visual instruments: a track name and an options record → VisualLayer, drawing that track's accepted notes (vis.emit) or its audio (vis.scan). Auditioned by vis-glass-drum, vis-ink-line, vis-phosphor-scope |
sun_palette · museum_palette · quiet_palette | one album rack each: drums, basses, keys/textures, plus a single character macro (heat / color / warmth) | sample- and circuit-backed instrument racks shared by an album's songs. They load sample banks, so a song that imports one needs those banks present |
dc-sample-vault | the patches and phrases of six original songs (lamplight, lampCall, …) | a source vault with no tracks of its own: companion scores render its patch + phrase into bounceOf buffers and play only those |
intro-tallyman | performance | a finite-ending wrapper over the tallyman song, for the first-signal receiver |
Notable surface facts:
- Instruments may declare live knobs, namespaced by module (Macro Namespacing): the
bassmodule shipsbass.cutoff/bass.resmacros (additive, default 0 — the voice is unchanged until you turn them up). Macro names are the one namespace the resolver qualifies, so two libraries never collide on a knob.drums(drums.punch),keys(keys.bright/keys.space),pads,leads,circuits,modal,mira,machinesand the guitar modules declare knobs the same way (priv … = macro …);fx,pedals,vintage,rhythmandharmonydeclare none. To modulate any other field, stillwith-override at the call site. - Effects come in two families (Voice signal flow §5). Bus effects (reverb / echo) are track-transform lambdas applied with
play … |> hall— they live once on the mixer bus so tails overlap note-to-note (fx, and thepedalsbus row:spaceEcho,spring,slapback). Voice effects (drive / modulation —chorus,phaser,flanger,bitcrush,drive,fold) are signal lambdas applied inside a patch source —source = saw (freq pitch) |> grit; wrap these audio functions inaudioFxto process a track or return persistently. Thepedalsvoice row (grit,warmth,dimension,phase90,flange,crush) covers these. vintageinstruments lean on the voice's ZDF-ladder filter (thecutoff/resonance/filtEnvfields are Moog-style) plus source effects (unisonsupersaw,additivedrawbars,fmoperators, in-voicechorus/drive).- Rhythms trigger on
c2, so a pattern drives any drum patch:play kick fourFloor. They are concrete pattern literals (including euclideanclave = !"c2(3,8)"), not pattern-combinator lambdas. - …and
rhythmKitmoves the whole set to another register.c2is a kick's note; a snare wantsc3and a hatc5, and that single missing specialization is why 49 corpus songs re-type!"c2 ~ ~ ~ …"instead of importing it (Names and library imports §0.2).rhythmtherefore also exportsmodule rhythmKit(shift: Semitones), a Configurable library modules kit parameterized over the trigger register rather than a timbre: one application flattens into all six patterns transposed byshift, reached by qualified access —snares = rhythmKit { shift = 12 }thenplay snare snares.backbeat,play clap snares.backbeat. The register is named once on the application line instead of re-typed into every literal, and the fields are ordinary patterns, sotops.sixteenths |> degradeBy 0.5still works. Pattern pipes, named offsets and reusable transforms now also work:shiftC3 = 12, thenbackbeat |> transpose shiftC3, or a helperup = \p -> p |> transpose 12. UserhythmKitto choose one register for the whole kit; use a transform to vary a particular part. Therhythmlibpreset (examples/songs/rhythmlib.volta) is the worked kit: an eight-track drum arrangement containing no note literal at all. Everything aboverhythmKitinrhythm.voltais byte-frozen — an imported pattern's eventsource_offsetpoints into that file, so inserting a line above the literals re-blesses the golden snapshot of every song that imports them.
The studio preset is the worked tour — it imports drums, bass, keys, fx and rhythm and builds intro/main/lead/outro sections. See examples/songs/studio.volta.
How it's implemented#
- Library source:
examples/songs/— one<module>.voltaper row above (drums.volta,bass.volta, …). They are ordinary corpus files: golden_ir snapshots them,volta fmtchecks them, and a song imports one by bare name because it sits in the same directory. - Which files are "the library":
runtime/public/lib/index.json, a flat JSON array of the module stems above. It is both the browser's boot manifest and the listruntime/scripts/sync-assets.mjscopies out of the corpus intoruntime/public/lib/— so adding a module means editing that one array. The copies themselves are generated and gitignored; edit them and the next sync throws your edit away. - Loading:
runtime/src/modules.ts—ModuleLibraryfetches/lib/index.jsonat boot, then each/lib/<path>.volta, and exposes the set as the bundle passed ascompile's second argument (sources()). Imports resolve against this bundle exactly like any module (Reuse sounds and patterns with imports). - Historical browser adapters (removed 2026-08-10): the old workbench's reference panel line-scanned each loaded module for its header blurb and public (non-
priv) bindings, presenting Standard library and Your modules sections, and cmd/ctrl-click on animport "name"jumped there. Those TypeScript files were deleted with the workbench; see git history. The Rust workbench usesui/src/docsview.rsfor the canonical language reference and compiler-backed editor navigation, and does not ship that module browser. - Compile test:
compiler/src/lower/tests.rs(studio_song_compiles_against_the_standard_library) resolves, checks, and lowersexamples/songs/studio.voltaagainst the library bundle.
What the library can and cannot carry#
The boundary is measured, not argued: a builtin can become a library function only if the library spelling compiles to the same masked IR — same events, payloads, articulation and graph, spans and the source-hashed seed stripped. compiler/tests/library_equivalence.rs is that test, with a row per candidate, and its 2026-09-22 verdict over the candidates Language Foundations P6 named is that one shape carries and four do not.
A pattern constructor carries. A pattern is an ordinary value, so naming one in a module and importing it changes nothing but the source offsets: all six of rhythm.volta's patterns are byte-identical to the literals they replace. That is why the rhythm module never needed a builtin.
Four kinds of builtin cannot move, each for a reason that is about the language and not about the function:
| Kind | Why it cannot move | Example |
|---|---|---|
| its content is a range or domain guarantee | a user function cannot declare the unit or range its result carries | scale [0, 1] turns a −1…1 modulator into a 0–1 knob value; the arithmetic keeps Bipolar, and 141 corpus songs refuse the library spelling outright |
| it shares a subgraph | a user function substitutes its argument instead of binding it, so every mention re-lowers the whole graph (21 nodes become 27) — and an immediately-applied inner lambda is substitution too | scale [400Hz, 400Hz + depth * 3000Hz] with a live depth |
| it reads a value the record view drops | patternData is the only door out of a pattern, it filters out every rest, and an Event has no chord_root/just_cents | a library imitate detunes an adaptive c4:maj7 |
| it orders or overloads | the list algebra has no sort, and one name with two readings has no user-function counterpart | invertVoicing, dropVoicing and arp order a chord by pitch; chop is a pattern transform and a sample modifier |
And even a function that passed every row could only be added, not moved: the compiler reads no .volta source, so no builtin is implemented by a library definition. An import "m" (scale) does take the bare name over for that one file, which is the only shadowing that exists.
Notes & limits#
- Flat namespace. One module per concern — the Reuse sounds and patterns with imports namespace is flat and re-export is not built, so there is no
lib/allaggregate or nestedlib/drums/909. - Live macro control is namespaced. The macro-naming question is settled: the resolver qualifies each library's macro names by module path (
bass.cutoff), so two imported instruments never collide (Macro Namespacing). Which modules are knobbed is listed under Notable surface facts above. - Concrete rhythms only. A
rhythmof lambdas (every, swing shapes) awaits lambda pattern transforms; the shipped set is concrete literals, plus therhythmKitregister parameterization above. - No stdlib versioning. A saved draft that imports a library can break if the library changes — Reuse sounds and patterns with imports punts on versioning and the stdlib is the first place that bites. Planned extensions (more instruments, effects, and rhythms) and the open core-vs-library boundary questions live in The standard library / ideas.md.
The Moving Parts preset demonstrates the mod controls and the same fx.filterMotion helper in a voice, track insert and return; see Modulation recipes.