usage: tuney [-h] [OPTIONS] [TUNING.COMPUTED] [TABLE] [RATIOS]

Turn text into music. Use positional `TEXT` to play characters as notes, then tune the scale, audio, MIDI, and timing from the same config model.

 positional arguments
 ----------------------------------------------------------------------------------------------------------------------
  TEXT  Positional text to start the program with (default: )

 options
 ----------------------------------------------------------------------------------------------------------------------
  -h, --help
        show this help message and exit
  -m FLOAT, --max-gap FLOAT
        Maximum silent gap to keep in recordings, in seconds (default: 4.0)
  --hover-time FLOAT
        Time to hover over a widget before showing help, in seconds (default: 1.0)
  --backspace-repeat-delay FLOAT
        Time to hold backspace before it starts repeating, in seconds (default: 2.0)
  --backspace-repeat-rate FLOAT
        Backspace repeats per second after backspace_repeat_delay (default: 4.0)
  -g, --gui, --no-gui
        Open the graphical interface (default: False)
  -s, --silent, --no-silent
        Disable synthesized audio output (default: False)
  --use-speech, --no-use-speech
        Speak the replay text along with the synthesized notes (default: False)
  --speech-level FLOAT
        Speech volume multiplier (default: 1.0)
  -o {None}|PATH, --output {None}|PATH
        Audio file to write while playing text (default: None)
  -b, --run-in-background, --no-run-in-background
        If True, listen to the keyboard even when other applications are in front (default: False)
  -p {None}|STR, --preset {None}|STR
        Named performance preset to load (default: None)
  -c {None}|PATH, --config-file {None}|PATH
        Load configs from a JSON or toml file (default: None)
  -t TEXT, --text TEXT
        Text to start the program with (optional)

 mapper options
 ----------------------------------------------------------------------------------------------------------------------
  Convert letters to scale indexes
  ----------------------------------------------------------------------------------------------------------------------
  -a {None}|STR, --alphabet {None}|STR
        Characters mapped to note numbers, or the default alphabet if empty (default: None)
  -l INT, --length INT
        Number of note numbers to cycle through; zero uses the full alphabet (default: 0)
  -C, --case-sensitive, --no-case-sensitive
        Treat uppercase and lowercase characters as distinct (default: True)
  -I, --invert, --no-invert
        Reverse the order of mapped note numbers (default: False)
  -O INT, --mapper-offset INT
        Offset from the center of the mapped note range (default: 0)
  -r INT, --range-limit INT
        Limit pitch range to this many notes (default: 60)
  -L {wrap,reflect,reflect_repeat}, --limiter {wrap,reflect,reflect_repeat}
        What to do when mapped notes are outside the pitch range (default: wrap)

 scale options
 ----------------------------------------------------------------------------------------------------------------------
  Convert scale indexes to note names and note numbers
  ----------------------------------------------------------------------------------------------------------------------
  -A STR, --note-names STR
        The base note names (default: ABCDEFGHIJKLMNOPQRSTUVWXYZ)
  -q STR, --root STR
        The root note to start scales with (default: C)
  -j STR, --begin STR
        The first note from the note names: TODO: validate begin <= base <= end (default: A)
  -E STR, --end STR
        The Last note from the alphabet (default: G)
  -Q {None}|STR, --notes {None}|STR
        If `notes` is set, once the scale is generated, only the notes in
        `notes` are actually used in the list.

        For example, notes='CDEFGAB' would correspond to only the white notes on the piano. (default: None)
  -i [INT [INT ...]], --intervals [INT [INT ...]]
        The intervals between notes. Can also be entered as a string: "2212221" (default: 2 2 1 2 2 2 1)
  -X {none,whole,half}, --accidentals {none,whole,half}
        Which accidentals are allowed in note names (default: whole)
  -Y INT, --scale-offset INT
        Offset all note numbers by this (default: 0)

 tuning options
 ----------------------------------------------------------------------------------------------------------------------
  Convert note numbers into frequencies
  ----------------------------------------------------------------------------------------------------------------------
  --type {None,computed,table,ratios}
        Which tuning source to use (default: computed)
  -T FLOAT, --detune FLOAT
        Detune everything, in cents of an octave division (default: 0)
  -U FLOAT, --root-frequency FLOAT
        The frequency of the reference `root_note` (default: 440)
  -W INT, --root-note INT
        The note number of the reference note (default: 69)

 device options
 ----------------------------------------------------------------------------------------------------------------------
  Audio output device settings
  ----------------------------------------------------------------------------------------------------------------------
  --sample-rate {None}|INT
        Audio output sample rate, in frames per second (default: None)
  -d {None}|INT|STR, --audio-device {None}|INT|STR
        Audio output device name or index (default: None)
  --dtype {None,int8,uint8,int16,int32,float32}
        Sample data type sent to the audio output device (default: None)

 sound options
 ----------------------------------------------------------------------------------------------------------------------
  Synthesizer sound settings
  ----------------------------------------------------------------------------------------------------------------------
  -G FLOAT, --gain FLOAT
        Audio output gain (default: 1.0)
  -n INT, --audio-note-offset INT
        Offset added to generated note numbers before tuning (default: 44)
  -N FLOAT, --minimum-note-time FLOAT
        Minimum duration of each synthesized note, in seconds (default: 0.5)

 sound.oscillator options
 ----------------------------------------------------------------------------------------------------------------------
  Synthesizer oscillator settings
  ----------------------------------------------------------------------------------------------------------------------
  -w {sine,square,triangle}, --waveform {sine,square,triangle}
        Waveform used to synthesize notes (default: triangle)
  -u FLOAT, --duty-cycle FLOAT
        Fraction of each waveform cycle before its falling edge (default: 0.5)
  -K INT, --key-scale-note INT
        Note number with no keyboard gain adjustment (default: 64)
  -k FLOAT, --key-scale FLOAT
        Gain decibels added per keyboard octave above key_scale_note (default: 0.0)

 sound.polyphony options
 ----------------------------------------------------------------------------------------------------------------------
  --headroom FLOAT
        Divisor applied to mixed voices to provide polyphonic headroom (default: 4)
  --max-voices INT
        Maximum number of notes that can play simultaneously (default: 10)

 midi options
 ----------------------------------------------------------------------------------------------------------------------
  Where to send MIDI output
  ----------------------------------------------------------------------------------------------------------------------
  --midi-enable, --no-midi-enable
        Enable MIDI output (default: False)
  --midi-output {None}|STR
        MIDI output port name (default: None)
  --midi-channel INT
        MIDI channel, from 0 to 15 (default: 0)
  --midi-velocity INT
        Velocity used for MIDI note-on messages (default: 64)
  --midi-note-offset INT
        Offset added to MIDI note numbers (default: 0)

 text-timings options
 ----------------------------------------------------------------------------------------------------------------------
  Timings for playing back texts
  ----------------------------------------------------------------------------------------------------------------------
  --space FLOAT
        Base duration for a space, in milliseconds (default: 100)
  --dot FLOAT
        Base duration for a dot, in milliseconds (default: 300)
  --comma FLOAT
        Base duration for a comma, in milliseconds (default: 200)
  --colon FLOAT
        Base duration for a colon, in milliseconds (default: 400)
  --semicolon FLOAT
        Base duration for a semicolon, in milliseconds (default: 400)
  --blank-line FLOAT
        Base duration for a blank line, in milliseconds (default: 1000)
  --overlap FLOAT
        Time that consecutive characters overlap, in milliseconds (default: 20)
  --seed {None}|INT
        Seed for randomized character timings, or a random seed if empty (default: None)
  --alpha-only, --no-alpha-only
        Ignore characters without an explicit timing unless they are alphabetic (default: True)
  --strip-accents, --no-strip-accents
        Remove accents before generating character events (default: True)
  --scale FLOAT
        Multiplier applied to all generated timing values (default: 3.0)
  --other [STR FLOAT [STR FLOAT ...]]
        Additional per-character base durations, in milliseconds (default: )
  --timings {None}|{[FLOAT [FLOAT ...]]}
        Possible durations for alphabetic characters, in milliseconds (default: None)

 subcommands
 ----------------------------------------------------------------------------------------------------------------------
  Computed tuning parameters (default: tuning.computed:computed)
    - tuning.computed:computed
    - tuning.computed:none
  ----------------------------------------------------------------------------------------------------------------------
  Absolute frequencies, indexed by note number (default: table:none)
    - table:table
    - table:none
  ----------------------------------------------------------------------------------------------------------------------
  Ratio expressions, relative to root_frequency (default: ratios:none)
    - ratios:ratios
    - ratios:none
