Printable Cards
Create high-quality printable foldable greeting cards rendered as 2-page PDFs via HTML/CSS + WeasyPrint.
Card Layout
US Letter landscape (11 x 8.5 in), 2 pages, designed for double-sided printing (flip on short edge), fold in half.
| Page |
Left Half |
Right Half |
| 1 (outside) |
Back cover (accent bg, border, symbol, label) |
Front cover (full-bleed image) |
| 2 (inside) |
Open space for handwriting |
Header + message + closing |
Workflow
- Gather info: recipient name(s), relationship/context, occasion, gender/style preference, any personal details for the message
- Generate front cover image: use
generate_image at 3:4 aspect ratio. See references/cover-prompts.md for prompt templates. Feminine = floral/botanical wreath. Masculine = textured background with gold calligraphy.
- Clean cover image: run
scripts/clean_cover_image.py <raw.png> <clean.png> to remove AI artifacts (shadows, table surfaces, grey borders). Verify visually.
- Choose color palette: see
references/color-palettes.md for tested palettes. Match palette to the front cover style. Parameters: accent, accent_dark, light_bg, dark_text.
- Write the message: write in HTML using
<p> tags. Save to a .html file. Key principles:
- Write from the correct perspective (who is giving the card)
- Include specific personal details, not generic compliments
- Sound human, not like a greeting card company
- High emotional intelligence: loving, positive, honest
- 3 paragraphs is the sweet spot
- Generate the PDF: run
scripts/generate_card.py with all parameters. Use --masculine flag for bold sans-serif styling.
- Verify: view both pages of the PDF. Check front cover fills the right half with no gaps, inside text is centered and readable, colors are cohesive between outside and inside.
- Deliver: attach the PDF. Include printing instructions: double-sided, flip on short edge, fold in half.
Script Usage
python scripts/generate_card.py \
--name "Chloe" \
--front-image /path/to/clean_cover.png \
--message-file /path/to/message.html \
--closing "All my love, your little brother" \
--accent "#C4889B" \
--accent-dark "#9E6B7E" \
--light-bg "#FDF2F5" \
--dark-text "#5A2D45" \
--output /path/to/Card.pdf \
[--masculine]
Message Writing Guidelines
The message is the hardest part. Follow these rules:
- Ask for context first. Who is giving the card? What is their relationship? What do they love about this person? Any inside jokes or specific things to mention?
- Write from the giver's voice, not a generic third person.
- Be specific. "The way you always sit with me and really talk" beats "you are always there for me."
- Stay honest. Do not over-idealize. If siblings tease each other, acknowledge it warmly.
- 3 paragraphs: (1) opening with personal connection, (2) what you admire/appreciate with specifics, (3) birthday wish + love.
- Closing line: short, warm, identifies the relationship (e.g. "Your favorite brother", "Love always, Mom").
Dependencies
Ensure weasyprint is installed: pip install weasyprint
Common Issues
| Issue |
Fix |
| Front cover has grey edges/shadows |
Run clean_cover_image.py more aggressively, or regenerate with "no shadows, no borders, no 3D effects" in prompt |
| Inside background doesn't match outside |
Ensure light_bg color complements the front cover palette |
| Text looks generic/AI |
Rewrite with specific personal details from the user |
| Card looks too feminine/masculine |
Adjust palette and toggle --masculine flag |
1---2name: printable-cards3description: Create beautiful printable foldable greeting cards (birthday, thank you, etc.) as PDFs. Use when the user asks to make, design, or create a printable card, greeting card, birthday card, or foldable card for someone.4license: Unspecified5---6# Printable Cards78Create high-quality printable foldable greeting cards rendered as 2-page PDFs via HTML/CSS + WeasyPrint.910## Card Layout1112US Letter landscape (11 x 8.5 in), 2 pages, designed for double-sided printing (flip on short edge), fold in half.1314| Page | Left Half | Right Half |15|------|-----------|------------|16| 1 (outside) | Back cover (accent bg, border, symbol, label) | Front cover (full-bleed image) |17| 2 (inside) | Open space for handwriting | Header + message + closing |1819## Workflow20211. **Gather info**: recipient name(s), relationship/context, occasion, gender/style preference, any personal details for the message222. **Generate front cover image**: use `generate_image` at 3:4 aspect ratio. See `references/cover-prompts.md` for prompt templates. Feminine = floral/botanical wreath. Masculine = textured background with gold calligraphy.233. **Clean cover image**: run `scripts/clean_cover_image.py <raw.png> <clean.png>` to remove AI artifacts (shadows, table surfaces, grey borders). Verify visually.244. **Choose color palette**: see `references/color-palettes.md` for tested palettes. Match palette to the front cover style. Parameters: `accent`, `accent_dark`, `light_bg`, `dark_text`.255. **Write the message**: write in HTML using `<p>` tags. Save to a `.html` file. Key principles:26 - Write from the correct perspective (who is giving the card)27 - Include specific personal details, not generic compliments28 - Sound human, not like a greeting card company29 - High emotional intelligence: loving, positive, honest30 - 3 paragraphs is the sweet spot316. **Generate the PDF**: run `scripts/generate_card.py` with all parameters. Use `--masculine` flag for bold sans-serif styling.327. **Verify**: view both pages of the PDF. Check front cover fills the right half with no gaps, inside text is centered and readable, colors are cohesive between outside and inside.338. **Deliver**: attach the PDF. Include printing instructions: double-sided, flip on short edge, fold in half.3435## Script Usage3637```bash38python scripts/generate_card.py \39 --name "Chloe" \40 --front-image /path/to/clean_cover.png \41 --message-file /path/to/message.html \42 --closing "All my love, your little brother" \43 --accent "#C4889B" \44 --accent-dark "#9E6B7E" \45 --light-bg "#FDF2F5" \46 --dark-text "#5A2D45" \47 --output /path/to/Card.pdf \48 [--masculine]49```5051## Message Writing Guidelines5253The message is the hardest part. Follow these rules:5455- **Ask for context first.** Who is giving the card? What is their relationship? What do they love about this person? Any inside jokes or specific things to mention?56- **Write from the giver's voice**, not a generic third person.57- **Be specific.** "The way you always sit with me and really talk" beats "you are always there for me."58- **Stay honest.** Do not over-idealize. If siblings tease each other, acknowledge it warmly.59- **3 paragraphs**: (1) opening with personal connection, (2) what you admire/appreciate with specifics, (3) birthday wish + love.60- **Closing line**: short, warm, identifies the relationship (e.g. "Your favorite brother", "Love always, Mom").6162## Dependencies6364Ensure `weasyprint` is installed: `pip install weasyprint`6566## Common Issues6768| Issue | Fix |69|-------|-----|70| Front cover has grey edges/shadows | Run `clean_cover_image.py` more aggressively, or regenerate with "no shadows, no borders, no 3D effects" in prompt |71| Inside background doesn't match outside | Ensure `light_bg` color complements the front cover palette |72| Text looks generic/AI | Rewrite with specific personal details from the user |73| Card looks too feminine/masculine | Adjust palette and toggle `--masculine` flag |