Skip to content

Fix Mistral transcription requests#671

Open
NoelDeMartin wants to merge 1 commit into
laravel:0.xfrom
NoelDeMartin:multipart-mistral-regression
Open

Fix Mistral transcription requests#671
NoelDeMartin wants to merge 1 commit into
laravel:0.xfrom
NoelDeMartin:multipart-mistral-regression

Conversation

@NoelDeMartin
Copy link
Copy Markdown
Contributor

@NoelDeMartin NoelDeMartin commented May 29, 2026

I recently upgraded my laravel/framework version, and I started getting errors from Mistral's transcription API. In particular, I got the following:

{
  "object": "error",
  "message": {
    "detail": [
      {
        "type": "assertion_error",
        "loc": [],
        "msg": "Assertion failed, When diarize is set to True and streaming is disabled, the timestamp granularity must be set to ['segment'], got []",
        "input": {
          "model": "voxtral-mini-latest",
          "audio": "--audio-bytes--",
          "language": null,
          "temperature": null,
          "max_tokens": null,
          "stream": false,
          "return_language": false,
          "streaming": "disabled",
          "timestamp_granularities": [],
          "diarize": true,
          "context_bias": [],
          "target_streaming_delay_ms": null,
          "metadata": null
        },
        "ctx": {
          "error": {}
        }
      }
    ]
  },
  "type": "invalid_request_error",
  "param": null,
  "code": null,
  "raw_status_code": 422
}

Looking at the code, I was confused because the timestamp_granularities seems to be set to "segments" in the code... but after some digging, I could trace back the regression to a recent PR in laravel/framework: laravel/framework#59984

This was released in v13.9.0, and I'm not sure how many things are broken because of that. At the very least, this PR fixes Mistral's transcriptions.

I have reported this issue to laravel/framework in case you want to take a look at a more general fix: laravel/framework#60319

This fixes a regression caused in laravel/framework v13.9.0 (PR laravel/framework#59984)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

HTTP requests payload regression for multipart arrays

1 participant