render_pdf_smart
Extract text from prose pages and render only figure or diagram pages as images, returning interleaved text and image blocks to cut token usage when reading PDFs.
Instructions
Smart PDF rendering: extracts text from prose pages and renders only pages with figures/diagrams as images. Far more token-efficient than rendering every page. Returns interleaved text and image content blocks.
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": {
"path": "<path>"
},
"name": "render_pdf_smart"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| dpi | No | Resolution for rendered pages | |
| mode | No | hybrid: text for prose, images for figures (default). render: rasterize every page. text: extract text only. | hybrid |
| path | Yes | Absolute path to the PDF file | |
| pages | No | Page range: "all", single page "3", or range "1-5" (1-indexed) | all |