Warm-process MCP server for Rector. Keeps the Rector container bootstrapped across calls — ~9x faster per-file analysis vs cold CLI invocation. Compatible with any MCP client (Claude Desktop, Cline, Continue, Zed, custom).
Single tool 'rector_process' has a clear verb-noun name and solid description (89 chars). Input schema is present with two parameters (path, dryRun), both typed and described. However, output schema is only documented in the PHP docblock return type annotation, not in the MCP tool registration itself, LLMs cannot see this. The tool performs a destructive operation (file rewrites) but lacks explicit dry-run/confirmation guidance in the description. Security containment is well-implemented (path validation, working-dir pinning) but not surfaced in the tool description for the LLM. Error handling returns structured objects with error_class and trace fields, which is good, but lacks actionable recovery guidance (e.g., 'If warm_boot=true and error occurs, the container may be corrupted, retry with a fresh server instance').
Run Rector refactoring on a path. Server-pinned config.
Output schema not visible in MCP tool registration. PHP docblock documents return type as array{exit_code: int, output: string, warm_boot: bool, error?: string, error_class?: string, trace?: string}, but this is not exposed to the MCP client. LLMs cannot plan downstream actions without knowing the response structure.
Destructive operation (file rewrites when dryRun=false) lacks explicit confirmation or dry-run guidance in tool description. Description says 'Run Rector refactoring' but does not emphasize that non-dry-run mode modifies files on disk. LLMs may not realize the irreversible consequences.
Error responses include technical details (error_class, trace) but lack actionable recovery guidance. When warm_boot=true and an error occurs (e.g., 'toMutatingScope on null'), the description should guide the LLM: 'Warm container may be corrupted. Retry with a fresh server instance or contact the operator.'
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-23 | D | 58 | 2025-06-18+ | v2 |
Path parameter description does not explain the containment boundary. It says 'Absolute path to file or directory under the server's working dir' but does not clarify that paths outside the working directory are rejected, or how to discover the working directory.
No tool annotation hints (readOnlyHint, destructiveHint, idempotentHint) present. The tool should be marked with destructiveHint=true when dryRun=false to signal to clients that this operation modifies state.