Skip to main content
Glama
lzaafe-alt

lolosqltools

by lzaafe-alt

check_performance_patterns

Analyze SQL text to detect performance anti-patterns and BSG standard violations, returning categorized results sorted by severity from CRITICAL to LOW.

Instructions

Detects SQL anti-patterns and performance bad practices against BSG standards. Returns categorized violations sorted by severity (CRITICAL > HIGH > MEDIUM > LOW).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sqlYesThe SQL text to analyze for performance anti-patterns
contextNoContext filter: run only patterns applicable to this object type. ALL runs every pattern.ALL

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A3.8/5.0
Behavior3/5

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

No annotations are provided, so the description carries the behavioral burden. It does disclose output behavior (categorized, sorted CRITICAL > HIGH > MEDIUM > LOW) and that it checks against BSG standards, which is useful. However, it says nothing about whether this is read-only (implied but unstated), performance cost, or whether it halts on first error.

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?

Two tightly packed sentences with zero waste: purpose first, then return contract. Front-loaded and appropriately sized.

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 two-parameter analysis tool with no annotations and no output schema, the description covers the essentials: what it detects, the standard it checks against, and the return shape (categorized, severity-sorted). The main missing piece is explicit guidance on when to choose this over its sibling validators.

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 coverage is 100%, so both parameters are fully documented in the schema, including the context enum semantics ('ALL runs every pattern'). The description adds no parameter detail beyond what the schema provides, so baseline 3 is correct.

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 (detects) and resource (SQL anti-patterns / performance bad practices) against a named standard (BSG standards). Clearly distinguishable from siblings like validate_object_name or validate_sql_object, which validate structural/naming correctness rather than performance patterns.

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?

Implicitly frames usage via the 'context' enum, which tells the agent they can scope to QUERY/VIEW/SP/ALL, but the description itself gives no explicit when-to-use guidance or routing to sibling validators. Adequate but with a clear gap: an agent can't tell from the description why it would pick this over validate_sql_object.

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