Conversation
joanise
added this pull request to stack #886
September 15, 2026 21:29
Changed Files
|
Contributor
|
preprocess CLI into core, with CLI and API shims
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #885 +/- ##
==========================================
- Coverage 85.43% 85.40% -0.04%
==========================================
Files 51 51
Lines 4780 4781 +1
Branches 710 711 +1
==========================================
- Hits 4084 4083 -1
- Misses 525 526 +1
- Partials 171 172 +1 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
roedoejet
reviewed
Sep 17, 2026
| == TargetTrainingTextRepresentationLevel.phonological_features | ||
| ): | ||
| steps.append("pfs") | ||
| steps = [*steps, "pfs"] |
Member
Author
There was a problem hiding this comment.
We discussed it, but to put the answer here: it's the difference between mutating the caller's variable or not. append changes the caller's list, the alternative expansion does not. It's nitpicking, but it's cleaner design: a function ought not mutate it's caller's arguments unless it's a function whose task is to mutate the caller's arguments. And especially not if it doesn't document doing so.
joanise
force-pushed
the
dev.ej/fs2-prepro-v2
branch
from
September 17, 2026 20:47
9e4fe65 to
b7e594d
Compare
joanise
force-pushed
the
dev.ej/fs2-prepro-v2
branch
from
September 17, 2026 20:55
b7e594d to
931144b
Compare
In order to support a programmatic API for EveryVoice, we need preprocess, train, synthesize to accept a Config object instead of the name of a config file, so that a script using the API can a) create or load the config, as desired, and then b) preprocess or train or whatever. This requires separating load_config_base_command from the other base commands, to be called first in CLI shims, or separately in API shims.
joanise
force-pushed
the
dev.ej/fs2-prepro-v2
branch
2 times, most recently
from
September 18, 2026 18:47
931144b to
08f41d5
Compare
This branch has not been deployed
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.
PR Goal?
I'm going to use stacked pull requests for the refactoring project. This PR primarily refactors
preprocess()in all modules, as we discussed in the project to create a HuggingFace/workbook friendly API to EveryVoice. A number of other changes happened here too, and they're too intricately tied together to separate into multiple PRs, but I'm making a PR to create a "checkpoint" here for review.fs2l preprocessthe help gives you examples using thefs2lcommand, and then for EV I use a string replacement to make it show theeveryvoicecommand equivalent. I gave some thought on factoring thosereplace()commands out, but I didn't come up with a good solution yet.list[str]that the API will use as is, but the CLI dynamically constructs the Enum typer needs. That dynamic Enum is kinda ugly, but it's only for the CLI, we should not use it elsewhere, so I think it's appropriate. Maybe I should factor that block out to base_cli since it's the same 5 lines of code in 3 submodules.Feedback sought?
This is going to be the basis of our bilat discussion Thursday. High level feedback about the approach is key at this point. Micro-level feedback about things I've changed will also be useful, as long as you keep in mind that train and synthesis functions are not done yet.
Priority?
If you can take a cursory look before we meet Thursday, great, but if not we'll look at it together on Thursday anyway.
Tests added?
no
The CLI is already well exercised. The API will need its own tests.
How to test?
The CLI should work as before.
Confidence?
medium
Version change?
yes, intermodule compatibility is going to be broken all over, so at the very least this represents a patch bump, if not a minor bump.
Related PRs?
EveryVoiceTTS/StyleTTS2#34
EveryVoiceTTS/FastSpeech2_lightning#164
EveryVoiceTTS/HiFiGAN_iSTFT_lightning#68