Add the --auto CLI flag + docs - #39
Open
yumiaura wants to merge 1 commit into
Open
Conversation
Expose the auto-settings engine on the command line. `audio8bit -i song.mp3 --auto` picks the melody source, note method, voices, transpose and duty from the song and prints what it chose; any flag you also pass explicitly still wins. - cli.py: add --auto (store_true). The auto-eligible options (source, method, voices, transpose, duty, key-snap, arrange, echo, dither) now default to None so "explicit vs let-auto-decide" is detectable, and are passed straight through to convert(); a switch() helper maps the on/off flags to bool-or-None. Without --auto, convert() still resolves each None to its module default, so behaviour is unchanged. Help text notes what --auto fills in. - README.md: two usage examples (plain --auto, and --auto with one forced flag) and an --auto entry in the options list. - docs/README_*.md: the same two additions synced into all 10 translations, ASCII punctuation only. - CHANGELOG.md: Added entry under a new Unreleased section, naming the branches. Verified end to end: `python main.py -i input.mp3 --auto` prints the chosen settings (instrumental/nes, centred register, E-minor key) with a passing quality report; a plain run without --auto is unchanged; --help lists the flag.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Phase B of the
--autofeature - the user-facing surface. Stacked on #38(base branch
feat/auto-engine); review/merge #38 first.audio8bit -i song.mp3 --autopicks the melody source, note method, voices,transpose and duty from the song's own features and prints what it chose. Any
flag you also set explicitly still wins (
--auto -V leadforces lead, auto doesthe rest).
--auto(store_true). The auto-eligible options (source,method,voices,transpose,duty,key-snap,arrange,echo,dither) now default toNoneso explicit-vs-auto is detectable, and passstraight through to
convert(); aswitch()helper maps the on/off flags tobool-or-None. Without
--auto,convert()resolves eachNoneto its moduledefault, so behaviour is unchanged.
--autooptions bullet, synced across translations, ASCII punctuation only.
## Unreleased, naming both branches.Test plan
python main.py -i input.mp3 --autoprints the chosen settings(instrumental/nes, transpose +24, E-minor) with a passing quality report.
--auto -V lead(override) keeps lead, auto-picks the rest.--autois unchanged (chords).--helplists--auto; smoke-import ofaudio8bit.cliOK.Note on scope
--autofixesmethod=transcribe(never auto-selects the lighterpitchpath): monophonic material is already served by
voices=lead, so transcribe isthe right general choice and
--method pitchremains available to force it. Theplan allowed auto-selecting pitch for a clean monophonic vocal; I kept it simple
and honest instead of adding a flaky pre-transcription heuristic. Happy to
revisit if you want it.