Skip to main content
Glama
GreptimeDB MCP Server

GreptimeDB MCP Server

Official
by GreptimeTeam

describe_table

Retrieve a table's schema, semantic metadata, sample rows, and query guidance to understand unfamiliar data before writing SQL.

Instructions

Get a table profile: schema, semantic metadata, sample rows, and guidance.

Use it when deciding how to query an unfamiliar table. When the right table
is not known yet, search_table_semantics first; describing candidates one
by one is slower than querying the data.

The semantic profile says what the table means, not what its data says.
signal_type is metric, log, trace, or event; source and source_version name
the ingestion protocol; pipeline names the schema that shaped the rows;
semantic_options carries signal-specific facts such as metric type and
unit. metadata_quality describes how the metric type was obtained --
`declared` by the protocol or `inferred` from the name -- and says nothing
about telemetry quality. entity_declarations lists the entities the table
contributes to the semantic graph. A null or missing semantic field means
unknown, not the opposite fact.

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": {
      "table": "<table>"
    },
    "name": "describe_table"
  }
}

Input Schema

NameRequiredDescriptionDefault
tableYesUnquoted table, schema.table, or catalog.schema.table name. A catalog prefix is ignored; reads use the connected catalog.
sample_limitNoMaximum sample rows to return (0-20, default: 5)
include_samplesNoInclude a small sample of table rows for context
include_semanticsNoInclude table semantic metadata from information_schema.table_semantics

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changedv0.6.2
    • addedInput schema / properties / include_samples / description
      Added value: +"Include a small sample of table rows for context"
    • addedInput schema / properties / include_semantics / description
      Added value: +"Include table semantic metadata from information_schema.table_semantics"
    • addedInput schema / properties / sample_limit / description
      Added value: +"Maximum sample rows to return (0-20, default: 5)"
    • addedInput schema / properties / table / description
      Added value: +"Unquoted table, schema.table, or catalog.schema.table name. A catalog prefix is ignored; reads use the connected catalog."
    • changedOutput schema / (root)
      Previous value: -{
      -  "properties": {
      -    "result": {
      -      "title": "Result",
      -      "type": "string"
      -    }
      -  },
      -  "required": [
      -    "result"
      -  ],
      -  "title": "describe_tableOutput",
      -  "type": "object"
      -}New value: +null
  2. Addedv0.5.0

TDQS

A4.3/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does substantial work: it discloses that the semantic profile describes meaning rather than data, defines signal_type, source, pipeline, semantic_options, metadata_quality (declared vs inferred), and entity_declarations, and warns that null/missing means unknown rather than the opposite. It does not state read-only nature, permissions, or cost/latency explicitly, but the extensive field-level disclosure is well beyond what an unannotated tool usually gets.

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?

Purpose and routing guidance are front-loaded in the first two sentences, with the semantic-field glossary after. The third paragraph is dense and slightly long, but every line maps to something the caller must interpret and no output schema exists to document it, so little could be cut without loss.

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?

There is no output schema, so the description must explain return contents, and it does so in detail for the semantic metadata portion. The 'sample rows' and 'guidance' portions of the return are named but not characterized, and the interaction between include_samples/include_semantics and what is returned is left to the schema, a minor gap for a four-parameter profile tool.

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% and every parameter (table, sample_limit, include_samples, include_semantics) is documented inline, so the schema does the heavy lifting. The description adds no extra syntax, prefix-handling, or cost implications for those parameters, which is the expected baseline of 3 when the schema is complete.

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?

Opens with a specific verb and resource: "Get a table profile: schema, semantic metadata, sample rows, and guidance." It enumerates exactly what comes back and names the sibling search_table_semantics as the different tool, so an agent can distinguish the two without opening either 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 scopes when to use it ("when deciding how to query an unfamiliar table") and when to prefer the alternative ("When the right table is not known yet, search_table_semantics first"), plus a rationale that describing candidates one by one is slower. Both the use case and the exclusion are stated.

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