Skip to main content
Glama
wrale

mcp-server-tree-sitter

by wrale

adapt_query

Transform a query from one programming language to another using tree-sitter-based code analysis. Ideal for adapting code queries across different languages with accurate context management.

Instructions

Adapt a query from one language to another.

    Args:
        query: Original query string
        from_language: Source language
        to_language: Target language

    Returns:
        Adapted query
    

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
from_languageYes
queryYes
to_languageYes
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. It states the tool adapts queries but doesn't explain how the adaptation works (e.g., translation, syntax conversion), what errors might occur, or any performance considerations. This leaves significant gaps in understanding the tool's behavior.

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 front-loaded with the core purpose, followed by structured parameter and return details. It's efficient with minimal waste, though the parameter explanations could be more integrated into the main text rather than in a separate Args/Returns block.

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?

For a 3-parameter tool with no annotations and no output schema, the description is minimally adequate. It covers the basic purpose and parameters but lacks details on adaptation mechanics, error handling, or output format. Given the complexity, it's incomplete but not entirely inadequate.

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?

The description lists the three parameters (query, from_language, to_language) and their roles, adding meaning beyond the schema's 0% coverage. However, it doesn't specify language formats (e.g., SQL, Python) or query constraints, leaving some ambiguity. With low schema coverage, this partial compensation earns a baseline score.

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 states the tool's purpose: 'Adapt a query from one language to another.' It specifies the verb ('adapt') and resource ('query'), making the function unambiguous. However, it doesn't explicitly distinguish this from sibling tools like 'build_query' or 'run_query', which prevents a perfect score.

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?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention when to choose 'adapt_query' over 'build_query' or 'run_query', nor does it specify prerequisites or exclusions. The usage context is implied but not articulated.

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

Related 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/wrale/mcp-server-tree-sitter'

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