Skip to main content
Glama

collection_stats

Counts and averages loaded Spotify playlist tracks grouped by decade, artist, genre, or month, optionally split by a second dimension, to produce chartable summary tables.

Instructions

Counts and averages of the loaded playlists grouped by one dimension (optionally also split by a second one), as a small table you can chart. Examples: decade x playlist, top 20 artists, tracks per genre family, additions per month, one artist's albums (filters.artist).

Args: group_by: decade, year, artist (primary), album, genre (exact tags), genre_family, playlist, month_added or popularity_bin (steps of 5). split_by: optional second dimension from the same list; one row per group x split value. metrics: any of unique_tracks, entries, hours, avg_popularity, share (% of the selection's unique tracks). Default: unique_tracks and share. filters: narrow the tracks first (same filters as find_tracks). limit: groups to return, biggest first (default 50, max 500). Time dimensions and popularity bins are returned in order.

Input Schema

NameRequiredDescriptionDefault
limitNo
filtersNo
metricsNo
group_byYes
split_byNo

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.0.1

TDQS

A4.2/5.0
Behavior4/5

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

With no annotations, the description carries the behavioral burden well: it discloses defaults for metrics and limit, the 500-group cap, ordering rules (biggest first, chronological order for time dimensions and popularity bins), and the row-per-group-x-split shape. It does not state that the tool is read-only and non-mutating, which would be useful given the absence of annotations, but nothing contradicts expected behavior.

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 summary is front-loaded with the operation and output shape, examples follow, and the Args block maps cleanly onto the five parameters. Example lists and dimension lists are slightly verbose but each item carries information an agent needs to pick valid values.

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-value explanation is unnecessary, and the description covers dimensions, metrics, defaults, ordering, and limits. Given a moderately complex aggregation tool, the remaining gap is the absence of any statement about its relationship to sibling aggregation or overview tools.

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?

Schema description coverage is effectively 0% for the top-level parameters, so the description must compensate, and it does: it enumerates every accepted group_by and split_by value, lists all valid metrics with their defaults, explains how filters narrow tracks first, and documents limit's default and maximum. It adds meaning well beyond the bare schema, with the only soft spot being that filter field semantics are delegated to find_tracks.

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 opens with a specific verb and resource: counts and averages of loaded playlists grouped by one dimension, optionally split by a second, returned as a chartable table. An agent immediately knows the operation and output shape. It does not distinguish itself from the sibling group_tracks, which sounds close enough that a routing decision may be ambiguous.

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?

Concrete worked examples (decade x playlist, top 20 artists, tracks per genre family, additions per month, one artist's albums via filters.artist) make the intended use pattern clear, and it cross-references find_tracks for filter semantics. There is no explicit when-not guidance or named alternative such as group_tracks, so the agent must infer exclusions.

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