Metadata-Version: 2.4
Name: aviconv-aip
Version: 1.0.0
Summary: Template-driven extraction of airports, runways, frequencies, and navaids from PDF AIPs into schema-valid AIXM 5.1.1.
Project-URL: Homepage, https://github.com/ams-dev25/aviconv
Project-URL: Documentation, https://ams-dev25.github.io/aviconv/
Project-URL: Source, https://github.com/ams-dev25/aviconv
Project-URL: Issues, https://github.com/ams-dev25/aviconv/issues
Author: aviconv contributors
License: MIT
Keywords: aip,airac,airport,aixm,aviation,icao,navaid,pdf,scraper
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Scientific/Engineering :: GIS
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Classifier: Typing :: Typed
Requires-Python: >=3.11
Requires-Dist: aviconv-aixm<0.5,>=0.4.0
Requires-Dist: aviconv-core<0.1,>=0.0.2
Requires-Dist: click>=8.1
Requires-Dist: pdfplumber>=0.11
Requires-Dist: pydantic>=2.7
Requires-Dist: pyyaml>=6.0
Provides-Extra: ocr
Requires-Dist: pytesseract>=0.3.10; extra == 'ocr'
Description-Content-Type: text/markdown

# aviconv-aip

Template-driven extraction of **airports, runways, radio frequencies, and
navaids** from a published **PDF AIP** into schema-valid **AIXM 5.1.1**.

Part of the [aviconv](https://github.com/ams-dev25/aviconv) converter family.
This is the v1.0 headline feature: most States publish their AIP only as PDF,
and nothing free turns those PDFs into structured AIXM.

## What it is — and is not

`aviconv-aip` is a **template-driven, human-in-the-loop** extractor, not a
magic button. PDF AIP extraction is heuristic — layouts vary between
publishers and OCR mis-reads. So the honest deliverable is:

- one **declarative template per AIP publisher** (adding a publisher means
  adding a YAML template, not changing extractor code);
- a **provenance record on every extracted value** — AIP edition, AIRAC
  cycle, template version, and source page — so a reviewer can audit any
  value back to the PDF;
- a coarse per-field **confidence** signal (`high` = matched table cell,
  `low` = OCR/heuristic fallback);
- a **human-review report** listing every value beside its source page;
- output routed through the released `aviconv-aixm` writer and the
  `aviconv aixm validate --semantic` gate, so an implausible extraction
  surfaces as a finding before it reaches a user.

**Scope is locked** to airports/runways/frequencies/navaids — *not*
procedures, *not* airspace.

## Offline / Pyodide boundary

The PDF and OCR dependencies (`pdfplumber`, optional `pytesseract`) are **not
Pyodide-safe**. `aviconv-aip` is therefore a **CLI-and-service feature only**,
never a browser-playground feature. This boundary is locked.

## Install

```bash
pip install aviconv-aip           # base install (pdfplumber)
pip install "aviconv-aip[ocr]"    # + optional OCR fallback (needs tesseract)
```

Without the `ocr` extra, image-only pages are *flagged* in the extraction
result rather than causing a crash.

## Usage

```bash
aviconv aip list-templates                          # bundled publishers
aviconv aip extract --template pakistan AD-2.pdf     # PDF → records JSON
aviconv aip extract --template pakistan --review AD-2.pdf   # human-review report
aviconv aip to-aixm  --template pakistan AD-2.pdf    # PDF → AIXM 5.1.1
```

See the [package docs](https://ams-dev25.github.io/aviconv/packages/aip/) and
the [template-authoring guide](https://ams-dev25.github.io/aviconv/guide/adding-an-aip-template/).

## Source AIP licensing

No source AIP PDF is committed to this repository — only extraction templates
and small synthetic, licence-clean fixtures ship. AIP content licensing varies
by State; see [`LICENSES/README.md`](LICENSES/README.md).
