Skip to main content

Python-scripted live slide framework

Project description

๐ŸŽ“ Auditorium

PyPI - License PyPI - Python Version PyPI

The presentation framework for people who think in code.

Auditorium lets you build live technical presentations as Python scripts. Each slide is an async def function. Animate algorithms step by step, render live-computed plots, run numerical demos โ€” anything Python can do, your slides can do. No PowerPoint. No Markdown. Just code.

from auditorium import Deck

deck = Deck(title="My Talk")

@deck.slide
async def sorting_demo(ctx):
    """Explain how the algorithm builds the sorted prefix."""
    await ctx.md("## Bubble Sort, Step by Step")
    data = [5, 3, 8, 1, 2]
    for i in range(len(data)):
        for j in range(len(data) - 1 - i):
            if data[j] > data[j + 1]:
                data[j], data[j + 1] = data[j + 1], data[j]
            await ctx.md(f"`{data}`")
            await ctx.sleep(0.5)
    await ctx.step()
    await ctx.md("**Sorted!**")
pip install auditorium
auditorium run talk.py

โœจ Why Auditorium?

Most presentation tools treat slides as static documents. Auditorium treats them as programs.

  • ๐Ÿ Run algorithms live โ€” sort arrays, traverse graphs, train models, all animated on stage
  • ๐Ÿ“Š Compute content โ€” generate plots, tables, or LaTeX from data, not screenshots
  • ๐Ÿ“ฆ Use any Python library โ€” numpy, matplotlib, pandas, whatever you import works
  • ๐ŸŒ Share with students worldwide โ€” presenter mode syncs your slides to every connected browser in real time
  • ๐Ÿ”— Go public โ€” --public gives you an instant shareable URL, no deployment needed
  • ๐Ÿ“ค Export everywhere โ€” record to video, export to PDF, or share as a self-contained HTML that replays your talk with original timing

If you've ever wished you could await inside a PowerPoint slide, this is for you.


๐Ÿš€ Quick Start

pip install auditorium    # or: uv add auditorium

Create talk.py:

from auditorium import Deck

deck = Deck(title="My Talk")

@deck.slide
async def intro(ctx):
    """Notes for the presenter โ€” only visible in presenter view."""
    await ctx.md("# Welcome!")
    await ctx.md("*Press right arrow to continue*")

@deck.slide
async def demo(ctx):
    """Show progressive reveals and timed content."""
    await ctx.md("## Key Points")
    await ctx.step()
    await ctx.md("- First point")
    await ctx.step()
    await ctx.md("- Second point")
    await ctx.sleep(1)
    await ctx.md("*(that one appeared automatically)*")

Run it:

auditorium run talk.py

๐Ÿ“‹ Features

Feature Description
๐Ÿ Imperative Python slides Each slide is an async def โ€” loops, conditionals, imports, anything
๐Ÿ‘๏ธ Progressive reveals await ctx.step() pauses for keypress, await ctx.sleep(n) auto-advances
๐Ÿงฎ LaTeX math KaTeX bundled โ€” $inline$ and $$display$$ in any markdown
๐Ÿ’ป Syntax highlighting Fenced code blocks with highlight.js (bundled)
๐Ÿ“ Flexible layouts columns, rows with "auto" sizing, arbitrarily nested
๐ŸŽค Presenter mode --presenter โ€” notes, timer, slide mirror, next-slide preview
๐Ÿ”„ Shared navigation Presenter drives all audience tabs โ€” students see what you show
๐ŸŒ Public sharing --public bridges to a relay โ€” instant shareable URL, no deployment
๐Ÿ• Late-join sync New viewers see the full slide state immediately
๐Ÿ“„ PDF / HTML / PNG export Vector PDF, self-contained interactive HTML, or PNG per slide
๐ŸŽฌ Video recording Headless or live recording via Playwright
๐Ÿ”€ Step-by-step export Each reveal as a separate frame with original timing
โ™ป๏ธ Hot reload Edit your .py and the browser updates instantly
๐Ÿ“ก Offline All assets bundled โ€” zero CDN, zero internet required
๐Ÿ”Œ Auto-reconnect Survives server restarts without losing your place

๐ŸŒ Share Publicly

Present from your laptop, share with the world:

