1022 B
1022 B
Seed auto-pick
POST /api/seed-autopick(routes/tts.py) validates input (core/seed_score.seed_list: explicit seeds 0-9999 orcount1-16, default 8), then for each seed calls_seed_finder_request_audioin a worker thread (shared_SEED_FINDER_VOICE_LOCK, voices.json restored in itsfinally), scores it in a second thread and moves on. Per-candidate timeout 240 s; a timeout ends the run (the worker still holds the lock until it restores). Client disconnect is checked between candidates (cancel = abort the fetch).- Scoring:
core/seed_score.py(constants at top, formula in the docstring). Sub-scores come fromroutes.stt._transcribe_audio+_word_accuracy(imported lazily),core.audio._loudness_info,core.audio.audio_problems. First STT failure disables ASR for the rest of the run (degraded: true,stt.note). - Never saves. The UI confirms via the existing
/api/tts-voice-seed. - Limits: sequential, so 16 candidates take minutes; audio returns base64 in the JSON (about 0.5 MB each).