Files
ubuntu-post-install/paintplus/scripts/README.md
T
Claude 084922afaa paintplus: vendor the app source and rename from EditmaskwithAI
Bring the full EditmaskwithAI application into the repo under paintplus/
(429 files) so the service is self-contained — the installer copies the
vendored source to ~/docker/paintplus/src instead of cloning at runtime.

Rename to PaintPlus (service + branding; app logic untouched):
- services/editmaskwithai.sh -> services/paintplus.sh (register_service
  paintplus, install_paintplus, ~/docker/paintplus, Caddy paintplus:8000,
  Authelia option preserved)
- container names -> paintplus across docker-compose*.yml; dev network
  -> paintplus-network
- browser <title> -> "PaintPlus - AI Image Editor"; README heading ->
  PaintPlus with upstream provenance note
- README utilities table: editmaskwithai -> paintplus

Backend/frontend code (help strings referencing the old container name,
the ai_photo_edit.db filename) is intentionally left as-is to avoid
touching application logic.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Nb2vJ8W7bHKx1JXVvpCraH
2026-06-26 05:48:43 +00:00

3.1 KiB

Classic Eyes Scripts

This directory contains scripts for generating and importing classic eye images into the AI Photo Edit patch library.

Overview

The scripts generate a variety of classic eye styles that can be used as reusable patches for photo editing:

  • Realistic eyes - Detailed eyes with gradient irises and realistic highlights
  • Anime eyes - Large, expressive eyes in anime style with prominent highlights
  • Cartoon eyes - Simple, bold cartoon-style eyes

Each style is available in multiple iris colors: blue, green, brown, hazel, grey, and amber.

Scripts

1. generate_classic_eyes_ppm.py

Generates classic eye images using only the Python standard library (no dependencies required).

python scripts/generate_classic_eyes_ppm.py

This creates PPM format images in data/classic_eyes_ppm/. PPM is a simple image format that can be converted to PNG later.

2. download_classic_eyes.py

Full-featured script that generates eyes and imports them directly into the patch library. Requires PIL/Pillow.

# Run inside the backend container
docker exec -it ai-photo-edit-backend python /app/../scripts/download_classic_eyes.py

# Or with the API running
python scripts/download_classic_eyes.py --api --base-url http://localhost:8101

# Or save to a directory for later import
python scripts/download_classic_eyes.py --output-dir ./my_eyes

3. startup_import_eyes.py

Converts PPM files to PNG and imports them into the patch library. Run this inside the backend container.

docker exec -it ai-photo-edit-backend python /app/../scripts/startup_import_eyes.py

4. import_saved_eyes.py

Import previously saved eye images from a directory.

python scripts/import_saved_eyes.py /path/to/saved/eyes

Quick Start

  1. Generate the eye images (no dependencies needed):

    python scripts/generate_classic_eyes_ppm.py
    
  2. Start the application:

    docker compose up -d
    
  3. Import the eyes:

    docker exec -it ai-photo-edit-backend python /scripts/startup_import_eyes.py
    
  4. Verify in the app: Open the patch library in the UI to see the imported classic eyes.

Generated Eyes

Style Colors Available Size
Realistic Blue, Green, Brown, Hazel, Grey, Amber 200x200
Anime Blue, Green, Brown, Hazel, Grey, Amber 200x200
Cartoon Blue, Green, Brown, Hazel, Grey, Amber 200x200

Total: 18 unique eye variants

Extending

To add more eye styles or colors, edit the generate_classic_eyes_ppm.py or download_classic_eyes.py scripts:

# Add new color
colors["purple"] = (128, 0, 128)

# Add new style in create_classic_eye() function
elif style == "fantasy":
    # Your custom eye drawing code
    pass

File Formats

  • PPM: Portable Pixmap format - simple, universal, generated without dependencies
  • PNG: Preferred format for the patch library - converted from PPM using PIL

License

The generated eye images are created programmatically and are free to use without restrictions.