Skip to main content
Glama
atengk

mcp-server-kafka

by atengk

kafka_sample_messages

Samples messages from a Kafka topic read-only without committing offsets, using latest, earliest, or specific-offset strategies for safe inspection.

Instructions

从指定 Kafka 主题以零提交位移方式只读采样消息(支持 latest/earliest/offset 策略、自适应解码与大报文截断保护)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNo
topicYes
offsetNo
strategyNolatest
partitionNo
connectionNo
max_bytes_per_messageNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.3.1

TDQS

A3.6/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 so well: it discloses zero-commit-offset semantics (consumer group positions are unaffected), read-only operation, adaptive decoding, and large-message truncation protection. It omits auth/permission requirements and any limits on sampling cost or pace.

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?

A single densely packed sentence that front-loads the core purpose (read-only topic sampling) and relegates qualifying details to a parenthetical. No wasted words, though the parenthetical crams several distinct behaviors together.

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?

An output schema exists, so return values need not be described. However, for a 7-parameter tool with zero annotation and zero schema-description coverage, the description leaves half the parameters undocumented, which is a meaningful gap even though the behavioral picture is solid.

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 0% across 7 parameters, so the description must compensate. It valuably names the strategy values (latest/earliest/offset) not present in the schema and implies max_bytes_per_message via 'large message truncation', but leaves limit, offset, partition, and connection entirely unexplained.

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: read-only sampling of messages from a named Kafka topic. This is clearly distinct from write-oriented siblings like kafka_produce_message and from metadata tools like kafka_list_topics. It stops short of an explicit naming of a sibling to contrast against, so it lands at 4 rather than 5.

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 by the tool's own behavior ('sample messages'); there is no statement of when to choose this over kafka_describe_topic or other read tools, nor any when-not-to-use condition. Adequate but leaves the agent to infer the selection context.

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