界面已本地化;技能介绍与说明文档按所选语言由 AI 自动翻译,代码、命令、路径和专业术语保留原文,以原作者文档为准。
探索技能
效率与协作 · SKILL.md

realistic-background

realistic-background

【效率与协作】Editing Image Background | AI Background Replacement. Replace image backgrounds with realistic AI-generated scenes. Triggers: background replacement, change background, realistic background, background editing, background swap

独立 GitHub 快照 · 自动分类 · 以原作者文档为准

技能说明

GitHub

name: realistic-background description: "Editing Image Background | AI Background Replacement. Replace image backgrounds with realistic AI-generated scenes. Triggers: background replacement, change background, realistic background, background editing, background swap" allowed-tools: Bash(curl *), WebFetch

Editing Image Background

Replace image backgrounds with realistic AI-generated scenes. Automatically segments the foreground subject and generates a new background based on a text prompt.

Quick Start

Requires an each::labs API key. Get one at eachlabs.ai.

curl -X POST https://api.eachlabs.ai/v1/prediction \
  -H "Content-Type: application/json" \
  -H "X-API-Key: $EACHLABS_API_KEY" \
  -d '{
    "model": "realistic-background",
    "version": "0.0.1",
    "input": {
      "image": "https://example.com/product-photo.jpg",
      "prompt": "RAW photo, 8k uhd, dslr, soft lighting, high quality, modern kitchen countertop with marble surface",
      "cfg_scale": 7,
      "steps": 20,
      "denoising_strength": 0.75
    }
  }'

Parameters

ParameterTypeDefaultDescription
cfg_scaleinteger7CFG scale for guidance strength
denoising_strengthnumber0.75Denoising strength
imagestring-Image to replace background
max_heightinteger1024Maximum output height
max_widthinteger1024Maximum output width
negative_promptstring(deformed, distorted, disfigured:1.3), poorly drawn, bad anatomy...Negative prompt
only_masked_padding_pixelsinteger4Only masked padding pixels
promptstringRAW photo, 8k uhd, dslr, soft lighting, high quality, film grain, Fujifilm XT3Prompt for background generation
sampler_namestringDPM++ SDE KarrasSampler. enum: DPM++ 2M, DPM++ SDE, DPM++ 2M SDE, DPM++ 2M SDE Heun, DPM++ 2S a, DPM++ 3M SDE, Euler a, Euler, LMS, Heun, DPM2, DPM2 a, DPM fast, DPM adaptive, Restart
seedinteger1Seed
stepsinteger20Steps

Examples

Product on a studio surface:

curl -X POST https://api.eachlabs.ai/v1/prediction \
  -H "Content-Type: application/json" \
  -H "X-API-Key: $EACHLABS_API_KEY" \
  -d '{
    "model": "realistic-background",
    "version": "0.0.1",
    "input": {
      "image": "https://example.com/watch-photo.jpg",
      "prompt": "RAW photo, 8k uhd, luxury product photography, dark slate surface, dramatic studio lighting, soft reflections",
      "cfg_scale": 8,
      "steps": 25,
      "denoising_strength": 0.8,
      "sampler_name": "DPM++ SDE Karras"
    }
  }'

Portrait with outdoor background:

curl -X POST https://api.eachlabs.ai/v1/prediction \
  -H "Content-Type: application/json" \
  -H "X-API-Key: $EACHLABS_API_KEY" \
  -d '{
    "model": "realistic-background",
    "version": "0.0.1",
    "input": {
      "image": "https://example.com/portrait.jpg",
      "prompt": "RAW photo, 8k uhd, beautiful cherry blossom garden in spring, soft natural lighting, bokeh background",
      "cfg_scale": 7,
      "steps": 20,
      "denoising_strength": 0.7,
      "seed": 42
    }
  }'

Related Models

Documentation

我的收藏