Skip to main content
Glama

Project duplication statistics

get_statistics
Read-onlyIdempotent

Report duplication metrics from the latest scan: file, line, and token counts, clone count, and duplicated percentages.

Instructions

Report the duplication statistics of the last scan: for the whole project and per format, the number of files, lines and tokens analyzed, the number of clones, and the duplicated lines and tokens with their percentages. Use it to judge overall duplication or to compare before and after a refactoring (call check_current_directory in between). Takes no arguments and is read-only; it reflects the last scan, not the files on disk right now.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv5.2.0
    • addedInput schema / additionalProperties
      Added value: +false
  2. First observedv0.1.0

TDQS

A4.7/5.0
Behavior5/5

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

Annotations already declare readOnlyHint, destructiveHint, and idempotentHint, so the description adds the key non-obvious behavior: results reflect the last scan, not the files on disk right now. This is valuable context beyond the annotations and prevents misinterpretation of stale data.

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?

The description is compact yet informative, with the core purpose front-loaded and usage guidance appended. Every sentence adds value; there is no fluff. The structure is easy to parse despite the dense metric list.

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?

Given no parameters, no output schema, and annotations covering safety, the description fully specifies what the tool returns and when to use it. It also flags the staleness caveat, making it complete for an agent to call correctly.

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?

With zero parameters and 100% schema coverage, the schema already documents everything. The description adds no parameter details, but the baseline for zero-parameter tools is 4, and no additional explanation is needed.

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?

The description clearly states the tool reports duplication statistics from the last scan, enumerating specific metrics (files, lines, tokens, clones, percentages). It differentiates from siblings by focusing on project-wide stats rather than file-specific clones or directory state, making its 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 Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It explicitly says when to use it: to judge overall duplication or compare before/after a refactoring, with a specific instruction to call check_current_directory in between. It does not name alternatives directly, but the context implies it is not for current disk state, which provides adequate guidance without explicit exclusions.

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