Bria Lifestyle Product Shot by Text
Transform isolated product images into dynamic lifestyle scenes with AI-driven contextual realism.
API
If you're looking for an API, you can choose from your desired programming language.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
import requests
import base64
# Use this function to convert an image file from the filesystem to base64
def image_file_to_base64(image_path):
with open(image_path, 'rb') as f:
image_data = f.read()
return base64.b64encode(image_data).decode('utf-8')
# Use this function to fetch an image from a URL and convert it to base64
def image_url_to_base64(image_url):
response = requests.get(image_url)
image_data = response.content
return base64.b64encode(image_data).decode('utf-8')
# Use this function to convert a list of image URLs to base64
def image_urls_to_base64(image_urls):
return [image_url_to_base64(url) for url in image_urls]
api_key = "YOUR_API_KEY"
url = "https://api.segmind.com/v1/bria-lifestyle-shot-by-text"
# Request payload
data = {
"fast": True,
"image_url": "https://segmind-resources.s3.amazonaws.com/input/e7c734c4-9c4a-42f6-8df0-dc946b863191-45d0cf11ce028ea08ddf7aca1c2c38ad.jpeg",
"scene_description": "A classroom setting with desks and books",
"optimize_description": True,
"exclude_elements": "no people",
"placement_type": "automatic",
"original_quality": False,
"force_rmbg": False,
"content_moderation": False
}
headers = {'x-api-key': api_key}
response = requests.post(url, json=data, headers=headers)
print(response.content) # The response is the generated image
Attributes
Optional SKU identifier for tracking products. Use unique codes for easier inventory management.
Fast mode balances speed and quality. Set to true for quick generation or false for detailed results.
URL of the product image to blend in a scene. Use high-res images for quality outputs.
Describes the scene for the product. Use vivid settings like 'modern office desk' for best results.
Enables AI to enhance scene details. Set true to enhance scene realism or false to use the basic description.
Specifies elements to exclude from the scene. Use 'no people' to remove human figures.
Determines product placement control. Choose 'original' for fixed spots or 'automatic' for varied angles.
Allowed values:
Maintains image quality if true. Toggle on to preserve details in original placement mode.
Defines output image proportions. Set '16:9' for widescreen or '1:1' for a square frame.
Allowed values:
Forces removal of backgrounds. Use true to cleanly isolate product images from noisy backgrounds.
Applies moderation to visuals. Enable for content checks before generation or disable for faster processing.
To keep track of your credit usage, you can inspect the response headers of each API call. The x-remaining-credits property will indicate the number of remaining credits in your account. Ensure you monitor this value to avoid any disruptions in your API usage.
Resources to get you started
Everything you need to know to get the most out of Bria Lifestyle Product Shot by Text
Efficient Guide to Using the Model
This guide walks you through key parameters, recommended settings, and best practices to get the most out of your image‐generation model. Whether you need quick mockups or high-fidelity product shots, these tips will streamline your workflow.
1. Understanding Core Parameters
- •fast (boolean)
- •true: faster results with balanced fidelity
- •false: slower but more detailed outputs
- •image_url (string)
- •High-resolution URLs yield crisper blends.
- •scene_description (string)
- •Vivid, concise phrases (e.g., “modern office desk with succulents”).
- •optimize_description (boolean)
- •true: AI enriches and refines the scene
- •false: sticks to your raw description
- •exclude_elements (string)
- •Specify unwanted items (e.g., “no people,” “no shadows”).
- •placement_type (enum)
- •original, automatic, manual_placement, etc., to control product position.
- •aspect_ratio (enum)
- •Common: 1:1 (social), 16:9 (widescreen), 9:16 (mobile stories).
- •force_rmbg (boolean)
- •true: removes background noise for a clean product cutout.
- •content_moderation (boolean)
- •true: checks for policy violations; adds slight latency.
2. Recommended Settings by Use Case
A. Quick Prototyping & Internal Reviews
- •fast: true
- •optimize_description: false
- •placement_type: automatic
- •aspect_ratio: 4:3
- •force_rmbg: false
- •content_moderation: false
→ Generates rapid drafts for team feedback.
B. High-Quality E-Commerce Shots
- •fast: false
- •optimize_description: true
- •placement_type: original (keep product angle consistent)
- •original_quality: true
- •aspect_ratio: 1:1 or 4:5
- •force_rmbg: true
- •content_moderation: true
→ Ensures pristine, brand-compliant visuals.
C. Social Media & Marketing Banners
- •fast: true
- •optimize_description: true
- •placement_type: automatic_aspect_ratio
- •aspect_ratio: 16:9 or 9:16
- •force_rmbg: optional
→ Balances speed and creative flexibility for campaigns.
D. Custom Layouts & Collages
- •fast: false
- •optimize_description: false
- •placement_type: manual_placement or custom_coordinates
- •aspect_ratio: Choose based on final canvas
- •force_rmbg: true
→ Perfect for multi-product collages and bespoke layouts.
3. Tips for Best Results
- •Use High-Res Inputs: Provide ≥1024×1024px images.
- •Be Specific: Rich scene descriptions (colors, lighting, props) reduce iterations.
- •Iterate Gradually: Start with fast mode, then switch to detailed (fast=false) for final polish.
- •Leverage Exclusions: Filter out unwanted elements to reduce manual retouching.
- •Test Aspect Ratios: Match output dimensions to platform requirements up front.
By tailoring these parameters to your project goals, you’ll achieve consistent, high-impact visuals with minimal trial and error.
Other Popular Models
Discover other models you might be interested in.
sdxl-controlnet
SDXL ControlNet gives unprecedented control over text-to-image generation. SDXL ControlNet models Introduces the concept of conditioning inputs, which provide additional information to guide the image generation process

idm-vton
Best-in-class clothing virtual try on in the wild

faceswap-v2
Take a picture/gif and replace the face in it with a face of your choice. You only need one image of the desired face. No dataset, no training

sdxl-inpaint
This model is capable of generating photo-realistic images given any text input, with the extra capability of inpainting the pictures by using a mask
