kilo_verify_worktree
Runs lint, test, and build checks in a working directory or worktree, then returns a compact pass/fail verdict with git state and output tails for failed checks to save context.
Instructions
Run a structured verification gate on a working directory or worktree.
Executes a sequence of verification commands (lint, test, build) and returns a compact structured verdict with git head/dirty state and output tails for failed checks only, minimizing context window waste.
SECURITY NOTE: This tool executes arbitrary shell commands provided by the caller or read from project configuration.
Commands are taken from the explicit commands list, or, when omitted,
from the [verify] table in a project-local kilo-mcp.toml or .kilo-mcp.toml
at the root of working_directory (e.g. commands = ["pytest", "ruff check ."]).
If neither is found, returns an error explaining both options.
Each command runs sequentially with cwd=working_directory via the shell.
If a command exceeds timeout_seconds, its entire process group is killed.
All commands are run regardless of individual failures.
Returns a JSON string: { "ok": bool, "working_directory": str, "head": str | null, "dirty": bool, "checks": [ { "command": str, "exit_code": int | null, "passed": bool, "duration_s": float, "timed_out": bool, "output_tail": str } ] }
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": {
"working_directory": "<working_directory>"
},
"name": "kilo_verify_worktree"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| commands | No | Optional list of shell commands to execute sequentially. If omitted, commands are read from the [verify] table in kilo-mcp.toml or .kilo-mcp.toml at the root of working_directory. | |
| tail_lines | No | Number of output tail lines to capture for failed checks (1..500, default 40). | |
| timeout_seconds | No | Maximum execution time in seconds per command (1..3600, default 600). | |
| working_directory | Yes | Path to the repository or worktree to verify. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |