session_start
Opens a keep-alive managed session on a remote connection for long-running or interactive tasks, auto-selecting tmux, pty-daemon, or setsid; use exec for plain queries.
Instructions
在任意连接(集群/服务器)上开一个保活托管会话。
后端自动选择:远端有 tmux → 交互会话(attach 可回);无 tmux → 部署 pty-daemon 静态守护(可 attach,远端零依赖);部署不可行且给了 command → setsid 后台保活(不可 attach,仅日志)。普通查询任务不要用 本工具,直接用 exec。
Args: connection: 连接 label purpose: 会话用途名(唯一标识,重复会报 exists 或复用) backend: 显式指定 tmux | pty-daemon | setsid(缺省自动) command: setsid 后端必填的后台命令
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": {
"connection": "<connection>",
"purpose": "<purpose>"
},
"name": "session_start"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| backend | No | ||
| command | No | ||
| purpose | Yes | ||
| connection | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||