Skip to main content

AutoReporter — Offline-first LLM-driven PDF report generator

AutoReporter

Drop in messy project files (spreadsheets, experiment logs, notes, or charts) and get back a clean, magazine-quality PDF report — built to work 100% offline inside closed networks using Python 3.10+, Typst, and any OpenAI- or Anthropic-compatible LLM.


How the AI Review Process Catches Errors & Hallucinations

Most AI PDF tools generate a draft in one shot and hope for the best. That leads to made-up numbers, broken charts, or ugly cut-off tables. AutoReporter runs a check-your-own-work loop before, during, and after drafting:

Your Files ──▶ 1. Python Math & Charts ──▶ 2. AI Writes Draft ──▶ 3. Auto-Fix Compile Errors
                                                                           │
Final PDF ◀── Keep Highest-Scoring PDF ◀── 5. Patch & Rebuild ◀── 4. AI Reviews Page Pictures
  1. Real math first (stops made-up numbers): Before the AI writes a single paragraph, Python scans your data and calculates the real stats (averages, ranges, missing values, correlations). Charts are plotted by real Python scripts from your actual files, and summary tables are saved as clean .csv files that Typst reads directly — so the AI never has to re-type big tables from memory.
  2. Automatic bug fixing (stops broken builds): If a Python chart script crashes or the Typst layout has a syntax error, AutoReporter grabs the exact error message and line number and sends it right back to the AI to fix (up to 3–4 tries automatically).
  3. Post-draft Vision AI review (catches visual & factual slips): After the draft PDF compiles, AutoReporter converts every page into a PNG picture and sends those page images — along with the draft source and report plan — back through a vision-capable AI acting as a strict editor. It checks for:
    • Tables or text overflowing off the page, or raw code symbols accidentally showing up
    • Overlapping chart labels, tiny unreadable text, or crowded axes
    • Awkward page breaks, giant blank gaps, or going over your page limit
    • Missing key findings or captions that don't match what's shown
  4. Targeted fixes + rollback safety net: The reviewer scores the draft from 1 to 10 and lists concrete fixes. AutoReporter re-runs any flagged chart script, patches the layout, recompiles, and checks again (default: 2 rounds). It always keeps the highest-scoring working PDF — if a later edit fails to compile or accidentally deletes content, AutoReporter throws out the bad patch and keeps the best version.

Compact Cheatsheet

What You Can Pass In (inputs)

A single file, a list of files, a whole folder, or live Python objects:

  • Spreadsheets & data: .csv, .tsv, .parquet, .xlsx, pandas.DataFrame
  • Notes & logs: .md, .txt, .log, .json, .jsonl, Python dict, or raw text strings
  • Existing figures: .png, .jpg, .svg (embedded directly into the report)

Report Options (Python & CLI)

Python (generate_report) CLI (autoreporter build) Default What It Does (Plain English)
inputs positional args (required) File(s), folder, DataFrame, or text to turn into a report
prompt -p, --prompt None Optional instructions (e.g. "Focus on what beat the baseline")
theme -t, --theme "executive_board" Pick 1 of the 10 themes below, or "auto" to let the AI choose
output_dir / output_filename -o / --output-dir current dir Where to save the PDF (auto-named from title if omitted)
audience --audience "mixed" Who's reading: "executive", "technical", "mixed", "stakeholder"
tone --tone theme default Writing style tweak (e.g. "formal", "concise", "persuasive")
max_pages --max-pages auto Keep the report at or under this page count
page_size --page-size "letter" "letter", "a4", or "widescreen_16_9" (slide-style deck)
toc --toc "auto" Table of contents: True, False, or "auto" (on for 5+ pages)
include_charts --no-charts True Generate matching Python SVG charts (--no-charts turns off)
visual_qa_rounds --qa-rounds 2 How many post-draft AI review rounds to run (0 skips review)
save_intermediates --save-intermediates False Save .typ, chart scripts/SVGs, CSVs, and QA notes for manual edits
dry_run --dry-run False Only build and print the outline plan — don't render the PDF yet

AI Connection & Branding Options

Python (LLMConfig / BrandingConfig) CLI Flag Env Var Default Plain-English Meaning
provider --provider AUTOREPORTER_PROVIDER "auto", "openai", or "anthropic" (SDK to use)
model --model AUTOREPORTER_MODEL Model name (e.g. claude-opus-5-5, gpt-5.4, gemini-2.5-flash)
base_url --base-url AUTOREPORTER_BASE_URL Custom API URL (work gateway, Gemini, vLLM, LiteLLM)
api_key --api-key AUTOREPORTER_API_KEY API key (also falls back to OpenAI/Anthropic/Gemini env vars)
vision_model --vision-model AUTOREPORTER_VISION_MODEL Optional separate model just for the visual review step
ca_bundle / verify_ssl --ca-bundle / --insecure AUTOREPORTER_CA_BUNDLE Corporate SSL certificate file for private networks
temperature / max_tokens --temperature / --max-tokens 0.3 / 8192 Creativity vs. consistency, and max length per AI call
title, author, organization --title, --author, --org auto / None Cover page, header, and footer metadata
logo_path, classification --logo, --classification None Company logo + header/footer banner (e.g. INTERNAL USE ONLY)

Offline-ready out of the box: All 7 open-source font families and all 10 Typst themes are bundled inside the Python package. No internet downloads happen at runtime.


