Skip to main content
Glama

add_slice

Add a named rectangular region to a sprite, with optional 9-patch center, pivot point, color, and user data for organizing sprite slices.

Instructions

Create a slice (named region) at (x, y, width, height).

Args:
    center_*: Optional 9-patch center rectangle, **relative to the slice's
        top-left**. Provide all four to mark the stretchable middle.
    pivot_*: Optional pivot point (relative to the slice).
    color: Optional slice colour shown in the editor.
    data: Optional user data string.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
xYes
yYes
dataNo
nameYes
colorNo
widthYes
heightYes
pivot_xNo
pivot_yNo
center_xNo
center_yNo
filenameYes
center_widthNo
center_heightNo
Behavior2/5

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

With no annotations, the description should disclose behavioral traits like side effects, error conditions, or requirements. It only says 'Create a slice' without noting that a 'filename' parameter identifies the sprite, whether the sprite must be open, or if duplicate names cause errors. The description is insufficient for an unannotated tool.

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?

The description is short and to the point, using a clear structure with 'Args:' list. However, the formatting is somewhat non-standard for MCP descriptions (e.g., code-like indentation). Overall, it is concise without being terse.

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

Completeness2/5

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

Given 14 parameters, 6 required, no output schema, and no annotations, the description should provide more context (e.g., which sprite operates on, return value, error handling). It does not mention that the slice is added to the current sprite or that filename is needed. This leaves significant gaps for an agent.

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?

The description adds meaning for optional parameters: center_* 'relative to slice's top-left' and 'provide all four to mark stretchable middle', pivot_* 'relative to slice', color 'shown in editor', data 'optional user data'. However, required parameters like filename, x, y, width, height are not explained, and schema coverage is 0%. The description partially compensates but not fully.

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

Purpose4/5

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

The description states 'Create a slice (named region) at (x, y, width, height)', clearly indicating the verb (create) and resource (slice). However, it does not distinguish this tool from related sibling tools like 'set_slice' or 'remove_slice', so it misses some differentiation.

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

Usage Guidelines2/5

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

No guidance is provided on when to use this tool versus alternatives like 'set_slice' or 'list_slices'. The description does not mention prerequisites (e.g., sprite must be open) or when not to use it. This leaves the agent without context for tool selection.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/MalloyTheDev/aseprite-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server