let harmony = Engine.new(Palestrina);
fn detect_pitch(buf) -> Note
const MAX_VOICES: usize = 4;
voice_leading.reject_parallels()
struct GuitarInput { onset }
engine.harmonize(note, scale)
fn detect_pitch(
  buf: &[f32]
) -> Option<Note>
let voices =
  counterpoint::
    generate(line, mode);
if interval == Fifth
  && motion == Parallel
  { reject() }
#[inline(always)]
fn onset(
  frame: &Frame
) -> bool
block_size: 128
sample_rate: 48_000
latency_ms: 7.2
// Palestrina
// counterpoint
// rules.rs
CONTRAPUNK WEEKEND JAM·WK 01·Koji Kondo· STARTS IN 2DAYS→ /jam
COMMUNITY · MIT · GITHUB

MADE TOGETHER.

Guitarists, theorists, DSP engineers, and bedroom producers. Read the code, open an issue, send a PR.

"

The Jazz mode voicings are better than I am. I mean that as a compliment to the code.

KE
@kenji_osaka
JAZZ GUITARIST
"

I make my species-counterpoint students check their homework against Palestrina mode. Beats my red pen.

LE
@lena.strings
COMPOSITION PROF
"

Random-below-no-2nds into a Rhodes plugin hosted in-app. Instant ECM record.

DR
@drifter_7
AMBIENT PRODUCER
"

Looked under the hood expecting hacks. Found a voice-leading solver with comments. Read the whole thing on a flight.

BO
@boris.k
DSP ENGINEER
"

We run two guitars into two instances, quantize to different modes. Feels like a third band member.

SU
@sunday_kids
POST-ROCK BAND
"

Parallel-fifths rejection on by default is a value statement. Ship more value statements.

MA
@mara.note
MUSIC THEORIST
◆ ◇ ◆ ◇ ◆ RECENT COMMITS
feat(modes): add RandomBelowNoSeconds — avoid minor/major 2nd intervals
feat(host): CLAP plugin GUI window wiring via clack-host
perf(pitch): McLeod refinement drops jitter by 0.4ms
fix(solver): clamp voice-cross penalty when voices tie
feat(styles): Bach Chorale preset + unit tests on 4-voice cadences
docs: engine deep-dive — 57 scales across 10 families
fix(wasm): Web Audio worklet timing on Safari
chore: tauri v2 upgrade, drop v1 migration shims
GET CONTRAPUNK

THREE WAYS IN.
ALL FREE.

Browser at app.contrapunk.com. macOS DMG from GitHub Releases. Build from source with cargo tauri dev.