Skip to main content
Glama
Wildcard-Official

DeepContext

Official

search_codebase

Search an indexed codebase with natural language to locate functions, classes, and patterns. Understand dependencies and explore existing systems.

Instructions

<parameter name="codebase_path" required="true">
  <type>string</type>
  <description>ABSOLUTE path to the codebase directory to search</description>
  <examples>
    <valid>/Users/name/project</valid>
    <valid>/home/user/code/repo</valid>
    <invalid>.</invalid>
    <invalid>../project</invalid>
    <invalid>relative/path</invalid>
  </examples>
  <validation>Must be absolute path starting with / (Unix) or C:\ (Windows)</validation>
</parameter>

<parameter name="max_results" required="false">
  <type>number</type>
  <description>Maximum number of code chunks to return</description>
  <default>5</default>
  <best_practice>Keep at default 5 for focused results. Use multiple targeted searches rather than increasing this limit</best_practice>
</parameter>

Code chunks with file paths, line numbers, relevance scores, symbol information, imports, and exports Codebase must be indexed first with index_codebase

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYes
max_resultsNo
codebase_pathYes
Behavior5/5

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

No annotations are provided, so the description bears full responsibility. It discloses that results are ranked by semantic relevance, may miss type definitions, exclude filtered content, and require prior indexing. This goes far beyond the minimal safety/behavior hint.

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 long but well-structured with clearly labeled sections. Some repetition exists (e.g., Grep appears multiple times), but each section serves a purpose and the front-loaded purpose statement makes it easy to scan.

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?

With no annotations and no output schema, the description covers everything needed: return format, prerequisites, limitations, result interpretation, and workflow. It is complete enough for an agent to use correctly without external documentation.

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

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The schema has 0% description coverage, but the tool description compensates thoroughly. Each parameter includes type, meaning, examples, validation rules (e.g., absolute path), and best practices (e.g., keeping max_results at 5).

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 opens with a specific verb+resource statement: 'Finds relevant code in an indexed codebase using natural language or keyword queries.' This clearly distinguishes the tool from siblings like index_codebase and clear_index, which have different purposes.

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

Usage Guidelines5/5

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

A dedicated 'when_to_use' section lists concrete scenarios, and the workflow explicitly recommends alternatives like Grep for exact matches and test-file searches. Limitations with solutions further clarify when not to use the tool and what to use instead.

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/Wildcard-Official/deepcontext-mcp'

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