Add StructuredInputItem; patch version bump to 1.6.4#125
Merged
Conversation
5b877ce to
d8ac929
Compare
d8ac929 to
8b263fa
Compare
jiwon-oai
commented
May 13, 2026
Comment on lines
+556
to
+568
| if event.type == "tool_call_item": | ||
| raw_item = event.raw_item | ||
| if isinstance(raw_item, dict): | ||
| if raw_item.get("type") == "function_call": | ||
| current_tool_call = event.call_id | ||
| current_item_id = raw_item.get("id") | ||
| assert current_item_id | ||
| produced_items.add(current_item_id) | ||
| elif raw_item.type == "function_call": | ||
| current_tool_call = event.call_id | ||
| current_item_id = raw_item.id | ||
| assert current_item_id | ||
| produced_items.add(current_item_id) |
Collaborator
Author
There was a problem hiding this comment.
Newer versions of openai-agents allow the raw item to be a dict, so handling that here (pyright caught it).
jiwon-oai
commented
May 13, 2026
| [project] | ||
| name = "openai-chatkit" | ||
| version = "1.6.3" | ||
| version = "1.6.4" |
Collaborator
Author
There was a problem hiding this comment.
Patch version bump according to chatkit-python release rules, since this is a backwards-compatible change.
jiwon-oai
commented
May 13, 2026
| """Structured input answered by choosing one or more options.""" | ||
|
|
||
| type: Literal["multiple_choice"] = "multiple_choice" | ||
| options: list[str] |
Collaborator
Author
There was a problem hiding this comment.
@weedon-openai should we preemptively make these options typed objects instead of str to future-proof per-option additions such as icons, whether it's recommended, tooltips?
weedon-openai
approved these changes
May 14, 2026
| current_item_id = event.raw_item.id | ||
| assert current_item_id | ||
| produced_items.add(current_item_id) | ||
| if event.type == "tool_call_item": |
Collaborator
Author
There was a problem hiding this comment.
Newer versions of openai-agents allow the raw item to be a dict, so handling that here (pyright caught it)!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
StructuredInputItemthreads.add_structured_inputScreenshot of updated docs:
Screen recording of local chatkit studio:
Screen.Recording.2026-05-13.at.1.32.26.PM.mov