Skip to content

Transcription locks the language on the first chunk, so a take that opens with silence comes out in the wrong language #1664

Backlog

Description

@EtienneLescot

The automatic transcription detects the language on a take's first chunk only, then forces every later chunk onto it. When that first chunk holds no speech, whisper resolves room noise to an arbitrary language. The whole transcript then comes out in that language, the real speech included.

Seen on 2.4.0-rc.1, Windows 11, local whisper (whispercpp-vulkan, ggml-small-q8_0):

  • A 5 min 27 s take, transcribed in four chunks of 91.3 s, 90.9 s, 90.5 s and 54.2 s. Its first 91 s held only room sound; English speech came later.
  • The take's Transcript panel read Detected language: Korean, and the English speech was written in Korean.
  • An 11 s voice-over with the same speech, transcribed on its own, was detected as English.
  • On Linux, a take with no speech at all was detected as French and downloaded the French word aligner.

Steps

  1. Record a take that opens with a minute or more of silence or room noise, then has speech.
  2. Let the background transcription finish, then select the take's card in Media.
  3. Read Detected language and the transcript.

Expected: the transcript is in the language spoken.

Workaround: Media → the take's card → Regenerate as → the right language. That re-run came out correctly, with Detected language: English.

Why

electron/stt/index.ts#L381-L401 pins the language resolved by the first chunk, and #L447-L450 takes it from the first chunk that reports one. The pin exists for a good reason: a later chunk that opens on a name or a pause must not flip the language mid-recording. But it trusts the first chunk even when that chunk had no speech to detect from.

Fix direction

  • Pin the language only once the detection is confident (whisper's language probability), and keep detecting on the next chunks until then.
  • Or detect on the first chunk that the VAD finds real speech in.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions