CoolFace
Apppublic

itsjustalex/pptx-beautifier

sourceHugging Faceupdated 3mo agoView on Hugging Face
0likes
App README

✨ PPTX Beautifier

Upload a .pptx, get a tidier deck back — without breaking your corporate design. You get a downloadable beautified .pptx and a browser-viewable version, plus AI improvement notes added as PowerPoint comments.

What it does

Upload just the messy deck, or add a reference template (a second .pptx) and the app restyles the messy deck to match it.

StepWhat changesRisk to brand
Match template (optional)Imports each slide onto the template's matching layout and applies the template's theme, colours and heading/body fonts — the template is the corporate designThe template defines the target design
Layout cleanupSnaps near-aligned shapes to a shared edge; equalises near-equal widths (e.g. cards in a row)None — geometry only
Typography polishEnables word-wrap so text can't spill off boxes; trims trailing blank linesNone — whitespace only
AI suggestionsWording / bullet-length / phrasing tips added as PowerPoint commentsNone — original text is never edited

When a template is supplied, fonts hard-coded in the messy deck are rewritten to the template's heading/body fonts ("template wins"), and theme colours re-skin to the template palette. Text, images and content are preserved.

Fonts, colours, font sizes and wording are never modified. Those carry your corporate identity, so they're left exactly as authored. Only positions, sizes and whitespace are adjusted, and AI feedback is purely advisory (it lives in the Comments pane).

Outputs

  • Download `.pptx` — the cleaned deck with AI suggestions as comments. Opens in PowerPoint with no "repair" prompt.
  • Open in browser — a self-contained HTML rendering of every slide. No PowerPoint or LibreOffice needed to view.

Run locally

bash
cd pptx-beautifier
python -m venv .venv
# Windows:  .venv\Scripts\activate
# macOS/Linux:  source .venv/bin/activate
pip install -r requirements.txt
uvicorn app.main:app --reload --port 8080

Open http://127.0.0.1:8080 and drop in a .pptx.

Enable Claude-powered suggestions (optional)

Without a key, the app falls back to fast local heuristics (long-bullet / too-many-bullets checks). To use Claude:

bash
export ANTHROPIC_API_KEY=sk-ant-...      # Windows: $env:ANTHROPIC_API_KEY="sk-ant-..."
export ANTHROPIC_MODEL=claude-sonnet-4-6 # optional, this is the default

Deploy to a public URL

The repo is container-ready. Two easy paths:

Fly.io

bash
fly launch --copy-config --name <your-unique-name>   # uses fly.toml
fly secrets set ANTHROPIC_API_KEY=sk-ant-...          # optional
fly deploy

Render.com

  1. 1.Push this folder to a GitHub repo.
  2. 2.Render → New → Blueprint → pick the repo (uses render.yaml).
  3. 3.Add ANTHROPIC_API_KEY as a secret env var (optional).

Any host that runs a Docker container works (Cloud Run, Railway, etc.) — the container reads PORT from the environment and persists jobs under DATA_DIR.

How it's built

app/
  main.py       FastAPI routes: upload, status, view, download
  beautify.py   Safe geometry + whitespace cleanup (the brand-preserving part)
  suggest.py    Claude suggestions, with a heuristic fallback
  comments.py   Injects suggestions as native PowerPoint comments (OOXML)
  render.py     Renders the deck to standalone HTML (no LibreOffice)
  store.py      Filesystem-backed job store
static/         Upload UI + results page

No database and no external converters — just Python, python-pptx, and lxml.