Skip to main content
Glama
Smart Quota Orchestrator

Smart Quota Orchestrator

by ElNeMeR70

sqo_code_search

Search code and symbols by identifier or natural-language query to return top-K relevant functions/classes with exact file and line coordinates, reducing token use versus grep and full-file reads.

Instructions

Instant SQLite FTS5 BM25 code & symbol chunk search. Returns top-K relevant functions/classes with exact file:Lstart-Lend coordinates in <250 tokens (90%+ savings vs grep + full reads).

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": {
      "workspace": "<workspace>",
      "query": "<query>"
    },
    "name": "sqo_code_search"
  }
}

Input Schema

NameRequiredDescriptionDefault
queryYesIdentifier, symbol, or natural-language code query.
top_kNoNumber of top chunks to return (default: 6).
workspaceYesAbsolute path to the workspace root directory.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv13.0.0

TDQS

A3.5/5.0
Behavior3/5

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

No annotations are supplied, so the description carries the full behavioral burden. It does disclose the retrieval mechanism (FTS5 BM25), the result granularity (chunks with file:start-end coordinates) and the rough output budget (<250 tokens), but it omits prerequisites such as whether the workspace must first be indexed or what happens with a stale index.

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?

Two front-loaded sentences with the core capability first and the efficiency claim second. The '90%+ savings vs grep' phrase is mild marketing but does serve as selection rationale rather than pure filler.

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 a three-parameter read tool with no output schema, the description adequately covers what comes back (ranked chunks with exact line coordinates) and roughly how large it is. The remaining gaps—index setup assumptions and empty-result behavior—are minor for this complexity.

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

Parameters3/5

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

Schema description coverage is 100%, so all three parameters are already documented. The description adds only marginal meaning ('top-K relevant functions/classes' reinforcing top_k), and says nothing extra about query syntax or what the workspace path must point to.

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?

States a specific verb and resource ('SQLite FTS5 BM25 code & symbol chunk search') plus the return shape ('top-K relevant functions/classes with exact file:Lstart-Lend coordinates'). It clearly contrasts with grep + full reads, but names no sibling tool (e.g., sqo_find_callers) so an agent must still infer which SQE search tool to use.

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?

Usage is only implied: you search code by identifier or natural-language query and save tokens versus grep. There is no explicit when-to-use/when-not-to-use guidance and no pointer to sibling tools like sqo_find_callers or sqo_edit_symbol that overlap on symbol lookup.

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