conversations
listlengths
2
6
[ { "role": "user", "content": "What does this SuperCollider patch do?\n```supercollider\n(\nSynthDef(\\Synth3,\n {arg ress = 0;\n var klank, env;\n klank = Klank.ar(`[{Rand(70,21000)}!7, {Rand(0.128,0.700)}!7],BrownNoise.ar(0.7));\n klank = klank;\n env = EnvGen.kr(Env.perc(0.07, ress), doneActi...
[ { "role": "user", "content": "Do you know other programming languages?" }, { "role": "assistant", "content": "Only as far as SuperCollider needs them. I am sc-mind, a 198M model trained on SuperCollider; I can read its sclang syntax and explain it, and that is the limit of what I was trained to ...
[ { "role": "user", "content": "What does this SuperCollider code do?\n```supercollider\n// set() creates a local environment that overrides the outer currentEnvironment\n\nPdefn(\\z).set(\\a, 1, \\b, 5);\n(\nPdefn(\\z, { |e|\n loop { yield((e.a + e.b) + 0.1.rand.round(0.01)) }\n})\n); // [1]\n\nt = Pdefn(\\...
[ { "role": "user", "content": "Write a self-contained SuperCollider patch that uses `Mix`. Define every value it uses." }, { "role": "assistant", "content": "```supercollider\n(\n{\n var n;\n n = 8; // number of 'voices'\n Mix.new( // mix all stereo pairs down.\n Pan2.ar( // pan the voice t...
[ { "role": "user", "content": "Explain this code:\n```supercollider\n{ Pan2.ar(SinOsc.ar(440) * 0.2, SinOsc.kr(0.1)) }.play;\n```" }, { "role": "assistant", "content": "A sine that slowly moves between the speakers.\n\n`SinOsc.kr(0.1)` is a control-rate sine at 0.1 Hz — one cycle every 10 seconds...
[ { "role": "user", "content": "What does this SuperCollider code do?\n```supercollider\n(\n{\n // LFSaw begins at 0, illustrates attack time better\n var sig = LFSaw.ar(440);\n var amps = Amplitude.ar(\n sig,\n attackTime: [0.001, 0.01],\n releaseTime: [0.01, 0.2]\n );\n [sig] ++ amps\n}.plot\n...
[ { "role": "user", "content": "Write a minimal SuperCollider example that uses `WrapIndex`." }, { "role": "assistant", "content": "```supercollider\n// indexing into a table\n(\n{\n var buf = LocalBuf.newFrom([200, 300, 400, 500, 600, 800]);\n var freq = WrapIndex.kr(buf, MouseX.kr(0, BufFrames...
[ { "role": "user", "content": "Show another SuperCollider example using `FBSineL`." }, { "role": "assistant", "content": "```supercollider\n// increase feedback\n{ FBSineL.ar(SampleRate.ir, 1, Line.kr(0.01, 4, 10), 1, 0.1) * 0.2 }.play(s);\n```" } ]
[ { "role": "user", "content": "What does `SynthDesc.controls` do?" }, { "role": "assistant", "content": "Description of a synth definition Returns: an array of instances of ControlName, each of which have the following fields: name, index, rate, defaultValue" } ]
[ { "role": "user", "content": "This SuperCollider code does not compile. What is wrong and what should it be?\n\n```supercollider\ns.boot;\ns.scope;\na = { HilbertFIR.ar(SinOsc.ar(100) * -20.dbamp, LocalBuf(2048) }.play;\na.release;\n```" }, { "role": "assistant", "content": "A closing bracket is...
[ { "role": "user", "content": "What does `ServerOptions.sampleRate` do?" }, { "role": "assistant", "content": "The preferred sample rate. If non-nil the server app will attempt to set the sample rate of the hardware. The hardware has to support the sample rate that you" } ]
[ { "role": "user", "content": "Give me an Ndef with an LFO at 0.3 Hz. (ugens blip, cutoff 2400, lfo 0.3, freq 220, amp 0.12)" }, { "role": "assistant", "content": "`Ndef` holds the synth and the environment, so you can edit it live:\n\n```supercollider\n// Ndef drone: blip source through a 2400 H...
[ { "role": "user", "content": "What is `Mix` in SuperCollider?" }, { "role": "assistant", "content": "Mix — Sum an array of channels. Mix will mix an array of channels down to a single channel or an array of arrays of channels down to a single array of channels. More information can be found unde...
[ { "role": "user", "content": "Explain this code:\n```supercollider\nRoutine({ loop { Synth(\\kick); 0.5.wait } }).play;\n```" }, { "role": "assistant", "content": "It starts a kick every half second, forever.\n\nA Routine is a language-side coroutine: `.play` runs it on the clock, and `wait` sus...
[ { "role": "user", "content": "Write a SuperCollider patch for Very quick-and-dirty hack to show stereo phase. Start by defining the values the patch depends on." }, { "role": "assistant", "content": "```supercollider\n(\nb = Bus.audio(s, 2);\na = { |inbus = 0|\n var sig = In.ar(inbus, 2);\n //...
[ { "role": "user", "content": "Write a minimal SuperCollider example that uses `Dshuf`." }, { "role": "assistant", "content": "```supercollider\n(\n{\n var a, freq, trig;\n a = Dseq([Dshuf([1, 3, 2, 7, 8.5], 3)], inf);\n trig = Impulse.kr(MouseX.kr(1, 40, 1));\n freq = Demand.kr(trig, 0, a) *...
[ { "role": "user", "content": "How do I play a random majorPentatonic scale at octave 5? (scale majorPentatonic, seq Prand, dur 0.4, octave 5, instr fm, root 0)" }, { "role": "assistant", "content": "Put the scale and the degree pattern in the `Pbind` and it will pick notes for you:\n\n```superco...
[ { "role": "user", "content": "Explain this code:\n```supercollider\nPbind(\\degree, Pseq([0, 2, 4, 7], inf), \\dur, 0.25).play;\n```" }, { "role": "assistant", "content": "It plays a four-note major arpeggio in a loop, one note every 250 ms.\n\n`Pbind` builds an event stream: each event is the c...
[ { "role": "user", "content": "This SuperCollider code does not compile. What is wrong and what should it be?\n\n```supercollider\n// using timer to modulate sine frequency: the slower the trigger is the higher the frequency\n(\n{ var trig;\n trig = Impulse.kr(MouseX.kr(0.5, 20, 1));\n SinOsc.ar(Timer.kr(t...
[ { "role": "user", "content": "Write a minimal SuperCollider example that uses `Resonz`." }, { "role": "assistant", "content": "```supercollider\n{ Resonz.ar(WhiteNoise.ar(0.5), 2000, 0.1) }.play\n\n// modulate frequency\n{ Resonz.ar(WhiteNoise.ar(0.5), XLine.kr(1000, 8000, 10), 0.05) }.play\n\n/...
[ { "role": "user", "content": "Write a minimal SuperCollider example that uses `LinCongN`." }, { "role": "assistant", "content": "```supercollider\n// default initial params\n{ LinCongN.ar(MouseX.kr(20, SampleRate.ir)) * 0.2 }.play(s);\n```" } ]
[ { "role": "user", "content": "What is `EaseOutCubic` in SuperCollider?" }, { "role": "assistant", "content": "EaseOutCubic — Cubic ease-out Easing equation for a cubic (t^3) ease-out, decelerating to zero velocity. Category: Ease." } ]
[ { "role": "user", "content": "What does this SuperCollider patch do?\n```supercollider\n~x.play;\n\n~x = { var alpha,beta; alpha = rrand(99,399); beta = alpha = rrand(99,399);Pan2.ar(LeakDC.ar(Normalizer.ar(BPeakEQ.ar(BPeakEQ.ar(BPeakEQ.ar(BPeakEQ.ar(\nFreeVerb.ar(Formant.ar(TRand.kr(alpha,alpha+(rrand(5,20...
[ { "role": "user", "content": "Write a self-contained SuperCollider patch that uses `NodeControl`. Define every value it uses." }, { "role": "assistant", "content": "```supercollider\nd = SynthDef(\"help-NodeControl\", { |out = 0, freq = 400|\n Out.ar(out,\n SinOsc.ar(freq, 0, 0.5)\n )\n});...
[ { "role": "user", "content": "Write a complete SuperCollider patch built around `Pan2` that runs as it is." }, { "role": "assistant", "content": "```supercollider\n(\ns.bind {\n SynthDef(\"tpulse2\", { arg out=0, freq=700, sawFreq=440.0;\n Out.ar(out, Pan2.ar(SyncSaw.ar(freq, sawFreq, 0.1),...
[ { "role": "user", "content": "How do I structure a live-coding performance in one file?" }, { "role": "assistant", "content": "One Tdef per musical layer, each with its own loop, so you can start and stop layers while the set\nruns.\n\n```supercollider\n(\nTdef(\\kick, {\n loop {\n Syn...
[ { "role": "user", "content": "This SuperCollider code does not compile. What is wrong and what should it be?\n\n```supercollider\n// logistic map\n// equation: x1 = -r*x0^2 + r*x0\n(\n{ var r;\n r = MouseX.kr(3.5441, 4); // stable range\n QuadL.ar(SampleRate.ir/4, r.neg, r, 0, 0.1) * 0.4;\n}.play(s);\n``...
[ { "role": "user", "content": "What does this SuperCollider code do?\n```supercollider\n(\n// Dust randomly triggers Decay to create an exponential\n// decay envelope for the WhiteNoise input source\n{\nz = Decay.ar(Dust.ar(1, 0.5), 0.3, WhiteNoise.ar);\nDelayN.ar(z, 0.2, 0.2, 1, z); // input is mixed with d...
[ { "role": "user", "content": "Write a minimal SuperCollider example that uses `Dswitch`." }, { "role": "assistant", "content": "```supercollider\n(\n {\n var d, trig;\n d = Dswitch([\n Dwhite(3, 4, 2),\n Dwhite(0, 1, 2),\n Dseq([1, 1, 1, 0], 2)\n ], Dseq([0, 1, 2, 1, 0],...
[ { "role": "user", "content": "Write a self-contained SuperCollider patch that uses `MouseX`. Define every value it uses." }, { "role": "assistant", "content": "```supercollider\n(\nb = Bus.control(s, 9); // nine channel control rate\nb.setn([244, 737, 20, 271, 382, 172, 4, 2399, 251]);\n{\n var...
[ { "role": "user", "content": "What is rq in BPF.ar?" }, { "role": "assistant", "content": "rq is the reciprocal of Q, so it is a bandwidth control, not a Q control. Small rq means a narrow, resonant band; large rq means a wide, gentle one. The signature is `BPF.ar(in, freq, rq, mul, add)`. A com...
[ { "role": "user", "content": "What happens when I call .play on a function?" }, { "role": "assistant", "content": "`.play` on a Function builds a SynthDef from the function body, adds it to the server under an anonymous name, and starts one Synth of it. You get back the Synth, so `x = { SinOsc.a...
[ { "role": "user", "content": "What does this SuperCollider code do?\n```supercollider\n// Find/make a dataset of points:\nx = 15.collect{[1.0.rand, 1.0.rand]};\n// Append the index onto the end, for later reference\nx = x.collect{|data, i| data ++ i };\n// Use the KDTree quark and the .makeBufferData method...
[ { "role": "user", "content": "Why does every UGen have mul and add arguments?" }, { "role": "assistant", "content": "They are a convenience applied to the UGen's output: the result is `ugens_result * mul + add`. So `SinOsc.ar(440, 0, 0.2)` is the same as `SinOsc.ar(440) * 0.2`, and `SinOsc.ar(44...
[ { "role": "user", "content": "Write a SuperCollider patch for We all could use a little more that runs as it is, with nothing assumed about the session." }, { "role": "assistant", "content": "```supercollider\n(\nSynthDef(\\cowbell, {\n | out=0, amp=0.3, gate=1, fund_freq=540, pan=0.0 |\n ...
[ { "role": "user", "content": "What does `EZNumber.action` do? What arguments does it take?" }, { "role": "assistant", "content": "A function to be evaluated when the value changes. Te first argument will be the Arguments: arg1 — An instance of Function or FunctionList. Default value is nil.." ...
[ { "role": "user", "content": "This SuperCollider code does not compile. What is wrong and what should it be?\n\n```supercollider\ns.boot;\n(\nb = Buffer.alloc(s, 512, 1);\nb.sine1(1.0 / [1, 2, 3, 4], true, true, true);\nx = { Osc.ar(b, 200, 0, 0.5) }.play;\n;\nx.free; b.free;\n```" }, { "role": "ass...
[ { "role": "user", "content": "Show another SuperCollider example using `StandardN`." }, { "role": "assistant", "content": "```supercollider\n// mouse-controlled param\n{ StandardN.ar(SampleRate.ir/2, MouseX.kr(0.9, 4)) * 0.3 }.play(s);\n```" } ]
[ { "role": "user", "content": "What does `TIRand.ar` do? What arguments does it take?" }, { "role": "assistant", "content": "Triggered integer random number generator. Arguments: lo — Lower limit of the output range.; hi — Upper limit of the output range.; trig — The trigger. Trigger can be any s...
[ { "role": "user", "content": "What is `Bus`?" }, { "role": "assistant", "content": "Bus — Representation of a bus on the server" }, { "role": "user", "content": "What does `Bus.control` do?" }, { "role": "assistant", "content": "Allocate a control bus on the server." },...
[ { "role": "user", "content": "Write a minimal SuperCollider example that uses `MouseY`." }, { "role": "assistant", "content": "```supercollider\n{ SinOsc.ar(MouseY.kr(40, 10000, 1), 0, 0.1) }.play;\n```" } ]
[ { "role": "user", "content": "Write a minimal SuperCollider example that uses `PV_Mul`." }, { "role": "assistant", "content": "```supercollider\ns.boot;\n\n(\nSynthDef(\"help-mul\", { |out = 0|\n var inA, chainA, inB, chainB, chain ;\n inA = SinOsc.ar(500, 0, 0.5);\n inB = SinOsc.ar(Line.kr(...
[ { "role": "user", "content": "What does `RedParticle.age` do?" }, { "role": "assistant", "content": "Scalar that decrease by 1 for every update. The default is" } ]
[ { "role": "user", "content": "Explain `PLatoocarfianN` in SuperCollider briefly." }, { "role": "assistant", "content": "PLatoocarfianN — UGenPatterns quark library Latoocarfian. Category: Streams-Patterns-Events > UGenPatterns > Generators." } ]
[ { "role": "user", "content": "Show another SuperCollider example using `LinCongL`." }, { "role": "assistant", "content": "```supercollider\n// randomly modulate params\n(\n{ LinCongL.ar(\n LFNoise2.kr(1, 1e4, 1e4),\n LFNoise2.kr(0.1, 0.5, 1.4),\n LFNoise2.kr(0.1, 0.1, 0.1),\n LFNoise2.kr(0.1...
[ { "role": "user", "content": "Give me a Pbind with pluck voices and a 0.2 rhythm. (scale minorPentatonic, seq Pwalk, dur 0.2, octave 4, instr pluck, root 0)" }, { "role": "assistant", "content": "Put the scale and the degree pattern in the `Pbind` and it will pick notes for you:\n\n```supercolli...
[ { "role": "user", "content": "Write a minimal SuperCollider example that uses `BufSamples`." }, { "role": "assistant", "content": "```supercollider\n// example; this buffer is mono, so the number of samples matches the number of frames\nb = Buffer.read(s, ExampleFiles.child);\n\n// indexing with...
[ { "role": "user", "content": "Write a self-contained SuperCollider patch that uses `Mix`. Define every value it uses." }, { "role": "assistant", "content": "```supercollider\n(\n{\n var n;\n n = 8; // number of 'voices'\n Mix.new( // mix all stereo pairs down.\n Pan2.ar( // pan the voice t...
[ { "role": "user", "content": "Write a complete SuperCollider patch built around `SyncSaw` that runs as it is." }, { "role": "assistant", "content": "```supercollider\ns.boot;\n(\n// send a synth def to server\nSynthDef(\"tpulse\", { arg out=0,freq=700,sawFreq=440.0;\n Out.ar(out, SyncSaw.ar(fre...
[ { "role": "user", "content": "What does this SuperCollider patch do?\n```supercollider\n(\n{\nvar trigger, fund, flashInst;\nflashInst = Array.fill(7,\n{\ntrigger = Dust.kr(2)*PinkNoise.ar(1);\nfund = rrand(100, 137);\nPan2.ar(\nMix.ar(\nArray.fill(7,\n{arg counter;\nvar partial;\npartial = counter + 3;\n//...
[ { "role": "user", "content": "This SuperCollider code does not compile. What is wrong and what should it be?\n\n```supercollider\n// Compare:\n\n{ WhiteNoise.ar(0.25) }.play;\n\n{ HPZ1.ar(WhiteNoise.ar(0.25)) }.play;\n\n// HPZ1 is useful to detect changes in a signal:\n// see also HPZ2\n(\n{\n var changing...
[ { "role": "user", "content": "This SuperCollider code does not compile. What is wrong and what should it be?\n\n```supercollider\na = { |x| #[440, 720, 801, 1020.2].at(x) }; b = a.cpsmidi; [a.value(3), b.value(3)];\na = Pseries(220, 220, inf).cpsmidi; a.asStream.nextN(12); // overtone series as midinotes\n/...
[ { "role": "user", "content": "Write a minimal SuperCollider example that uses `Trig`." }, { "role": "assistant", "content": "```supercollider\n{ Trig.ar(Dust.ar(1), 0.2) * FSinOsc.ar(800, 0.5) }.play\n\n{ Trig.ar(Dust.ar(4), 0.1) }.play\n```" } ]
[ { "role": "user", "content": "Give me a Pbind with fm voices and a 0.4 rhythm. (scale minorPentatonic, seq Pshuf, dur 0.4, octave 4, instr fm, root 0)" }, { "role": "assistant", "content": "`Pbind` sequences an Event per beat, and `\\degree` + `\\scale` does the pitch:\n\n```supercollider\n(\nSy...
[ { "role": "user", "content": "Write a kick drum with a 0.25 s decay. (osc sine, sweep 0.06, decay 0.25, f0 180, f1 40, amp 0.6, rev 1)" }, { "role": "assistant", "content": "Start with a swept sine, then shorten the decay to taste:\n\n```supercollider\n// kick drum: sine oscillator, 0.06 s pitch...
[ { "role": "user", "content": "Write an Ndef at 110 Hz I can retune while it plays. (ugens sine, cutoff 3200, lfo 0.3, freq 110, amp 0.12)" }, { "role": "assistant", "content": "`Ndef` holds the synth and the environment, so you can edit it live:\n\n```supercollider\n// Ndef drone: sine source th...
[ { "role": "user", "content": "This SuperCollider code does not compile. What is wrong and what should it be?\n\n```supercollider\n{ XFade2.ar(Saw.ar, SinOsc.ar, LFTri.kr(0.1) }.play\n```" }, { "role": "assistant", "content": "A closing bracket is missing: the parenthesis opened earlier is never ...
[ { "role": "user", "content": "Write a GrainBuf synth at 16 grains per second. (rate 16, dur 0.2, interp 2, mode noise1, rev 1)" }, { "role": "assistant", "content": "A working granular patch, with the buffer loaded before the synth starts:\n\n```supercollider\n// granular synth with GrainBuf\n(\...
[ { "role": "user", "content": "What does this SuperCollider patch do?\n```supercollider\n(\n{\n~a={SinOsc.ar([22.5, 23], mul: ChaosGen.allSubclasses.choose.ar(rrand(1, 30))* 0.3)};\n~b={SinOsc.ar([22.5, 23], mul: 0.3)};\n~c={SinOsc.ar([22.5, 23]*400, mul: ChaosGen.allSubclasses.choose.ar(rrand(1, 30))* 0.03)...
[ { "role": "user", "content": "Write a Pbind whose degrees repeat every Pwalk cycle. (scale majorPentatonic, seq Pwalk, dur 0.4, octave 6, instr fm, root 0)" }, { "role": "assistant", "content": "`Pbind` sequences an Event per beat, and `\\degree` + `\\scale` does the pitch:\n\n```supercollider\n...
[ { "role": "user", "content": "What does `Object.!?` do?" }, { "role": "assistant", "content": "If the receiver is not nil, evaluate the Function passing in the receiver as argument and return the result, otherwise return" } ]
[ { "role": "user", "content": "Explain `LinuxPlatform` in SuperCollider briefly." }, { "role": "assistant", "content": "LinuxPlatform — Linux platform-specific methods This class is available only on Linux, and implements Linux platform-specific methods. Category: Platform." } ]
[ { "role": "user", "content": "How do I build a live drone with Ndef at 165 Hz? (ugens sine, cutoff 2400, lfo 0.3, freq 165, amp 0.12)" }, { "role": "assistant", "content": "`Ndef` is a named proxy you can redefine while it is playing:\n\n```supercollider\n// Ndef drone: sine source through a 240...
[ { "role": "user", "content": "Write a minimal SuperCollider example that uses `QuadC`." }, { "role": "assistant", "content": "```supercollider\n// default params\n{ QuadC.ar(SampleRate.ir/4) * 0.2 }.play(s);\n```" } ]
[ { "role": "user", "content": "This SuperCollider code does not compile. What is wrong and what should it be?\n\n```supercollider\nNdef(\\lfo2, { LFNoise1.kr(LFNoise1.kr(0.1).exprange(1, 300) ! 2, 400, 800) });\nNdef(\\sound, { Blip.ar(Ndef.kr(\\lfo2), 30) * 0.2 }).play;\n\nNdef(\\lfo2, { [MouseX.kr(10, 300,...
[ { "role": "user", "content": "Write a self-contained SuperCollider patch that uses `LeastChange`. Define every value it uses." }, { "role": "assistant", "content": "```supercollider\n(\nd = { |amp = 1.0|\n var in1, in2;\n in1 = LFNoise0.ar(800, amp);\n in2 = SinOsc.ar(800);\n LeastChange.ar(...
[ { "role": "user", "content": "Write a complete SuperCollider patch built around `BufWr` that runs as it is." }, { "role": "assistant", "content": "```supercollider\n(\n// allocate a buffer for writinig into\ns = Server.local;\ns.sendMsg(\"/b_alloc\", 0, 44100 * 2);\n);\n\n\n// write into the buf...
[ { "role": "user", "content": "Write a kick drum with a 0.5 s decay. (osc sine, sweep 0.06, decay 0.5, f0 180, f1 48, amp 0.8, rev 1)" }, { "role": "assistant", "content": "The pitch envelope is what makes it read as a drum, not the oscillator:\n\n```supercollider\n// kick drum: sine oscillator, ...
[ { "role": "user", "content": "Write a minimal SuperCollider example that uses `MulAdd`." }, { "role": "assistant", "content": "```supercollider\ns.boot;\n\n// The mul and add arguments of SinOsc themselves use MulAdd!\n// These two examples will create precisely the same synth graph:\nx = { SinO...
[ { "role": "user", "content": "Write a minimal SuperCollider example that uses `BRF`." }, { "role": "assistant", "content": "```supercollider\n{ BRF.ar(Saw.ar(200, 0.1), FSinOsc.kr(XLine.kr(0.7, 300, 20), 0, 3800, 4000), 0.3) }.play;\n\n{ BRF.ar(Saw.ar(200, 0.5), MouseX.kr(100, 10000, 1), 0.3) }....
[ { "role": "user", "content": "How do I build a live drone with Ndef at 82.5 Hz? (ugens blip, cutoff 200, lfo 0.8, freq 82.5, amp 0.12)" }, { "role": "assistant", "content": "`Ndef` is a named proxy you can redefine while it is playing:\n\n```supercollider\n// Ndef drone: blip source through a 20...
[ { "role": "user", "content": "Explain `PHSpar` in SuperCollider briefly." }, { "role": "assistant", "content": "PHSpar — defines Pbind(s) for using synth values of a HSpar Defines Pbind(s) which, when played, can use values of synths derived from HSpar's synth definitions. Category: Libraries > ...
[ { "role": "user", "content": "Write a self-contained SuperCollider patch that uses `WrapIndex`. Define every value it uses." }, { "role": "assistant", "content": "```supercollider\n// indexing into a table\n(\n{\n var buf = LocalBuf.newFrom([200, 300, 400, 500, 600, 800]);\n var freq = WrapInd...
[ { "role": "user", "content": "Write a SuperCollider patch that uses `ExpRand` and actually plays. Assume nothing about the session." }, { "role": "assistant", "content": "```supercollider\n(\nSynthDef(\"help-ExpRand\", { |out = 0|\n Out.ar(out,\n FSinOsc.ar(\n ExpRand(100.0, 8000.0),\n ...
[ { "role": "user", "content": "Write a minimal SuperCollider example that uses `BufRateScale`." }, { "role": "assistant", "content": "```supercollider\nb = Buffer.read(s, ExampleFiles.child);\n\n(\nx = { |rate = 1|\n BufRd.ar(1, b, Phasor.ar(0, BufRateScale.kr(b) * rate, 0, BufFrames.kr(b)))\n}....
[ { "role": "user", "content": "Explain this SuperCollider patch.\n```supercollider\n// for the members of the cult of q\n// who don't want to ~tilde\n\n\n//-- INIT\nq = q ? ();\n\nq.local = currentEnvironment;\n\nq.local.pattern = Pbind(\\note, Pbrown(0, { 17.rand + 1 } ! 12), \\dur, 0.05, \\amp, 0.01);\n\n\...
[ { "role": "user", "content": "What is `MIDIFuncChanArrayMessageMatcher` in SuperCollider?" }, { "role": "assistant", "content": "MIDIFuncChanArrayMessageMatcher — Matches incoming MIDI messages to responder funcs based on message channel This is used by MIDIMessageDispatcher to match incoming MI...
[ { "role": "user", "content": "What is `ProxySynthDef`?" }, { "role": "assistant", "content": "ProxySynthDef — synth def that wraps ugen graph" }, { "role": "user", "content": "What does `ProxySynthDef.sampleAccurate` do?" }, { "role": "assistant", "content": "always use O...
[ { "role": "user", "content": "What does `SequenceableCollection.unixCmd` do? What arguments does it take?" }, { "role": "assistant", "content": "Executes a system command asynchronously. This object should be an array of strings where the first string is the path to the executable to be run and ...
[ { "role": "user", "content": "This SuperCollider code does not compile. What is wrong and what should it be?\n\n```supercollider\n//code that utilizes the glitch.\n//warning! extremely loud.\n//note: might not sound the same on all soundcards\n(\n{GlitchRHPF.ar(\n BrownNoise.ar(1.dup),\n 0.5,\n Saw.kr(1...
[ { "role": "user", "content": "Write a kick drum with a 0.18 s decay. (osc sine, sweep 0.06, decay 0.18, f0 220, f1 40, amp 0.8, rev 0)" }, { "role": "assistant", "content": "Start with a swept sine, then shorten the decay to taste:\n\n```supercollider\n// kick drum: sine oscillator, 0.06 s pitch...
[ { "role": "user", "content": "What is `PV_ChainUGen`?" }, { "role": "assistant", "content": "PV_ChainUGen — Base class for UGens that operate on FFT chains" }, { "role": "user", "content": "What does `PV_ChainUGen.fftSize` do?" }, { "role": "assistant", "content": "Return...
[ { "role": "user", "content": "What does this SuperCollider code do?\n```supercollider\n(\n// Dust randomly triggers Decay to create an exponential\n// decay envelope for the WhiteNoise input source\n{\nz = Decay.ar(Dust.ar(1, 0.5), 0.3, WhiteNoise.ar);\nDelayN.ar(z, 0.2, 0.2, 1, z); // input is mixed with d...
[ { "role": "user", "content": "What can you do?" }, { "role": "assistant", "content": "Write and explain SuperCollider: SynthDefs, UGens, Patterns, Ndef, buses and envelopes, and tell you why a patch is silent or will not compile. I am 198M parameters, so I am narrow on purpose." } ]
[ { "role": "user", "content": "Explain `Pwalk` in SuperCollider briefly." }, { "role": "assistant", "content": "Pwalk — A one-dimensional random walk over a list of values that are embedded Category: Streams-Patterns-Events > Patterns > List." } ]
[ { "role": "user", "content": "Write a minimal SuperCollider example that uses `Pause`." }, { "role": "assistant", "content": "```supercollider\ns.boot;\n\nSynthDef(\\a, { Out.ar(0, SinOsc.ar(800, 0, 0.2)) }).add;\n\nSynthDef(\\b, { |gate = 1| Out.ar(1, PinkNoise.ar(0.3)); Pause.kr(gate, 1001) })...
[ { "role": "user", "content": "What does `DigitalIn.ar` do? What arguments does it take?" }, { "role": "assistant", "content": "Read data from a digital input Arguments: digitalPin — Digital pin number to read. Pin numbers begin at 0. This value cannot be modulated.; mul; add." } ]
[ { "role": "user", "content": "What is a UGen?" }, { "role": "assistant", "content": "A UGen is a unit generator: the primitive signal-processing node of the server. SinOsc, Saw, WhiteNoise, LPF and EnvGen are UGens, and they are wired into a graph inside a SynthDef." } ]
[ { "role": "user", "content": "Explain `Process` in SuperCollider briefly." }, { "role": "assistant", "content": "Process — Runtime environment for the virtual machine and interpreter. A Process is the runtime environment for the virtual machine and interpreter. It has a subclass named Main which...
[ { "role": "user", "content": "Write a Pbind in minorPentatonic using Pwalk for the degrees. (scale minorPentatonic, seq Pwalk, dur 0.25, octave 6, instr pluck, root 0)" }, { "role": "assistant", "content": "Put the scale and the degree pattern in the `Pbind` and it will pick notes for you:\n\n``...
[ { "role": "user", "content": "This SuperCollider code does not compile. What is wrong and what should it be?\n\n```supercollider\nb = Buffer.read(s, ExampleFiles.child);\n\n(\nx = { |rate = 1|\n BufRd.ar(1, b, Phasor.ar(0, BufRateScale.kr(b) * rate, 0, BufFrames.kr(b)))\n}.play;\n```" }, { "role": ...
[ { "role": "user", "content": "What is `VarGui`?" }, { "role": "assistant", "content": "VarGui — slider / player gui to set envir variables and synth controllers and play synths, event patterns and tasks" }, { "role": "user", "content": "What does `VarGui.new` do?" }, { "role"...
[ { "role": "user", "content": "Explain `OSCMessageDispatcher` in SuperCollider briefly." }, { "role": "assistant", "content": "OSCMessageDispatcher — The default dispatcher class for OSCFunc and OSCdef. OSCMessageDispatcher dispatches incoming OSC messages to matching functions. Normally users sh...
[ { "role": "user", "content": "Write a Pbind in minorPentatonic using Pwalk for the degrees. (scale minorPentatonic, seq Pwalk, dur 0.4, octave 6, instr pluck, root 0)" }, { "role": "assistant", "content": "`Pbind` sequences an Event per beat, and `\\degree` + `\\scale` does the pitch:\n\n```supe...
[ { "role": "user", "content": "Write a minimal SuperCollider example that uses `PV_MagSquared`." }, { "role": "assistant", "content": "```supercollider\ns.boot;\n\n(\nb = Buffer.alloc(s, 2048, 1);\nc = Buffer.read(s, ExampleFiles.child);\n);\n\n(\nSynthDef(\"help-magSquared\", { |out = 0, bufnum ...
[ { "role": "user", "content": "What does `AbstractSInstrument.arguments` do?" }, { "role": "assistant", "content": "a dictionary keeping track of the latest set" } ]
[ { "role": "user", "content": "Write a kick drum with a 0.5 s decay. (osc saw, sweep 0.06, decay 0.5, f0 150, f1 48, amp 0.8, rev 1)" }, { "role": "assistant", "content": "A kick is a sine with a fast pitch drop and a short amplitude envelope:\n\n```supercollider\n// kick drum: saw oscillator, 0....
[ { "role": "user", "content": "Show another SuperCollider example using `RunningSum`." }, { "role": "assistant", "content": "```supercollider\n// RMS Power\n(\n{\n var input, numsamp;\n\n input = LFSaw.ar;\n numsamp = 30;\n\n (RunningSum.ar(input.squared, numsamp) / numsamp).sqrt\n}.p...
[ { "role": "user", "content": "Resizing FreqScope?" }, { "role": "assistant", "content": "SuperCollider forum — Resizing FreqScope?\n\nOddly, this seems to work:\n\n```supercollider\n// max partial = 20 kHz\n// do not play this loudly\na = { Blip.ar(100, 200, 0.02).dup }.play;\n\nv = FreqScope(80...
[ { "role": "user", "content": "This SuperCollider code does not compile. What is wrong and what should it be?\n\n```supercollider\n{ Latoocarfian2DN.ar(MouseX.kr(20, SampleRate.ir * 0.5), MouseX.kr(40, SampleRate.ir), mul:0.2) }.play(s);\n\n\n(\n{ Latoocarfian2DN.ar(\n SampleRate.ir/4,\n SampleRate.ir,\n ...