Skip to main content
logo

poster2json

Convert scientific posters (PDF/images) to structured JSON metadata using Large Language Models.


contributors stars open issues license

PyPI Version PyPI Downloads DOI

Documentation · Changelog · Report Bug · Request Feature



Description

poster2json extracts structured metadata from scientific conference posters (PDF or image format) into machine-actionable JSON conforming to the poster-json-schema.

The pipeline uses:

  • Llama-3.1-8B-Instruct (a verbatim mirror of Meta's release; swap with any HuggingFace instruct model via --model) for JSON structuring
  • pdfplumber for layout-aware PDF text extraction (stream-order alto layout engine by default; POSTER2JSON_LAYOUT=blocks selects the XY-cut engine)
  • lingua-language-detector for ISO 639-1 language detection on body text (overrides any value the model emits — body text beats metadata-fragment guessing)
  • ROR (https://api.ror.org) for affiliation canonicalisation; matched names get a ROR identifier attached
  • ORCID (https://pub.orcid.org) for author disambiguation; matched creators get an ORCID identifier attached (uses the authenticated Member API when ORCID_CLIENT_ID and ORCID_CLIENT_SECRET are set, otherwise the public API)

Quick Start

Installation

pip install poster2json

CLI Usage

# Extract metadata from a poster (default: Llama-3.1-8B-Instruct @ 4bit)
poster2json extract poster.pdf -o result.json

# Use a different instruct model (any HuggingFace repo id works)
poster2json extract poster.pdf --model google/gemma-2-9b-it --quantization 4bit

# Trade VRAM for quality
poster2json extract poster.pdf --quantization 8bit
poster2json extract poster.pdf --quantization fp16

# Validate extracted JSON
poster2json validate result.json

# Process multiple posters
poster2json batch ./posters/ -o ./output/

Python API

from poster2json import extract_poster, validate_poster

# Extract metadata
result = extract_poster("poster.pdf")
print(result["titles"][0]["title"])

# Validate the result
is_valid = validate_poster(result)

Output Format

Output conforms to the poster-json-schema (DataCite 4.7):

{
  "$schema": "https://posters.science/schema/v0.2/poster_schema.json",
  "creators": [
    {
      "name": "Garcia, Sofia",
      "givenName": "Sofia",
      "familyName": "Garcia",
      "affiliation": [
        {
          "name": "Stanford University",
          "affiliationIdentifier": "https://ror.org/00f54p054",
          "affiliationIdentifierScheme": "ROR",
          "schemeURI": "https://ror.org/"
        }
      ]
    }
  ],
  "titles": [
    { "title": "Machine Learning Approaches to Diabetic Retinopathy Detection" }
  ],
  "publicationYear": null,
  "language": "en",
  "researchField": "Health Sciences",
  "subjects": [
    { "subject": "Machine Learning" },
    { "subject": "Diabetic Retinopathy" }
  ],
  "descriptions": [
    { "description": "We present a deep learning model...", "descriptionType": "Other" }
  ],
  "publisher": null,
  "content": {
    "sections": [
      { "sectionTitle": "Abstract", "sectionContent": "..." },
      { "sectionTitle": "Methods", "sectionContent": "..." },
      { "sectionTitle": "Results", "sectionContent": "..." }
    ]
  },
  "imageCaptions": [{ "id": "fig1", "caption": "Figure 1. ROC curves showing..." }],
  "tableCaptions": [{ "id": "table1", "caption": "Table 1. Performance metrics" }],
  "formats": ["application/pdf"]
}

Notes on the auto-populated fields:

  • language is detected from the raw body text (lingua heuristic). Returns null when text is too short (<200 chars / <50 non-ASCII codepoints) or the detector is unsure.
  • researchField must be one of the four OpenAlex top-level domains: Health Sciences, Life Sciences, Physical Sciences, Social Sciences. Null when the model can't pick one confidently.
  • affiliation gets ROR enrichment when the matcher returns a high-confidence chosen result. Strings without a confident match pass through unchanged. Set POSTER2JSON_ROR=0 to disable.
  • publisher and publicationYear are always emitted as null. They are platform-owned and set when the poster is published, not by extraction.
  • formats is derived from the input file's extension, not the model.

System Requirements

Requirement Specification
GPU NVIDIA CUDA-capable, ≥8GB VRAM (default 4bit); ≥16GB for --quantization fp16 or image/OCR posters
RAM ≥32GB recommended
Python 3.10+
OS Linux, macOS, Windows (via WSL2)

Performance

Field accuracy of poster2json 0.10.5 at default settings on 21 hand-labeled posters (20 PDF, 1 image). Each field is compared with the text printed on the poster using ROUGE-L, where 1.00 means identical. Posters is the number of labeled posters that have the field.

Field Posters Mean ROUGE-L
Title 21 0.978
Author names 21 0.898
Given/family split 12 1.000
Affiliations 21 0.953
Author-affiliation assignment 21 0.884
Section text 21 0.839
Figure captions 13 0.975
Table captions 5 1.000
All content (forgiving) 21 0.862
Content, boundary-free F1 21 0.917

Only fields copied from the poster are scored. Summaries, keywords and the research field are written or chosen by the model, so they have no score. See Evaluation for how each field is compared.

Documentation

Document Description
Architecture Technical details & methodology
Evaluation Validation metrics & results

Development Setup

# Clone the repository
git clone https://github.com/fairdataihub/poster2json.git
cd poster2json

# Create a virtual environment
python -m venv .venv

# Activate the virtual environment
source venv/bin/activate
.venv\Scripts\activate # On Windows

# Install poetry
pip install poetry

# Install dependencies
poetry install

# Run tests
poe test

# Format code
poe format

If you are on windows and have multiple python versions, you can use the following commands:

py -0p # list all python versions

py -3.12 -m venv .venv

License

MIT License - see LICENSE for details.

Citation

@software{poster2json2026,
  title = {poster2json: Scientific Poster to JSON Metadata Extraction},
  author = {O'Neill, James and Soundarajan, Sanjay and Portillo, Dorian and Patel, Bhavesh},
  year = {2026},
  version = {0.8.0},
  url = {https://github.com/fairdataihub/poster2json},
  doi = {10.5281/zenodo.18320010}
}

Funding

This project is funded by The Navigation Fund (10.71707/rk36-9x79).

Contributing

Contributions welcome! Please see CONTRIBUTING.md for guidelines.

Metadata

Release files for poster2json 0.10.6

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

Source distribution (sdist)

Source distribution for poster2json 0.10.6
File Size Uploaded Provenance Actions
poster2json-0.10.6.tar.gz 150.3 kB Without provenance Details for poster2json-0.10.6.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for poster2json 0.10.6
File Interpreter ABI Platform Actions
poster2json-0.10.6-py3-none-any.whl Python 3 none any Details for poster2json-0.10.6-py3-none-any.whl

Total release size: 308.2 kB

Release files / poster2json-0.10.6.tar.gz

Download URL poster2json-0.10.6.tar.gz
Size 150.3 kB
Tags Source
SHA-256 checksum
How to use checksums
9c7b7998eb0d2f890b4854fe45a33f666ed2d75797ecc018be65e096ebf01779
BLAKE2b-256 checksum
How to use checksums
6ffdd6220ecf42cec8bb0d30c70437c8b32ba0de0a873d45618e8a93dcd5bc01
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/2.5.1 CPython/3.12.16 Linux/7.0.0-1016-aws

Release files / poster2json-0.10.6-py3-none-any.whl

Download URL poster2json-0.10.6-py3-none-any.whl
Size 157.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b5b089fec9f879e227b318092fcb0a1749f3b876dcfa06cbb0b6b0b78baaa5f8
BLAKE2b-256 checksum
How to use checksums
b1a5daa8e342a71c7f1f2b79c39c3adb5f0d876f97c9156046bcf125aa865218
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/2.5.1 CPython/3.12.16 Linux/7.0.0-1019-azure

Security for poster2json 0.10.6

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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

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.10.6 This release

2 release files No 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