Metadata-Version: 2.5
Name: sirdas
Version: 0.3.0
Summary: Local document parsing for AI agents and ML: PDF, Word, Excel, PowerPoint, HTML, email and scans to Markdown, cited fields, chunks and datasets. Nothing is uploaded.
Project-URL: Homepage, https://sirdas.app
Project-URL: Documentation, https://sirdas.app/docs/agents/python.md
Author: Sırdaş
License-Expression: MIT
Keywords: ai-agents,anonymization,dataset,document-parsing,fine-tuning,langchain,llamaindex,llm,local-first,ocr,pdf,rag
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
Classifier: Topic :: Text Processing
Requires-Python: >=3.9
Provides-Extra: langchain
Requires-Dist: langchain-core>=0.2; extra == 'langchain'
Provides-Extra: llamaindex
Requires-Dist: llama-index-core>=0.10; extra == 'llamaindex'
Description-Content-Type: text/markdown

# sirdas (Python)

Local document parsing for AI agents and machine learning. PDF (including scans), Word, Excel, PowerPoint, OpenDocument, EPUB, HTML, CSV, email and images become Markdown, **fields cited with page and position**, tables, form fields, cited chunks and training datasets. **Nothing is uploaded**: it runs on your machine.

```bash
pip install sirdas          # needs Node.js 20+ (the engine is shared with the CLI and MCP server)
```

```python
import sirdas

doc = sirdas.read("factura.pdf")                 # one call does it all
doc["document_type"]                             # "factura"
{f["name"]: f["value"] for f in doc["fields"]}   # número, CUFE, NIT, IVA, total… each with page, evidence and bbox
doc["next_steps"]                                # what to do next

sirdas.convert("informe.docx")["markdown"]
sirdas.split_documents("lote-escaneado.pdf", output_dir="separados/")
sirdas.forms("formulario.pdf")                   # filled fields and checkboxes
sirdas.dataset(["a.pdf", "b.docx"], "ds/", format="alpaca")   # + Hugging Face dataset card
```

LangChain and LlamaIndex:

```python
from sirdas.integrations import SirdasLoader, SirdasReader
docs = SirdasLoader("contrato.pdf").load()              # langchain Documents, stable ids
nodes = SirdasReader().load_data("historia.pdf")        # llama_index Documents
```

Personal data is anonymized by default (`anonymize=False` to keep it). Password-protected PDFs raise `PasswordRequired`; pass `password=`.

Docs: https://sirdas.app/docs/agents/python.md
