Skip to main content
Glama

declare_performance

Records a quantitative performance spec on a part to re-prove after edits, storing metric-agnostic requirements in the .FCStd so verify_performance can check them.

Instructions

Record a quantitative PERFORMANCE spec on a part so it can be re-proved after every edit — the performance twin of declare_intent, which only covers geometry. Persists in the .FCStd as a JSON property bag; one contract per part, re-declaring replaces it.

Each requirement is metric-agnostic — the contract layer only orchestrates, so the metric is whatever the named tool already returns, and "Cd ≤ 0.30", "Δp ≤ 50 Pa", "first mode ≥ 200 Hz" and "ΔT ≤ 40 K" are the same machinery:

{"name": "drag_at_cruise",
 "metric": "cd",                        # dotted path into the tool's result
 "tool": "cfd_external_flow_submit",    # what measures it at solver tier
 "conditions": {"model": "$handle", "velocity_m_s": 30, "fluid": "air-20c"},
 "limit": {"max": 0.30},                # max, min, or both (a window)
 "screen": {"tool": "cfd_body_drag", "metric": "cd",
            "conditions": {"shape": "sphere", "diameter_mm": 50,
                           "velocity_m_s": 30}},
 "fidelity_floor": "solver",            # "screen" if an estimate is proof enough
 "trust": {"converged": true, "band_max_pct": 5}}

"$handle" anywhere in conditions is replaced with this part's handle at verification time, so a contract is portable between parts. trust demands are enforced by verify_performance against the solver's own trust block: a requirement asking for converged: true can never be satisfied by an unconverged solve.

Returns {handle, contract: {requirements: [...]}, n_requirements}. Raises ValueError on a malformed requirement, naming the offending one.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
handleYes
requirementsYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.2/5.0
Behavior4/5

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

No annotations, so the description carries the full burden and does well: it discloses persistence in the .FCStd as a JSON property bag, one-contract-per-part with re-declaring replacing it, $handle substitution at verification time, trust enforcement via verify_performance, and ValueError on malformed requirements. It does not cover permissions or concurrency, but the mutation lifecycle and error behavior are strong.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The dense JSON example is valuable but the prose and example together are long and somewhat back-loaded; the key scoping facts (twin of declare_intent, one per part, replaces on redeclare) are scattered rather than front-loaded in a single crisp sentence.

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, 2-param but structurally rich tool with no output schema, the description covers the contract model, the return shape ({handle, contract, n_requirements}), the trust interaction with verify_performance, and error behavior. Coverage is strong; only the top-level handle parameter and cross-part portability caveats are lightly treated.

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% (schema just lists handle and requirements), so the description must compensate and does: it documents the requirement object structure in detail (name, metric, tool, conditions, limit window, screen, fidelity_floor, trust) and explains $handle substitution and value constraints. The handle parameter itself is only implied.

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 (Record) and resource (quantitative PERFORMANCE spec / contract) on a part, and explicitly contrasts it with the sibling declare_intent ('the performance twin of declare_intent, which only covers geometry'). An agent can distinguish this from declare_intent and verify_performance without opening any schema.

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?

Clearly positions the tool relative to declare_intent and verify_performance (internally enforced), and states the persistence/re-declaration semantics. It does not spell out explicit when-not-to-use cases, but the twin framing gives clear selection context.

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

Deploy Server

Other Tools