Skip to content

WhisperX transcription error #17

Closed

Description

@topkoa

An HTTP 422 Unprocessable Entity error means your WhisperX server received your request but couldn't process it. This usually happens due to missing parameters, invalid audio formats, or data types that the server's API doesn't support.

reported by @MajorMokoto

Activity

  1. topkoa commented on Jul 14, 2026

    @topkoa
    CollaboratorAuthor

    Fixed — in both halves, and it turned out to be worse than a bad request: remote transcription had never worked for anyone.

    transcribe_vocals_remote() was posting the vocal stem to /align, which is forced alignment — "here are the lyrics, tell me when each word is sung". Its text field is required and we have no lyrics (producing them is the entire point), so FastAPI rejected every request with a 422 in its validation layer, before the server's handler ever ran. There was no /transcribe endpoint at all. Not a regression: the feature was wired to an endpoint that answers a different question.

    What landed

    • feedBack-demucs-server#14 — adds POST /transcribe. Whisper hears the words, then wav2vec2 force-aligns Whisper's own transcript, so the timings are tight enough for a chart (raw Whisper segments drift, and a chart built from them sits visibly late).
    • feedBack#959 — points the client at it. Also fixes a second bug found on the way: language was sent as a query param where the server reads a form field, so an explicit language hint was silently ignored and Whisper's auto-detection quietly decided instead — loading the wrong wav2vec2 aligner. It "worked", it was just wrong.

    To pick it up

    The server's server.py is downloaded at install time, so an existing install needs to refresh its source: Settings → Stem Splitter → Check for update (the button added in plugin 0.3.3). Nothing large is re-downloaded — it's a few hundred KB of source, and the model cache is untouched. A server that hasn't updated now answers 404, and the plugin says so explicitly ("it predates remote transcription support") rather than failing silently.

    Why it hid for so long

    Every test of that module tested the mapper, fed a hand-written dict. The mapper was always fine — the request was never exercised, and the request was the bug. Both repos now test the request itself, against a real FastAPI app, because the 422 happened above the handler: a unit test calling the handler directly would have passed while the endpoint rejected every call.

    And the 422 explaining all this was reaching the app the whole time — it was being truncated into invisibility in the queue, which is what #16 was about. Fixing that is what made this findable.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions