Skip to Content
DocsCLI CommandsImage Generation

Image Generation

Generate AI-powered profile pictures and banners with the generate-actor-images CLI.

Overview

Uses fal.ai’s Flux models to generate:

  • Actor profile pictures (1024x1024 square)
  • Actor banners (1920x1080 landscape)
  • Organization logos (1024x1024 square)
  • Organization banners (1920x1080 landscape)

Usage

# Set API key export FAL_KEY=your_fal_key_here # Generate all missing images bun run command:images

Get a FAL API key: https://www.fal.ai/ 

Features

  • Concurrent Generation - Max 10 images at once
  • Smart Skip - Automatically skips existing images
  • Satirical Style - Parodies real company logos
  • Progress Tracking - Live status updates

Output

Checking actor and organization images... Checking 50 actor profile pictures... Checking 50 actor banners... Checking 25 organization logos... Checking 25 organization banners... Found 30 images to generate (120 already exist) Starting concurrent generation (max 10 at a time)... Generated actor-pfp for Actor1 Generated actor-banner for Actor1 Generated org-logo for OpenLie Complete! { generated: 30, failed: 0, skipped: 120, totalActors: 50, totalOrganizations: 25 }

Image Specifications

Actor Profile Pictures

  • Size: 1024x1024 (square)
  • Model: fal-ai/flux/krea (high quality)
  • Style: Professional portrait
  • Based on: physicalDescription field

Actor Banners

  • Size: 1920x1080 (16:9)
  • Model: fal-ai/flux/schnell (fast)
  • Style: Thematic background
  • Based on: profileBanner field

Organization Logos

  • Size: 1024x1024 (square)
  • Model: fal-ai/flux/schnell
  • Style: Satirical parody
  • Based on: pfpDescription + original company mapping

Organization Banners

  • Size: 1920x1080 (16:9)
  • Model: fal-ai/flux/schnell
  • Style: Branded background
  • Based on: bannerDescription field

Company Name Mappings

The generator maps satirical names to real companies for parody logos:

{ 'openlie': 'OpenAGI', 'anthropimp': 'Anthropic', 'xitter': 'Twitter/X', 'goolag': 'Google', 'crapple': 'Apple', // ... and many more }

Output Directories

Images are saved to:

public/ images/ actors/ # Actor profile pictures actor1.jpg actor2.jpg actor-banners/ # Actor banners actor1.jpg actor2.jpg organizations/ # Org logos openlie.jpg anthropimp.jpg org-banners/ # Org banners openlie.jpg anthropimp.jpg

Performance

  • Concurrency: 10 simultaneous generations
  • Speed: ~5-10 seconds per image
  • Total Time: ~2-5 minutes for 50 actors + 25 orgs (300 total images)

Troubleshooting

No FAL_KEY

Error: FAL_KEY not found in environment variables Please add FAL_KEY to your .env file

Solution: Set FAL_KEY environment variable

Generation Failed

Failed to generate actor-pfp for Actor1: Error: Fal.ai API returned no images

Solution:

  • Check API key validity
  • Check API quota/limits
  • Retry (failed images won’t block others)

Missing Required Fields

Error: Actor Actor1 is missing physicalDescription field

Solution: Add required fields to the actor’s individual file in public/data/actors/actor1.json:

{ "id": "actor1", "name": "Actor 1", "physicalDescription": "Description here", // Required for profile pic "profileBanner": "Banner description here" // Required for banner }

Then rebuild the full file: bun run scripts/build-actors-json.ts

Regenerating Images

To regenerate specific images, delete them first:

# Delete and regenerate all actor images rm -rf public/images/actors/* bun run command:images # Delete single image rm public/images/actors/actor1.jpg bun run command:images # Will regenerate only missing

Cost Estimation

FAL.ai pricing (approximate):

  • Flux Krea: ~$0.03 per image (high quality)
  • Flux Schnell: ~$0.01 per image (fast)

For 50 actors + 25 orgs (300 total images):

  • Profile pics: 75 × 0.03=0.03 = 2.25
  • Banners: 225 × 0.01=0.01 = 2.25
  • Total: ~$4.50

Example

export FAL_KEY=your_key bun run command:images # Generates all missing images with concurrent processing
Last updated on