vllm-project/vllm-omni

[Bug]: --allowed-local-media-path is ignored for pure diffusion speech

Open

#5,789 opened on Aug 5, 2026

 (0 comments) (0 reactions) (0 assignees)Python (1,067 forks)github user discovery
bughelp wantedlow priority

Repository metrics

Stars
 (4,990 stars)
PR merge metrics
 (Avg merge 7d 6h) (387 merged PRs in 30d)

Description

Your current environment

Description

For pure diffusion speech models such as k2-fsa/OmniVoice, the --allowed-local-media-path option is accepted but is not propagated to the MediaConnector used to load ref_audio.

Requests using local file:// reference audio fail with:

RuntimeError: Cannot load local files without `--allowed-local-media-path`.

Environment

  • vLLM: 0.26.0
  • vLLM-Omni: main
  • Model: k2-fsa/OmniVoice
  • GPU: H200

Expected Behavior

Local audio under the directory specified by --allowed-local-media-path should be accepted.

Root Cause

The pure diffusion speech path creates MediaConnector() without passing the configured local media path.

Related PR

https://github.com/vllm-project/vllm-omni/pull/5788

Your code version

Your Code Version

v0.26.0
bfaaa3c2 (main, issue reproduced)
390c1a54 (fix, PR #5788)

🐛 Describe the bug

When serving a pure diffusion speech model such as k2-fsa/OmniVoice, --allowed-local-media-path is accepted by the CLI but is not propagated to the MediaConnector used by the diffusion speech handler.

As a result, a ref_audio file located inside the explicitly allowed directory is rejected with HTTP 500.

Reproduction

Start the server:

CUDA_VISIBLE_DEVICES=2 \
vllm serve k2-fsa/OmniVoice \
  --omni \
  --port 8108 \
  --trust-remote-code \
  --allowed-local-media-path /home/lcc/ref_audio

Place a valid reference audio file at:

/home/lcc/ref_audio/women_1.wav

Send a request:

curl http://127.0.0.1:8108/v1/audio/speech \
  -H "Content-Type: application/json" \
  -d '{
    "model": "k2-fsa/OmniVoice",
    "input": "Hello, this is a voice cloning test.",
    "response_format": "wav",
    "ref_audio": "file:///home/lcc/ref_audio/women_1.wav"
  }' \
  --output output.wav

Expected behavior

The reference audio should be loaded because it is a child of the directory specified by --allowed-local-media-path.

Actual behavior

The request returns HTTP 500:

RuntimeError: Cannot load local files without `--allowed-local-media-path`.

Relevant traceback:

Diffusion speech generation failed: Cannot load local files without
`--allowed-local-media-path`.

Traceback (most recent call last):
  File "vllm_omni/entrypoints/openai/serving_speech.py", line 3641,
    in _create_diffusion_speech
    wav, sr = await self._resolve_ref_audio(request.ref_audio)
  File "vllm_omni/entrypoints/openai/serving_speech.py", line 2028,
    in _resolve_ref_audio
    wav_np, sr = await connector.fetch_audio_async(ref_audio_str)
  File "vllm/multimodal/media/connector.py", line 469,
    in fetch_audio_async
    return await self.load_from_url_async(...)
  File "vllm/multimodal/media/connector.py", line 441,
    in load_from_url_async
    return await future
  File "vllm/multimodal/media/connector.py", line 322,
    in _load_file_url
    raise RuntimeError(
RuntimeError: Cannot load local files without `--allowed-local-media-path`.

Root cause

The pure diffusion initialization path calls OmniOpenAIServingSpeech.for_diffusion() without passing allowed_local_media_path or allowed_media_domains.

Consequently, _resolve_ref_audio() creates an unconfigured connector:

if self._diffusion_mode:
    connector = MediaConnector()

The non-diffusion path correctly passes these settings from model_config.

A proposed fix propagates both media access settings through the pure diffusion speech initialization path.

Related PR: https://github.com/vllm-project/vllm-omni/pull/5788

Before submitting a new issue...

  • Make sure you already searched for relevant issues, and asked the chatbot living at the bottom right corner of the documentation page, which can answer lots of frequently asked questions.

Contributor guide