Skip to main content
Glama

compare_segments

Compare two user segments side by side in a table report, displaying selected metrics grouped by a dimension.

Instructions

Compare two user segments side by side in a table report.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
counter_idYesYandex Metrika counter ID
metricsYesMetrics to compare, e.g. ['ym:s:visits', 'ym:s:users']
dimensionsYesDimension to group by, e.g. 'ym:s:trafficSource'
segment_a_nameYesHuman-readable name for segment A, e.g. 'Organic'
segment_a_filterYesFilter expression for segment A, e.g. "ym:s:trafficSource=='organic'"
segment_b_nameYesHuman-readable name for segment B, e.g. 'Direct'
segment_b_filterYesFilter expression for segment B, e.g. "ym:s:trafficSource=='direct'"
date_fromNoStart date YYYY-MM-DD
date_toNoEnd date YYYY-MM-DD
limitNoMaximum rows to return

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior2/5

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

No annotations are provided, so the description must fully disclose behavioral traits. However, it only mentions a table report without details on pagination (though 'limit' parameter exists), data format, authentication needs, or handling of missing data. This is insufficient for an agent to understand important behaviors beyond the basic output.

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?

The description is a single sentence that is front-loaded and concise. It contains no redundant information. However, given the tool's complexity, it could be slightly more detailed without being verbose.

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

Completeness3/5

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

With the tool having 10 parameters and no output schema description in the tool definition, the description is minimal. Although an output schema exists, the description does not explain the report structure. The context given is adequate but not complete for an agent to fully understand the tool's capabilities and limitations.

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%, so the baseline is 3. The description adds no additional meaning beyond the schema's parameter descriptions. Since the schema already explains each parameter, the description does not need to compensate further.

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?

Description clearly states the tool compares two user segments side by side in a table report. It uses a specific verb and resource, and it distinguishes itself from the sibling tool 'compare_segments_drilldown', which likely drills down into a comparison. This makes the purpose unambiguous.

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?

No explicit guidance on when to use this tool versus alternatives. While the description implies use for side-by-side comparison, it does not specify when to choose this over 'compare_segments_drilldown' or other reporting tools. The usage context is implied but not explicitly stated.

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/mrkhachaturov/ya-metrics-mcp'

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