feat(api): Add gpt-5.5 model and tool name/namespace fields - #326
Conversation
Castiron-Internal-PR: openai/openai-ruby-internal#12 Castiron-Source-SHA: 7061898c8ce360d8688f132bbd0f165a71c112df Castiron-Public-Base-SHA: f53b245
There was a problem hiding this comment.
Pull request overview
This PR updates the Ruby SDK’s Responses/Conversations models and typing artifacts (RBS/RBI) to align with updated OpenAPI definitions, including new fields on function tool call outputs and refreshed model enums.
Changes:
- Add
nameandnamespaceto function call output items across Responses, Conversations, and beta variants (models + tests). - Expand model enum/type lists to include
:"gpt-5.5"across chat/responses request/response typing surfaces. - Add generated OpenAPI transformed reference tracking artifacts (
api_reference/.gitattributes,.castiron.stats.yml).
Reviewed changes
Copilot reviewed 25 out of 36 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| test/openai/resources/responses/input_items_test.rb | Updates pattern assertions for new name/namespace fields on function call outputs. |
| test/openai/resources/conversations/items_test.rb | Updates pattern assertions for new name/namespace fields on function call outputs. |
| test/openai/resources/beta/responses/input_items_test.rb | Updates beta pattern assertions for new name/namespace fields. |
| sig/openai/models/responses/response_input_item.rbs | Adds name/namespace to response input item function call output typing. |
| sig/openai/models/responses/response_function_tool_call_output_item.rbs | Adds name/namespace typing for function tool call output item. |
| sig/openai/models/responses/response_compact_params.rbs | Adds :"gpt-5.5" to compact params model type. |
| sig/openai/models/chat_model.rbs | Adds :"gpt-5.5" to ChatModel type. |
| sig/openai/models/beta/response_create_params.rbs | Adds :"gpt-5.5" to beta response create params model type. |
| sig/openai/models/beta/response_compact_params.rbs | Adds :"gpt-5.5" to beta compact params model type. |
| sig/openai/models/beta/beta_responses_client_event.rbs | Adds :"gpt-5.5" to beta client event model typing. |
| sig/openai/models/beta/beta_response.rbs | Adds :"gpt-5.5" to beta response model typing. |
| sig/openai/models/beta/beta_response_input_item.rbs | Adds name/namespace to beta response input item function call output typing. |
| sig/openai/models/beta/beta_response_function_tool_call_output_item.rbs | Adds name/namespace typing for beta function tool call output item. |
| rbi/openai/models/responses/response_input_item.rbi | Adds name/namespace accessors and Sorbet types for response input items. |
| rbi/openai/models/responses/response_function_tool_call_output_item.rbi | Adds name/namespace accessors and Sorbet types for function tool call outputs. |
| rbi/openai/models/responses/response_compact_params.rbi | Adds Sorbet constant for GPT_5_5. |
| rbi/openai/models/chat_model.rbi | Adds Sorbet constant for GPT_5_5. |
| rbi/openai/models/beta/response_create_params.rbi | Adds Sorbet constant for beta GPT_5_5. |
| rbi/openai/models/beta/response_compact_params.rbi | Adds Sorbet constant for beta GPT_5_5. |
| rbi/openai/models/beta/beta_responses_client_event.rbi | Adds Sorbet constant for beta client event GPT_5_5. |
| rbi/openai/models/beta/beta_response.rbi | Adds Sorbet constant for beta response GPT_5_5. |
| rbi/openai/models/beta/beta_response_input_item.rbi | Adds name/namespace accessors and Sorbet types for beta response input items. |
| rbi/openai/models/beta/beta_response_function_tool_call_output_item.rbi | Adds name/namespace accessors and Sorbet types for beta function tool call outputs. |
| lib/openai/models/responses/response_input_item.rb | Adds optional name/namespace fields to response input item function call outputs. |
| lib/openai/models/responses/response_function_tool_call_output_item.rb | Adds optional name/namespace fields to function tool call output item model. |
| lib/openai/models/responses/response_compact_params.rb | Adds GPT_5_5 to compact params model variants/constants. |
| lib/openai/models/chat_model.rb | Adds GPT_5_5 constant to ChatModel. |
| lib/openai/models/beta/response_create_params.rb | Adds GPT_5_5 to beta response create params variants/constants. |
| lib/openai/models/beta/response_compact_params.rb | Adds GPT_5_5 to beta compact params variants/constants. |
| lib/openai/models/beta/beta_responses_client_event.rb | Adds GPT_5_5 to beta client event variants/constants. |
| lib/openai/models/beta/beta_response.rb | Adds GPT_5_5 to beta response variants/constants. |
| lib/openai/models/beta/beta_response_input_item.rb | Adds optional name/namespace fields to beta response input item function call outputs. |
| lib/openai/models/beta/beta_response_function_tool_call_output_item.rb | Adds optional name/namespace fields to beta function tool call output item model. |
| api_reference/.gitattributes | Configures git attributes for the transformed OpenAPI reference file. |
| .castiron.stats.yml | Adds generation metadata for the transformed OpenAPI/codegen sync. |
Files not reviewed (10)
- rbi/openai/models/beta/beta_response.rbi: File type not supported
- rbi/openai/models/beta/beta_response_function_tool_call_output_item.rbi: File type not supported
- rbi/openai/models/beta/beta_response_input_item.rbi: File type not supported
- rbi/openai/models/beta/beta_responses_client_event.rbi: File type not supported
- rbi/openai/models/beta/response_compact_params.rbi: File type not supported
- rbi/openai/models/beta/response_create_params.rbi: File type not supported
- rbi/openai/models/chat_model.rbi: File type not supported
- rbi/openai/models/responses/response_compact_params.rbi: File type not supported
- rbi/openai/models/responses/response_function_tool_call_output_item.rbi: File type not supported
- rbi/openai/models/responses/response_input_item.rbi: File type not supported
Suppressed comments (4)
sig/openai/models/responses/response_function_tool_call_output_item.rbs:63
to_hashis typed as returningcreated_by,name, andnamespaceas non-nilString, but these fields are nilable on the model. Update the return type to reflect possiblenilvalues.
rbi/openai/models/responses/response_function_tool_call_output_item.rbi:137to_hashreturn type markscreated_by,name, andnamespaceas non-nilString, but these fields are modeled asT.nilable(String)and can be missing/unset. Adjust the return type to avoid incorrect typing.
rbi/openai/models/beta/beta_response_function_tool_call_output_item.rbi:170to_hashreturn type markscreated_by,name, andnamespaceas non-nilString, but these fields are modeled asT.nilable(String)and can be missing/unset. Adjust the return type to avoid incorrect typing.
sig/openai/models/beta/beta_response_function_tool_call_output_item.rbs:70to_hashis typed as returningcreated_by,name, andnamespaceas non-nilString, but these fields are nilable on the model. Update the return type to reflect possiblenilvalues.
created_by: String,
name: String,
namespace: String
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| created_by: String, | ||
| name: String, | ||
| namespace: String |
| created_by: String, | ||
| name: String, | ||
| namespace: String |
| created_by: String, | ||
| name: String, | ||
| namespace: String, |
| created_by: String, | ||
| name: String, | ||
| namespace: String, |
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 25 out of 36 changed files in this pull request and generated no new comments.
Files not reviewed (10)
- rbi/openai/models/beta/beta_response.rbi: File type not supported
- rbi/openai/models/beta/beta_response_function_tool_call_output_item.rbi: File type not supported
- rbi/openai/models/beta/beta_response_input_item.rbi: File type not supported
- rbi/openai/models/beta/beta_responses_client_event.rbi: File type not supported
- rbi/openai/models/beta/response_compact_params.rbi: File type not supported
- rbi/openai/models/beta/response_create_params.rbi: File type not supported
- rbi/openai/models/chat_model.rbi: File type not supported
- rbi/openai/models/responses/response_compact_params.rbi: File type not supported
- rbi/openai/models/responses/response_function_tool_call_output_item.rbi: File type not supported
- rbi/openai/models/responses/response_input_item.rbi: File type not supported
Suppressed comments (6)
sig/openai/models/responses/response_function_tool_call_output_item.rbs:63
to_hashis declared to always return non-nilcreated_by,name, andnamespace, but these are optional fields and may be absent/unset at runtime. The return type should allownilfor these values to avoid misleading type guarantees.
sig/openai/models/responses/response_function_tool_call_output_item.rbs:14- In the RBS record type
response_function_tool_call_output_item, the newly addednameandnamespace(and existingcreated_by) are typed as required non-nilString, but the Ruby model exposes them as optional fields (they can be absent and read back asnil). This makes the public type stricter than runtime behavior and contradicts the tests that treat these fields as nilable.
sig/openai/models/beta/beta_response_function_tool_call_output_item.rbs:17 - In the RBS record type
beta_response_function_tool_call_output_item, the newly addednameandnamespace(and existingcreated_by) are typed as required non-nilString, but these are optional fields on the Ruby model and can read back asnilwhen absent. This makes the public type stricter than runtime behavior.
caller_: OpenAI::Models::Beta::BetaResponseFunctionToolCallOutputItem::caller_?,
created_by: String,
name: String,
namespace: String
sig/openai/models/beta/beta_response_function_tool_call_output_item.rbs:70
to_hashis declared to always return non-nilcreated_by,name, andnamespace, but these fields are optional and may be absent/unset at runtime. The return type should allownilfor these values.
caller_: OpenAI::Models::Beta::BetaResponseFunctionToolCallOutputItem::caller_?,
created_by: String,
name: String,
namespace: String
rbi/openai/models/responses/response_function_tool_call_output_item.rbi:137
- The
to_hashreturn type markscreated_by,name, andnamespaceas non-nilString, but these fields are optional on the model and may be absent/unset (so accessing them from the returned hash can yieldnil). This should be reflected in the RBI return type.
rbi/openai/models/beta/beta_response_function_tool_call_output_item.rbi:170 - The
to_hashreturn type markscreated_by,name, andnamespaceas non-nilString, but these are optional fields and may be absent/unset at runtime (so reading them from the returned hash can yieldnil). Update the RBI return type to be nilable.
Automated Release PR --- ## [0.77.0](v0.76.0...v0.77.0) (2026-08-03) ### Features * **api:** promote Ruby SDK changes ([#326](#326)) ([d46c2e3](d46c2e3)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Summary
Introduce the gpt-5.5 model variant to public model enums and add optional name and namespace fields to function tool call input/output item models (beta and stable). Update constructors and type signatures to accept these new optional fields. These are additive, backward-compatible API changes.
Changes
Internal pull request: https://github.com/openai/openai-ruby-internal/pull/12
Validation