chat
Sends a message to the AI Brainstem and returns its answer as JSON, including session_id to continue the conversation; use wait=false for long tasks and poll job_status.
Instructions
Send one message to the AI Brainstem and return its answer as JSON: response, session_id, model, agent_logs (the agents it used). A failure is returned as a tool error with a plain explanation. Pass the returned session_id to continue the conversation. wait=false: for work that may take minutes. Returns {status: running, session_id} at once; poll job_status(session_id) for the answer. One message at a time per session.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"user_input": "<user_input>"
},
"name": "chat"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| wait | No | ||
| session_id | No | ||
| user_input | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |