Metadata-Version: 2.4
Name: betteria
Version: 0.1.1
Summary: A commandline tool to enhance PDFs from Internet Archive.
Requires-Python: >=3.9.0
Requires-Dist: img2pdf>=0.6.0
Requires-Dist: opencv-python>=4.11.0.86
Requires-Dist: pdf2image>=1.17.0
Requires-Dist: pillow>=11.2.1
Requires-Dist: tqdm>=4.67.1
Provides-Extra: dev
Requires-Dist: maturin; extra == 'dev'
Requires-Dist: pytest; extra == 'dev'
Requires-Dist: ruff; extra == 'dev'
Requires-Dist: twine; extra == 'dev'
Description-Content-Type: text/markdown

# betteria

A commandline tool to enhance PDFs from Internet Archive.

## Installation

```bash
pip install betteria
```

## Usage

```bash
betteria --help
```

    usage: betteria [-h] --input INPUT [--output OUTPUT] [--dpi DPI] [--threshold THRESHOLD] [--use_adaptive USE_ADAPTIVE] [--invert INVERT]

    Clean and compress a scanned PDF by whitening pages and saving as CCITT Group 4 TIFFs (via a manual page-by-page approach).

    options:
    -h, --help            show this help message and exit
    --input INPUT         Path to input PDF
    --output OUTPUT       Path to output PDF (default: output.pdf)
    --dpi DPI             DPI for rasterizing PDF pages
    --threshold THRESHOLD
                            Global threshold value
    --use_adaptive USE_ADAPTIVE
                            Set True to use adaptive thresholding instead of global
    --invert INVERT       Set True if pages are inverted (light text on dark background)

