refactor_code
Refactor code based on an instruction while preserving external behavior. Provide code or file path to receive refactored output with a summary of changes.
Instructions
Refactor code according to an instruction, preserving external behavior.
Provide exactly one of code or file_path. Returns the full refactored
code plus a summary of changes; this tool does not write files itself --
use batch_refactor if you want changes applied to disk.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| code | No | ||
| think | No | ||
| file_path | No | ||
| instruction | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |