voice_to_piano_roll
Record a melody by humming or playing into a microphone and transcribe it directly into FL Studio's piano roll with adjustable quantization, scale snapping, and confidence filtering.
Instructions
Hum/play a melody into the mic, get it written straight into FL's piano roll.
Args:
duration_sec: how long to record.
bpm: used to convert seconds -> bars. Match your FL tempo.
device: mic index (see voice_list_devices); None = default.
scale_root: e.g. "C", "F#", "Bb". If given, notes are snapped.
scale: e.g. "minor", "major", "dorian". One of
gen_list_scales. Used only when scale_root is given.
transpose_semitones: shift all notes up/down after transcription.
quantize_grid_sec: snap note starts to this grid (e.g. 0.125 = 1/32
at 120 BPM, 0.25 = 1/16, 0.5 = 1/8). None = off.
min_confidence: drop notes where the engine was uncertain (0..1).
min_note_sec: drop notes shorter than this many seconds.
polyphonic: use Spotify Basic Pitch (chords / overlapping notes —
needs the polyphonic extra). Default = monophonic pyin.
clear_first: clear the open piano roll before writing.
Returns: {ok, notes_written, piano_roll_state, wav_path, transcription_count}
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| duration_sec | No | ||
| bpm | No | ||
| device | No | ||
| scale_root | No | ||
| scale | No | ||
| transpose_semitones | No | ||
| quantize_grid_sec | No | ||
| min_confidence | No | ||
| min_note_sec | No | ||
| polyphonic | No | ||
| clear_first | No |