Skip to main content
Glama

2D Fourier transform

singularis_fft2
Idempotent

Compute 2D fast Fourier transforms or inverses for real arrays, enabling image spectra, 2D convolution, and field filtering. Returns real/imag pairs with a Parseval energy check.

Instructions

2D fast Fourier transform (or inverse) of a real 2D field of any shape: image spectra, 2D convolution, field filtering. Inputs: x inline or path; inverse flag. Returns the transform as a [real, imag] pair plus a Parseval energy check. Cost scales with N log N. (singularis_fft also accepts a 2D field; this tool is the explicit 2D entry.)

Input Schema

NameRequiredDescriptionDefault
xNo
imNo
pathNo
inverseNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.1.11

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already cover safety (destructive=false, idempotent=true, openWorld=true), so the description's job is lighter. It still adds real value: the input is a real field of any shape, cost scales as N log N, and a Parseval energy check accompanies the result — none of which appears in the annotations or schema. Minor tension: it reads as a pure computation while readOnlyHint=false implies state change, though no explicit read-only claim is made.

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?

Roughly four sentences, each earning its place: capability, use cases, input routes, return shape, cost, and sibling disambiguation. The most load-bearing information (what it computes) is front-loaded, and the sibling note is correctly deferred to a parenthetical at the end.

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 complex-but-pure numeric tool with an output schema (so return values need no prose) and full annotations, the description covers capability, inputs, direction, and cost. The remaining gaps are the meaning of 'im' and the relationship between the x and path inputs when both are omitted.

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?

With 0% schema description coverage, the description must carry parameter meaning, and it partially does: 'x inline or path' clarifies the two mutually exclusive input routes and 'inverse flag' names the direction control. It never explains the 'im' parameter (imaginary component) or the null-default/optionality semantics, leaving one of four parameters undocumented in both schema and prose.

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 ('2D fast Fourier transform (or inverse) of a real 2D field') and adds concrete applications (image spectra, 2D convolution, field filtering). It also names the nearest sibling and positions itself against it: 'singularis_fft also accepts a 2D field; this tool is the explicit 2D entry.'

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

Usage Guidelines4/5

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

Gives clear use contexts (spectra, convolution, filtering) and explicitly points at the alternative entry, singularis_fft. However it never states a rule for choosing between them — it only notes both accept 2D input — so the agent is left to infer which entry to prefer.

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