Install & Quickstart

pip install autoreporter-ai
# Optional Parquet & Excel file support:
pip install "autoreporter-ai[all-formats]"

(Installs as autoreporter-ai on PyPI; imports in Python as import autoreporter and provides the autoreporter CLI.)

Python (One Call)

from autoreporter import BrandingConfig, LLMConfig, generate_report

result = generate_report(
    inputs=["experiments.txt", "metrics.csv", "findings.md"],
    prompt="Summarize why V3 beat V2 and call out any remaining risks.",
    theme="executive_board",   # or "auto"
    output_dir="./reports",
    output_filename="v3_eval.pdf",
    llm=LLMConfig(
        provider="anthropic",  # "auto" | "openai" | "anthropic"
        base_url="https://internal-llm.corp",
        model="claude-opus-5-5",
        api_key="...",         # or set AUTOREPORTER_API_KEY
    ),
    audience="executive",
    max_pages=6,
    visual_qa_rounds=2,        # AI reviews rendered page PNGs and fixes issues
    branding=BrandingConfig(
        author="Data Science Team",
        organization="Applied Research",
        classification="INTERNAL USE ONLY",
    ),
    save_intermediates=True,   # keep report.typ + SVGs if you want to tweak anything
)

print(result.pdf_path, result.page_count, result.qa_score)

Using Gemini (OpenAI-Compatible Endpoint)

llm = LLMConfig(
    provider="openai",
    base_url="https://generativelanguage.googleapis.com/v1beta/openai/",
    model="gemini-2.5-flash",  # or gemini-2.5-pro
    api_key="...",             # or set GEMINI_API_KEY / AUTOREPORTER_API_KEY
)

Reuse Settings Across Multiple Reports

from autoreporter import ReportGenerator

gen = ReportGenerator(
    provider="openai",
    base_url="https://internal-llm.corp/v1",
    model="gpt-5.4",
    default_theme="swiss_grid",
)
gen.generate("q4_metrics.csv", output_dir="./reports")
gen.generate(["ablation.txt", "notes.md"], theme="technical_monograph", output_dir="./reports")

Command Line

autoreporter themes list
autoreporter build metrics.csv notes.md --theme swiss_grid --max-pages 5 -o report.pdf

The 10 Built-In Design Themes

Every theme controls the page layout, fonts, colors, and chart colors automatically so charts look like they belong in the report.

Theme ID Look & Feel Great For
executive_board Deep navy cover, gold accents, clean KPI cards Leadership briefings & annual reports
swiss_grid Crisp white & black grid with bold red accents Benchmarks & engineering audits
technical_monograph Serif book style with wide margin sidenotes ML experiments & research write-ups
editorial_broadsheet Warm paper, serif headlines, burgundy & teal Strategy memos & deep-dive essays
modern_saas Clean indigo cards, generous whitespace Tech product & platform reviews
scientific_journal Forest teal, structured numbered figures Lab results & statistical studies
warm_atelier Ivory paper, terracotta & sage tones Impact reports & design research
nordic_minimal Extra-airy white, calm fjord blue & gray Scorecards & clean executive briefs
bold_magazine High-contrast dark title bands, bright amber Demos, showcases & standout findings
dark_telemetry Full dark mode with cyan & amber charts On-screen briefings & monitoring

Development, Testing & Internal PyPI

# Offline unit, theme, and full 6-stage pipeline tests (55 tests)
pytest -m "not live"

# Live end-to-end test using Gemini (needs GEMINI_API_KEY or .env)
pytest tests/integration/test_live_gemini.py -m live -v -s

# Build self-contained wheel (includes all fonts & themes) and upload to private PyPI
python -m build
twine upload --repository-url https://pypi.internal.corp/simple/ dist/*

Metadata

Release files for autoreporter-ai 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for autoreporter-ai 0.1.0
File Size Uploaded Provenance Actions
autoreporter_ai-0.1.0.tar.gz 3.6 MB With provenance Details for autoreporter_ai-0.1.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for autoreporter-ai 0.1.0
File Interpreter ABI Platform Actions
autoreporter_ai-0.1.0-py3-none-any.whl Python 3 none any Details for autoreporter_ai-0.1.0-py3-none-any.whl

Total release size: 7.1 MB

Release files / autoreporter_ai-0.1.0.tar.gz

Download URL autoreporter_ai-0.1.0.tar.gz
Size 3.6 MB
Tags Source
SHA-256 checksum
How to use checksums
6f19a3e9a396b2eef3e66c664d6eff048dd2987c14ec5073a9ebd8e1b2e2667f
BLAKE2b-256 checksum
How to use checksums
19749a5a7eefcd0379b804a081a344bff82afe121c0f87558cebe5dacca66557
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 29, 2026.

Transparency log

Release files / autoreporter_ai-0.1.0-py3-none-any.whl

Download URL autoreporter_ai-0.1.0-py3-none-any.whl
Size 3.6 MB
Tags Python 3
SHA-256 checksum
How to use checksums
7612c641633650bdabdffba6b038b07cf6aa93eed7116ec93c3bc538706001e7
BLAKE2b-256 checksum
How to use checksums
a3d17871e046bc026d4bffe07cfb48569cd5f1c5b1a17d6badf94f52f07942e8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 29, 2026.

Transparency log

Security for autoreporter-ai 0.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for autoreporter_ai-0.1.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 29, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page