Skip to main content
Glama

hotspots

Rank files by risk from git history using recency-weighted churn and distinct author count, filtering lock files and bulk commits to help prioritize code review.

Instructions

Rank files by risk: recency-weighted churn (lines added+deleted, halving every half_life_days) multiplied by (1 + log2 of distinct authors). Only files that still exist are listed. Commits touching more than max_files_per_commit files (reformats, imports) and lock files are ignored; exclude takes extra globs like '*.min.js'. since/until accept git dates ('6 months ago', '2026-01-01'); path limits to a directory; as_of pins 'now'.

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": "hotspots"
  }
}

Input Schema

NameRequiredDescriptionDefault
refNoHEAD
pathNo
repoNo
as_ofNo
limitNo
sinceNo12 months ago
untilNo
excludeNo
max_commitsNo
half_life_daysNo
max_files_per_commitNo

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.1/5.0
Behavior4/5

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

No annotations are supplied, so the description carries the full burden, and it discloses meaningful behavior: only currently-existing files are listed, commits touching more than max_files_per_commit files and lock files are filtered out, and churn is halved every half_life_days. It omits any note on cost/performance for large repos or on permissions, which keeps it short of a 5.

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?

Front-loaded with the ranking definition, then parameter semantics in a compact second half; every clause carries information, though the single dense opening sentence asks the reader to parse a formula inline.

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 values need no explanation, and the description covers the non-obvious behavioral rules for an 11-parameter analytics tool. The gaps are the four unmentioned parameters (ref, repo, limit, max_commits) in an unannotated, zero-coverage schema.

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 description coverage is 0%, so the description must compensate and does so for most parameters: since/until accept git dates with examples, as_of pins 'now', path limits to a directory, exclude adds globs, half_life_days drives the decay, max_files_per_commit controls the reformat filter. It leaves ref, repo, limit and max_commits unexplained.

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 ('Rank files by risk') and immediately defines the ranking formula (recency-weighted churn times 1 + log2 of distinct authors), which makes it trivially distinguishable from sibling analytics tools like bus_factor or churn_timeline.

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?

Gives useful in-tool guidance, such as when to use exclude ('extra globs like *.min.js') and what date formats since/until accept, but never says when to pick this tool over siblings such as bus_factor or churn_timeline.

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