Skip to main content
Glama

duplication

Read-onlyIdempotent

Identify near-duplicate function pairs by normalized line shingles and containment percent. Use before a refactor to fold twins together instead of fixing only one copy.

Instructions

Near-duplicate function pairs by normalized line shingles, with the containment percent. Use it before a refactor so twins get folded together instead of one copy getting fixed alone.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
repoNopath to the scored repo's root (default: the repo the server was started in)
similarityNocontainment threshold, shared over smaller, 0 to 1 (default 0.8)
Install Server

TDQS

A4.1/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true and idempotentHint=true, covering the safety profile. The description adds useful behavioral detail about how it works: normalized line shingles and a containment percentage. There is no contradiction with the annotations.

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 two focused sentences with no filler. The first sentence states the output and method; the second provides a concrete use case. It is easy to scan and every sentence earns its place.

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 analysis tool with two optional parameters and no output schema, the description is complete enough: it says what the tool finds, how it computes similarity, what metric is returned, and when to use it. No critical information is missing for an agent to 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 coverage is 100%, with both parameters fully documented including the default and range for 'similarity.' The description reinforces the 'containment' concept but adds no new parameter-level detail beyond the schema, so the baseline of 3 applies.

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 clearly identifies the tool's subject ('near-duplicate function pairs') and its method ('normalized line shingles'), plus the metric it returns ('containment percent'). It lacks an explicit verb like 'find' or 'list,' but the intent is unambiguous. It does not explicitly differentiate from sibling tools, but the narrowly defined purpose makes confusion unlikely.

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 description gives explicit guidance on when to use the tool: 'Use it before a refactor.' It also explains the benefit, folding twins together instead of fixing one copy alone. It does not name alternatives or exclusions, but the use case is clearly stated.

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

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/JeanFrancoisGagne/crapkit'

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