Skip to main content
Glama
JSungMin

vs-token-safer

search_text

Search source files for text or regex patterns in strings, comments, and config keys that the symbol index cannot find, returning token-limited results.

Instructions

Raw text/regex search in source (string literals, comments, config keys — things the symbol index can't answer). Bounded and token-capped to file:line: trimmed-line. The sanctioned replacement for Bash grep when you genuinely need text, not symbols. Prefer search_symbol for code symbols.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
qYesString or regular expression to find.
pathNoSearch ONE named file (any extension — naming a README.md/.txt/etc auto-includes it; no docs flag needed). Relative to the project root or absolute.
globNoSearch only files matching this basename glob (e.g. *.md, *.json) — any extension the glob covers, no docs flag needed.
projectPathNo
maxResultsNo
docsNoWhen NO path/glob is given, widen the project-wide sweep to README/docs/config text (md/txt/json/yaml/…), not just source. Ignored when path/glob targets a file directly.
Behavior4/5

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

With no annotations, the description discloses the bounded and token-capped nature, output format (file:line: trimmed-line), and the role of the docs parameter. It does not mention permissions or reversibility, but for a search tool this is sufficient.

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 three sentences long, front-loads the core purpose, and contains no unnecessary words. Every sentence adds value.

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?

Given no annotations and no output schema, the description covers the essential behavior (what it does, when to use, output format). It could mention regex flags or case sensitivity, but overall it is complete enough for a search 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 description coverage is 67%, and the description adds context to the docs parameter by explaining its conditional usage. The description also implies output formatting, which is not in the schema. However, the description does not elaborate on 'maxResults' or 'projectPath'.

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 clearly states it performs raw text/regex search in source for items the symbol index cannot handle, and explicitly distinguishes it from search_symbol for code symbols. The verb 'search' and resource 'text/regex' are specific.

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 explicitly says to prefer search_symbol for code symbols, and frames search_text as the sanctioned replacement for Bash grep when text is needed. It also explains when to use the docs parameter.

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/JSungMin/vs-token-safer'

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