grok_session_ensure
Connect or create a Grok session for a Codex task and project path with a specific Git branch. Establishes the session without initiating coding.
Instructions
当任务涉及代码项目时,先调用此工具连接或创建当前 Codex 任务、项目路径和 Git 分支对应的 Grok 会话。它只建立会话,不会让 Grok 开始编码。
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": {
"codex_task_id": "<codex_task_id>",
"project_root": "<project_root>"
},
"name": "grok_session_ensure"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| branch | No | ||
| project_root | Yes | ||
| codex_task_id | Yes | ||
| open_observer | No | ||
| working_directory | No |