Spiral gives your agent every tool with one account. Browse the tools →

Instinct · ImageReleased 2026-03-27

How to Use SAM 3.1 Image to RLE in Instinct

SAM 3.1 Image to RLE finds objects in an existing image and returns their segmentation masks as RLE data. It fits annotation pipelines and editing tools that need object selections they can process.

Prompts to try with SAM 3.1 Image to RLE in Instinct

Copy an example into Instinct, or ask in your own words.

Each morning, use SAM 3.1 Image to RLE on new product photos in the incoming image collection with the description 'handbag.' Prepare mask previews for approval before any background removal.

SAM 3.1 Image to RLEInstinct
Try asking
  • Every Friday, use SAM 3.1 Image to RLE to select 'bicycle' in new images from the annotation queue. Keep objects separate and prepare a review sheet with the original images and mask overlays.

  • Each evening, use SAM 3.1 Image to RLE to prepare 'face' selections in new event photos. Queue the images for redaction review and retain the originals.

  • Every Monday, use SAM 3.1 Image to RLE to select 'chair' in newly submitted room photos. Organize the individual mask previews by source image for the design team to review.

  • Each morning, use SAM 3.1 Image to RLE to select 'license plate' in new vehicle photos. Prepare overlays for human review before a separate pixelation step.

How to set up SAM 3.1 Image to RLE in Instinct

Pick the way that suits you. Each takes about two minutes.

Use the Spiral skill

  1. Send Instinct this message

    Your agent reads Spiral's skill and sets itself up.

    set up https://spiral.ai/SKILL.md
  2. Sign in or paste a key

    Approve Spiral in the browser, or give the agent a key from the console.

Use Spiral's MCP server

  1. Create an API key

    In the console, open API keys and create a key for Instinct. Copy it.

  2. Send Instinct this message

    Instinct reads Spiral's skill and asks for your API key.

    set up https://spiral.ai/SKILL.md
  3. Give Instinct the key

    When Instinct asks for the key, add it where Instinct keeps secrets, never in the chat itself.

Use the Spiral CLI

  1. Install and sign in

    Installs the Spiral CLI, signs you in and adds its skill to your coding agents.

    npx -y spiral-cli@latest init

Call the Spiral API

  1. Create an API key

    In the console, under API keys.

  2. Run SAM 3.1 Image to RLE

    One request; the result comes back by polling or a webhook.

    curl https://api.spiral.ai/v1/runs \
      -H "Authorization: Bearer $SPIRAL_API_KEY" \
      -H "Content-Type: application/json" \
      -H "Idempotency-Key: $(uuidgen)" \
      -d '{
        "provider": "fal",
        "model": "fal-ai/sam-3-1/image-rle",
        "input": {
          "image_url": "https://raw.githubusercontent.com/facebookresearch/segment-anything-2/main/notebooks/images/truck.jpg"
        }
      }'

Then paste one of the prompts above: Instinct finds SAM 3.1 Image to RLE on Spiral, shows the price and runs it.

SAM 3.1 Image to RLE providers and prices

Spiral runs SAM 3.1 Image to RLE through fal. Open a card for today's price, with every fee included.

falImage
Sam 3 1 · Image to RLE
fal-ai/sam-3-1/image-rle

Settings you can ask for

SAM 3.1 Image to RLE works from your image URL and prompt. Ask Instinct for any of these in your prompt.

SettingAllowed valuesDefaultDescription
Apply maskon or offon

Apply the mask on the image.

Output formatjpeg, png, or webppng

The format of the generated image.

Return multiple maskson or offoff

If True, upload and return multiple generated masks as defined by max_masks.

Max masks1 to 323

Maximum number of masks to return when return_multiple_masks is enabled.

Include scoreson or offoff

Whether to include mask confidence scores.

Include boxeson or offoff

Whether to include bounding boxes for each mask (when available).

Every API field of Sam 3 1 · Image to RLE is on its tool page: open its card above.

What can you do with SAM 3.1 Image to RLE in Instinct?

Prepare object masks from recurring image batches for later review. A scheduled agent can reuse short descriptions with SAM 3.1 and organize the selections into a consistent review queue.

Prepare product cutouts

Use SAM 3.1 Image to RLE to select a product in a photograph, then pass the decoded mask to an editor for background removal. Review the selection before exporting the cutout.

Draft dataset annotations

Generate object masks from short category labels with SAM 3.1 Image to RLE. Present each selection for review before adding it to a training dataset.

Prepare selective photo edits

Select an object with SAM 3.1 Image to RLE, then use its mask in a separate editing step to recolor, blur, or highlight that region.

Prepare privacy redactions

Find faces, license plates, or screens with SAM 3.1 Image to RLE. Apply pixelation in an editor and inspect the full image for missed regions before sharing.

Separate objects for a collage

Request individual object selections from SAM 3.1 Image to RLE, then turn reviewed masks into cutouts for a collage or presentation.

Build an interactive selection tool

Let a person describe an object, inspect the mask, and refine the selection with points. Use SAM 3.1 Image to RLE for segmentation and application code for previews and editing.

Questions about SAM 3.1 Image to RLE in Instinct

Can Instinct use SAM 3.1 Image to RLE?

Yes. Add Spiral to Instinct as an MCP server, and Instinct can find and run SAM 3.1 Image to RLE like any built-in tool.

How much does SAM 3.1 Image to RLE cost in Instinct?

$0.013 per run at the default inputs. You pay from your Spiral balance as you go, with no subscription, and a failed run is not charged. Your Instinct plan is separate.

Do I need a fal account to use SAM 3.1 Image to RLE in Instinct?

You need no fal account. Instinct uses one Spiral API key for every tool, and Spiral runs SAM 3.1 Image to RLE on its own fal account.

How long does it take to set up SAM 3.1 Image to RLE in Instinct?

About two minutes: create an API key, then send Instinct this message, then give Instinct the key.

Does Instinct wait while SAM 3.1 Image to RLE runs?

SAM 3.1 Image to RLE runs in the background. Instinct starts the run, checks on it and gives you the image when it's ready.

What does SAM 3.1 Image to RLE produce?

It returns object segmentation masks encoded with run-length encoding, or RLE. An agent can use that mask data in an annotation tool or decode it to prepare an editing selection.

How should I describe the object I want?

Start with a short noun phrase such as "wheel," "red umbrella," or "hardcover book." Keep the request focused on an object and one or two useful attributes.

Can I ask for an object by its position or relationship to other objects?

Long referring expressions exceed the documented direct prompting scope. Have the agent identify the intended object first, then use a short description or a visual selection to guide segmentation.

Can SAM 3.1 select several objects of the same kind?

Concept segmentation is designed to find all instances matching a description. Request separate masks when your next step needs individual objects, then review the selections for missed or unwanted matches.

How can I correct a selection?

Use point guidance to refine the intended object. Keep points associated with the same object identifier when they should update one selection.

Get started

Start using SAM 3.1 Image to RLE in Instinct

One Spiral account for every tool your agent needs. No subscription; you pay per run.

Paste this into Instinct:

Set up Instinct

set up https://spiral.ai/SKILL.md
Are you an AI agent? See setup options