Read a long document with Phở
read_documentRead a long document without loading it into the conversation. Phở downloads and reads the file on its servers (a PDF or Word file; scanned PDFs are read page by page), then returns a short map of it (page count, outline) and ONLY the pages that answer the question, each marked with its page number so you can cite it. Use it instead of pasting or attaching a long paper, book, report, guideline or thesis: a 150-page book is about 100,000 tokens, and this returns the few pages needed. source is an https link to a PDF or .docx, a DOI (read from an open-access copy only), an arXiv id or a PMC id. document_id is a document already in the user's Phở account (see list_documents), which is how a user's own uploaded file is read: they upload it on pho.chat once. Give question (what the user wants to know) or pages ("12-15, 40"). With neither, a short document comes back whole and a long one comes back as its map. Call again with another question or other pages as often as needed. Personal information (names, ID, phone and card numbers, emails, addresses, dates of birth) is hidden by default before the text leaves Phở, so it never reaches this conversation; published papers (DOI, arXiv, PMC) are not hidden. Pass redact: false only when the user asks to see their own document unhidden. Works without a sign-in for public files that carry their text; nothing is saved then. With a free Phở sign-in the document is kept in the user's account (deletable with delete_document), scanned PDFs can be read, and the user gets a link to continue on pho.chat. No model on Phở answers the question: you do, from the returned pages.
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_document"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| pages | No | Exact pages to return, e.g. "12-15, 40". Wins over question. | |
| redact | No | Hide personal information before the text leaves Phở. Default: on, off for published papers (DOI, arXiv, PMC). Set false only when the user asks. | |
| source | No | An https link to a PDF or .docx, a DOI (10.xxxx/…), an arXiv id (2401.01234) or a PMC id (PMC1234567). | |
| question | No | What the user wants to know from the document, in their words. Phở returns the pages that answer it. | |
| max_chars | No | Upper size of the returned text in characters (default 12,000, about 3,000 tokens). | |
| document_id | No | Instead of source: a document already in the user's Phở account. | |
| retry_unread | No | For a scanned PDF with pages that could not be read: read those pages again. | |
| wait_seconds | No | For a scanned PDF: wait up to this many seconds (0-45) for Phở to finish reading it. |