[Bugfix] Fix the issue where the seed parameter does not take effect when using the OpenAI Python client (#3436)

Signed-off-by: Phi-C <chenxjhit@163.com>
This commit is contained in:
Phi-C authored and GitHub committed 2026-05-08 07:22:32 +00:00
1 parent 32663f21d5
commit 50fd3a3f85
1 file changed
+2
@@ -2424,6 +2424,8 @@ class OmniOpenAIServingChat(OpenAIServingChat, AudioMixin):
cfg_text_scale = extra_body.get("cfg_text_scale")
cfg_img_scale = extra_body.get("cfg_img_scale")
seed = extra_body.get("seed")
if seed is None:
seed = getattr(request, "seed", None)
negative_prompt = extra_body.get("negative_prompt")
num_outputs_per_prompt = extra_body.get("num_outputs_per_prompt", 1)