pdf_compare
Compare two PDFs page by page to detect text differences. Reports identical pages and trimmed diffs for same-layout documents.
Instructions
Compare two PDFs page by page (by absolute page index) and report text differences. Returns identical:true when text matches. Diffs content-stream-order text (not visual reading order), so it is best for same-layout documents; reflowed or multi-column PDFs produce noisy diffs. Inserting/deleting a page shifts all later pages and reports them as changed. Large diffs are trimmed (truncated:true) to fit the response limit.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| filePathA | Yes | Absolute path to the first (baseline) PDF file | |
| filePathB | Yes | Absolute path to the second (comparison) PDF file | |
| pages | No | Page range to compare, e.g. '1-5' or '1,3,5'. Defaults to all pages. |