Skip to main content
Glama

validate_script

Statically validate Synthesizer scripts without executing them. Detect syntax errors, missing imports, invalid attributes, and unavailable grids before running.

Instructions

Statically validate a Synthesizer script.

The script is parsed, never run. Checks run least invasive first: syntax, import availability by specification lookup only, referenced Synthesizer attributes and keyword arguments, and locally available grids.

Args: source: Python source text.

Returns: A mapping with ok (no error-level diagnostics), script_was_run (always False), a summary sentence, diagnostics (a list of {severity, code, line, message} capped at 100) with diagnostics_truncated recording whether that cap bit, imports as {found, missing} lists of top-level module names, notes explaining any check that was skipped, and suggested_commands the host may choose to run itself. grids with {requested, local} grid names is present only when the script builds a Grid and the local grid listing is available, and error is present only when validation itself failed.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sourceYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Install Server

TDQS

A4.4/5.0
Behavior5/5

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

With no annotations provided, the description fully discloses behavior: the script is parsed, never run, checks run least invasive first, and the exact return structure is specified including the constant 'script_was_run' of False, conditions for optional keys like 'grids' and 'error', and limits like diagnostics capped at 100. This is extensive transparency beyond any structured metadata.

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 detailed but well-structured, starting with the core purpose, then behavior and returns. The 'Args' and 'Returns' sections are clearly segmented and each sentence conveys necessary information about the complex return payload. It is not excessively verbose for the complexity, though it could be tightened slightly, earning a 4.

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?

For a static validation tool with one parameter and a rich output schema, the description covers all essential aspects: what it checks, what it never does, the order of checks, the complete return mapping with conditional fields, and even notes on skipped checks. An agent has everything needed to invoke it correctly and interpret results, making it fully complete.

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 carry the parameter meaning. It provides 'source: Python source text' which exactly defines the single required parameter. While minimal, it is sufficient and unambiguous. Given the low schema coverage, this adequately compensates, though it could add more detail (e.g., encoding), so a 4 is appropriate.

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?

The description states 'Statically validate a Synthesizer script' with a specific verb and resource, and clarifies it is 'never run.' It lists the checks performed (syntax, import availability, references, grids), distinguishing it from sibling tools that plot, inspect environments, or search documentation. This is a clear, non-tautological purpose that an agent can act on.

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 explains what the tool does and that it is static (never runs), but does not explicitly state when to use it instead of alternatives. It does not mention sibling tools or conditions under which validation is preferred over running the script. The behavior implies use for pre-run checks, but no direct guidance on alternatives is given, so it earns a 3.

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

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/synthesizer-project/synthia'

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