Skip to main content
Glama

check_consistency

Verify identifier naming patterns for consistency with existing code, providing suggestions to maintain uniform naming conventions.

Instructions

Check if an identifier name is consistent with existing naming patterns.

Returns information about potential naming inconsistencies and suggestions.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
requestYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The 'check_consistency' tool handler, which calls 'session_tracker.check_consistency' to identify naming inconsistencies.
    @mcp.tool()
    async def check_consistency(
        request: ConsistencyCheckRequest, context: Context
    ) -> dict[str, Any]:
        """
        Check if an identifier name is consistent with existing naming patterns.
    
        Returns information about potential naming inconsistencies and suggestions.
        """
        consistency = session_tracker.check_consistency(request.identifier)
    
        if consistency:
            return {
                "consistent": False,
                "issue": consistency["message"],
                "existing_similar": consistency["existing"],
                "suggestion": consistency["suggestion"],
            }
    
        # Check if it exists
        info = session_tracker.get_identifier_info(request.identifier)
        if info:
            return {
                "consistent": True,
                "exists": True,
                "info": {
                    "type": info.type,
                    "occurrences": info.occurrences,
                    "first_seen": info.first_seen.isoformat(),
                    "last_seen": info.last_seen.isoformat(),
                },
            }
    
        return {
            "consistent": True,
            "exists": False,
            "message": "No consistency issues found",
        }
Behavior2/5

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

No annotations are provided, so the description carries full burden. It mentions the tool returns 'information about potential naming inconsistencies and suggestions', which gives some behavioral insight (non-destructive, read-only analysis). However, it lacks details on permissions, rate limits, error handling, or what constitutes 'existing naming patterns' (e.g., from a database or predefined rules). This is a significant gap for a tool with no annotation coverage.

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 description is brief and front-loaded, with two sentences that directly state the tool's purpose and output. There's no wasted text, but it could benefit from slightly more detail to improve clarity without losing conciseness. The structure is efficient but under-specified.

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

Completeness3/5

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

Given the tool has an output schema (which should document return values), the description doesn't need to explain outputs. However, with no annotations, 0% schema coverage, and one parameter, the description is incomplete—it lacks context on the system (e.g., programming language, project) and behavioral details. It's minimally viable but has clear gaps in guiding the agent.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/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. It implies a single parameter ('identifier name') but doesn't specify format, constraints, or examples (e.g., is it a variable name, file path, or something else?). The description adds minimal value beyond the schema's structural definition, failing to clarify the parameter's meaning or usage context.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose3/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states the tool checks if an identifier name is consistent with existing naming patterns, which is a clear purpose. However, it doesn't distinguish this from sibling tools like 'check_code' or 'check_lollipop_status', leaving ambiguity about what specific domain or system this applies to. The verb 'check' is clear but the scope 'existing naming patterns' is somewhat vague without context.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

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

No explicit guidance is provided on when to use this tool versus alternatives. The description doesn't mention prerequisites, context (e.g., during code review or naming validation), or how it differs from siblings like 'check_code' or 'suggest_fix'. This leaves the agent guessing about appropriate use cases.

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

Install Server

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/kimasplund/mcp-pyrefly'

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