Skip to content

Commit 4a0020c

Browse files
BroadbentJimjimoosciuc
authored andcommitted
fix: Inappropriate lack of Optional type on OpenAI ChatCompletionRequest (sgl-project#4681)
1 parent 3b33ed8 commit 4a0020c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

python/sglang/srt/openai_api/protocol.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -323,7 +323,7 @@ class ChatCompletionRequest(BaseModel):
323323
max_tokens: Optional[int] = None
324324
n: int = 1
325325
presence_penalty: float = 0.0
326-
response_format: Union[ResponseFormat, StructuralTagResponseFormat] = None
326+
response_format: Optional[Union[ResponseFormat, StructuralTagResponseFormat]] = None
327327
seed: Optional[int] = None
328328
stop: Optional[Union[str, List[str]]] = None
329329
stream: bool = False

0 commit comments

Comments
 (0)