Skip to main content
Glama

add_dataset_filter

Add a filter to a dataset by specifying expression, operator, and values. Returns the filter index for easy removal.

Instructions

Append a to the named dataset's block. operator ∈ Equal / NotEqual / GreaterThan / LessThan / GreaterThanOrEqual / LessThanOrEqual / Like / In / Between / TopN / BottomN / TopPercent / BottomPercent. values must be non-empty (single-value filters use a one-element list). Returns the new filter's index for later removal. Optional field_format wraps the expression as Format(, fmt) to coerce typed fields for string-parameter comparison. Response includes warnings for field/parameter type mismatches detected via best-effort cross-check.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYes
valuesYes
operatorYes
expressionYesFilterExpression — usually a Fields! reference.
dataset_nameYes
field_formatNoOptional format string (e.g. 'MMM, yyyy') wrapping the expression as Format(<body>, '<fmt>').
Behavior4/5

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

Despite no annotations, the description reveals key behaviors: it returns the new filter index, includes best-effort type mismatch warnings, and specifies value must be non-empty. It does not mention permissions or idempotency, but covers the main effects.

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?

The description is a single, well-structured paragraph. Every sentence adds value: main action, operator list, values constraint, return intent, field_format, and warnings. No wasted words.

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?

The description covers the return value (filter index), all parameter nuances, and response warnings. It lacks details on path or dataset_name format, but given no output schema, it is sufficiently complete for a 6-parameter tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The description adds substantial meaning beyond the schema: it explains operator enumeration, values constraint (non-empty, single-value as one-element list), field_format wrapping, and the 'Fields!' expression convention. With only 33% schema coverage, this compensates effectively.

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 clearly states the tool appends a <Filter> to a dataset's <Filters> block, specifies operator options, value constraints, and return value, distinguishing it from siblings like remove_dataset_filter and add_tablix_filter.

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?

The description implies use for dataset filters (vs tablix filters) but does not explicitly exclude or compare with alternatives like add_tablix_filter. It provides clear context for when to use this tool.

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/mafaq229/pbirb-mcp'

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