A blackbox FAL serverless service that applies professional photo editing inspirations to images using Google's Nano Banana model.
- 🎨 8 Professional Inspirations - Variations, marketplace, cinematic, and more
- 🖼️ Always 3 Images - Consistent output for every request
- 📐 Aspect Ratio Support - 1:1, 16:9, 4:3, and more
- ⚡ Fast & Scalable - CPU-optimized, scales to zero
- 🔒 Blackbox Design - Simple API, complex prompts handled internally
Playground: https://fal.ai/models/Adc/stock-inspirations/
API:
- Async (Recommended):
https://queue.fal.run/Adc/stock-inspirations/ - Sync:
https://fal.run/Adc/stock-inspirations/
pip install fal-client python-dotenvCreate .env file:
FAL_KEY=your-fal-api-key-hereimport fal_client
# Upload your image
image_url = fal_client.upload_file("your_image.jpg")
# Apply inspiration
handler = await fal_client.submit_async(
"Adc/stock-inspirations",
arguments={
"inspiration_name": "marketplace_pure",
"image_urls": [image_url],
"aspect_ratio": "1:1", # Optional
"extra_prompt": "vibrant colors" # Optional
}
)
result = await handler.get()
# Get your 3 generated images
for img in result['images']:
print(img['url'])| Inspiration | Description | Images Required |
|---|---|---|
variations |
Professional variations with different styles | 1 |
marketplace_pure |
Clean product photography (white background) | 1 |
marketplace_lifestyle |
Lifestyle marketplace photography with context | 1 |
change_pose |
Change subject pose while maintaining identity | 1 |
style_cinematic |
Apply cinematic film photography style | 1 |
background_white |
Replace background with white studio background | 1 |
enhance |
Enhance image quality and sharpness | 1 |
fuse_images |
Combine multiple images into compositions | 2-5 |
Supported aspect ratios (optional):
21:9- Ultra-wide16:9- Widescreen4:3- Standard3:2- Classic photo1:1- Square9:16- Vertical- And more...
{
"inspiration_name": str, # Required: Name of inspiration
"image_urls": List[str], # Required: List of image URLs
"aspect_ratio": str, # Optional: Output aspect ratio
"extra_prompt": str # Optional: Additional instructions
}{
"success": bool,
"images": [
{"url": str, "index": int}, # 3 images
{"url": str, "index": int},
{"url": str, "index": int}
],
"inspiration_name": str,
"prompt_used": str,
"aspect_ratio": str,
"processing_time": float,
"request_id": str,
"error": str # Only if success=False
}Run examples:
python example_usage.pyTest deployed endpoint:
python test_deployed_endpoint.py# Authenticate
fal auth login
# Deploy
bash deploy.sh
# or
fal deploy stock_inspirations_app.py# Create virtual environment
python -m venv venv
source venv/bin/activate # or: venv\Scripts\activate on Windows
# Install dependencies
pip install -r requirements.txt
# Run examples
python example_usage.py- Machine Type: M (CPU) - Fast deployment, low cost
- Concurrency: 0-2 workers, scales to zero
- Timeout: 120s per request
- Engine: Google Nano Banana Edit model via FAL
Typical processing time: 9-11 seconds per request
Cost: Based on FAL's nano-banana/edit pricing
MIT