Skip to main content
Glama

get_trends

Compares the average of a health metric over the past N days to the prior N days to detect trends, returning recent average, prior average, and percentage change.

Instructions

Compares the average of metric (see get_daily_metric for valid names) over the last window_days days against the window_days before that -- e.g. window_days=7 answers "is this week's step count up or down vs last week." Returns recent_avg, prior_avg, and delta_percent (None if there's no prior-window data to compare against).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
metricYes
window_daysNo
Behavior3/5

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

Discloses the algorithm (compare averages over two windows) and return fields (recent_avg, prior_avg, delta_percent) with a note on None for missing prior data. However, no annotations provided, and the description does not cover potential edge cases like non-numeric metrics or timezone handling.

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 concise sentences front-loaded with purpose, followed by example and return format. No extraneous words, logical flow.

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?

Covers key return fields without output schema, references sibling tool for valid metrics, and gives example. Does not explicitly state that metric must be numerical or handle errors, but adequately addresses core functionality.

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?

Schema has 0% coverage, but the description explains both parameters: metric references get_daily_metric for valid names, window_days explained with example. Sufficiently compensates for missing schema descriptions.

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?

Clearly states the tool compares averages over two windows, specifies the metric reference from get_daily_metric, and provides a concrete example. Differentiates from sibling tools by focusing on trend analysis vs raw daily values.

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?

Implicitly suggests use for period-over-period comparison but does not explicitly state when to use versus alternatives like get_daily_metric. The example aids understanding but lacks clear when-not guidelines.

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/rajanshxrma/cadence'

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