Skip to main content
Glama

locus_inspect

Inspect a document's indexed corpus to see chunk count, word count, top BM25 terms, entities, and wikilinks, so you can debug indexing quality and verify retrieval readiness.

Instructions

Inspect a document's corpus representation: chunk count, word count, top BM25 terms, entities, and internal wikilinks. Useful for debugging indexing quality.

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": {
      "doc_path": "<doc_path>"
    },
    "name": "locus_inspect"
  }
}

Input Schema

NameRequiredDescriptionDefault
limitNo
doc_pathYes
store_pathNo.locus

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.3.1

TDQS

B3.1/5.0
Behavior2/5

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

No annotations exist, so the description carries the full behavioral burden. It discloses the returned fields (valuable, since there is no output schema) but says nothing about whether inspection triggers re-indexing, what happens if doc_path is not in the corpus, or how store_path affects behavior. For a zero-annotation tool this leaves significant gaps.

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?

Two tight sentences with the output inventory front-loaded and no filler. Each clause adds information an agent cannot get from the schema.

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

Completeness3/5

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

Listing the returned fields partially substitutes for a missing output schema, which is helpful. But with three undocumented parameters, no annotations, and no error/precondition information, the definition is only adequate for a debugging tool that will be called with a file path.

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

Parameters2/5

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

Schema coverage is 0%, so the description must compensate and does not: doc_path is only obliquely referenced by "a document's", while store_path (the corpus location, defaulted to .locus) and limit (likely bounding the number of BM25 terms/entities shown) are never explained. An agent cannot know what limit constrains or why it would point at a non-default store.

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?

Uses a specific verb ("Inspect") on a specific resource ("a document's corpus representation") and enumerates exactly what is shown: chunk count, word count, top BM25 terms, entities, wikilinks. It doesn't name a sibling to differentiate from (e.g., locus_doctor, locus_explain, locus_query_entity), so an agent must infer the boundary itself.

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?

"Useful for debugging indexing quality" implies the diagnostic use case, which is genuine guidance. However, there is no statement of when to prefer this over locus_doctor, locus_explain, or locus_chunks_with_label, and no prerequisites such as requiring the document to already be indexed.

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