Commit Graph
7 Commits
Author SHA1 Message Date
Palash Debnath ce3827b613 fix(batch): check the speech model inside the transcribe step, not ahead of the whole pipeline (#4625)
* fix(batch): check the speech model when restoring, not in every pipeline run

#4623 added the missing-model check to the batch transcribe stage. Every
batch pipeline test that does not stub it then failed in CI's model-free
environment, leaving main red. Restored jobs are the only ones that skip
enqueue's check, so restore now checks once and shows such a job as failed
with Retry, leaving the pipeline as it was.

Also confines queue record paths to the batch folder after resolving them
(the CodeQL path alerts on the record writer) and reads test files as UTF-8.

* fix(batch): check the speech model inside the transcribe step itself

Review found that a job queued before its speech model was removed could
still download it, and that checking at restore can run before startup
swaps a missing saved model for an installed one. The check now runs in the
transcribe function, right before the backend loads, for every job: queued,
retried or restored. Pipeline tests that stub the guarded transcribe call
never reach it; the one test that runs it with a stubbed model opts out.

Queue record paths are checked after resolving but replaced and removed by
their own directory entry, so a link can't make a cleanup delete another
job's record.
2026-12-03 16:42:04 -08:00
debpalash dd4fab090f fix(dub): blocking transcribe refuses a job with no audio instead of a 500 (#4219)
A subtitle-only job (/dub/from-srt) has no vocals or audio file. The SSE
route already refused it with "No audio available for transcription."; the
legacy blocking route handed None to the ASR backend and returned 500. It
now answers 409 before any ASR preflight or model load.

The subtitle-only transcribe test uses the asr_model_installed fixture, so
it asserts the job-level refusal on CI (no ASR weights) as on a dev
machine. A whisper.cpp language test now creates the audio file it names.
2026-11-23 06:36:48 +05:30
velixio 8c6f352618 fix(dub): ask for the language of an unrecognised caption track
An unknown caption tag now resolves to no language, but importing the
captions cleared the missing-language marker, so translation fell back
to English. Keep the marker when the tag is unknown, and match language
names whole so "myanmar-english" is not read as Burmese.
2026-11-07 16:08:38 +05:30
debpalash 43e6d512cd Dub: trim line ends after the speaker re-split
Trimming a segment's end to its last voiced speech before diarization
could cut a whispered reply sharing that segment, which the re-split
then dropped. Both transcription paths now keep the original bounds
through diarization and trim each speaker's line afterwards.
2026-10-27 19:48:43 +05:30
debpalash 6a4bda0568 feat(convert): Keep my delivery; dub lines start and end on detected speech
Convert gets a Keep my delivery switch that converts the recording itself
through CosyVoice 3's upstream inference_vc, so only the voice changes and
the source timing, pauses and intonation stay (#3421). Engines declare
supports_voice_conversion; the active engine is used when it converts,
otherwise any installed one; a typed 409 names what to install.

Dub onset snapping now requires voiced speech, so a sigh, breath or rustle
no longer sets a line's start, long snaps may cross audible non-speech, and
line ends are trimmed back to the last voiced speech (#3419 item 3).
2026-10-27 15:30:44 +05:30
debpalash 561c62717b fix(batch): tell the user to pick a source language when ASR reports none
Batch dubbing stopped with a generic RuntimeError whose text was hidden
behind More info. It now raises SourceLanguageRequiredError, a terminal
SOURCE_LANGUAGE_REQUIRED failure class with a hint, and the batch card
shows a localized message that says to choose the source language in
Dubbing or use an ASR model that detects it.
2026-10-26 03:03:19 +05:30
dutch2005 5ee41e305b feat(asr): add local whisper.cpp transcription with optional Vulkan acceleration
Run local transcription and translation while preserving CPU choices, cached checkpoint names, actual model provenance and consistent source-language choices for translation, pack setup and glossary extraction.
2026-10-26 02:55:31 +05:30