record_session
Persist an entire chat history in one call: append all turns to the session and local JSON ledger, then warm the cache for immediate next load.
Instructions
Persist an ENTIRE chat history in one call.
turns is a list of {"user": "...", "assistant": "..."} dicts in
chronological order — pass every exchange you have. Each turn is
appended to the session (never overwriting prior turns), mirrored to the
local JSON ledger, and the chat cache is warmed at the end so the next
load is an immediate cached hit.
Prefer this over a flurry of record_turn calls when you have the
full conversation in context (e.g. when the user asks you to save the
whole chat).
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": {
"session_id": "<session_id>"
},
"name": "record_session"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| turns | No | ||
| session_id | Yes | ||
| project_root | No | ||
| user_peer_id | No | ||
| assistant_peer_id | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |