๐ฏ What This Replaces
Every week, someone manually creates an email showcasing TLH's current estate sales. They download photos, write descriptions, format the email, and send it via Mailchimp. This tool automates 90% of that work.
Actual email generated by the system โ photos, collages, and AI-written highlights
โก How It Works
Scrape Sales
Pull this week's sales from TLH website
Download Photos
Grab top photos from each sale
AI Highlights
Gemini Vision analyzes items
Create Collages
Auto-generate photo grids
Generate HTML
Mailchimp-ready email
๐ง Running the Generator
# From the workspace cd tlh/estate-email-generator # Set your Gemini API key (for AI highlights) export GEMINI_API_KEY="your-key-here" # Run the generator python generate.py # Output files created: # output/email.html โ Ready for Mailchimp # output/collage_*.jpg โ Photo grids # output/summary.json โ Structured data
๐ฌ Mailchimp Integration
The generator outputs Mailchimp-compatible HTML. You have two options:
- Paste into existing template: Copy the generated HTML into your current Mailchimp template's code editor
- Use as standalone: Create a new campaign with "Code your own" and paste the full email
With Mailchimp API access, we can fully automate sending โ the script would upload images, create the campaign, and schedule it. Just need API credentials added to the config.
โจ AI-Generated Highlights
The system uses Gemini Vision to analyze photos and write compelling one-line descriptions. Examples from actual runs:
Valley Center Sale
"Highlights include a large Cobalt glass set, late model Buick sedan, owl wall plug-in warmer, and a portable oxygen concentrator."
San Diego Sale
"Highlights include the curated antique book collection, vintage child-themed pitcher, hand-painted animal dish set, and Spode Blue Room Christmas Plate."
๐ What Gets Generated
| Output | Description | Location |
|---|---|---|
| email.html | Complete Mailchimp-ready email with inline styles | output/email.html |
| Photo collages | 2x3 grid images for each sale | output/collage_*.jpg |
| Raw photos | Downloaded sale photos | output/photos/ |
| summary.json | Structured data (addresses, dates, highlights) | output/summary.json |
๐ Next Steps
To fully automate weekly sends:
- Mailchimp API access โ Need API key + list ID to auto-create campaigns
- Image hosting โ Currently uses local paths; need to upload to Mailchimp or S3
- Cron schedule โ Run every Thursday to prep Friday send
- Review step โ Email preview to Justin/Brett before auto-send