Skip to main content

pyspoor

Typed Python adapter for spoor-core.

from spoor import parse_path

result = parse_path("report.pdf")
print(result.content.value.markdown)
for warning in result.warnings:
    print(warning["code"], warning.get("location"))

Agents must inspect result.warnings; a successful parse can still report a missing PDF text layer, suspicious text, merged-table degradation, or omitted visuals.

Tables: narrowing and pagination

For CSV/XLSX, parse_bytes / parse_path accept the same narrowing options as the CLI, so callers can page through full tables instead of the default 100-row preview:

from spoor import parse_bytes

# A slice by inclusive 1-based row range (mutually exclusive with limit/offset)
parse_bytes(data, source_name="data.xlsx", sheet="Sheet1", rows=(5, 104))

# Or paginate by limit/offset and keep only some columns
parse_bytes(data, source_name="data.xlsx", columns=["分类", "金额"], limit=100, offset=200)

PDFs: page ranges

For page-oriented PDFs, pass pages (inclusive 1-based) to parse only a slice and avoid reading a large document end to end:

parse_path("report.pdf", pages=(1, 3))  # only pages 1–3

Extracting embedded media

Resolve a safe media URI emitted in the output (DOCX images, extractable PDF images) to raw bytes for handing to an external vision model:

from spoor import extract_media

image = extract_media(data, "spoor://docx/part/word/media/image1.png", source_name="report.docx")

Build locally with maturin develop.

Metadata

Release files for pyspoor 0.11.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distributions (wheels)

Table of built distributions (wheels) for pyspoor 0.11.0
File
pyspoor-0.11.0-cp39-abi3-win_amd64.whl CPython 3.9 abi3 Windows x86-64 Details
pyspoor-0.11.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.9 abi3 Linux glibc 2.17+ x86-64 Details
pyspoor-0.11.0-cp39-abi3-macosx_11_0_arm64.whl CPython 3.9 abi3 macOS 11.0+ ARM64 Details
pyspoor-0.11.0-cp39-abi3-macosx_10_12_x86_64.whl CPython 3.9 abi3 macOS 10.12+ x86-64 Details

Total release size: 6.4 MB

Release files / pyspoor-0.11.0-cp39-abi3-win_amd64.whl

Download URL pyspoor-0.11.0-cp39-abi3-win_amd64.whl
Size 1.6 MB
Tags CPython 3.9 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
0510b4f8213e15ab5fd3e713f24740389a77ce9a7f68b0733a4dd2e09c1a9af9
BLAKE2b-256 checksum
How to use checksums
2de29dd94c3cf89bc967e30822f798a1add8ed4821e69d241de1acacc48b802e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jul 12, 2026.

Transparency log

Release files / pyspoor-0.11.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL pyspoor-0.11.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 1.7 MB
Tags CPython 3.9 Linux glibc 2.17+ x86-64 abi3
SHA-256 checksum
How to use checksums
2ffa8830a32abc92daa96c673e88464e607f32a1b7576a4c15d75f4e4832390e
BLAKE2b-256 checksum
How to use checksums
53cc0a8c205040fad54088cb29ee60d954ddbd98b1f261e5db70e05571f9e5c3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jul 12, 2026.

Transparency log

Release files / pyspoor-0.11.0-cp39-abi3-macosx_11_0_arm64.whl

Download URL pyspoor-0.11.0-cp39-abi3-macosx_11_0_arm64.whl
Size 1.6 MB
Tags CPython 3.9 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
9dbc66a7ebf035d319038eb0f4e4084a0721d8e310a6400b90740879162bbf44
BLAKE2b-256 checksum
How to use checksums
ae1f99531c3bccbaf8d805f18c44e190458ce3fb6fc421426c2b3b71483d051a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jul 12, 2026.

Transparency log

Release files / pyspoor-0.11.0-cp39-abi3-macosx_10_12_x86_64.whl

Download URL pyspoor-0.11.0-cp39-abi3-macosx_10_12_x86_64.whl
Size 1.6 MB
Tags CPython 3.9 abi3 macOS 10.12+ x86-64
SHA-256 checksum
How to use checksums
b1132a62396344170175fbb14b951a904405723db7c43b9187984755bf5d7db7
BLAKE2b-256 checksum
How to use checksums
fefba6cc0a70eed99c17c12d8d028b5aff7162d3adc8f5d280de8960fea472cb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jul 12, 2026.

Transparency log

Release history Release notifications | RSS feed

0.14.0

4 release files

0.13.0

4 release files

0.12.0

4 release files

This release

0.11.0 This release

4 release files

0.10.0

4 release files

0.9.1

4 release files

0.8.20

4 release files

0.8.18

4 release files

0.8.17

4 release files

0.8.16

4 release files

0.8.15

4 release files

0.8.14

4 release files

0.8.13

4 release files

0.8.12

4 release files

0.8.11

4 release files

0.8.10

4 release files

0.8.9

4 release files

0.8.8

4 release files

0.8.7

4 release files

0.8.6

4 release files

0.8.5

4 release files

0.8.4

4 release files

0.8.2

4 release files

0.8.0

4 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page