agentleFS
0xatd0xatd/cheaptokens-skills/skills/venice-image-edit/SKILL.md

venice-image-edit

Skill2 starsChanged 5 months agoMITView on GitHub

Transform existing images with Venice. Covers POST /image/edit (prompt-driven single-image edit), /image/multi-edit (compose 1-3 images), /image/upscale (2-4x upscale + enhance), and /image/background-remove. Accepts base64, file upload, or HTTPS URL.

  • Reads credentials

4 other projects use a version of this, 1 of them edited.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

1 rule. About 0 are common, 0 are distinctive, and 1 is very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈0

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    All four endpoints return the edited image as binary image/png — there is no return_binary field on edit / multi-edit / upscale / …

    line 24

≈ “Common” is an estimate: at least 1 in 5 of the 372,429 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Venice Image Editing

Four endpoints, all operating on existing images:

EndpointPurpose
POST /image/editTransform one image with a text prompt.
POST /image/multi-editComposite / layer 2–3 images with a single prompt. Also has a multipart/form-data variant.
POST /image/upscaleUpscale 2–4× and/or enhance quality.
POST /image/background-removeProduce a transparent cutout.

For text-to-image generation, see venice-image-generate.

Shared rules

  • Input image accepts base64 string, file upload (multipart for /image/multi-edit), or HTTPS URL (for edit + multi-edit + background-remove).
  • File size < 25 MB. Image dimensions must be between 65,536 (256×256 equivalent) and 33,177,600 pixels (~5,761×5,761). Upscale caps at 16,777,216 pixels after scaling.
  • HTTPS URLs must be publicly reachable from Venice's network.
  • All four endpoints return the edited image as binary image/png — there is no return_binary field on edit / multi-edit / upscale / background-remove (that flag only exists on /image/generate).

/image/edit

Edit one image with a short, descriptive prompt.

curl https://api.venice.ai/api/v1/image/edit \
  -H "Authorization: Bearer $VENICE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "qwen-edit",
    "prompt": "Change the color of the sky to a sunrise",
    "image": "iVBORw0KGgoAAAANSUhEUg...",
    "aspect_ratio": "16:9",
    "safe_mode": true
  }'
FieldNotes
modelDefault qwen-edit. See GET /models?type=inpaint for edit-capable models. modelId is accepted for backwards compatibility but deprecated on /image/edit — prefer model.
promptRequired, ≤ 32 768 chars (usually 1500 is plenty). Short & specific works best.
imageRequired. Base64 string, file upload, or https:// URL.
aspect_ratioOptional: auto, 1:1, 3:2, 16:9, 21:9, 9:16, 2:3, 3:4, 4:5. Supported values vary per model — check constraints on GET /models.
safe_modeDefault true; blurs adult content.

Good prompts: "remove the tree", "add sunglasses to the cat", "make the sky a vivid orange sunrise".

/image/multi-edit

Combine up to 3 images into one with a prompt. The first image is the base; the rest are layers / masks / references.

Field name: /image/multi-edit takes modelId, not model. This is the only image endpoint that uses modelId as the primary field name.

JSON (base64 or URLs)

{
  "modelId": "qwen-edit",
  "prompt": "Place the person from image 2 onto the beach in image 1",
  "images": [
    "https://example.com/beach.jpg",
    "data:image/png;base64,iVBOR..."
  ],
  "safe_mode": true
}

Multipart (file upload)

POST /image/multi-edit
Content-Type: multipart/form-data

--boundary
Content-Disposition: form-data; name="modelId"

qwen-edit
--boundary
Content-Disposition: form-data; name="prompt"

Place the person from image 2 onto the beach in image 1
--boundary
Content-Disposition: form-data; name="images"; filename="base.jpg"
Content-Type: image/jpeg

<bytes>
--boundary
Content-Disposition: form-data; name="images"; filename="subject.png"
Content-Type: image/png

<bytes>
--boundary--
FieldNotes
modelIdRequired field name (multi-edit does not accept model). Default qwen-edit.
promptRequired, ≤ 32 768 chars.
imagesRequired. 1–3 items. JSON variant accepts base64 or HTTPS URLs; multipart variant accepts raw file parts.
safe_modeDefault true.

/image/upscale

Upscale by 1–4×, optionally running Venice's enhancer. Set enhance: true + scale: 1 to enhance without scaling.

curl https://api.venice.ai/api/v1/image/upscale \
  -H "Authorization: Bearer $VENICE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "image": "iVBORw0KGgo...",
    "scale": 2,
    "enhance": true,
    "enhanceCreativity": 0.5,
    "enhancePrompt": "gold",
    "replication": 0.35
  }'
FieldTypeDefaultNotes
imagebase64 or file—Required. Must be ≥ 65 536 px² to start.
scale1..421 requires enhance: true. 4 on large images auto-scales down to stay within 16 MP.
enhancebool / "true" / "false""false"Turn on Venice's enhancer. Required when scale === 1.
enhanceCreativity0..10.5Higher = more AI reinterpretation. 1 essentially produces a new image.
enhancePromptstring, ≤ 1500—Short stylistic cue: "gold", "marble", "angry, menacing".
replication0..10.35Preserve original lines/noise. Higher = less plastic / less AI-feel.

Response is the upscaled image as binary (image/png typically).

/image/background-remove

Produce a transparent PNG cutout.

# With base64
curl https://api.venice.ai/api/v1/image/background-remove \
  -H "Authorization: Bearer $VENICE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"image": "iVBOR..."}'

# With a URL
curl https://api.venice.ai/api/v1/image/background-remove \
  -H "Authorization: Bearer $VENICE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"image_url": "https://example.com/photo.jpg"}'

Send either image (base64 / file) or image_url. Response is image/png with alpha channel.

Error behavior (all four endpoints)

CodeCause
400Bad params — image dims out of range, file too large, unknown model, unsupported aspect ratio for the model, content-policy refusal.
401Auth failed. (Pro-gating on these paths surfaces as 400 / 402 depending on condition.)
402Insufficient balance. Bearer: plain { "error": "Insufficient balance" }. x402: PAYMENT_REQUIRED body + PAYMENT-REQUIRED header.
415Wrong Content-Type (e.g. JSON sent to a multipart endpoint, or vice versa).
429Rate limited.
500 / 503Inference / capacity issue — retry with jitter.

(413 and 422 are not documented for these image paths in the OpenAPI spec — a 413 from the platform may still appear if you exceed ingress limits, but treat 400 / 415 as the primary failure surface.)

Gotchas

  • /image/multi-edit images[] explicitly accepts data:image/...;base64,... URLs or plain base64. For /image/edit and /image/upscale, send base64 as a plain string unless the docs say otherwise — if your client adds a data: prefix and you get a 400, strip it.
  • For multipart /image/multi-edit, the field name is images and you send multiple parts with the same field name — order matters (base first).
  • Field-name asymmetry: /image/edit prefers model (modelId is a deprecated alias). /image/multi-edit accepts only modelId. Get the name right per endpoint — sending the wrong one is a 400.
  • /image/upscale with scale=4 on a large input is silently clamped to stay under 16 MP.
  • safe_mode: true can blur otherwise valid inputs if the source image trips content classifiers; switch to false (and handle the legal/ToS consequences yourself) when you control the input.
  • /image/background-remove takes either image or image_url, not both.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.