Skip to content

fix: pass structured output request params#2396

Open
he-yufeng wants to merge 1 commit into
strands-agents:mainfrom
he-yufeng:fix/openai-responses-structured-params
Open

fix: pass structured output request params#2396
he-yufeng wants to merge 1 commit into
strands-agents:mainfrom
he-yufeng:fix/openai-responses-structured-params

Conversation

@he-yufeng
Copy link
Copy Markdown
Contributor

Summary

  • make OpenAIResponsesModel.structured_output() reuse the full formatted Responses request
  • drop only the stream field before calling responses.parse()
  • cover params, instructions, store, and text_format forwarding in a regression test

Fixes #1908.

To verify

  • python -m pytest tests/strands/models/test_openai_responses.py::test_structured_output tests/strands/models/test_openai_responses.py::test_structured_output_forwards_request_params -q
  • python -m ruff check src/strands/models/openai_responses.py tests/strands/models/test_openai_responses.py
  • python -m ruff format --check src/strands/models/openai_responses.py tests/strands/models/test_openai_responses.py
  • git diff --check

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] OpenAIResponsesModel.structured_output() drops config params (temperature, reasoning, etc.)

1 participant