Skip to main content
Glama
S-CurveLabs

io.github.S-CurveLabs/sqlglass

Official
by S-CurveLabs

extract_parameter

Converts hard-coded literals in saved queries into parameters, adding a default from the original value.

Instructions

Turn a hard-coded value in a saved query into a parameter: every occurrence of the literal ('2026-01-01', 100) becomes @param, and a '-- param:' header line is added with the old value as its default.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
paramYes
queryYes
dry_runNo
literalYes
descriptionNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.3/5.0
Behavior2/5

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

No annotations are present, so the description must carry the full behavioral burden. It does disclose the edit mechanics, but it never says whether the saved query is actually modified in place, whether dry_run prevents a write, or what the return/output is — critical for a tool that changes a saved artifact.

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?

Single sentence, front-loaded with the core operation, and the substitution rule plus header-line behavior are packed in without filler. The example is compact and informative.

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?

For a tool with no annotations, no output schema, and five undocumented parameters, this description leaves too much unspecified: persistence/side effects, dry_run semantics, query identity, and success result shape. It is adequate as a purpose statement but not as a complete call contract.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description is the only source for all five parameters. It clarifies 'literal' and 'param' indirectly and mentions the old value becomes the default, but it does not explain what 'query' refers to (SQL text vs saved query ID), nor the roles of 'dry_run' and 'description'.

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?

Opens with a specific verb and resource ('Turn a hard-coded value in a saved query into a parameter') and then defines the exact transformation behavior: every occurrence of the literal becomes @param, and a '-- param:' header is added with the old value as default. This clearly distinguishes it from query-building, linting, and library-management siblings.

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 implies the tool is for parameterizing hard-coded literals in saved queries and gives the exact substitution semantics, but it never states when not to use it or names an alternative. An agent must infer that this is the right tool from the transformation description alone.

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