商品平铺图提取 Clothing Extraction
БесплатноЗапускает вложенные скриптыНе проверен从任意图提取干净商品平铺图。真人图 / 街拍图 → 白底平铺商品图。当用户说「提取衣服」「扒图」「转平铺」「抠成商品图」「从买家秀提取」时使用。
от dlazyai2 468 установок в других каталогахОб этом скилле
clothing-extraction — 从任意图中提取商品平铺图
任意一张图 → 干净的商品平铺图。这是 flat-lay 的逆操作。
最常见的用途是补素材:手上只有一张真人上身图 / 买家秀 / 竞品截图,但主图位需要一张干净平铺图;或者要把它作为 to-3d、fabric-on-body、flat-lay 的干净输入。
生成效果示例
| 输入:任意图 |
|---|
![]() |
source-photo.jpg — 真人街拍图:浅灰针织连衣裙 + 珍珠项链 + 托特包 + 银色高跟鞋,480×640 |
实际执行的命令:
dlazy gpt-image-2 \
--prompt 'Extract the garment worn by the model in this photo and render it as a clean e-commerce flat-lay. Output only the light-grey textured sleeveless knit mini dress with the mock neckline, laid flat and centred, front view, symmetric, fully unoccluded — remove the model, the pearl necklace, the tote bag, the shoes, the fountain and the whole background. Keep the garment 100% faithful: same light-grey colour, same knit texture, same neckline and armhole shape, same waist seam and hem length. Pure white seamless background, even soft studio light, subtle contact shadow. No person, no props, no text.' \
--images docs/clothing-extraction/source-photo.jpg \
--size 1024x1024 --quality medium --imageFormat jpeg \
--save docs/clothing-extraction/example-output.jpg
输出

example-output.jpg — 1024×1024。模特、项链、托特包、高跟鞋与喷泉背景全部清除,只留连衣裙;摊平居中、左右对称,立领罗纹、袖窿形状、腰线接缝与裙长按原图还原,浅灰针织纹理保留。
1、能力边界
| 模板 | 说明 |
|---|---|
| 整套穿搭 | 一次识别全身多件,分别输出上装 / 下装 / 鞋 / 包的平铺图 |
| 上装正面 | 只提取上装,正面摊平 |
| 下装正面 | 只提取下装,正面摊平 |
| 自定义 | 自己描述要提取哪一件、以什么形态输出 |
| 能做 | 说明 |
|---|---|
| 去人去景 | 模特、道具、背景全部移除 |
| 摊平对称 | 输出正面、居中、左右对称的平铺形态 |
| 遮挡补全 | 被手臂/包袋挡住的部分按对称与常规版型推断补出 |
不做:不改颜色、图案与版型;不凭空添加原图没有的设计元素;不用于抹除他人品牌标识后冒充自有商品。
2、输入素材规则
生成前先自检这几条硬性约束:
- 大小:20KB ~ 15MB
- 分辨率:大于 400×400
- 格式:jpg / jpeg / png / webp
输入建议
| 做法 | 说明 |
|---|---|
| ✅ 商品在画面中占比大 | 占比越大,织法与图案还原得越准 |
| ✅ 正面或微侧角度 | 纯背面图推不出前襟结构 |
| ✅ 光线均匀 | 强阴影会被当成图案 |
| ⚠️ 遮挡区域 | 手臂、包、头发挡住的部分是推断出来的,不是还原——关键设计位被挡住时要人工确认 |
| ❌ 极小占比 / 严重模糊 | 只能得到一个大概的形状 |
3、提取指令的四段结构
【段1 · 指定目标】Output only the [唯一要保留的单品,写清品类+颜色+关键特征].
【段2 · 逐项清除】Remove the model, [列出画面里所有其他元素:配饰/包/鞋/道具/背景].
【段3 · 输出形态】Laid flat and centred, front view, symmetric, fully unoccluded.
【段4 · 保真项】Keep the garment 100% faithful: same [颜色], [织法/面料], [领口与袖型], [腰线与下摆长度].
段2 必须逐项点名。只写 remove the background 时,项链、包、鞋会被留在画面里当成商品的一部分。
整套穿搭 = 跑多次,每次段1 指定一件、段2 把其余全部列为要清除的对象。别指望一次输出多张。
4、工具调用
本技能使用 dLazy 的 gpt-image-2(图像编辑模型;提取的本质是「保留一个目标 + 清除其余 + 重构形态」,需要强指令跟随与对象级理解)。
调用方式
两种等价写法,选一种。统一入口会自动选后端、失败重试、建目录落盘、估算成本:
# A. 统一入口(推荐):可切任意后端,加 --dry-run 不计费空跑
node scripts/gen.mjs --task clothing-extraction \
--prompt '<见下方 Prompt 模板>' \
--images <按下表顺序> \
--save output/clothing-extraction-<sku>.jpg
# B. 直接用 dLazy CLI(不想引入 Node 依赖时,效果等价)
dlazy gpt-image-2 --prompt '...' --images ... --save output/clothing-extraction.jpg
参数约定(本技能固定用法)
| 参数 | 取值 | 理由 |
|---|---|---|
--images |
[原图] |
单图输入 |
--size |
1024x1024(平铺图标准方图) |
平铺主图通常是方图 |
--quality |
high |
织法与图案还原全靠这档 |
--imageFormat |
png(想要留白边界更干净)/ jpeg |
png 便于后续二次抠图 |
--batch |
2 ~ 3 |
遮挡补全有随机性 |
--save |
docs/clothing-extraction/output-<件名>.jpg |
一件一个文件 |
Command Examples
# basic call: 提取上装
dlazy gpt-image-2 \
--prompt 'Extract the garment worn by the model and render it as a clean e-commerce flat-lay. Output only the top. Remove the model, accessories, bag, shoes and the whole background. Laid flat and centred, front view, symmetric, fully unoccluded. Keep the garment faithful: same colour, texture, neckline and hem. Pure white seamless background, subtle contact shadow. No person, no props, no text.' \
--images docs/clothing-extraction/source-photo.jpg \
--size 1024x1024 --quality high
# complex call: 整套穿搭 → 循环逐件提取
SRC=docs/clothing-extraction/source-photo.jpg
提取() { # $1=件名 $2=目标描述 $3=要清除的其余元素
dlazy gpt-image-2 \
--prompt "Extract one garment from this photo and render it as a clean e-commerce flat-lay. Output only $2. Remove the model, $3 and the whole background. Laid flat and centred, front view, symmetric, fully unoccluded; infer any occluded area from symmetry and standard garment construction. Keep it 100% faithful: same colour, same fabric texture, same neckline and armhole shape, same seams and hem length. Pure white seamless background, even soft studio light, subtle contact shadow. No person, no props, no text." \
--images "$SRC" --size 1024x1024 --quality high --imageFormat p
Установить 商品平铺图提取 Clothing Extraction в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл 商品平铺图提取 Clothing Extraction?
从任意图提取干净商品平铺图。真人图 / 街拍图 → 白底平铺商品图。当用户说「提取衣服」「扒图」「转平铺」「抠成商品图」「从买家秀提取」时使用。
Как установить скилл 商品平铺图提取 Clothing Extraction?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл 商品平铺图提取 Clothing Extraction запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
theme-factory
Toolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with…
от Anthropicaccess
Manage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropicconfigure
Set up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how…
от Anthropicaccess
Manage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropic