Skip to main content
Glama
lzaafe-alt

lolosqltools

by lzaafe-alt

format_sql

Formats SQL to BSG standards: uppercase keywords, leading-comma SELECT columns, normalized clause indentation, separate AND/OR lines, 4-space BEGIN...END blocks, and removes inline -- comments.

Instructions

Applies BSG-standard formatting to SQL: uppercases keywords, reformats SELECT columns to leading-comma style, normalizes clause indentation (FROM/WHERE/JOIN), separates AND/OR conditions to their own lines, normalizes BEGIN...END indentation to 4 spaces, and removes inline -- comments from the code body.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sqlYesThe SQL text to format

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A3.7/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does so well: it discloses that keywords are uppercased, commas repositioned, indentation normalized, AND/OR split onto lines, and inline -- comments stripped from the body. It does not state idempotency, error behavior on malformed SQL, or whether the formatted text is returned as a string, which keeps it from a 5.

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?

It is a single front-loaded sentence with the core action first, followed by a tight enumeration of rules. The list is long but every clause carries information; no filler is present.

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 one-parameter, no-output-schema tool, the description is nearly sufficient: it fully specifies the transformation semantics. It omits the return shape and failure mode for unparseable SQL, which are the only meaningful remaining gaps.

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?

Schema description coverage is 100% and there is a single parameter ('sql'), so the schema already explains the input. The description adds no format/syntax details beyond what the schema provides, making the baseline 3 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 opens with a specific verb and resource ('Applies BSG-standard formatting to SQL') and then enumerates the exact transformations performed. No sibling tool does SQL formatting, and the enumerated rules make the tool's purpose unmistakable.

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

Usage Guidelines2/5

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

There is no guidance on when to use this tool versus alternatives, nor on prerequisites such as whether the input must already be valid/parseable SQL. The usage is inferable from the name, but nothing is stated explicitly.

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