Skip to main content
Glama
openai-decisions-mcp

openai-decisions-mcp

find_code

Read-only

Locate relevant code ranges in supplied project files by query, returning paths, line ranges, and relevance probabilities without exposing code text.

Instructions

Locate relevant code within caller-supplied project files or line ranges. Evaluates every 200-line chunk with 20-line overlap, returns paths/ranges and relevance probabilities without code text. Discover candidate paths with your normal file listing first. Maximum 20 chunks and 1 MiB total text; oversized scopes fail before any paid call. One paid request per chunk, up to 3 concurrently. Returns every result, refusal and error; no automatic filtering or Read hook. Independent chunks cannot establish cross-file behavior.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "files": "<files>",
      "query": "<query>"
    },
    "name": "find_code"
  }
}

Input Schema

NameRequiredDescriptionDefault
filesYesPrefer a native JSON array. A JSON-encoded array string is also accepted for client compatibility; identical validation applies.
queryYesSelf-contained question about the code to locate.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.1

TDQS

A4.7/5.0
Behavior5/5

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

Annotations declare read-only, non-destructive, open-world behavior, and the description adds substantial context beyond that: 200-line chunks with 20-line overlap, no code text returned, paid requests per chunk, concurrency limits, and failure before paid calls on oversized scopes. It also discloses that all results, refusals, and errors are returned without filtering and that independent chunks cannot establish cross-file 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 dense but front-loaded, starting with the core action and scope before moving to cost and limits. Every sentence contributes operational information; none restate the name or title.

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?

There is no output schema, but the description explains the return format (paths/ranges and probabilities without code text), cost model, concurrency, size limits, and error behavior. For a paid, chunk-based code search tool, this is complete enough for correct invocation.

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 100%, so the schema already carries most parameter detail. The description adds useful semantics about line ranges, chunking, chunk count limits, and total text size, which go beyond the schema's field descriptions.

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 and resource: locate relevant code within caller-supplied project files or line ranges. It also clarifies the output shape (paths/ranges and relevance probabilities, not code text), which lets an agent distinguish this from siblings like decide or evaluate_batch.

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

Usage Guidelines4/5

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

It gives a concrete prerequisite: discover candidate paths with normal file listing first. It also states scope limits and failure behavior, though it does not name explicit alternative tools or when-not-to-use this tool.

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

Deploy Server

Other Tools