DSL reference
Options go in brackets after the source — att("report.pdf[pages: 1-4]") —
or as keyword arguments: att("report.pdf", pages="1-4").
This page is generated from the option schemas in the code itself
(the same data behind att.options(...) and
GET /v1/options), so it cannot drift.
.bmp .gif .heic .heif .jpeg .jpg .png .tif .tiff .webp
| option | type | default | what it does |
|---|---|---|---|
max_dim | int | — | Downscale so the longest side is at most this many pixels max_dim: 1024 |
rotate | int | — | Rotate counterclockwise by this many degrees (negative = clockwise) rotate: 90 |
ocr | bool_or_auto | False | Recognize text in the image with RapidOCR: true/false, or auto (only when rapidocr is installed) ocr: true |
ocr_engine | str | rapidocr | OCR engine: rapidocr (local, default) or lighton (remote LightOnOCR vLLM endpoint via ATTACHMENTS_LIGHTON_URL) ocr_engine: lighton |
.cfg .css .ini .java .js .json .log .markdown .md .py .rst .tex .toml .ts .txt .xml .yaml .yml __text__
No options — it just works.
.csv .tsv
| option | type | default | what it does |
|---|---|---|---|
rows (alias: max_rows, limit) | int | 200 | Maximum number of data rows rendered as text. rows: 100 |
summary | bool | False | Append a pandas-backed summary (shape, dtypes, numeric stats). summary: true |
delimiter (alias: sep) | str | — | Field delimiter: a literal character or tab/comma/semicolon/pipe. Overrides sniffing. delimiter: semicolon |
.docx
| option | type | default | what it does |
|---|---|---|---|
images (alias: render) | bool | False | Extract embedded images. images: true |
.flac .m4a .mp3 .ogg .opus .wav
| option | type | default | what it does |
|---|---|---|---|
model | str | base | Whisper model size: tiny, base, small, medium, or large-v3. model: small |
language | str | — | Spoken language code (e.g. 'en', 'fr'); omit to autodetect. language: en |
.htm .html
| option | type | default | what it does |
|---|---|---|---|
images (alias: render) | bool | False | Extract inline data-URI images. images: true |
select (alias: css) | str | — | CSS selector; extract only matching elements select: "h1, .article" |
.ipynb
| option | type | default | what it does |
|---|---|---|---|
outputs | bool | False | Include per-cell execution outputs: text outputs as fenced blocks (truncated at ~2000 chars each) and image/png outputs as image items. outputs: true |
.pdf
| option | type | default | what it does |
|---|---|---|---|
pages (alias: page) | pages | — | Pages to include: a 1-based page number or range. pages: 1-4 |
password (alias: pw) | str | — | Password for encrypted PDFs. password: secret |
images (alias: render) | bool_or_auto | auto | Render pages to PNG: true/false, or auto (only when no text). images: true |
dpi | int | 200 | Resolution for rendered page images. dpi: 300 |
ocr | bool_or_auto | auto | OCR scanned pages with RapidOCR when there is no text layer: true/false, or auto (only when rapidocr is installed). ocr: true |
ocr_engine | str | rapidocr | OCR engine: rapidocr (local, default) or lighton (remote LightOnOCR vLLM endpoint via ATTACHMENTS_LIGHTON_URL). ocr_engine: lighton |
max_pages | int | — | Hard cap on the number of pages parsed/rendered. max_pages: 10 |
.pptx
| option | type | default | what it does |
|---|---|---|---|
images (alias: render) | bool_or_auto | False | Extract embedded slide pictures: true/false ('auto'/'always' behave like true; slides are never rasterized). images: true |
.svg .svgz
| option | type | default | what it does |
|---|---|---|---|
images (alias: render) | bool_or_auto | False | Rasterize the SVG to PNG with cairosvg (true/false/auto/always). images: true |
.xls .xlsx
| option | type | default | what it does |
|---|---|---|---|
sheet | str_or_int | — | Sheet to render: a sheet name or 0-based index. Omit to render all sheets. sheet: Sales |
rows (alias: max_rows) | int | 200 | Maximum number of rows rendered as text per sheet. rows: 100 |