Skip to content

fix: limit vLLM VAD segments to 30 seconds - #3420

Merged
LauraGPT merged 1 commit into
mainfrom
codex/funasr-issue-3419-20260726
Jul 26, 2026
Merged

fix: limit vLLM VAD segments to 30 seconds#3420
LauraGPT merged 1 commit into
mainfrom
codex/funasr-issue-3419-20260726

Conversation

@LauraGPT

Copy link
Copy Markdown
Collaborator

Summary

  • configure the standalone Fun-ASR-Nano vLLM server's FSMN-VAD model with a 30-second maximum segment duration
  • add a regression test that verifies the limit is applied when the VAD model is constructed

Why

The server constructed FSMN-VAD without max_single_segment_time, so it inherited the 60-second default. Passing this value to AutoModel.generate() is ineffective because FSMN-VAD stores it in VADXOptions at model construction time.

On the 480-second attachment from #3419, a 60-second segment omitted a substantial passage around the Blackwell/product update and robot discussion. The 30-second configuration matches the existing Fun-ASR-Nano examples and documentation.

Validation

  • python3 -m pytest tests/test_fun_asr_nano_autocast_device.py tests/test_fun_asr_nano_ctc_batch_fallback.py tests/test_fun_asr_nano_missing_ctc_weights.py tests/test_fun_asr_nano_openai_response.py tests/test_fun_asr_nano_repetition_penalty.py -q (27 passed)
  • python3 -m py_compile examples/industrial_data_pretraining/fun_asr_nano/serve_vllm.py tests/test_fun_asr_nano_openai_response.py
  • python3 -m black --check tests/test_fun_asr_nano_openai_response.py
  • git diff --check origin/main...HEAD

Real-audio comparison using the issue attachment:

Metric Before After
VAD segments 13 20
Maximum segment duration 60.01 s 30.01 s
Aligned, script-normalized CER 22.74% 19.63%
RTF 0.0087 0.0169

The CER comparison removes the unmatched 0-17.69 second teaser that is absent from the reference transcript and converts both reference and hypothesis to Simplified Chinese before retaining letters and numbers. The recovered passage is present after the change, although proper-name recognition such as Blackwell remains imperfect.

Related to #3419.

@gemini-code-assist

Copy link
Copy Markdown
Contributor

Caution

The consumer version of Gemini Code Assist on GitHub has been sunset. All code review activity has officially ceased.

@LauraGPT
LauraGPT requested a review from yufan-aslp July 26, 2026 05:48
@LauraGPT
LauraGPT merged commit 70c868c into main Jul 26, 2026
@LauraGPT
LauraGPT deleted the codex/funasr-issue-3419-20260726 branch July 26, 2026 06:53
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.

1 participant