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
DOCS · GITHUB

READ THE MANUAL.

Full reference. No login wall. No "sign up for early access". Just markdown in /docs.

◆ ◇ ◆ ◇ ◆ EXCERPT · src/harmony/voice_leading/style_rules.rs
/// Style-rule preset: Palestrina (strict 16th-c. species).
/// Hard rules: reject parallel 5ths + 8ves, max leap = perfect 4th.
/// Soft weights: stepwise motion rewarded, leaps penalized, common-
/// tones preferred, contrary motion bonused.
pub const PALESTRINA: StyleRules = StyleRules {
    reject_parallel_fifths:  true,
    reject_parallel_octaves: true,
    max_leap_semitones:      5,
    stepwise_bonus:         60,
    common_tone_bonus:      45,
    leap_penalty_per_semi: -15,
    voice_cross_penalty: -150,
    spread_preference:      -4,
    contrary_motion_bonus:  40,
};