Skip to main content
Glama

Build from text layers

build_from_layers
DestructiveIdempotent

Construct Minecraft structures from stacked text layers by mapping characters to blocks. Use it for houses, statues, and pixel art; oversized bounding boxes over 100,000 blocks are rejected.

Instructions

Build a structure from text layers, like floor plans stacked bottom to top: character k of row j of layer i becomes block (x + k, y + i, z + j). Ideal for houses, statues and pixel art; use fill_region for big solid volumes. get_blocks returns this same format, so a region can be read, edited and written back. Refuses structures whose bounding box exceeds 100,000 blocks.

Example: palette {"#": "stone_bricks", "G": "glass", ".": "air"} with layers [["###", "#.#", "###"], ["#G#", "G.G", "#G#"]] builds a 3x3 stone ring with a glass ring on top.

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": {
      "x": "<x>",
      "y": "<y>",
      "z": "<z>",
      "palette": "<palette>",
      "layers": "<layers>"
    },
    "name": "build_from_layers"
  }
}

Input Schema

NameRequiredDescriptionDefault
xYesX of the west (lowest X) edge.
yYesY of the bottom layer.
zYesZ of the north (lowest Z) edge.
layersYesHorizontal slices from bottom to top. Each slice is a list of rows from north to south (+Z); each row is a string read west to east (+X), one character per block. Every slice needs the same number of rows and every row the same length.
paletteYesMaps single characters to a block id, an object {block, block_state?, nbt?}, or null (leave unchanged). '.' is air unless mapped here. A space always means 'leave unchanged' and cannot be redefined.

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.5/5.0
Behavior4/5

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

Annotations already declare destructiveHint=true, idempotentHint=true and readOnlyHint=false, so the description is not the sole carrier of the safety profile. Beyond that it adds real context: the 100,000-block refusal limit, that palette values may be null to leave blocks unchanged, and that a space always means 'leave unchanged' and cannot be redefined — semantics not derivable from annotations.

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

Conciseness5/5

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

Purpose and coordinate mapping are front-loaded, followed by the alternative-routing sentence and the size limit; the worked example at the end is compact and directly illustrates the palette/layers relationship. No filler sentences.

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

Completeness5/5

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

Despite five required parameters and nested BlockSpec objects, the description covers origin anchoring, layer ordering, palette encoding, the round-trip with get_blocks, and the size guard, while an output schema exists so return values need no explanation. Nothing essential for a correct call is missing.

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% and each parameter already has a detailed description, so the baseline is 3. The description reinforces the x/y/z anchoring and layers ordering with a formula and a worked palette/layers example, which adds illustrative but not strictly new meaning beyond 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 and resource ('Build a structure from text layers') and immediately defines the coordinate mapping (x + k, y + i, z + j), so the agent knows exactly what the tool produces. It explicitly distinguishes itself from fill_region for solid volumes and names get_blocks as the read counterpart, making sibling disambiguation concrete.

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

Usage Guidelines5/5

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

Gives positive guidance (houses, statues, pixel art) plus an explicit exclusion routed to a named alternative ('use fill_region for big solid volumes') and a stated workflow for round-tripping via get_blocks. The hard limit (refuses bounding boxes over 100,000 blocks) tells the agent when to switch approaches before calling.

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