[Refactor][GPT-OSS] Harmony Responses API Refactor to use HarmonyParser (#47185)
Signed-off-by: Yifan Zong <yzong@redhat.com>
This commit is contained in:
@@ -454,6 +454,7 @@ async def test_streaming(client: OpenAI, model_name: str, background: bool):
|
||||
if event.type == "response.output_item.added":
|
||||
assert event.item.id != current_item_id
|
||||
current_item_id = event.item.id
|
||||
current_content_index = -1
|
||||
elif event.type in [
|
||||
"response.output_text.delta",
|
||||
"response.reasoning_text.delta",
|
||||
@@ -465,7 +466,7 @@ async def test_streaming(client: OpenAI, model_name: str, background: bool):
|
||||
"response.content_part.added",
|
||||
"response.reasoning_part.added",
|
||||
]:
|
||||
assert event.content_index != current_content_index
|
||||
assert event.content_index == current_content_index + 1
|
||||
current_content_index = event.content_index
|
||||
elif event.type in [
|
||||
"response.output_text.delta",
|
||||
|
||||
Reference in New Issue
Block a user