auditorium run talk.py --public
โ•ญโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€ Auditorium โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฎ
โ”‚ Deck:   My Talk                                               โ”‚
โ”‚ Slides: 15                                                    โ”‚
โ”‚ URL:    http://127.0.0.1:8000                                 โ”‚
โ”‚ Mode:   independent (per-tab)                                 โ”‚
โ•ฐโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฏ

Public URL: http://vps.apiad.net:4243/r/my-talk/

Anyone with the link sees your presentation in real time. No deployment, no hosting โ€” your laptop runs the deck, a lightweight relay forwards it.

# Choose your own URL slug
auditorium run talk.py --public --name my-talk

# Use your own relay server
auditorium run talk.py --public --relay myserver.com:4243

Self-host a relay (it's one command):

auditorium relay                    # run directly
make relay-install                  # install as systemd service
make relay-update                   # pull + sync + restart

๐ŸŽค Presenter Mode

Start with --presenter to sync all audience tabs to your navigation:

auditorium run talk.py --presenter

Two tabs open: your presenter view (notes + timer + slide mirror + next-slide preview) and the audience view. Navigate from the presenter tab โ€” every connected browser follows in real time.

  • ๐Ÿ“ Docstrings become speaker notes (never shown to the audience)
  • โšก Late-joining tabs catch up instantly (full slide state replayed)
  • ๐Ÿ”’ Audience keyboards are locked โ€” only the presenter navigates

Without --presenter, each tab navigates independently.


๐Ÿ“ Layouts

@deck.slide
async def layout_demo(ctx):
    """Layouts nest freely."""
    await ctx.md("## Two Columns")
    left, right = await ctx.columns([2, 1])

    async with left:
        await ctx.md("Main content (2/3 width)")

    async with right:
        await ctx.md("Sidebar (1/3)")

Use "auto" for natural-size regions:

header, body, footer = await ctx.rows(["auto", 1, "auto"])

๐ŸŽฌ Recording & Export

Requires pip install auditorium[record] and playwright install chromium.

# Record to video
auditorium record talk.py -o talk.webm

# Export to PDF (vector), HTML (interactive), or PNG
auditorium export talk.py -f pdf -o talk.pdf
auditorium export talk.py -f html -o talk.html
auditorium export talk.py -f png -o slides/

# Step-by-step: one frame per reveal, with original timing in HTML
auditorium export talk.py -f html --step-by-step -o talk.html

โŒจ๏ธ Navigation

Key Action
โ†’ / Space Advance step or next slide
Page Down Skip to next slide
โ† Previous slide
r Restart current slide
Digits + Enter Jump to slide N

๐Ÿ“š Example

See examples/demo_deck.py for a full 11-slide deck exercising every feature.

auditorium run examples/demo_deck.py

๐Ÿ“œ License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

auditorium-1!3.3.0.tar.gz (642.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

auditorium-1!3.3.0-py3-none-any.whl (577.1 kB view details)

Uploaded Python 3

File details

Details for the file auditorium-1!3.3.0.tar.gz.

File metadata

  • Download URL: auditorium-1!3.3.0.tar.gz
  • Upload date:
  • Size: 642.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for auditorium-1!3.3.0.tar.gz
Algorithm Hash digest
SHA256 47fc921f4cf829a975140b184a8cc72c2e458cb95b3f20eef7a963ca1a858421
MD5 e8a031b755cda5157670045a4f31027c
BLAKE2b-256 10f61e2ce74414239d4b47db037a008af209db752dbf241157051c971c584eda

See more details on using hashes here.

Provenance

The following attestation bundles were made for auditorium-1!3.3.0.tar.gz:

Publisher: deploy.yaml on apiad/auditorium

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file auditorium-1!3.3.0-py3-none-any.whl.

File metadata

  • Download URL: auditorium-1!3.3.0-py3-none-any.whl
  • Upload date:
  • Size: 577.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for auditorium-1!3.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 775e18da1fcd7e36c14d8d81f16e07814d8e7e477d80ae26023fc16a5bb0194e
MD5 e912c460abffafe644be1fcc2d04a6f7
BLAKE2b-256 e0d1dc84cb2afb771db242765a1ce56c1ca0ec4465e18beeeeb6580efc88e6d1

See more details on using hashes here.

Provenance

The following attestation bundles were made for auditorium-1!3.3.0-py3-none-any.whl:

Publisher: deploy.yaml on apiad/auditorium

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page