inpainting
Edit specific areas of an image by applying text prompts to mask and inpaint designated regions, enabling targeted modifications while preserving image integrity.
Instructions
Inpaint a specific part of an image using a text mask prompt.
Args:
image_path: File path of the original image
prompt: Text prompt for the area to be inpainted
mask_prompt: Text prompt for specifying the area to be masked (e.g., "window", "car")
negative_prompt: Text prompt for excluding attributes from generation
height: Output image height (pixels)
width: Output image width (pixels)
cfg_scale: Image matching degree for the prompt (1-20)
open_browser: Whether to open the image in the browser after generation
Returns:
Dict: Dictionary containing the file path of the inpainted image
Input Schema
Name | Required | Description | Default |
---|---|---|---|
cfg_scale | No | ||
height | No | ||
image_path | Yes | ||
mask_prompt | Yes | ||
negative_prompt | No | ||
open_browser | No | ||
prompt | Yes | ||
width | No |
Input Schema (JSON Schema)
{
"properties": {
"cfg_scale": {
"default": 8,
"title": "Cfg Scale",
"type": "number"
},
"height": {
"default": 512,
"title": "Height",
"type": "integer"
},
"image_path": {
"title": "Image Path",
"type": "string"
},
"mask_prompt": {
"title": "Mask Prompt",
"type": "string"
},
"negative_prompt": {
"default": "",
"title": "Negative Prompt",
"type": "string"
},
"open_browser": {
"default": true,
"title": "Open Browser",
"type": "boolean"
},
"prompt": {
"title": "Prompt",
"type": "string"
},
"width": {
"default": 512,
"title": "Width",
"type": "integer"
}
},
"required": [
"image_path",
"prompt",
"mask_prompt"
],
"title": "inpaintingArguments",
"type": "object"
}