compare_files
Compare two files and view differences in unified, side-by-side, inline, or context formats. Customize with context lines, ignore whitespace, word-level diff, and custom labels.
Instructions
Compare two files and show differences with multiple format options
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": {
"file1": "<file1>",
"file2": "<file2>"
},
"name": "compare_files"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file1 | Yes | First file path | |
| file2 | Yes | Second file path | |
| format | No | Diff format | |
| contextLines | No | Number of context lines (default: 3) | |
| ignoreWhitespace | No | Ignore whitespace changes | |
| wordDiff | No | Show word-level differences | |
| label1 | No | Label for first file | |
| label2 | No | Label for second file |