Skip to content

Qwen3-ASR streaming timestamps depend on max_tokens instead of audio time #927

Description

@ainergiz

Problem

Qwen3-ASR calculates partial streaming timestamps from token-budget progress:

token_count / remaining_tokens * audio_duration

remaining_tokens starts from the generation budget and changes between chunks. This is not audio time, so changing max_tokens changes timestamps for the same audio and generated text.

Reproduction

Run stream_transcribe() on the same file with max_tokens=64 and max_tokens=8192, then compare each event's start_time and end_time.

Actual: partial timestamps change with the token budget. In one 8.57-second test, 31 partial events covered only about the first 0.03 seconds before the final boundary jumped to the end.

Expected: do not expose token-budget positions as audio timestamps. Text-delta events should be untimed unless the model or an aligner provides real alignment. Coarse audio chunk extents can remain timed.

Tested on current main at 246e233.

Activity

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

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions