Skip to content

craigsdennis/mspaintify-python-workers

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

28 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MSPaintify

A Cloudflare Python Worker that turns photos into delightfully terrible MS Paint-style drawings using OpenAI's GPT-Image-2 via AI Gateway.

Built for events! Multiple events can be configured via Workers KV without code changes.

How it works

  1. Upload — Take a photo on your phone via the capture page
  2. Process — A durable Python Workflow sends your photo to GPT-Image-2 with a delightfully unhinged prompt
  3. Display — The presenter screen shows a live slideshow of before/after pairs

Architecture

  • Python Worker (src/worker.py) — FastAPI app on Pyodide/WASM handling uploads and serving static assets
  • Workflow (src/workflow.py) — Durable DAG-based execution for image generation
  • Frontend (assets/) — Presenter screen, mobile capture, admin gallery
  • Storage — R2 for images, KV for per-event config, AI Gateway for image generation

Event Configuration

Set up a new event without deploying:

npx wrangler kv key put <event-slug> '{"title":"My Event","additionalInstructions":"Add a logo in the corner"}' --binding=CONFIG --remote

Then visit:

  • Presenter: https://mspaintify.<user>.workers.dev/?event=<event-slug>
  • Capture: https://mspaintify.<user>.workers.dev/capture.html?event=<event-slug>

Resources

About

A Python Workers implementation of MSPaintify keyed to events. For PyCon 2026.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors