Skip to main content
Glama

Query a data file

query_data
Read-only

Run read-only structured queries on local CSV, Parquet, Excel, or JSON files. Filter, select, sort, paginate, and aggregate data, then receive results as a Markdown table without modifying the file.

Instructions

Run a read-only structured query over a local data file: filter (where), select columns, order_by, limit/offset, and group_by with aggregations (count/sum/avg/min/max). Returns a Markdown table. No SQL, no writes — the file is never modified.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYesPath to the data file.
limitNo
whereNoRow filters (ANDed together).
offsetNo
selectNoColumns to keep in the output.
group_byNoGroup rows by these columns.
order_byNo
aggregateNoAggregations to compute per group (with group_by).
Behavior4/5

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

The description reinforces the readOnlyHint annotation and adds concrete behavioral detail: 'the file is never modified' and 'Returns a Markdown table'. It also constrains the query language with 'No SQL'. These details go beyond the annotation and give the agent a clearer picture of side effects and output.

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 with no waste. The core behavior is front-loaded, every clause adds information, and the return format and safety guarantee are stated tersely.

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 moderately complex tool with no output schema, the description covers the important decision factors: read-only, file never modified, Markdown return, and supported query operations. It falls short only on file-format/error behavior and explicit sibling tool placement, but these are secondary given the schema and sibling names.

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?

The description maps many schema parameters to high-level concepts: where -> filter, select -> columns, order_by, limit/offset, group_by with aggregations. However it does not detail sub-fields like op operators, value formats, or order_by.dir. Schema description coverage is 63%, so the schema already handles some burden, but the description does not fully compensate for the remaining uncovered parameters.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific verb and resource: 'Run a read-only structured query over a local data file' and enumerates concrete operations (filter, select, order_by, limit/offset, group_by with aggregations). It does not explicitly differentiate from sibling tools like describe_data or preview_data, but the querying scope is clear enough to understand its purpose.

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?

There is no explicit guidance on when to choose this tool over siblings such as describe_data or preview_data. The description implies use for structured querying via its operation list, and 'No SQL, no writes' sets boundaries, but it does not state when-not or alternatives, leaving routing to inference.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/aurelio-nakamura/dataloupe'

If you have feedback or need assistance with the MCP directory API, please join our Discord server