remove usermessages

This commit is contained in:
Xi Yan 2025-02-20 15:26:37 -08:00
parent afee71604f
commit 5644d10c82
4 changed files with 8 additions and 27 deletions

View file

@ -3954,23 +3954,16 @@
"ContinueAgentTurnRequest": { "ContinueAgentTurnRequest": {
"type": "object", "type": "object",
"properties": { "properties": {
"new_messages": { "tool_responses": {
"type": "array", "type": "array",
"items": { "items": {
"oneOf": [
{
"$ref": "#/components/schemas/UserMessage"
},
{
"$ref": "#/components/schemas/ToolResponseMessage" "$ref": "#/components/schemas/ToolResponseMessage"
} }
]
}
} }
}, },
"additionalProperties": false, "additionalProperties": false,
"required": [ "required": [
"new_messages" "tool_responses"
], ],
"title": "ContinueAgentTurnRequest" "title": "ContinueAgentTurnRequest"
}, },

View file

@ -2573,15 +2573,13 @@ components:
ContinueAgentTurnRequest: ContinueAgentTurnRequest:
type: object type: object
properties: properties:
new_messages: tool_responses:
type: array type: array
items: items:
oneOf: $ref: '#/components/schemas/ToolResponseMessage'
- $ref: '#/components/schemas/UserMessage'
- $ref: '#/components/schemas/ToolResponseMessage'
additionalProperties: false additionalProperties: false
required: required:
- new_messages - tool_responses
title: ContinueAgentTurnRequest title: ContinueAgentTurnRequest
InferenceStep: InferenceStep:
type: object type: object

View file

@ -354,12 +354,7 @@ class Agents(Protocol):
agent_id: str, agent_id: str,
session_id: str, session_id: str,
turn_id: str, turn_id: str,
new_messages: List[ tool_responses: List[ToolResponseMessage],
Union[
UserMessage,
ToolResponseMessage,
]
],
) -> Union[Turn, AsyncIterator[AgentTurnResponseStreamChunk]]: ... ) -> Union[Turn, AsyncIterator[AgentTurnResponseStreamChunk]]: ...
@webmethod( @webmethod(

View file

@ -174,12 +174,7 @@ class MetaReferenceAgentsImpl(Agents):
agent_id: str, agent_id: str,
session_id: str, session_id: str,
turn_id: str, turn_id: str,
new_messages: List[ tool_responses: List[ToolResponseMessage],
Union[
UserMessage,
ToolResponseMessage,
]
],
) -> AsyncGenerator: ) -> AsyncGenerator:
pass pass