Skip to main content
Glama
lagaam-ai

Lagaam

Official

query_data

Run read-only SELECT queries against Trino and Pinot lakehouses, validated and budget-checked before execution to return row-capped, governed results.

Instructions

Run a read-only SELECT and get the rows back.

    Write a single SELECT in the engine's dialect. The query is checked
    for safety, priced against your budget, and executed with a row cap —
    so name the columns you need (no SELECT *), and add WHERE filters to
    keep the scan small. If it is rejected, the message says what to fix.
    Describe the tables first so column and table names are exact.
    

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sqlYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
rowsYes
columnsYes
warningsNo
row_countYes
truncatedNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.4

TDQS

A4.3/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 well: it discloses the read-only safety check, budget pricing, a row cap, and that rejections return actionable messages. It leaves out auth requirements and the concrete row-cap value, but the safety profile is substantially covered.

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?

Front-loaded with the core action, then constraints and the prerequisite in descending priority. Every sentence adds a constraint or instruction, though the multi-line formatting is slightly more verbose than strictly needed.

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?

An output schema exists so return values need not be explained, and the description covers the key execution concerns (safety, budget, row cap, error feedback). Given one undocumented parameter, it is nearly complete, missing only auth and exact limits.

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?

The single 'sql' parameter has 0% schema coverage, so the description must compensate, and it does: engine dialect, single SELECT only, no SELECT *, and add WHERE filters to bound the scan. It omits syntax specifics but adds real meaning beyond the bare string type.

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 and resource ('Run a read-only SELECT and get the rows back') and implicitly distinguishes itself from the metadata siblings by telling the agent to describe tables first. An agent can tell this executes queries rather than listing catalogs or describing schemas.

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?

Gives a clear prerequisite ('Describe the tables first so column and table names are exact') which routes the agent to describe_table, and explains the rejection path. It stops short of explicitly naming the alternative tools or stating when-not to use it.

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