Skip to main content
Glama

tool_get_image_size

Retrieve image dimensions and format to calculate correct sprite positioning transforms in Ren'Py projects. Accepts absolute or project-relative paths.

Instructions

Get dimensions and format of an image file.

Useful for calculating correct sprite positioning transforms. Supports absolute paths or paths relative to project_path.

Args: project_path: Absolute path to the Ren'Py project root directory. image_path: Path to image file (absolute, or relative to project_path).

Returns: dict with {ok, width, height, format, file_size}.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
image_pathYes
project_pathYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.4.0

TDQS

A3.6/5.0
Behavior3/5

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

No annotations are provided, so the description carries the full burden. It discloses path-resolution behavior (absolute or relative to project_path) and the return shape including an 'ok' flag, which hints at failure handling, but it says nothing about permissions, error cases, or supported formats.

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?

Two-sentence summary is front-loaded, and the Args/Returns blocks are compact and skimmable. Slight redundancy between the opening line and the argument notes, but nothing that wastes real space.

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 a simple two-parameter read tool with no output schema, the description supplies the return keys (ok, width, height, format, file_size) and path semantics, which covers what an agent needs to call and interpret it. Absent annotations on a read-only tool is the only real gap.

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 description coverage is 0%, so the description must compensate, and it does: both parameters are documented, with project_path identified as the project root and image_path explicitly allowed to be absolute or relative to it. That is meaningfully more than the bare-string schema provides.

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?

States a specific verb and resource ('Get dimensions and format of an image file'), which is unambiguous. It doesn't distinguish itself from any sibling, but the sibling list contains mostly unrelated tools, so the risk of confusion is low.

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?

'Useful for calculating correct sprite positioning transforms' implies a use context but names no condition, prerequisite, or alternative tool. An agent gets a hint about intent without guidance on when this tool is the right call.

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