read
Read web pages, local files and scholarly papers as Markdown, returning each item's content or error, and optionally answer one question across all items.
Instructions
Reads pages, files and papers — web pages, local documents and scholarly works, as Markdown. Call read{urls:["https://…"], files:["/path/to/file.pdf"], publications:["10.1038/nature14539"]}: 1–50 items, at most 20 publications. A title goes to search_literature first; a file wanted as bytes to download_file. Returns one text block per item, input order: === [n/N] {item}, the artifact's absolute path, a partial: or truncated: line when incomplete, then the content. A failed item is its header and an error: line; all failed = an error result. Add ask:"question" for one answer over every item, in a last === answer block.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "read"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ask | No | Optional question, answered once over every item read, after the item blocks; the items then show their size, not their content, unless include_content is true. | |
| urls | No | Web page URLs (http or https), each read as a page; a PDF or document URL is parsed. An identifier goes in publications, a local path in files. | |
| files | No | Local document paths (or file:// URLs) on this machine, each parsed to Markdown. A web URL goes in urls. Formats: PDF, DOC, DOCX, XLS, XLSX, PPTX (with their macro and template variants), ODT, ODS, ODP, RTF, EPUB, HTML, CSV, JSON, Markdown and plain text. | |
| model | No | With ask: the model that answers it, an alias (haiku, sonnet, opus, fable) or a model id; default haiku on claude, the configured ask model on codex. | |
| engine | No | With ask: the engine that answers it, claude (default) or codex. | |
| headers | No | Optional request headers (name → value) sent only to a url's own origin and a publication's landing origin, never with files; reader services, archives and resolver APIs never receive them. At most 32 headers, 8 KiB; no Host, Content-Length, Transfer-Encoding, Connection, Upgrade, TE, Trailer, Keep-Alive or Proxy-*. A caller header overrides the default of its name. | |
| refresh | No | Bypass the cache: read every item again and overwrite its cached artifact. | |
| ocr_language | No | Optional script for OCR of a scanned document: latin, zh, ja, ar, ru or he. By default the document's text layer, /Lang or metadata names it, else Latin; set it when a scan's gaps say it was read in Latin. Always a fresh read. | |
| publications | No | At most 20 works: a DOI, arXiv id, PMID, PMCID, ISBN, a search_literature handle, or a paper or book landing URL, each read as its full text. | |
| include_content | No | Default true. false: read and cache the full content, answering a size line in place of the body. |