You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The protocol currently supports making requests to an agent service. However, some agents may need to be able to communicate with the user in order to function optimally. For example:
User: please buy me a new set of cutting boards
AI: would you like wooden or plastic cutting boards?
User: I like wood
AI:searches for wooden cutting boards and places an order on Amazon
Adding a way for agents to prompt the user would greatly increase the versatility of the protocol imo.
Proposal
Two primary options:
Extension of the protocol with a status awaiting_input, and a way to resolve this status with additional input for an existing task or step
Extension of the task endpoint with a callback (or similar) attribute through which a client can specify a callback URL which may be polled with prompts for the user until they are resolved.
Example:
Giving the agent a task
POST /agent/tasks
{
"input": "Please find a nice olive wood cutting board on Amazon and order it for me.",
"callback_url": "https://my-service.url/agents/203820/callbacks"
}
The agent wants more info
POST https://my-service.url/agents/203820/callbacks
{
"prompt": "What is your budget for this purchase?"
}
{
"prompt_id": 123,
"status": "resolved",
"answer": "I don't want to spend more than €40 on this purchase",
"created": "2023-08-23T13:49:51.141Z",
"last_updated": "2023-08-23T13:53:12.634Z",
}
The protocol currently supports making requests to an agent service. However, some agents may need to be able to communicate with the user in order to function optimally. For example:
Adding a way for agents to prompt the user would greatly increase the versatility of the protocol imo.
Proposal
Two primary options:
Extension of the protocol with a status
awaiting_input
, and a way to resolve this status with additional input for an existing task or stepExtension of the
task
endpoint with acallback
(or similar) attribute through which a client can specify a callback URL which may be polled with prompts for the user until they are resolved.Example:
Responses:
Alternatives
GET /agent/tasks/<task_id>/chats
List chats regarding task
<task_id>
POST /agent/tasks/<task_id>/chats
Start a new chat regarding task
<task_id>
POST /agent/tasks/<task_id>/chats/<chat_id>/messages
Post a new message in an existing chat
GET /agent/tasks/<task_id>/chats/<chat_id>/messages
Get all messages in a chat
POST /agent/tasks/<task_id>/chats/<chat_id>/close
Close/resolve a chat
The text was updated successfully, but these errors were encountered: