Skip to main content
Glama

Count sequence markers

count_markers
Read-onlyIdempotent

Counts sequence markers without listing them, optionally filtered by type, color, time range, or text; returns totals, breakdowns, span durations, and first/last times.

Instructions

Count the markers of a sequence without listing them, optionally filtered by type, colour, time range and text. Returns total, matched, by_type, by_color, with_duration (span markers), first_time and last_time in seconds.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "count_markers"
  }
}

Input Schema

NameRequiredDescriptionDefault
textNoOnly markers whose name or comment contains this text (plain substring, case-insensitive).
typeNoOnly markers of this type. One of "comment", "chapter", "segmentation", "web_link".
colorNoOnly markers of this colour. Colour index or name: 0 green, 1 red, 2 purple, 3 orange, 4 yellow, 5 white, 6 blue, 7 cyan.
to_timeNoOnly markers that start at or before this sequence time, in seconds.
from_timeNoOnly markers that start at or after this sequence time, in seconds.
sequence_idNoStable sequence id (from list_sequences). Omit to use the active sequence.
sequence_nameNoSequence name; used only when sequence_id is not given.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent, non-destructive and closed-world, so the safety profile is covered. The description earns credit by disclosing the aggregate result shape (total, matched, by_type, by_color, with_duration, first_time/last_time in seconds), which the annotations do not provide and which is especially valuable given there is no output schema.

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, zero filler, with the core purpose and the 'without listing them' scoping point front-loaded before the return-value inventory.

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

Completeness5/5

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

For a read-only counting tool with no output schema, the description supplies exactly what is missing: the shape of the returned aggregate object and the units of the time fields. Combined with fully covered parameter schemas and annotation-declared safety, an agent has everything needed to select and call it correctly.

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 every filter parameter is already documented in detail (substring semantics, colour index mapping, inclusive time bounds, sequence_id precedence). The description only restates the filter categories at a high level and adds no syntax or precedence detail beyond the schema; baseline 3 applies.

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?

States a specific verb and resource ('Count the markers of a sequence') and explicitly carves out the scope difference from its nearest sibling with 'without listing them'. The enumerated filter axes and the return-field list make the tool's identity unmistakable.

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 phrase 'without listing them' implicitly routes the agent away from list_markers/find_markers when only aggregates are needed, which is clear contextual guidance. It stops short of naming an alternative or stating an explicit exclusion ('use list_markers instead when you need marker details').

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

Deploy Server

Other Tools