Constraint Decoding: Tool call with text (#4067)

This commit is contained in:
Xihuai Wang
2025-03-17 16:06:46 +08:00
committed by GitHub
parent ef3c2dd08e
commit 927ca935a7
4 changed files with 143 additions and 102 deletions

View File

@@ -257,7 +257,7 @@ class TestOpenAIServer(unittest.TestCase):
ret_num_top_logprobs == logprobs
), f"{ret_num_top_logprobs} vs {logprobs}"
assert isinstance(data.content, str)
assert isinstance(data.content, str) or response.choices[0].finish_reason
assert response.id
assert response.created