library/pdf-inspector
v0.1.0 SignedClassify PDFs and extract text and Markdown without OCR
Install
act pull actpkg.dev/library/pdf-inspector Capabilities
Moderate host access
Requests: Filesystem read-only.
- wasi:filesystem Filesystem read-only
** (ro)
Tools · 4
act:tools interface — expand a tool for its input schema.
to_markdown Convert a PDF to Markdown, preserving headings, lists and tables. Returns the detected PDF type alongside the Markdown — check `pages_needing_ocr` and `has_encoding_issues` to know whether the text is trustworthy.
Convert a PDF to Markdown, preserving headings, lists and tables. Returns the detected PDF type alongside the Markdown — check `pages_needing_ocr` and `has_encoding_issues` to know whether the text is trustworthy.
Parameter Type Description data object | null Inline PDF bytes, as a CBOR byte string — or the canonical `{"$bytes": "<base64>"}` envelope over JSON transports. path string | null Path to a PDF file on the host. Requires a `wasi:filesystem` read grant covering this path. pages array | null 1-indexed page numbers to extract. Omit to extract every page. profile variant `fidelity` (default) stays close to the source; `compact` emits fewer tokens. password string | null Password for an encrypted PDF. include_images boolean | null Include image placeholders in the Markdown. include_page_markers boolean | null Insert `<!-- Page N -->` markers between pages. Returns content.
detect Detect whether a PDF is text-based or scanned, with page count, title and layout complexity. Does not extract text, so it is much cheaper than to_markdown.
Detect whether a PDF is text-based or scanned, with page count, title and layout complexity. Does not extract text, so it is much cheaper than to_markdown.
Parameter Type Description data object | null Inline PDF bytes, as a CBOR byte string — or the canonical `{"$bytes": "<base64>"}` envelope over JSON transports. path string | null Path to a PDF file on the host. Requires a `wasi:filesystem` read grant covering this path. password string | null Password for an encrypted PDF. Returns content.
classify Cheaply classify a PDF (typically 10-50ms): type, page count, which pages need OCR, and confidence. Call this before to_markdown to avoid spending tokens on a scanned document.
Cheaply classify a PDF (typically 10-50ms): type, page count, which pages need OCR, and confidence. Call this before to_markdown to avoid spending tokens on a scanned document.
Parameter Type Description data object | null Inline PDF bytes, as a CBOR byte string — or the canonical `{"$bytes": "<base64>"}` envelope over JSON transports. path string | null Path to a PDF file on the host. Requires a `wasi:filesystem` read grant covering this path. Returns content.
extract_text Extract plain text from a PDF with no Markdown formatting, one line per detected text line.
Extract plain text from a PDF with no Markdown formatting, one line per detected text line.
Parameter Type Description data object | null Inline PDF bytes, as a CBOR byte string — or the canonical `{"$bytes": "<base64>"}` envelope over JSON transports. path string | null Path to a PDF file on the host. Requires a `wasi:filesystem` read grant covering this path. Returns content.
Readme
No README provided.