Skip to main content
Glama

Ask your data (NL → SQL)

run_nl_query
Read-onlyIdempotent

Answer plain-English questions about project data by generating and running a read-only SQL query, returning the matching rows.

Instructions

Answer a natural-language question about your project data by generating and running a read-only SQL query (no privileged schemas, rate-limited to 60/hour). Returns { sql, rows }. Use for ad-hoc analytics ("which components had the most critical bugs this week?"); use get_recent_reports/search_reports for plain report lookups, or search_mushi_docs for documentation questions.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
questionYesQuestion in plain English, e.g. "Which components had the most critical bugs this week?"

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.1.10
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
  2. First observedv0.1.0

TDQS

A4.7/5.0
Behavior5/5

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

Annotations already declare readOnlyHint, openWorldHint, and idempotentHint. The description adds non-obvious behavioral context beyond those: no privileged schemas, a 60/hour rate limit, and a return shape of { sql, rows }. This helps the agent anticipate operational and safety constraints.

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 sentences, each earning its place. The first defines the operation, constraints, and return format; the second gives usage context and routes to alternatives. No filler or redundancy.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the low complexity, strong annotations, and absence of an output schema, the description is complete: it communicates purpose, constraints, return shape, rate limit, and alternative tools. An agent has enough information to decide whether and how to invoke this tool.

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 the single required parameter is fully described with an example. The description reinforces the natural-language style and adds an example use case, but it does not add meaning beyond what the schema already provides.

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 states a specific verb+resource: answer a natural-language question by generating and running a read-only SQL query over project data. It clearly distinguishes itself from siblings by framing itself for ad-hoc analytics rather than report lookups or documentation searches.

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

Usage Guidelines5/5

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

The description explicitly says 'Use for ad-hoc analytics' and names the alternatives: 'use get_recent_reports/search_reports for plain report lookups, or search_mushi_docs for documentation questions.' This gives an agent clear when-to-use and when-not-to-use guidance.

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