Photo Studio
Generate professional AI-enhanced portraits and group photos using Seedream 4.5 AI model.
Quick Start
# Interactive mode - easiest way to start
python scripts/main.py generate --photo path/to/your/photo.jpg
# Non-interactive mode - for agent integration
python scripts/main.py generate --photo "$USER_PHOTO" --scenario portrait --non-interactive
Core Workflow
- Select scenario from 9 options: celebrity, portrait, couple, family, edit, fusion, series, poster, free
- Provide inputs: photos, styles, templates, prompts based on scenario
- Generate images: CLI preprocesses photos, calls Seedream 4.5 API, saves results to
output/images/
- Review and save: View, reorder, regenerate, or confirm images
Essential Commands
Generate Images
# Celebrity photos with characters
python scripts/main.py generate --photo "$USER_PHOTO" --scenario celebrity --non-interactive
# Portrait photos with style
python scripts/main.py generate --photo "$USER_PHOTO" --scenario portrait --style "职业商务照" --non-interactive
# Couple photos with pose and background
python scripts/main.py generate --photos "$PHOTO1,$PHOTO2" --scenario couple --pose "手牵手面向镜头" --background "海滩日落" --non-interactive
# Family photos with template
python scripts/main.py generate --photos "$PHOTO1,$PHOTO2,$PHOTO3" --scenario family --template "温馨家庭聚会" --non-interactive
# Edit images (change clothing, material, background, style, enhance)
python scripts/main.py generate --photo "$USER_PHOTO" --scenario edit --template change-clothing --clothing "运动外套" --non-interactive
# Fuse images (outfit, person-scenery, brand, multi-person)
python scripts/main.py generate --photos "$PHOTO1,$PHOTO2" --scenario fusion --template outfit-fusion --non-interactive
# Create series (seasons, brand kit, character states, story sequence)
python scripts/main.py generate --photo "$USER_PHOTO" --scenario series --template seasons --count 4 --non-interactive
# Design poster (movie, event, product)
python scripts/main.py generate --photo "$USER_PHOTO" --scenario poster --template movie-poster --non-interactive
# Free mode with custom prompt
python scripts/main.py generate --photo "$USER_PHOTO" --scenario free --prompt "A futuristic cyberpunk portrait" --non-interactive
List Available Options
# List all scenarios
python scripts/main.py list-scenarios
# List styles for portrait/couple/family/celebrity
python scripts/main.py list-styles --scenario <scenario_id>
# List couple poses
python scripts/main.py list-poses
# List family templates
python scripts/main.py list-templates
# List backgrounds for couple/family
python scripts/main.py list-backgrounds --scenario <scenario_id>
# List characters
python scripts/main.py list-characters
Configuration and Utilities
# View configuration
python scripts/main.py config --show
# Update configuration
python scripts/main.py config --set generation.default_image_count=3
# Add custom character
python scripts/main.py add-character "Character Name" "Description" --scene "Scene"
# Clean temporary files
python scripts/main.py cleanup
Scenarios Overview
| Scenario |
Photos Required |
Key Options |
| Celebrity |
1 |
characters, count |
| Portrait |
1 |
style, count |
| Couple |
2 |
pose, background, count |
| Family |
1-6 |
template, background, count |
| Edit |
1 |
template (5 options), template-specific params |
| Fusion |
1-6 |
template (4 options), template-specific params |
| Series |
1 |
template (4 options), count (4/6/8/10) |
| Poster |
1 |
template (3 options), template-specific params |
| Free |
1-14 |
prompt, negative-prompt, count |
Environment Setup
# Install dependencies
pip install -r requirements.txt
# Set API key (required for operation)
# API key environment variable name: ARK_API_KEY
# API will return error if key is not properly configured
# Mock mode for testing without API (optional)
export MOCK_API=true
Configuration
Key settings in config.json:
generation.image_width / generation.image_height - Image dimensions (default: 2048)
generation.default_image_count - Default number of images (default: 5)
scenarios.default_scenario - Default scenario (default: celebrity)
File Structure
photo-studio-skill/
├── SKILL.md # This file
├── scripts/ # Executable CLI tools
│ └── main.py # Main entry point
├── data/ # Scenario templates and options
├── references/ # Feature documentation
│ ├── celebrity.md # Celebrity photos with movie characters
│ ├── portrait.md # Professional personal portraits
│ ├── couple.md # Couple/friend portraits
│ ├── family.md # Family group photos
│ ├── edit.md # Image editing
│ ├── fusion.md # Multi-photo fusion
│ ├── series.md # Series creation
│ ├── poster.md # Poster design
│ └── free.md # Free mode with custom prompts
├── output/images/ # Generated images
├── temp/ # Temporary files
├── logs/ # Error logs
├── config.json # Configuration settings
├── requirements.txt # Python dependencies
├── AGENTS.md # Agent development guidelines
└── README.md # Project documentation
References
Load these reference files when working with specific features:
Feature Modules:
- references/celebrity.md - Celebrity photos with movie characters
- references/portrait.md - Professional personal portraits with various styles
- references/couple.md - Couple or friend portraits with poses and backgrounds
- references/family.md - Family group photos with templates
- references/edit.md - Image editing (clothing, material, background, style, enhancement)
- references/fusion.md - Multi-photo fusion (outfit, person-scenery, brand, composite)
- references/series.md - Series creation (seasons, brand kit, character states, story)
- references/poster.md - Poster design (movie, event, product)
- references/free.md - Free mode with custom prompts
Technical Notes
Image Generation
- Model: Seedream 4.5 (
doubao-seedream-4.5-251128)
- Resolution: 2048x2048 (configurable)
- Supports 1-14 reference photos
- Uses image-to-image generation with user photos as reference
- Processing time: ~10-20 seconds per image
Multi-Photo Scenarios
- Couple and family scenarios use multi-reference image fusion
- Person count controlled via prompt descriptions (not precise)
Mock Mode Benefits
- No API costs
- Fast testing (500ms instead of 10-20 seconds)
- No network dependency
- Consistent test results
Troubleshooting
Image generation fails:
- Check internet connection
- Verify API key is properly configured (see Environment Setup)
- Ensure photos are clear and well-lit (≥1024×1024 recommended)
- Check
logs/ directory for detailed errors
Common issues:
- Large photos require more processing time
- API rate limits may apply
- Person count in group photos is controlled via prompt (not precise)
1---2name: photo-studio-skill3description: Generate professional AI-enhanced photos using ByteDance Seedream 4.5 model. Use when users want to, (1) Create portraits with various styles, (2) Generate couple or family group photos, (3) Take photos with movie characters, (4) Edit images (change clothing, background, material, style), (5) Merge multiple photos (outfit fusion, person-scenery fusion, brand design), (6) Create series of related images (seasons, character states, story sequences), (7) Design posters (movie, event, product), or (8) Use custom prompts with full creative control.4---56# Photo Studio78Generate professional AI-enhanced portraits and group photos using Seedream 4.5 AI model.910## Quick Start1112```bash13# Interactive mode - easiest way to start14python scripts/main.py generate --photo path/to/your/photo.jpg1516# Non-interactive mode - for agent integration17python scripts/main.py generate --photo "$USER_PHOTO" --scenario portrait --non-interactive18```1920## Core Workflow21221. **Select scenario** from 9 options: celebrity, portrait, couple, family, edit, fusion, series, poster, free232. **Provide inputs**: photos, styles, templates, prompts based on scenario243. **Generate images**: CLI preprocesses photos, calls Seedream 4.5 API, saves results to `output/images/`254. **Review and save**: View, reorder, regenerate, or confirm images2627## Essential Commands2829### Generate Images3031```bash32# Celebrity photos with characters33python scripts/main.py generate --photo "$USER_PHOTO" --scenario celebrity --non-interactive3435# Portrait photos with style36python scripts/main.py generate --photo "$USER_PHOTO" --scenario portrait --style "职业商务照" --non-interactive3738# Couple photos with pose and background39python scripts/main.py generate --photos "$PHOTO1,$PHOTO2" --scenario couple --pose "手牵手面向镜头" --background "海滩日落" --non-interactive4041# Family photos with template42python scripts/main.py generate --photos "$PHOTO1,$PHOTO2,$PHOTO3" --scenario family --template "温馨家庭聚会" --non-interactive4344# Edit images (change clothing, material, background, style, enhance)45python scripts/main.py generate --photo "$USER_PHOTO" --scenario edit --template change-clothing --clothing "运动外套" --non-interactive4647# Fuse images (outfit, person-scenery, brand, multi-person)48python scripts/main.py generate --photos "$PHOTO1,$PHOTO2" --scenario fusion --template outfit-fusion --non-interactive4950# Create series (seasons, brand kit, character states, story sequence)51python scripts/main.py generate --photo "$USER_PHOTO" --scenario series --template seasons --count 4 --non-interactive5253# Design poster (movie, event, product)54python scripts/main.py generate --photo "$USER_PHOTO" --scenario poster --template movie-poster --non-interactive5556# Free mode with custom prompt57python scripts/main.py generate --photo "$USER_PHOTO" --scenario free --prompt "A futuristic cyberpunk portrait" --non-interactive58```5960### List Available Options6162```bash63# List all scenarios64python scripts/main.py list-scenarios6566# List styles for portrait/couple/family/celebrity67python scripts/main.py list-styles --scenario <scenario_id>6869# List couple poses70python scripts/main.py list-poses7172# List family templates73python scripts/main.py list-templates7475# List backgrounds for couple/family76python scripts/main.py list-backgrounds --scenario <scenario_id>7778# List characters79python scripts/main.py list-characters80```8182### Configuration and Utilities8384```bash85# View configuration86python scripts/main.py config --show8788# Update configuration89python scripts/main.py config --set generation.default_image_count=39091# Add custom character92python scripts/main.py add-character "Character Name" "Description" --scene "Scene"9394# Clean temporary files95python scripts/main.py cleanup96```9798## Scenarios Overview99100| Scenario | Photos Required | Key Options |101|----------|----------------|-------------|102| Celebrity | 1 | characters, count |103| Portrait | 1 | style, count |104| Couple | 2 | pose, background, count |105| Family | 1-6 | template, background, count |106| Edit | 1 | template (5 options), template-specific params |107| Fusion | 1-6 | template (4 options), template-specific params |108| Series | 1 | template (4 options), count (4/6/8/10) |109| Poster | 1 | template (3 options), template-specific params |110| Free | 1-14 | prompt, negative-prompt, count |111112## Environment Setup113114```bash115# Install dependencies116pip install -r requirements.txt117118# Set API key (required for operation)119# API key environment variable name: ARK_API_KEY120# API will return error if key is not properly configured121122# Mock mode for testing without API (optional)123export MOCK_API=true124```125126## Configuration127128Key settings in `config.json`:129- `generation.image_width` / `generation.image_height` - Image dimensions (default: 2048)130- `generation.default_image_count` - Default number of images (default: 5)131- `scenarios.default_scenario` - Default scenario (default: celebrity)132133## File Structure134135```136photo-studio-skill/137 ├── SKILL.md # This file138 ├── scripts/ # Executable CLI tools139 │ └── main.py # Main entry point140 ├── data/ # Scenario templates and options141 ├── references/ # Feature documentation142 │ ├── celebrity.md # Celebrity photos with movie characters143 │ ├── portrait.md # Professional personal portraits144 │ ├── couple.md # Couple/friend portraits145 │ ├── family.md # Family group photos146 │ ├── edit.md # Image editing147 │ ├── fusion.md # Multi-photo fusion148 │ ├── series.md # Series creation149 │ ├── poster.md # Poster design150 │ └── free.md # Free mode with custom prompts151 ├── output/images/ # Generated images152 ├── temp/ # Temporary files153 ├── logs/ # Error logs154 ├── config.json # Configuration settings155 ├── requirements.txt # Python dependencies156 ├── AGENTS.md # Agent development guidelines157 └── README.md # Project documentation158```159160## References161162Load these reference files when working with specific features:163164**Feature Modules:**165- **[references/celebrity.md](references/celebrity.md)** - Celebrity photos with movie characters166- **[references/portrait.md](references/portrait.md)** - Professional personal portraits with various styles167- **[references/couple.md](references/couple.md)** - Couple or friend portraits with poses and backgrounds168- **[references/family.md](references/family.md)** - Family group photos with templates169- **[references/edit.md](references/edit.md)** - Image editing (clothing, material, background, style, enhancement)170- **[references/fusion.md](references/fusion.md)** - Multi-photo fusion (outfit, person-scenery, brand, composite)171- **[references/series.md](references/series.md)** - Series creation (seasons, brand kit, character states, story)172- **[references/poster.md](references/poster.md)** - Poster design (movie, event, product)173- **[references/free.md](references/free.md)** - Free mode with custom prompts174175## Technical Notes176177### Image Generation178179- Model: Seedream 4.5 (`doubao-seedream-4.5-251128`)180- Resolution: 2048x2048 (configurable)181- Supports 1-14 reference photos182- Uses image-to-image generation with user photos as reference183- Processing time: ~10-20 seconds per image184185### Multi-Photo Scenarios186187- Couple and family scenarios use multi-reference image fusion188- Person count controlled via prompt descriptions (not precise)189190### Mock Mode Benefits191192- No API costs193- Fast testing (500ms instead of 10-20 seconds)194- No network dependency195- Consistent test results196197## Troubleshooting198199**Image generation fails:**200- Check internet connection201- Verify API key is properly configured (see Environment Setup)202- Ensure photos are clear and well-lit (≥1024×1024 recommended)203- Check `logs/` directory for detailed errors204205**Common issues:**206- Large photos require more processing time207- API rate limits may apply208- Person count in group photos is controlled via prompt (not precise)