Skip to main content
Glama

xmp4 — Semantic code knowledge for your stack

xmp4_grep

Server-side regex text search over indexed project source files. Free tier: requires file_path (single file). Premium tier (XMP4_PREMIUM_GREP_WALK=true): allows file_glob multi-file walk. Prefer xmp4_tests_for/xmp4_usages for SCIP symbols — grep is for text not indexed (comments, literals, config keys).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pageNoPage number (1-based, default 1)
patternYesRegex pattern (case-insensitive by default)
projectYesProject id: 'repo/project' or 'repo/project/language'. Case-insensitive prefix match. Append '/Python'|'/CSharp'|'/Java'|etc. only to disambiguate multi-language projects (e.g. 'django/Django/Python' vs 'django/Django/JavaScript'). 1 match → proceeds; N → warning lists candidates; 0 → do NOT iterate guesses, call xmp4_projects(query=...) once then retry.
file_globNoOptional file glob for multi-file walk (premium tier). Set XMP4_PREMIUM_GREP_WALK=true to enable.
file_pathNoSingle-file grep target, repo-relative (e.g. 'src/foo.rs'). Required in free tier.
page_sizeNoResults per page (default 20, max 100)
max_resultsNoMaximum number of hits to collect before pagination (default 50, max 1000)
case_sensitiveNoIf true, search is case-sensitive (default false)

TDQS

A4.6/5.0
Behavior4/5

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

With no annotations provided, the description carries the transparency burden. It discloses key behavioral traits: server-side execution, reliance on an index, and tier-based restrictions (file_path required in free tier; file_glob only with XMP4_PREMIUM_GREP_WALK=true). It does not mention result format or rate limits, but the core constraints are well-covered.

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?

Three sentences with no fluff. The primary action and resource are stated first, followed by tier constraints and alternative tool guidance. Every sentence earns its place, making it compact and readable.

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

Completeness4/5

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

For an 8-parameter tool with no output schema and no annotations, the description sufficiently explains core use cases, tier restrictions, and alternatives. It omits details like pagination behavior or result structure, but those are partially addressed in the schema. Overall, it provides enough context for an agent to decide when and how to invoke the tool.

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

Parameters4/5

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

Schema coverage is 100%, so baseline is 3. The description adds value beyond schema by explaining when file_path vs. file_glob should be used (free vs. premium) and that grep targets non-indexed text, which aids parameter selection and interpretation.

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 states a specific verb ('search') and resource ('indexed project source files') with a clear scope: server-side regex text search. It also distinguishes from sibling symbol-oriented tools by explicitly mentioning to prefer xmp4_tests_for/xmp4_usages for SCIP symbols, making its purpose unmistakable.

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?

The description provides explicit when-to-use and when-not-to-use guidance: use grep for text not indexed (comments, literals, config keys) and prefer symbol tools for SCIP symbols. It also clarifies free vs. premium tier usage (file_path vs. file_glob), giving clear context for caller decisions.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

TDQS

A3.7/5.0
Disambiguation5/5

Each tool targets a distinct purpose: callers vs callees vs usages vs tests_for are directionally different, grep vs search separates text from symbol queries, and outline/view/source/info each serve unique functions. No two tools clearly overlap.

Naming Consistency5/5

All tools follow a uniform 'xmp4_<snake_case_noun>' pattern with no mixed conventions or camelCase. The names are terse, descriptive, and predictably formatted.

Tool Count4/5

At 16 tools, this is slightly above the typical well-scoped range (3–15), but the breadth is justified by the comprehensive code-knowledge domain. Every tool covers a distinct feature, so the count feels reasonable rather than bloated.

Completeness5/5

The surface is remarkably complete for semantic code analysis: project discovery (xmp4_projects), symbol lookup (xmp4_search, xmp4_symbol_at, xmp4_info), navigation (xmp4_outline, xmp4_view, xmp4_source), relationship exploration (callers, callees, hierarchy, usages, tests_for), and supporting meta tools (guide, server, deps, grep). No obvious gaps exist for its stated purpose.