Skip to main content

srx-lib-docs

Small helpers to extract plain text from common office document formats used by SRX services.

What it includes:

  • extract_text(path_or_bytes, mime_type=None) supports PDF, DOCX, PPTX, XLSX
  • DocumentMarkdownConverter to download and convert PDF/DOCX/PPTX/XLSX to Markdown

Install

PyPI (public):

  • pip install srx-lib-docs

uv (pyproject):

[project]
dependencies = ["srx-lib-docs>=0.1.0"]

Usage

from srx_lib_docs import extract_text
text = extract_text("/path/to/file.pdf")

Markdown conversion with download:

from srx_lib_docs.markdown import DocumentMarkdownConverter

conv = DocumentMarkdownConverter()
result = await conv.process_document(url, mimetype="application/pdf")
print(result["markdown_content"])  # plus file_type, file_size, success

Notes

  • For XLSX, the first 20 rows of each sheet are read to keep it lightweight; adjust in code if needed.

License

Proprietary © SRX

Metadata

Release files for srx-lib-docs 0.1.7

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

Source distribution (sdist)

Source distribution for srx-lib-docs 0.1.7
File Size Uploaded
srx_lib_docs-0.1.7.tar.gz 5.6 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for srx-lib-docs 0.1.7
File Interpreter ABI Platform
srx_lib_docs-0.1.7-py3-none-any.whl Python 3 none any Details

Total release size: 12.5 kB

Release files / srx_lib_docs-0.1.7.tar.gz

Download URL srx_lib_docs-0.1.7.tar.gz
Size 5.6 kB
Tags Source
SHA-256 checksum
How to use checksums
f5b33a6af600fb98f932eb1e5cb0b2a38f096378705db26b0bc8bf547d2cdb4d
BLAKE2b-256 checksum
How to use checksums
d0c5a74b29e3c046cd1f44df2794ec3f42d263ac4d01df9e8ce07d740b393844
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.12

Release files / srx_lib_docs-0.1.7-py3-none-any.whl

Download URL srx_lib_docs-0.1.7-py3-none-any.whl
Size 6.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
832583a9e263de48b4c47a13d2979d4bc4280705d9526fefe2b9dc59f5ceb8fe
BLAKE2b-256 checksum
How to use checksums
6c394c3b818e5fd854d023c86485abf0b628b1c0f4f9550b7826f1dc2cbadea1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.12

Release history Release notifications | RSS feed

This release

0.1.7 This release

2 release files

0.1.6

2 release files

0.1.5

2 release files

0.1.4

2 release files

0.1.3

2 release files

0.1.2

2 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