Skip to main content
Glama
Brilliant MCP

Brilliant MCP

Official

generate_image

Generate an AI image from a prompt and apply it as a fill to an existing canvas element; create the target element first, then pass its ID.

Instructions

Generate an AI image and apply it as a fill on targetElementId. Target element must already exist — create it first (top-level hosted-CLI agents: emit an <edit> block; sub-agents and external MCP clients: call edit), then call generate_image with that element's id or #ref. Call get_knowledge(["images/prompts","images/integration","images/references"]) for prompt engineering, quality presets, and parallel-generation guidance. Runs on your own Google key when one is set (Settings > Your own AI > Google), otherwise on Brilliant AI for a signed-in account.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "canvasId": "<canvasId>"
    },
    "name": "generate_image"
  }
}

Input Schema

NameRequiredDescriptionDefault
promptNoNatural-language paragraph describing the image.
targetsNoBatch mode: generate multiple images in parallel (preferred when generating 2+).
canvasIdYesCanvas ID. Required.
imageSizeNo"1K" (default) | "2K" | "4K".
sessionIdNoSession ID for per-session visual feedback. Optional.
aspectRatioNoOutput aspect ratio: "1:1" (default) | "16:9" | "9:16" | "4:3" | "3:4". In batch mode applies to every target unless a target overrides it.
targetElementIdNoElement ID to apply the image fill to. Required unless targets is provided.
referenceElementIdsNoElement IDs to use as reference images (up to 14).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.10

TDQS

A4.1/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond the annotations (readOnlyHint=false, openWorldHint=true, non-idempotent), the description discloses the creation dependency, that generation runs on the user's own Google key when configured and otherwise on Brilliant AI, and that parallel batches are supported. It does not cover cost, latency, rate limits, or what happens on generation failure.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the core action, then prerequisites, knowledge pointers, and key routing in a compact sequence. The credentials sentence is lengthy relative to its value but each sentence carries operative information; nothing is redundant filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For an 8-parameter generative mutation tool with no output schema, the description covers the prerequisite workflow, auth routing, and helper lookups an agent needs before calling. It omits any hint of the return value (e.g., whether an element id or asset reference comes back) and failure handling, which leaves a small gap.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the schema already documents prompt, targets, imageSize, aspectRatio, and referenceElementIds; baseline is 3. The description adds only that targetElementId may take an element's id 'or #ref' and that batching is the preferred path, which is useful but marginal over the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb, resource, and effect: 'Generate an AI image and apply it as a fill on targetElementId.' The agent immediately knows this produces a raster image bound to an existing element, which is distinct from generate_svg or vectorize_image by implication of 'AI image' plus the 'apply as fill' outcome.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives explicit prerequisite ordering (element must exist first; emit an `<edit>` block or call `edit`), routes the agent to get_knowledge for prompt engineering, and says batch mode is preferred for 2+ images. It stops short of stating when to prefer this over generate_svg or vectorize_image, so the exclusion side is incomplete.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.