grep
Search a file for lines containing a substring, returning each match with its line number.
Instructions
Return lines matching pattern in a single file, with line numbers.
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": {
"pattern": "<pattern>",
"file": "<file>"
},
"name": "grep"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file | Yes | Path of the file to search. | |
| pattern | Yes | Substring to search for. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |