Metadata-Version: 2.4
Name: paper-scoring-reporting
Version: 0.1.0
Summary: Safe HTML, text, PDF, and SMTP reporting for Paper Scoring results
Author: Paper Scoring contributors
License-Expression: MIT
Project-URL: Repository, https://github.com/maikeruSan/paper-scoring-reporting
Classifier: Development Status :: 3 - Alpha
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 :: Communications :: Email
Requires-Python: >=3.11
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: paper-scoring-core<0.2,>=0.1
Requires-Dist: reportlab<5,>=4.2
Provides-Extra: test
Requires-Dist: build<2,>=1.2; extra == "test"
Requires-Dist: mypy<2,>=1.18; extra == "test"
Requires-Dist: pypdf<7,>=5; extra == "test"
Requires-Dist: pytest<10,>=9.0.3; extra == "test"
Requires-Dist: pytest-cov<8,>=6; extra == "test"
Requires-Dist: ruff<1,>=0.12; extra == "test"
Requires-Dist: twine<7,>=6; extra == "test"
Requires-Dist: types-reportlab<5,>=4.4; extra == "test"
Provides-Extra: security
Requires-Dist: bandit[toml]<2,>=1.8; extra == "security"
Requires-Dist: detect-secrets<2,>=1.5; extra == "security"
Requires-Dist: pip-audit<3,>=2.9; extra == "security"
Dynamic: license-file

# Paper Scoring Reporting

`paper-scoring-reporting` turns `paper-scoring-core` score results into plain-text,
mobile-friendly HTML, and PDF reports. SMTP delivery is a separate, explicitly
configured step. The package never reads `.env` files or process environment
variables.

## Install

```shell
python -m pip install paper-scoring-reporting
```

## Render and deliver

```python
from datetime import date

from paper_scoring_reporting import (
    ReportMetadata,
    SMTPSettings,
    SMTPSender,
    compose_report_email,
    render_report,
)

report = render_report(
    score_results,
    ReportMetadata(
        report_date=date.today(),
        category="cs.AI",
        scoring_version="3.0.0",
    ),
)

settings = SMTPSettings(
    host="smtp.example.invalid",
    port=587,
    sender="automation@example.invalid",
    username="automation@example.invalid",
    password=runtime_password,
)
email = compose_report_email(
    sender=settings.sender,
    recipients=["reviewer@example.invalid"],
    subject="Paper scoring report",
    report=report,
)
SMTPSender(settings).send(email)
```

Inject credentials at runtime from your process supervisor, secret store, CLI, or
MCP composition root. Do not put credentials in source files or report data.

## Accepted result values

The renderer accepts a sequence of `paper_scoring_core.ScoreResult` objects, objects
with a safe `model_dump()` method, dataclass instances, or mappings. Only the public
score-report fields are selected; arbitrary object attributes and unknown mapping
keys are ignored. Legacy title-cased mapping keys are accepted for migration.

## Development

```shell
python -m pip install -e '.[test,security]'
pytest
ruff check .
bandit -c pyproject.toml -r src
pip-audit
```

CI exercises Python 3.11 through 3.13 on Ubuntu and Windows, builds wheel and sdist
artifacts, and verifies their metadata.
