line_edit
Edit specific lines in files by number or range using replace, delete, or insert actions for targeted modifications without full file replacement.
Instructions
Edit specific lines by number or range
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": {
"file": "<file>",
"action": "<action>"
},
"name": "line_edit"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file | Yes | File to edit | |
| lineNumber | No | Line number to edit (1-based) | |
| lineRange | No | Line range (e.g., "10,20" or "5,$") | |
| action | Yes | Action to perform | |
| content | No | New content (for replace/insert actions) |