Project notes

Architecture

trail mix accepts finite mono f32 PCM plus a sample rate. Decoding, file metadata, databases, application state, and network transport remain caller responsibilities. This boundary keeps the analysis crates usable in desktop, command-line, and research tools without coupling them to one application.

Analyzer crates

trail mix keeps each job separate, then combines the results through the top-level trailmix crate.

beat salad

Estimates global tempo, beat positions, downbeat hints, and local tempo changes.

returns
BPM, beat grid, tempo segments

key lime

Builds chroma features and estimates global and local major or minor keys.

returns
Key, confidence, key segments

sampler platter

Condenses audio into compact waveform columns for display and storage.

returns
Min, max, and RMS waveform columns

Why PCM input

trail mix starts after decoding. An app turns an audio file into mono samples, passes those samples and the sample rate to trail mix, then stores the returned analysis however it wants.

Tradeoffs

The default analyzers use deterministic DSP rather than bundled neural-network weights. That keeps the core build small, inspectable, and fully offline, but it will not match specialized ML systems on every dataset.

References