extract_text_with_positions
Extract text from PDFs with position, font, and style details to support layout-aware analysis and inspection.
Instructions
Extract text items with position, font, and style metadata.
Returns a list of TextItem objects each with: text, x, y, width, height, font, font_size, page, is_bold, is_italic, is_underline, is_strikeout, item_type.
Args: path: Absolute path to a PDF file on the local filesystem. data: Base64-encoded PDF bytes. pages: Optional list of 0-indexed page numbers to extract.
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": "extract_text_with_positions"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| data | No | ||
| path | No | ||
| pages | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |