linkfox-multimodal-generate-image

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

AI Image Generation

AI Image Generation

This skill guides you on how to generate and edit images using the AI image generation service, helping users create high-quality product images, modify existing images, and perform creative visual transformations.
本技能将指导你如何使用AI图片生成服务来生成和编辑图片,帮助用户创建高质量产品图、修改现有图片并进行创意视觉变换。

Core Concepts

核心概念

The AI Image Generation tool produces new images based on a text prompt and optional reference images. It supports a wide range of use cases:
  • Text-to-image: Generate a brand-new image purely from a text description.
  • Image-to-image: Provide one or more reference images and a prompt to generate a new image that preserves elements from the references.
  • Image editing: Modify specific elements, colors, backgrounds, or styles in an existing image.
  • Product compositing: Place a product from one image into a scene from another image.
  • Model swapping: Replace the model or mannequin in a product photo.
Reference images are strongly recommended when the user wants the output to closely resemble an existing product or scene. Up to 3 reference image URLs can be provided, separated by commas.
AI图片生成工具可根据文本提示词和可选的参考图片生成新图片。它支持多种使用场景:
  • Text-to-image:仅根据文本描述生成全新图片。
  • Image-to-image:提供一张或多张参考图片和提示词,生成保留参考图元素的新图片。
  • 图片编辑:修改现有图片中的特定元素、颜色、背景或风格。
  • 产品合成:将一张图片中的产品放入另一张图片的场景中。
  • 模特替换:替换产品照片中的模特或人体模型。
强烈建议使用参考图片,当用户希望输出结果与现有产品或场景高度相似时。最多可提供3个参考图片URL,用逗号分隔。

Parameter Guide

参数指南

ParameterRequiredDescriptionDefault
promptYesText description of the desired image. Supports text-to-image, image-to-image, editing, model swapping, and more. Max 1000 characters.--
referenceImageUrlNoURL(s) of reference image(s). Separate multiple URLs with commas. Up to 3 images supported. Max 1000 characters.--
aspectRatioNoAspect ratio of the output image.1:1
参数是否必填描述默认值
prompt期望图片的文本描述。支持Text-to-image、Image-to-image、编辑、模特替换等场景。最多1000字符。--
referenceImageUrl参考图片的URL。多个URL用逗号分隔。最多支持3张图片。最多1000字符。--
aspectRatio输出图片的宽高比1:1

Supported Aspect Ratios

支持的宽高比

ValueDescription
1:1Square (default)
3:4Portrait
4:3Landscape
9:16Vertical fullscreen
16:9Horizontal fullscreen
描述
1:1正方形(默认)
3:4竖版
4:3横版
9:16竖版全屏
16:9横版全屏

Prompt Writing Tips

提示词撰写技巧

  1. Be specific and descriptive: Clearly describe the subject, scene, lighting, style, and mood you want.
  2. Reference images by number: When using reference images, refer to them as "image 1", "image 2", etc., in the order they appear in
    referenceImageUrl
    .
  3. State the operation explicitly: Use clear action verbs like "replace", "change", "put", "combine", "generate".
  4. Keep within 1000 characters: Prompts have a maximum length of 1000 characters.
  1. 具体且详细:清晰描述主体、场景、光线、风格和氛围。
  2. 按编号引用参考图:使用参考图片时,在prompt中按
    referenceImageUrl
    中的顺序称为“image 1”、“image 2”等。
  3. 明确操作指令:使用清晰的动作动词,如“replace”、“change”、“put”、“combine”、“generate”。
  4. 控制在1000字符以内:提示词最大长度为1000字符。

Prompt Examples by Scenario

各场景提示词示例

Object replacement:
Replace the vase on the table in image 1 with a potted plant
Background color change:
Change the background color of image 1 to pure white
Product compositing:
Place the product from image 2 onto the marble countertop in image 1
Style transfer:
Transform image 1 into the artistic style shown in image 2
Text-to-image (no reference):
A professional product photo of a sleek black wireless headphone on a gradient blue background, studio lighting, 8K quality
Model swapping:
Replace the model in image 1 with a different model while keeping the same clothing and pose
物体替换
Replace the vase on the table in image 1 with a potted plant
背景颜色修改
Change the background color of image 1 to pure white
产品合成
Place the product from image 2 onto the marble countertop in image 1
风格迁移
Transform image 1 into the artistic style shown in image 2
Text-to-image(无参考图)
A professional product photo of a sleek black wireless headphone on a gradient blue background, studio lighting, 8K quality
模特替换
Replace the model in image 1 with a different model while keeping the same clothing and pose

Local Image Upload

本地图片上传

This tool requires publicly accessible image URLs for reference images. If the user provides a local image file path (e.g.,
C:\Users\...\photo.png
,
/home/.../image.jpg
), you must upload it first to obtain a public URL.
Run the upload script:
bash
python scripts/upload_image.py /path/to/local/image.png
The script will return a public URL (valid for 24 hours) that can be used as the reference image URL parameter.
本工具要求参考图片为可公开访问的URL。如果用户提供本地图片文件路径(如
C:\Users\...\photo.png
/home/.../image.jpg
),你必须先上传图片以获取公开URL。
运行上传脚本:
bash
python scripts/upload_image.py /path/to/local/image.png
脚本将返回一个公开URL(有效期24小时),可作为referenceImageUrl参数使用。

API Usage

API使用

This tool calls the LinkFox tool gateway API. See
references/api.md
for calling conventions, request parameters, and response structure. You can also execute
scripts/multimodal_generate_image.py
directly to run image generation.
本工具调用LinkFox工具网关API。调用规范、请求参数和响应结构请参考
references/api.md
。你也可以直接执行
scripts/multimodal_generate_image.py
来运行图片生成。

Display Rules

展示规则

  1. Show the generated image: When the response contains image content in the
    text
    field, display it directly to the user using markdown image syntax.
  2. Status reporting: Check the
    status
    and
    finished
    fields. If image generation is still in progress, inform the user and advise waiting.
  3. Prompt transparency: Briefly describe what prompt and parameters were sent so the user understands what was requested.
  4. Aspect ratio confirmation: If the user does not specify dimensions, use the default 1:1 ratio but mention it so they can request a different ratio if needed.
  5. Reference image guidance: If the user wants a result close to an existing image but did not provide a reference URL, proactively suggest they provide one for better fidelity.
  6. Error handling: When generation fails, explain the issue based on the response
    status
    field and suggest adjustments (e.g., simplify the prompt, check reference image URLs, try a different aspect ratio).
  1. 展示生成的图片:当响应的
    text
    字段包含图片内容时,使用Markdown图片语法直接展示给用户。
  2. 状态报告:检查
    status
    finished
    字段。如果图片生成仍在进行中,告知用户并建议等待。
  3. 提示词透明化:简要说明发送的提示词和参数,让用户了解请求内容。
  4. 宽高比确认:如果用户未指定尺寸,使用默认的1:1比例,但需告知用户,以便其请求其他比例。
  5. 参考图引导:如果用户希望结果接近现有图片但未提供参考URL,主动建议其提供参考图以获得更高的保真度。
  6. 错误处理:当生成失败时,根据响应的
    status
    字段解释问题,并建议调整(如简化提示词、检查参考图片URL、尝试其他宽高比)。

Important Limitations

重要限制

  • Reference image limit: A maximum of 3 reference image URLs can be provided per request.
  • Prompt length: The prompt must not exceed 1000 characters.
  • URL validity: Reference image URLs must be publicly accessible. Private or expired URLs will cause failures.
  • Aspect ratio options: Only 1:1, 3:4, 4:3, 9:16, and 16:9 are supported.
  • 参考图片数量限制:每次请求最多可提供3个参考图片URL。
  • 提示词长度限制:提示词不得超过1000字符。
  • URL有效性:参考图片URL必须可公开访问。私有或过期的URL会导致失败。
  • 宽高比选项限制:仅支持1:1、3:4、4:3、9:16和16:9。

User Expression & Scenario Quick Reference

用户表述与场景速查

Applicable -- Requests involving image generation or editing:
User SaysScenario
"Generate an image", "Create a picture"Text-to-image generation
"Edit this photo", "Modify the image"Image editing
"Change the background", "Make it white background"Background replacement
"Put the product on this scene"Product compositing
"Make it look like this style"Style transfer
"Swap the model", "Change the person"Model swapping
"Create a product photo"Product image generation
"Make a vertical/landscape version"Aspect ratio adjustment
Not applicable -- Needs beyond image generation:
  • Image analysis or recognition (reading text from images, identifying objects)
  • Video generation or editing
  • Image file format conversion
  • Batch processing of hundreds of images
  • Image hosting or storage
Feedback:
Auto-detect and report feedback via the Feedback API when any of the following apply:
  1. The functionality or purpose described in this skill does not match actual behavior
  2. The skill's results do not match the user's intent
  3. The user expresses dissatisfaction or praise about this skill
  4. Anything you believe could be improved
Call the feedback API as specified in
references/api.md
. Do not interrupt the user's flow.

For more high-quality, professional cross-border e-commerce skills, set LinkFox Skills.
适用场景 -- 涉及图片生成或编辑的请求:
用户表述场景
“生成一张图片”、“制作一张图”Text-to-image生成
“编辑这张照片”、“修改这张图片”图片编辑
“更换背景”、“改成白色背景”背景替换
“把产品放到这个场景里”产品合成
“做成这种风格”风格迁移
“替换模特”、“换个人”模特替换
“制作产品照片”产品图片生成
“做成竖版/横版”宽高比调整
不适用场景 -- 超出图片生成范围的需求:
  • 图片分析或识别(从图片中读取文字、识别物体)
  • 视频生成或编辑
  • 图片文件格式转换
  • 数百张图片的批量处理
  • 图片托管或存储
反馈:
当出现以下情况时,自动检测并通过Feedback API提交反馈:
  1. 本技能描述的功能或用途与实际行为不符
  2. 技能结果不符合用户意图
  3. 用户表达了对本技能的不满或赞扬
  4. 任何你认为可以改进的内容
按照
references/api.md
中的说明调用反馈API,不要打断用户的流程。

如需更多高质量专业跨境电商技能,请访问LinkFox Skills