Metadata-Version: 2.4
Name: acatome-meta
Version: 0.2.1
Summary: Lightweight metadata lookup for scientific papers
Project-URL: Homepage, https://github.com/acatome/acatome-meta
Project-URL: Repository, https://github.com/acatome/acatome-meta
Project-URL: Issues, https://github.com/acatome/acatome-meta/issues
Author-email: Reto Stamm <reto@retostamm.com>
License-Expression: LGPL-3.0-or-later
License-File: LICENSE
Keywords: crossref,doi,metadata,pdf,scientific-papers,semantic-scholar
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: GNU Lesser General Public License v3 or later (LGPLv3+)
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Scientific/Engineering
Requires-Python: >=3.11
Requires-Dist: habanero>=1.2
Requires-Dist: pymupdf>=1.24
Requires-Dist: rapidfuzz>=3.0
Requires-Dist: semanticscholar>=0.8
Requires-Dist: tenacity>=8.0
Requires-Dist: typer>=0.12
Provides-Extra: dev
Requires-Dist: black>=24.0; extra == 'dev'
Requires-Dist: pytest>=8.0; extra == 'dev'
Requires-Dist: ruff>=0.5; extra == 'dev'
Description-Content-Type: text/markdown

# acatome-meta

Lightweight metadata lookup and verification for scientific papers. Resolves PDFs to their DOI, title, authors, and journal using Crossref and Semantic Scholar.

## Features

- **PDF title extraction** — extracts candidate titles from PDF first pages
- **Crossref lookup** — DOI resolution and metadata retrieval
- **Semantic Scholar** — citation counts, abstracts, and supplementary metadata
- **Fuzzy verification** — confirms extracted metadata matches the PDF content
- **Citation parsing** — extracts structured author/year/title from reference strings
- **Zero-config** — works out of the box, optional API keys for higher rate limits

## Installation

```bash
uv pip install -e .
```

## Usage

```python
from acatome_meta import lookup

meta = lookup("/path/to/paper.pdf")
print(meta["doi"], meta["title"], meta["authors"])
```

## CLI

```bash
acatome-meta lookup paper.pdf
acatome-meta verify paper.pdf --doi 10.1234/example
```

## Configuration

Set `SEMANTIC_SCHOLAR_API_KEY` for higher rate limits:

```bash
export SEMANTIC_SCHOLAR_API_KEY=your_key_here
```

## Testing

```bash
uv run python -m pytest tests/ -v
```

## License

LGPL-3.0-or-later — see [LICENSE](LICENSE).
