Skip to main content
Glama

profile

Read-onlyIdempotent

Summarizes selected JSON fields across records in one server-side scan, replacing ad-hoc loops for field discovery. Returns presence, null, type, distinct, numeric, length, and top-value summaries.

Instructions

Profile one or more fields across every selected record in one server-side scan; this replaces ad-hoc Python loops for discovering or summarizing unfamiliar JSON fields. Pass filePath for a one-call answer, or docId to reuse an open document. Returns present/missing/null counts, type counts, distinct count, exact numeric sum/min/max/average, lengths, and top values. Use fields like "status" or "capacity.used" relative to each selected record; omit fields to auto-discover up to 20 fields on selected records or profile selected scalar values. For a filtered count or a group breakdown use run_query; for whole records use sample.

Input Schema

NameRequiredDescriptionDefault
topNoTop values per field (default 10, max 50).
docIdNoA docId returned by load_doc.
queryYesPath/predicate selecting records, e.g. $.tasks[*]. Do not append a pipe.
fieldsNoOptional relative fields to profile together, e.g. ["status", "failureReason", "weightKg"].
filePathNoFile to open and profile now instead of supplying docId.

Output Schema

NameRequiredDescriptionDefault
okYes
hintNo
toolYes
errorNo
evictedNo
structuredTruncatedNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.6/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent, non-destructive and closed-world, so the safety profile is covered. The description adds real behavioral context beyond that: the work happens in a single server-side scan, omitting fields triggers auto-discovery capped at 20, and docId reuses an already-open document rather than re-reading. It does not mention size limits or performance characteristics for very large record sets, which keeps it from a 5.

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?

Three dense sentences, front-loaded with the core action and followed by routing guidance. The enumeration of return statistics is somewhat long and partly redundant with the output schema, but nothing is wasted or buried.

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?

For a read-only analytics tool with full schema descriptions and an output schema covering the returned statistics, the description supplies everything else an agent needs: selection syntax pointer, field semantics, discovery behavior, and sibling routing. No material gap remains.

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 the baseline is 3, and the description earns above that by explaining that fields are relative to each selected record ("status", "capacity.used") and that omitting them auto-discovers up to 20 fields or profiles selected scalar values. The filePath/docId tradeoff is also spelled out as a one-call answer vs reusing an open document, which is semantics the schema alone does not convey.

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?

States a specific verb and scope: profiling one or more fields across every selected record in one server-side scan. It also distinguishes itself from siblings by naming run_query for filtered counts/group breakdowns and sample for whole records, so an agent can select it without opening the schema.

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?

Explicitly frames the use case ('replaces ad-hoc Python loops for discovering or summarizing unfamiliar JSON fields'), gives the filePath-vs-docId decision rule, and names the exact alternatives for adjacent jobs. Both when-to-use and when-to-use-something-else are covered.

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