Skip to main content
Glama

CAD Oracle

Optimize sheet layout

optimize_sheet_layout
Read-onlyIdempotent

Nest 2D polygons with holes onto cut sheets with margin, kerf, and rotation step; returns verified placements and a 1:1 mm SVG cut sheet. Minimal example: {"sheet_mm":[100,100],"parts":[{"id":"p","polygon":[[0,0],[20,0],[20,10],[0,10]],"quantity":2}]}

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": {
      "sheet_mm": "<sheet_mm>",
      "parts": "<parts>"
    },
    "name": "optimize_sheet_layout"
  }
}

Input Schema

NameRequiredDescriptionDefault
partsYes
kerf_mmNo
sheet_mmYes
margin_mmNo
max_sheetsNo
timeout_msNo
include_svgNo
rotation_step_degNo

Output Schema

NameRequiredDescriptionDefault
statusYes
unplacedYes
verifiedYes
layout_svgYes
placementsYes
sheets_usedYes
min_spacing_mmYes
sheet_area_mm2Yes
unplaced_countYes
utilization_ratioYes
oversized_part_idsYes
total_part_area_mm2Yes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.1/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent, non-destructive, closed-world. Beyond that, the description adds that placements are 'verified' and returns a 1:1 mm SVG, which is meaningful output behavior. It doesn't discuss failure modes (e.g., what happens when parts don't fit in max_sheets) or timeout behavior, keeping it below a 5.

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?

One dense sentence plus a concrete minimal example — front-loaded purpose and immediately actionable. Slightly terse for its parameter surface, but every element earns its place.

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 nesting tool with an output schema, the description covers the core purpose, key tunables, and a copyable example. The output schema presumably explains returns, so the remaining gap is parameter-level coverage for max_sheets/timeout/include_svg.

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

Parameters4/5

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

Schema coverage is 0%, so the description must compensate. It explains kerf, margin, and rotation step in domain terms and the minimal example demonstrates the shape of sheet_mm and parts (polygon, quantity). It leaves max_sheets, timeout_ms, include_svg, and holes semantics implicit, so it doesn't fully cover the 8 parameters.

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 ('Nest'), resource ('2D polygons with holes onto cut sheets'), and the optimization levers (margin, kerf, rotation step). It's clearly distinguishable from siblings like check_assembly_fit or verify_printability.

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

Usage Guidelines3/5

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

The description implies usage through its nesting/cut-sheet framing and a worked example, but never states when to use this versus alternatives or any preconditions. Usage is conveyed mainly by implication.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources