mirror of
https://github.com/openai/codex.git
synced 2026-10-19 17:28:46 +00:00
Add structured asynchronous user input requests (#42178)
## What changed - Replace `send_user_message_async` with `request_user_input_async`, accepting one or more questions with optional suggested answers while allowing the turn to continue. - Attach structured question metadata to asynchronous agent messages while retaining readable fallback text, and preserve it through app-server events, thread history, and generated schemas. - Continue enabling the new tool for model catalogs that advertise either the old or new tool name. ## Testing - Cover tool registration, question validation, emitted items, continued turn execution, history preservation, and backwards-compatible deserialization. GitOrigin-RevId: ffc49aebde2e854c3c50a122aa52805fec3fc6b3
This commit is contained in:
@@ -14,6 +14,27 @@
|
||||
"AgentPath": {
|
||||
"type": "string"
|
||||
},
|
||||
"AsyncUserInputQuestion": {
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"options": {
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"type": [
|
||||
"array",
|
||||
"null"
|
||||
]
|
||||
},
|
||||
"title": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"title"
|
||||
],
|
||||
"type": "object"
|
||||
},
|
||||
"ByteRange": {
|
||||
"properties": {
|
||||
"end": {
|
||||
@@ -1369,6 +1390,16 @@
|
||||
],
|
||||
"default": null
|
||||
},
|
||||
"questions": {
|
||||
"default": null,
|
||||
"items": {
|
||||
"$ref": "#/definitions/AsyncUserInputQuestion"
|
||||
},
|
||||
"type": [
|
||||
"array",
|
||||
"null"
|
||||
]
|
||||
},
|
||||
"text": {
|
||||
"type": "string"
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user