fix(openai): support acknowledged safety checks in computer use (#31984)

This commit is contained in:
ccurme
2025-07-14 06:33:37 -04:00
committed by GitHub
parent a5f1774b76
commit de13f6ae4f
2 changed files with 78 additions and 0 deletions

View File

@@ -3452,6 +3452,10 @@ def _make_computer_call_output_from_message(message: ToolMessage) -> dict:
# string, assume image_url
output = {"type": "input_image", "image_url": message.content}
computer_call_output["output"] = output
if "acknowledged_safety_checks" in message.additional_kwargs:
computer_call_output["acknowledged_safety_checks"] = message.additional_kwargs[
"acknowledged_safety_checks"
]
return computer_call_output