diff --git a/GODSTRUMENT_MANUAL_SOURCE.md b/GODSTRUMENT_MANUAL_SOURCE.md
index 3dfeca0..71b4ec2 100644
--- a/GODSTRUMENT_MANUAL_SOURCE.md
+++ b/GODSTRUMENT_MANUAL_SOURCE.md
@@ -538,7 +538,7 @@ Learn these seven gestures and the whole planet is under your hands:
- **Press `T` — tracks, for making actual songs.** A conventional tracks-and-clips view for anyone who finds the cathedral overwhelming: every voice is a **track**, eight **bars** run across, and each cell cycles **● live** (the world plays that lane) → **A** → **B** → **C** (clip patterns on the groove grids — A and B come pre-seeded so it makes music immediately) → **silent**. Double-click any clip to edit its groove in the piano roll. Press **▶** and the arrangement loops on the godtime clock — the planet still plays *through* your song, because live lanes stay wired to the world. Arrangements **save with your patch**, play out over MIDI like everything else, and **export .mid** hands you a Standard MIDI File of the note lanes to drag into Ableton, Logic, anything. Not a DAW — a sketchpad where the world sits in on your session. The panel earns its keep like one, too: a **🎛 tracks button** sits bottom-right always; **drag the panel's top edge to resize** (remembered); the top bar **tabs between clips and grooves** — the grooves tab is a full-size pattern editor (pick a track, pick a letter, big piano roll or 16 steps; double-clicking any clip jumps you straight there); and **right-click any track name for that voice's full routing menu** — every cable, every level, patch and unpatch without leaving the panel.
-- **The Groove — one feel for the whole pattern.** The grooves tab carries Ableton's Groove Pool, reduced to the 16-step grid: **swing** lays the off-beats back, **humanize** is a touch of random timing so nothing is machine-stiff, **velocity** lets each hit breathe in loudness, and an **amount** master scales the lot — with one-click presets (*straight, swing 16, MPC 8-4, drunk*). Under the roll sit two expression lanes: **velocity** (how hard each step hits) and **chance** (how likely each step fires at all — drop a step to 40% and it plays four times in ten, so the loop varies itself). The feel and the per-step shaping **save with your patch**. And any lane takes a **⬢ Euclidean fill** — say how many *pulses* to spread across the steps and they distribute themselves as evenly as possible (E(3,8) is the tresillo, E(5,8) the cinquillo, E(4,16) four-on-the-floor), with *steps* and *rotate* to taste: the oldest rhythms of the world fall straight out of the arithmetic.
+- **The Groove — one feel for the whole pattern.** The grooves tab carries Ableton's Groove Pool, reduced to the 16-step grid: **swing** lays the off-beats back, **humanize** is a touch of random timing so nothing is machine-stiff, **velocity** lets each hit breathe in loudness, and an **amount** master scales the lot — with one-click presets (*straight, swing 16, MPC 8-4, drunk*). Under the roll sit three expression lanes: **velocity** (how hard each step hits), **chance** (how likely each step fires at all — drop a step to 40% and it plays four times in ten, so the loop varies itself), and **ratchet** (how many times a step re-fires, 1–4 — an instant roll or 32nd-note glitch from a single step, and if that step is a Play-One stack each sub-hit re-rolls the note). The feel and the per-step shaping **save with your patch**. And any lane takes a **⬢ Euclidean fill** — say how many *pulses* to spread across the steps and they distribute themselves as evenly as possible (E(3,8) is the tresillo, E(5,8) the cinquillo, E(4,16) four-on-the-floor), with *steps* and *rotate* to taste: the oldest rhythms of the world fall straight out of the arithmetic.
- **♪ One scale for the whole planet, and ⬛ Play One for the glitch.** Set a **root and scale** at the top of the grooves tab and every melody you draw is in that key — the piano roll is only ever the scale's own notes, so nothing lands wrong; change the scale and your patterns *re-harmonise* in place. And a column isn't limited to one note: **stack several** and it turns blue — a **Play One** group, from which the sequencer picks a single note at random each time it fires. Stack a handful of in-key notes under a fast Euclidean fill and the line glitches itself into something new on every pass, always in tune. (Adapted from Ableton's *Group Notes → Play One*.)
@@ -976,3 +976,4 @@ Every feed the world sends is one of eight temperaments; the shape dictates how
- **⬢ Euclidean fills** — Live 12's Euclidean generator (§11.3.5): spread N `pulses` as evenly as possible over the pattern, with adjustable `steps` (cycle length) and `rotate`. E(3,8) tresillo, E(5,8) cinquillo, E(4,16) four-on-the-floor — the world's oldest rhythms falling straight out of the arithmetic. Fills any groove or gate lane.
- **♪ Global Scale** — Live 12 Scale Awareness (§3.13): one root + scale (major, dorian, minor pentatonic, hirajoshi, …) that the whole groove editor sings in. The piano roll's rows ARE the scale degrees, so it's always folded-to-scale; change the scale and drawn patterns re-harmonise in place. Travels with the patch.
- **⬛ Play One** — adapted from Ableton's Group Notes → Play One: a piano-roll column can hold several candidate degrees (stack them; they turn blue). On each fire the sequencer picks one at random — stack in-scale notes under a fast Euclidean fill and the line glitches itself, always in key. `.mid` export prints the first candidate.
+- **⚡ Ratchets** — a per-step `ratchet` lane (1–4): each step can re-fire that many sub-hits within its slot, for instant rolls and 32nd-note glitch from a single step. Combined with Play One, every sub-hit re-rolls the note. This completes the generative-glitch loop: Euclidean picks the rhythm, Play One the pitch, ratchets the subdivision.
diff --git a/viz/index.html b/viz/index.html
index 8d47a1b..15dbca4 100644
--- a/viz/index.html
+++ b/viz/index.html
@@ -958,7 +958,7 @@
One Source, many Spirits, one Matter. That is the whole architecture: the Source is the world's data, the same for everyone; the Spirit is the skin — the belief system through which you read it; the Matter is the sound. Choose your spirit, and the same planet plays through it. The shelf so far, each rendered from its own published lore, literally and without frills: the Tree of Life (Hermetic Qabalah, Golden Dawn attributions — ten sephirot on three pillars, all twenty-two canonical paths, Mercury's data at Hod, the Moon's at Yesod, the body of the world at Malkut); the Lodge (from published Masonic sources only — Worshipful Master in the East, Wardens West and South, the North dark, Boaz and Jachin at the porch where your own hands stand as the candidate, the Blazing Star, the Volume of the Sacred Law as humanity's open book, and music given to the South, for Beauty holds the arts); the Hermetic ladder of the seven planetary gates, lead to silver; Yggdrasil and its nine worlds, the dwarves keeping the markets in Nidavellir; the Sufi lata'if, where the wind data literally breathes at Ruh, spirit-as-breath; and the Wu Xing, five phases in their generating ring and controlling star, the metal birds of the air routed to Metal; and the Spread — the Celtic Cross of the tarot (Waite's published layout), dealt live and never finished: the heavens in what crowns you, the deep debts and quake-roots in what is beneath you, the retrogrades in what is behind you, births and seasons in what is before you, money and fire in your hopes and fears — and your own hands in the Querent's place, because you are the one asking. Right-click the sky → skin to turn the wheel of traditions. Each map stands as its true figure — the Tree as a tree, the Lodge as a lodge — and every station opens into mind mode with its own scale under your hands. Newest on the shelf: the wheel — the astrologer's own view, twelve signs in a circle with 0° Aries at the ascendant's place, every feed routed to its sign by traditional rulership (wildfires to Aries, your holdings to Taurus, the word to Gemini, the far-travelling planes to Sagittarius…), the live planets riding the rim, your natal chart on the inner ring, and the aspects drawn as chords across the circle — red the squares and oppositions, green the trines and sextiles, gold the conjunctions, dashed where the living sky strikes your natal points. And everywhere else, those same aspects now draw as faint cables between the planets' own spheres in any skin — the sky's geometry made visible in whatever cosmology you're standing in. And every Spirit now speaks its own tongue: the sephirot in Hebrew (כתר, חכמה, בינה…), the chakras in Devanagari (सहस्रार, अनाहत…), the lata'if in Arabic (قلب, روح, سر…), the nine worlds in Old Norse (ásgarðr, miðgarðr, helheimr…), the planetary gates in their glyphs (☽ ☿ ♀ ☉ ♂ ♃ ♄), the five phases in their characters (木 火 土 金 水). The lore, in the letters it was written in. Two more Spirits joined the shelf: the runes — the Elder Futhark, all twenty-four in the Kylver-stone row, ringed as a rune-band, every feed seated by its rune-poem meaning (wealth's strife at ᚠ fehu, Odin's word at ᚨ ansuz, the giant's blow at ᚦ thurisaz for the quakes, need's narrow band at ᚾ nauthiz for hunger and want, the lot-cup ᛈ perthro holding your natal fate, and your raised hands at ᛉ algiz, the warding rune that is itself a figure with arms lifted); and the Wheel of the Year — the eight Celtic festivals at their true solar longitudes (the astronomical reckoning: quarters at the equinoxes and solstices, cross-quarters at fifteen degrees of the fixed signs), deaths and the deep things at Samhain where the veil thins, births at Imbolc, the fires and the dance and the bond at Beltane, the great fair of commerce and chatter at Lughnasadh — with the live sun walking the rim, showing exactly where the year stands today. Honesty note kept from the scholarship: the unified eightfold wheel is a modern synthesis of the attested Irish fire festivals and older solstice customs — true lore, honestly labeled. And newest of all, the first Spirit with no temple: the artist — Kandinsky's Concerning the Spiritual in Art (1911) taken at its word, his colour-sound table rendered as a wireframe easel. Six pigments squeezed round the palette — gelb the trumpet blown louder and louder (the news, the markets' mania), orange the Angelus bell (the clocks, the hours), rot the drumbeat (your heartbeat, the quakes, the flame), grün the violin's placid middle strings (the weather at rest), blau deepening from flute toward the organ (the whole heavenly circle), violett the bassoon (the retrogrades, Saturn, the sorrows) — with weiß, the great silence pregnant with possibility, waiting as the canvas itself (your unpainted chart lives there, and your own hands hold the brush), and schwarz, the pause after which nothing follows, at the palette's edge with the deaths and the debt. His four great contrasts strung dashed between the drops, and as each colour's data sings, its paint strokes itself up onto the canvas — the world painting, live. Labels in German, the tongue he wrote it in. And beside the easel now hangs the bagua — the I Ching's eight trigrams in the King Wen "Later Heaven" ring, south at the top as the old compasses have it, every feed seated by the Shuogua's own attributions: the earthquakes at ☳ zhèn, the trigram that literally means thunder-shock; the word at ☱ duì, for "Dui is the mouth and tongue"; the moon's data at ☵ kǎn, the sun's at ☲ lí; and your own hands at ☶ gèn, for the Shuogua says plainly: Gen is the hand. And at the centre, the oracle never rests: the two loudest trigrams of the moment stack into a live hexagram — the strongest below as the ground of the moment, the second above — drawn line by line in their own colours and named from all sixty-four by the King Wen table, re-cast as the world's weather shifts. When the planet falls silent it settles at hexagram 11, Peace: heaven below, earth above. The book that reads itself, forever.
The groove grids — sequence the voices. Open any voice's tab (shift-click it) and there's a 16-step grid on the godtime clock. The note voices (lead, bass) get a mini piano roll — eight rows of minor pentatonic, click to place a note, click again to clear — and while your groove is on, your melody replaces the data's: bitcoin lets go of the lead and you take it. Every other voice gets an 808-style gate row that rhythmically chops the world's signal — the reverb, the grit, the percussion breathing in your pattern while the planet still decides how hard. Grooves ride the godtime tempo (lock the dial, or let your heart drive it), and they save with your patch. And the sources get the grid too, with a different power: sample & hold — while a source's groove is on, the world's number is only sampled on your lit steps and held between them, so a smooth drifting feed becomes stepped, rhythmic, quantized in time. Bitcoin arpeggiating in your pattern. The wind as a sequence. If an out port is chosen in ⚙, godtime also sends MIDI clock (24 ppqn), so a DAW can slave its tempo to the planet — or to your pulse. And the grids play outward too: with an out port chosen, piano-roll notes go out as real MIDI on the lead and bass channels (each note one sixteenth long), and the mind-mode console plays on its own third channel — so your grooves and your chakra-scale jams drive Ableton, Strudel, or hardware exactly as they drive the built-in synth. The three mouths drink at once: ♪ for the browser synth, the out port for MIDI, both or neither — there is no switch, only where you point the sound.
Press T — tracks, for making actual songs. A conventional tracks-and-clips view for anyone who finds the cathedral overwhelming: every voice is a track, eight bars run across, and each cell cycles ● live (the world plays that lane) → A → B → C (clip patterns on the groove grids — A and B come pre-seeded so it makes music immediately) → silent. Double-click any clip to edit its groove in the piano roll. Press ▶ and the arrangement loops on the godtime clock — the planet still plays through your song, because live lanes stay wired to the world. Arrangements save with your patch, play out over MIDI like everything else, and export .mid hands you a Standard MIDI File of the note lanes to drag into Ableton, Logic, anything. Not a DAW — a sketchpad where the world sits in on your session. The panel earns its keep like one, too: a 🎛 tracks button sits bottom-right always; drag the panel's top edge to resize (remembered); the top bar tabs between clips and grooves — the grooves tab is a full-size pattern editor (pick a track, pick a letter, big piano roll or 16 steps; double-clicking any clip jumps you straight there); and right-click any track name for that voice's full routing menu — every cable, every level, patch and unpatch without leaving the panel.
-The Groove — one feel for the whole pattern. The grooves tab carries Ableton's Groove Pool, reduced to the 16-step grid: swing lays the off-beats back, humanize is a touch of random timing so nothing is machine-stiff, velocity lets each hit breathe in loudness, and an amount master scales the lot — with one-click presets (straight, swing 16, MPC 8-4, drunk). Under the roll sit two expression lanes: velocity (how hard each step hits) and chance (how likely each step fires at all — drop a step to 40% and it plays four times in ten, so the loop varies itself). The feel and the per-step shaping save with your patch. And any lane takes a ⬢ Euclidean fill — say how many pulses to spread across the steps and they distribute themselves as evenly as possible (E(3,8) is the tresillo, E(5,8) the cinquillo, E(4,16) four-on-the-floor), with steps and rotate to taste: the oldest rhythms of the world fall straight out of the arithmetic.
+The Groove — one feel for the whole pattern. The grooves tab carries Ableton's Groove Pool, reduced to the 16-step grid: swing lays the off-beats back, humanize is a touch of random timing so nothing is machine-stiff, velocity lets each hit breathe in loudness, and an amount master scales the lot — with one-click presets (straight, swing 16, MPC 8-4, drunk). Under the roll sit three expression lanes: velocity (how hard each step hits), chance (how likely each step fires at all — drop a step to 40% and it plays four times in ten, so the loop varies itself), and ratchet (how many times a step re-fires, 1–4 — an instant roll or 32nd-note glitch from a single step, and if that step is a Play-One stack each sub-hit re-rolls the note). The feel and the per-step shaping save with your patch. And any lane takes a ⬢ Euclidean fill — say how many pulses to spread across the steps and they distribute themselves as evenly as possible (E(3,8) is the tresillo, E(5,8) the cinquillo, E(4,16) four-on-the-floor), with steps and rotate to taste: the oldest rhythms of the world fall straight out of the arithmetic.
♪ One scale for the whole planet, and ⬛ Play One for the glitch. Set a root and scale at the top of the grooves tab and every melody you draw is in that key — the piano roll is only ever the scale's own notes, so nothing lands wrong; change the scale and your patterns re-harmonise in place. And a column isn't limited to one note: stack several and it turns blue — a Play One group, from which the sequencer picks a single note at random each time it fires. Stack a handful of in-key notes under a fast Euclidean fill and the line glitches itself into something new on every pass, always in tune. (Adapted from Ableton's Group Notes → Play One.)
⤳ Follow actions — the song composes itself. Give any clip (A/B/C) a follow action in the grooves tab — play again, next, any, any other, stop — with a chance, and once the arrangement is playing that clip can hand off to another at the bar line instead of just repeating. Set two clips to "any other" and they trade the lane back and forth; sprinkle a low-chance divert and the piece drifts. As Ableton's manual puts it, "structures that repeat but can also be surprising… never exactly repeat." A ⤳ marks any clip that can divert. Nothing changes for arrangements without follow actions — they loop exactly as written.
📽 The stage — send the visual to any screen. Right-click the sky → the stage and a clean black mirror window opens, fed live from the canvas. Drag it to a projector, an AirPlay display, a second monitor — macOS treats it like any window — and double-click for fullscreen. The stage has a camera: the whole view by default (whatever you're in — a skin, the wheel, mind mode's POV), or right-click any node → project this node and the camera glides after that one sphere through its orbits, or project its station to frame a whole wheel and its satellites. Change cameras live from the menus while the projector runs; the audience sees the camera breathe from subject to subject.
@@ -1344,6 +1344,7 @@
steps: isNote ? new Array(16).fill(-1) : new Array(16).fill(1),
vel: new Array(16).fill(0.8), // per-step Velocity Editor (§10.5.11)
chance: new Array(16).fill(1), // per-step Chance Editor (§10.5.13)
+ rat: new Array(16).fill(1), // per-step ratchet count (1 = single hit)
});
}
// ---- the arranger — tracks & clips for the casuals -----------------------
@@ -1710,30 +1711,35 @@
arrGrooveRefresh = paintG;
body.appendChild(grid);
- // --- per-step expression: velocity + chance, bound to the voice (§10.5.11-13) ---
+ // --- per-step expression: velocity / chance / ratchet, bound to the voice ---
if (nSel.isNote) {
const sqx = seqFor(arrSelKey, true);
if (!sqx.vel) sqx.vel = new Array(16).fill(0.8);
if (!sqx.chance) sqx.chance = new Array(16).fill(1);
+ if (!sqx.rat) sqx.rat = new Array(16).fill(1);
const em = document.createElement("div"); em.className = "arow emrow";
- for (const mode of ["velocity", "chance"]) {
+ for (const mode of ["velocity", "chance", "ratchet"]) {
const b = document.createElement("button"); b.className = "midibtn"; b.textContent = mode;
b.classList.toggle("on", arrExprMode === mode);
b.onclick = () => { arrExprMode = arrExprMode === mode ? "none" : mode; openArranger(); };
em.appendChild(b);
}
const eh = document.createElement("span"); eh.className = "albl";
- eh.textContent = arrExprMode === "none" ? "velocity / chance — shape how each step hits and how often it fires"
- : arrExprMode === "velocity" ? "drag a bar — how hard each step hits" : "drag a bar — how likely each step fires (100% = always)";
+ eh.textContent = arrExprMode === "none" ? "velocity / chance / ratchet — how hard each step hits, how often, and how many times"
+ : arrExprMode === "velocity" ? "drag a bar — how hard each step hits"
+ : arrExprMode === "chance" ? "drag a bar — how likely each step fires (100% = always)"
+ : "drag a bar — how many times each step re-fires (1–4): instant rolls & 32nd glitch";
em.appendChild(eh);
body.appendChild(em);
if (arrExprMode !== "none") {
- const arrv = arrExprMode === "velocity" ? sqx.vel : sqx.chance;
+ const isRat = arrExprMode === "ratchet";
+ const arrv = isRat ? sqx.rat : (arrExprMode === "velocity" ? sqx.vel : sqx.chance);
const lane = document.createElement("div"); lane.className = "exprlane";
const bars = [];
const paintExpr = () => { for (const b of bars) {
- b.fill.style.height = Math.round(clamp(arrv[b.stp], 0, 1) * 100) + "%";
- b.fill.classList.toggle("lit", steps[b.stp] >= 0);
+ const h = isRat ? (clamp(arrv[b.stp], 1, 4) - 1) / 3 : clamp(arrv[b.stp], 0, 1);
+ b.fill.style.height = Math.round(h * 100) + "%";
+ b.fill.classList.toggle("lit", stepFirst(steps[b.stp]) >= 0);
} };
for (let stp = 0; stp < 16; stp++) {
const cell = document.createElement("div"); cell.className = "exprcell";
@@ -1741,7 +1747,8 @@
const fill = document.createElement("div"); fill.className = "exprbar";
cell.appendChild(fill);
const setY = (cy) => { const r = cell.getBoundingClientRect();
- arrv[stp] = clamp(1 - (cy - r.top) / r.height, 0, 1); paintExpr(); };
+ const frac = clamp(1 - (cy - r.top) / r.height, 0, 1);
+ arrv[stp] = isRat ? (1 + Math.round(frac * 3)) : frac; paintExpr(); };
cell.addEventListener("mousedown", (e0) => { e0.preventDefault(); setY(e0.clientY);
const mv = (e2) => setY(e2.clientY);
const up = () => { window.removeEventListener("mousemove", mv); window.removeEventListener("mouseup", up); };
@@ -2143,17 +2150,25 @@
if (!sq.on) continue;
const n = dests.get(k);
if (n && n.isNote) {
- const deg = stepPick(sq.steps[seqCurStep]); // Play One: pick a random candidate
- if (deg >= 0) {
- const ch = sq.chance ? sq.chance[seqCurStep] : 1; // chance: does this note fire?
- if (ch >= 1 || Math.random() < ch) {
+ const cur = seqCurStep, sv = sq.steps[cur];
+ const hasNote = Array.isArray(sv) ? sv.length > 0 : sv >= 0;
+ const ch = sq.chance ? sq.chance[cur] : 1; // chance: does this step fire?
+ if (hasNote && (ch >= 1 || Math.random() < ch)) {
+ const rat = clamp(Math.round((sq.rat && sq.rat[cur]) || 1), 1, 4); // ratchet: sub-hits per step
+ const sub = (60000 / Math.max(40, godtime.bpm) / 4) / rat; // ms between sub-hits
+ const ch1 = /bass/.test(k) ? 1 : 0;
+ const fireHit = () => {
+ const deg = stepPick(sv); // Play One: re-pick per sub-hit
+ if (deg < 0) return;
const note = seqRootFor(k) + SEQ_ROWS[deg];
- let vel = sq.vel ? sq.vel[seqCurStep] : (/bass/.test(k) ? 0.9 : 0.7);
+ let vel = sq.vel ? sq.vel[cur] : (ch1 ? 0.9 : 0.7);
if (groove.velo) // Velocity Deviation (§10.5.11)
vel = clamp(vel + (Math.random() * 2 - 1) * groove.velo * groove.amount * 0.5, 0.05, 1);
Synth.pluck(note, vel);
- midiPluck(/bass/.test(k) ? 1 : 0, note, vel, 15000 / Math.max(40, godtime.bpm)); // one 16th long
- }
+ midiPluck(ch1, note, vel, sub * 0.9);
+ };
+ fireHit();
+ for (let h = 1; h < rat; h++) setTimeout(fireHit, h * sub);
}
}
}
@@ -2258,7 +2273,8 @@
if (!s || !Array.isArray(s.steps) || s.steps.length !== 16) return null;
return { on: !!s.on, steps: s.steps.slice(),
vel: Array.isArray(s.vel) && s.vel.length === 16 ? s.vel.slice() : new Array(16).fill(0.8),
- chance: Array.isArray(s.chance) && s.chance.length === 16 ? s.chance.slice() : new Array(16).fill(1) };
+ chance: Array.isArray(s.chance) && s.chance.length === 16 ? s.chance.slice() : new Array(16).fill(1),
+ rat: Array.isArray(s.rat) && s.rat.length === 16 ? s.rat.slice() : new Array(16).fill(1) };
}
function gsGrooveSelfCheck() { // ponytail: one runnable guard on the risky bits
const f = [];
@@ -2302,6 +2318,7 @@
stepToggle(ps, 0, 3); if (ps[0] !== 5) f.push("po-unstack"); // remove one → back to plain
if (!stepHas([3, 5], 5) || stepHas([3, 5], 7)) f.push("po-has");
if (stepPick([4]) !== 4 || stepFirst([9, 2]) !== 9) f.push("po-pickfirst");
+ if (migrateSeq({ steps: new Array(16).fill(0) }).rat[0] !== 1) f.push("ratchet-default"); // rat back-fills to 1
if (f.length) console.error("⚠ groove self-check FAILED:", f); else console.log("✓ groove self-check passed");
return f.length === 0;
}