[fix] Make Qwen2_5OmniProcessor warning a lot less noisy via warning_once#45455
Merged
tomaarsen merged 8 commits intohuggingface:mainfrom Apr 16, 2026
Merged
Conversation
|
The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update. |
Member
zucchini-nlp
left a comment
There was a problem hiding this comment.
Yes, let's delete entirely!
Comment on lines
-316
to
-319
| logging.warning( | ||
| "System prompt modified, audio output may not work as expected. " | ||
| + "Audio output mode only works when using default system prompt 'You are Qwen, a virtual human developed by the Qwen Team, Alibaba Group, capable of perceiving auditory and visual inputs, as well as generating text and speech.'" | ||
| ) |
Member
There was a problem hiding this comment.
Oh I hate this warning as well haha, couldn't convince qwen team to delete at model addition time 🫠
Now that it's maintained by us, ig we can decide what to do with it
Member
Author
zucchini-nlp
approved these changes
Apr 15, 2026
Member
zucchini-nlp
left a comment
There was a problem hiding this comment.
Yaay, we can delete apply_chat_template entirely and merge!
Comment on lines
-303
to
-309
| if isinstance(conversations[0], dict): | ||
| conversations = [conversations] | ||
| is_batched = True | ||
|
|
Member
There was a problem hiding this comment.
we can completely delete the whole fn 💃🏻
Contributor
|
[For maintainers] Suggested jobs to run (before merge) run-slow: qwen2_5_omni, qwen3_omni_moe |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this PR do?
There's 2 changes, one is a definite fix and one is a preference. Some background: there are a lot of models that have finetuned
qwen2_5_omni, e.g. https://huggingface.co/LCO-Embedding/LCO-Embedding-Omni-3B, and in the case of this model, finetuned with a whole new chat template/system prompt/no system prompt.This is totally fine, except every single input processing results in a spam of
So I've made 2 changes:
warning_onceinstead of warning every single timecheck_audio_system_promptorcheck_system_promptin the processor config. That way I should be able to remove the warning altogether in these cases where it's a totally incorrect warning.If change 2 goes too far, I can revert that commit and we can go for just option 1.
An alternative solution would be to just remove the warning: we don't often get involved with the chat template/system prompt choices of the architectures, right?
Code Agent Policy
This one was written manually, except the test, which was half generated
Before submitting
Pull Request section?
to it if that's the case.
documentation guidelines, and
here are tips on formatting docstrings.
Who can review?
@zucchini-nlp