Skip to main content
Glama
chelslava

ContextTree MCP

by chelslava

semantic_search

Search indexed code with natural-language queries to find relevant functions and classes, returning ranked fragments with exact file, line, and code snippets.

Instructions

Natural-language search over indexed code. Returns ranked code fragments with exact file, class, method, start_line, end_line, and code snippets.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNo
queryYes
directory_pathNo.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior3/5

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

No annotations are supplied, so the description carries the behavioral disclosure burden. It accurately conveys that this is a read-only ranked search and lists concrete output fields, but it does not disclose what happens when the code has not been indexed, how rankings are determined, or any failure behavior.

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 concise, information-dense sentences. It front-loads the tool purpose and immediately follows with the concrete return value shape. There is no filler or repetition of schema details.

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?

The output schema likely covers return-value details, but the description still lacks important contextual guidance like 'run index_workspace first' and when to choose semantic_search over find_ast_usages. It is adequate for a straightforward search tool but not fully complete for an autonomous 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 should compensate for the input parameters, but it only explains output fields. The parameter names and defaults provide some minimal intuition, but query, limit, and directory_path receive no real semantic guidance, especially around how the directory_path interacts with the indexed workspace.

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?

Description clearly identifies a semantic/natural-language search over indexed code and lists the enrich return fields (file, class, method, line numbers, code snippets). This makes it distinguishable from index_workspace and find_ast_usages in substance, though it never explicitly compares against those sibling tools.

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?

The phrase 'Natural-language search over indexed code' implies when to use it, but there is no explicit when-to-use/when-not-to-use guidance, no direct mention of find_ast_usages for exact-symbol queries, and no note that the workspace must be indexed before this tool is useful.

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/chelslava/mcp-context-tree'

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