2 genuinely different descriptions of this tool
Plain text · sha256 80fb15d2d15c
The description, line by line
9 lines Line numbers are v2.1.278 on the left and this capture on the right.
1
Reads a file from the local filesystem. You can access any file directly by using this tool.
2
Assume this tool is able to read all files on the machine. If the User provides a path to a file assume that path is valid. It is okay to read a file that does not exist; an error will be returned.
1
Reads a file from the local filesystem.
3
2
4
Usage:
5
- The file_path parameter must be an absolute path, not a relative path
6
- By default, it reads up to 2000 lines starting from the beginning of the file
3
- `file_path` must be an absolute path.
4
- Reads up to 2000 lines by default.
7
5
- When you already know which part of the file you need, only read that part. This can be important for larger files.
8
6
- Results are returned using cat -n format, with line numbers starting at 1
9
- This tool allows Claude Code to read images (eg PNG, JPG, etc). When reading an image file the contents are presented visually as Claude Code is a multimodal LLM.
10
- This tool can read PDF files (.pdf). For large PDFs (more than 10 pages), you MUST provide the pages parameter to read specific page ranges (e.g., pages: "1-5"). Reading a large PDF without the pages parameter will fail. Maximum 20 pages per request.
11
- This tool can read Jupyter notebooks (.ipynb files) and returns all cells with their outputs, combining code, text, and visualizations.
12
- This tool can only read files, not directories. To list files in a directory, use the registered shell tool.
13
- You will regularly be asked to read screenshots. If the user provides a path to a screenshot, ALWAYS use this tool to view the file at the path. This tool will work with all temporary file paths.
14
- If you read a file that exists but has empty contents you will receive a system reminder warning in place of file contents.
7
- Reads images (PNG, JPG, …) and presents them visually. Reads PDFs via the `pages` parameter (e.g. "1-5", max 20 pages/request; required for PDFs over 10 pages). Reads Jupyter notebooks (.ipynb) as cells with outputs.
8
- Reading a directory, a missing file, or an empty file returns an error or system reminder rather than content.
15
9
- Do NOT re-read a file you just edited to verify — Edit/Write would have errored if the change failed, and the harness tracks file state for you.
What it accepts
4 parameters The JSON parameter schema sent beside this description, 851 characters of it. Name, type, then whether the client marked it required.file_path
string
required
The absolute path to the file to read
limit
integer
optional
The number of lines to read. Only provide if the file is too large to read at once.
offset
integer
optional
The line number to start reading from. Only provide if the file is too large to read at once
pages
string
optional
Page range for PDF files (e.g., "1-5", "3", "10-20"). Only applicable to PDF files. Maximum 20 pages per request.
sha256 012b3f1d0393 · the schema as the client sent it:
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false,
"properties": {
"file_path": {
"description": "The absolute path to the file to read",
"type": "string"
},
"limit": {
"description": "The number of lines to read. Only provide if the file is too large to read at once.",
"exclusiveMinimum": 0,
"maximum": 9007199254740991,
"type": "integer"
},
"offset": {
"description": "The line number to start reading from. Only provide if the file is too large to read at once",
"maximum": 9007199254740991,
"minimum": 0,
"type": "integer"
},
"pages": {
"description": "Page range for PDF files (e.g., \"1-5\", \"3\", \"10-20\"). Only applicable to PDF files. Maximum 20 pages per request.",
"type": "string"
}
},
"required": [
"file_path"
],
"type": "object"
}