Make a module for DeepSynth Rack
Write a module in Rust with the DeepSynth Rack module kit, check it and hear it on your own computer, then send it to us. Once it passes our review, we add it to DeepSynth Rack, where anyone can find it in Add Module. Selling modules isn’t open yet.
Version 0.1.1, a zip of the Rust source, MIT licensed. Nothing you send runs on deepsynth.ai or in anyone’s rack until we’ve reviewed it and built it into a release.
What a module is
A module is one panel in the rack. It has:
- Inputs: jacks that take a cable in.
- Outputs: jacks that send a signal out.
- Params: knobs, switches and buttons. Each one has a range and a default.
- Lights that show what the module is doing.
- A panel that lays these out. A standard panel is 380 px tall, and its width is counted in HP: one HP is 15 px.
Signals are voltages, as on a hardware modular. Audio swings about ±5 V, pitch is 1 V per octave, and gates and triggers jump to 10 V. The kit runs a module on one channel; polyphony comes in a later version.
A module is three things in one folder: the DSP in Rust, a descriptor that names every jack, param and light, and a panel that places them. The kit checks that the three agree, runs the DSP through hard cases, writes what it sounds like to a WAV file and draws the panel.
1. Install Rust
Follow the steps at rust-lang.org/tools/install, then open a new terminal and check that cargo --version prints a version. The kit is tested with Rust 1.96.
2. Try the example
Unzip the kit and run the Gain example: its tests, the check, a sound file and a picture of its panel.
cd deepsynth-module-kit/modules/gain
cargo test
cargo run -- check
cargo run -- render --out gain.wav
cargo run -- panel --out panel.svgThe first run downloads the kit’s one dependency, which reads the JSON files, and builds everything. Open gain.wav in any audio player and panel.svg in a browser.
3. Start your module
cd deepsynth-module-kit
cp -R template modules/wave-folder
cd modules/wave-folderIn Cargo.toml, change name = "my-module" to your module’s name. Put your name in the copyright line of each source file and in LICENSE. Every place to fill in is marked TODO.
4. Write the DSP
A struct keeps the module’s state. new runs once, when the module is added; process runs once per sample. This is the kit’s Gain, a gain module with one knob, a CV input and a light:
// Copyright (c) 2026 Zero Coding Startup LLC. Licensed under the MIT License.
//! Gain: scales a signal by a knob, with an optional CV.
//!
//! Inputs: 0 IN (audio), 1 CV (0 to 10 V scales the knob)
//! Outputs: 0 OUT
//! Params: 0 GAIN (0 to 2, default 1)
//! Lights: 0 LEVEL (0 to 1)
#[derive(Debug, Clone)]
pub struct Gain {
level: f32,
smoothing: f32,
}
impl Gain {
/// Runs once, when the module is added. Set up everything here.
pub fn new(sample_rate: f32) -> Self {
// Reach a new knob setting in about 5 ms, so turning it never clicks.
let smoothing = 1.0 - (-1.0 / (0.005 * sample_rate)).exp();
Self { level: 1.0, smoothing }
}
/// Runs once per sample. Returns the output voltage and the light.
pub fn process(&mut self, input: f32, cv: Option<f32>, gain: f32) -> (f32, f32) {
let mut target = gain.clamp(0.0, 2.0);
if let Some(cv) = cv.filter(|v| v.is_finite()) {
target *= (cv / 10.0).clamp(0.0, 1.0);
}
self.level += (target - self.level) * self.smoothing;
if self.level.abs() < 1e-12 {
self.level = 0.0; // no denormals
}
let out = input * self.level;
let out = if out.is_finite() { out.clamp(-12.0, 12.0) } else { 0.0 };
(out, (out.abs() / 10.0).min(1.0))
}
}
#[cfg(test)]
mod tests {
use super::*;
#[test]
fn unity_gain_passes_the_signal() {
let mut gain = Gain::new(48_000.0);
let (out, _) = gain.process(5.0, None, 1.0);
assert!((out - 5.0).abs() < 1e-6);
}
#[test]
fn a_bad_input_never_reaches_the_output() {
let mut gain = Gain::new(48_000.0);
let (out, light) = gain.process(f32::NAN, Some(5.0), 1.0);
assert_eq!(out, 0.0);
assert_eq!(light, 0.0);
}
}The kit’s Module trait is how the Rack calls it: inputs (None when no cable is plugged in) and param values in, outputs and lights out.
use deepsynth_module as kit;
impl kit::Module for Gain {
fn new(sample_rate: f32) -> Self {
Gain::new(sample_rate)
}
fn process(&mut self, io: &mut kit::Io) {
let input = io.inputs[0].unwrap_or(0.0); // an empty jack reads 0 V
let cv = io.inputs[1]; // None when no cable is plugged in
let (out, light) = Gain::process(self, input, cv, io.params[0]);
io.outputs[0] = out;
io.lights[0] = light;
}
}The audio path must not allocate memory, take locks, wait, print or log. Make buffers in new.
5. Describe it
descriptor.json names the module and lists every input, output, param and light in panel order. Ranges are in the units process receives.
{
"name": "Gain",
"category": "amplifiers",
"description": "Scales a signal by a knob, with a CV input for the level.",
"width_hp": 3,
"polyphonic": false,
"inputs": [
{ "label": "IN", "signal": "audio" },
{ "label": "CV", "signal": "cv", "range": "0 to 10 V" }
],
"outputs": [
{ "label": "OUT", "signal": "audio" }
],
"params": [
{ "label": "GAIN", "kind": "knob", "min": 0, "max": 2, "default": 1 }
],
"lights": [
{ "label": "LEVEL", "color": "green" }
]
}| name | 2 to 48 characters, in your own words. Not another company’s brand or product name. |
|---|---|
| category | sources, modulation, filters, amplifiers, envelopes, effects, sequencers, utilities, logic or output |
| description | One line, up to 280 characters. |
| inputs, outputs | In panel order, each with a label and what it carries: audio, cv, pitch, gate or trigger. |
| params | In panel order: knob, switch or button, with min, max and default. |
| lights | In panel order, with a label and a color. |
| polyphonic | true if the module handles every channel of a cable. The kit runs channel 1 for now. |
6. Lay out the panel
panel.json places each knob, jack and light. x and y are the center of each control, in pixels from the panel’s top left corner. This panel is 3 HP, so 45 px wide. cargo run -- panel --out panel.svg draws it, so you can see the layout before you send it.
{
"name": "Gain",
"width_hp": 3,
"width_px": 45,
"widgets": [
{ "type": "knob", "name": "GAIN_PARAM", "x": 22.5, "y": 120, "size": 36, "text": "GAIN" },
{ "type": "light", "name": "LEVEL_LIGHT", "x": 22.5, "y": 170, "size": 6, "color": "green" },
{ "type": "input", "name": "IN_INPUT", "x": 22.5, "y": 250, "size": 22, "text": "IN" },
{ "type": "input", "name": "CV_INPUT", "x": 22.5, "y": 295, "size": 22, "text": "CV" },
{ "type": "output", "name": "OUT_OUTPUT", "x": 22.5, "y": 340, "size": 22, "text": "OUT" }
]
}7. Check it
cargo run -- check checks the descriptor and the panel against the rules above, then runs the module for two seconds in each hard case: silence, sines, 10 V DC, loud noise, unplugged inputs, every param at its min, default and max, a NaN and an infinity on each input, and 44.1, 48 and 96 kHz. Outputs must stay finite and within ±12 V. It also says how long the module takes per sample. On the Gain example:
Descriptor (descriptor.json)
PASS name "Gain" (4 characters)
PASS category "amplifiers"
PASS width 3 HP (45 px)
PASS 2 inputs: IN (audio), CV (cv, 0 to 10 V)
...
Panel (panel.json)
PASS 5 widgets in the descriptor's order: 1 param, 2 inputs, 1 output, 1 light
PASS every widget is inside the 45 x 380 px panel
PASS no two widgets overlap
...
Sound (2 s per case at 48 kHz; outputs within ±12 V, lights 0 to 1)
PASS silence (0 V into every input) (OUT up to 0.00 V)
PASS 10 V DC into every input (OUT up to 10.00 V)
PASS every param at its max (440 Hz sine in) (OUT up to 4.80 V)
PASS one NaN and one infinity into CV (440 Hz sine in) (OUT up to 4.62 V)
PASS at 96 kHz (440 Hz sine in) (OUT up to 4.63 V)
...
Result: PASSIf a bad value gets stuck inside a module, check warns. The first version of this Gain did: one NaN on the CV input kept it silent until it was removed. It now treats a CV that isn’t finite as unplugged.
8. Hear it
cargo run -- render writes one output to a WAV file, 48 kHz, with 10 V at full scale. Choose what goes into each input (sine, saw, square, noise, a DC voltage or a gate) and set any param:
cargo run -- render --out gain.wav --input 0=saw:110 --input CV=dc:5 --param GAIN=1.59. Send it
When cargo test and cargo run -- check pass, put the module in a repository with:
- The module’s Rust source with its unit tests. Use only the Rust standard library if you can; any crate it depends on must be permissively licensed too.
descriptor.jsonandpanel.json.- A license file, and your copyright line at the top of each source file.
- A short note on how to hear it: what to patch into it and what it should sound like. A
renderline that shows it off is a good way to say this.
Then send it with the form below.
Licensing rules
Draft: these rules are still being checked with a lawyer and may change before we accept the first module.
- The code must be your own work, or under a permissive license: MIT, BSD, Apache 2.0, zlib or CC0. DeepSynth Rack is closed source, so we can ship only code whose license allows that. The same goes for any data in the module, such as wavetables or samples.
- We can’t accept GPL or LGPL code, or a port or translation of GPL code. Most open-source modules written for other software racks are GPL, so ports of them can’t be accepted.
- Keep the copyright and license notices of any permissive code you include, and tell us where it came from.
- You keep the copyright in your module. Submitting it gives us a license to include it in DeepSynth Rack and ship it to the people who use DeepSynth Rack.
How review works
We read the code, build it into a test copy of the Rack and play it. We check that:
- It builds with our engine, and its tests pass.
- Its audio path doesn’t allocate memory, take locks, wait, print or log. Anything like that belongs in
new, which runs once. - It doesn’t touch the network, files, the system clock or other threads, and has no unsafe code.
- Its outputs stay finite: no NaN or infinity, no denormals and no runaway levels, with silence, loud noise, unplugged cables and every param at either end, at each sample rate the Rack runs at.
- It fits the CPU budget: about what a module of the same kind in the Rack already costs.
- Its panel works: every knob, jack and light matches the descriptor, the labels are readable, and nothing overlaps or runs off the panel.
- It does what its description says, and its license checks out.
We usually reply within two weeks, and tell you what to change if it doesn’t pass yet. Once it’s accepted, the module ships in the next DeepSynth Rack release. It shows up in Add Module in the Rack and on the modules page.
Selling
Not yet. For now, accepted modules are added to DeepSynth Rack, with no store and no payment for them.
Submit a module
Tell us about the module and where its code is. We’ll read it and write back.
Checking your account…
We keep what you send with your account’s email and ID, so we can review it and reply. It doesn’t add you to any mailing list. Questions? Write to info@deepsynth.ai.