Skip to main content
Glama
serial-hub-mcp

serial-hub-mcp

by yhuan416

串口日志统计

log_stats

Retrieve log storage statistics for one serial connection or all connections, covering entry counts, memory/disk distribution, partition and eviction details, time ranges, and directory paths.

Instructions

查看日志存储统计:各连接的日志总条数、内存/磁盘分布、分区/淘汰信息、时间范围、目录路径;省略 connection_id 则给出全局汇总。

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "log_stats"
  }
}

Input Schema

NameRequiredDescriptionDefault
connection_idNo连接 ID;省略则全查

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.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 burden. It does disclose the categories of data returned and the scoping behavior of the optional parameter, and '查看' signals a non-mutating read. It does not state whether this is strictly read-only, whether it scans disk and might be slow on large stores, or how large the response can get — meaningful gaps for a stats tool.

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?

One compact sentence front-loads the purpose, then lists the returned facets, then ends with the scoping rule. The enumeration is dense but each item is information the agent needs to recognize the right tool; little is wasted.

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 single-parameter read-only stats tool with no output schema and no annotations, the description covers purpose, return content categories, and scoping, which is enough to call it correctly. Only the mutation/permission profile and potential cost of a full scan are unaddressed.

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?

There is a single optional parameter with 100% schema description coverage, so the baseline is 3. The description's '省略 connection_id 则给出全局汇总' restates what the schema already says ('连接 ID; 省略则全查') rather than adding format, valid-value, or defaulting details.

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?

The description gives a specific verb plus resource ('查看日志存储统计') and enumerates the returned facets: per-connection log counts, memory/disk distribution, partition/eviction info, time range and directory paths. It also distinguishes two scopes (per-connection vs. global summary), which separates it from content-oriented siblings like log_query or log_clear, though it never names an alternative explicitly.

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?

The clause '省略 connection_id 则给出全局汇总' tells the agent how to get aggregate output, which implies when to include the parameter and when not to. However, there is no explicit statement of when to use this tool rather than log_query (content retrieval) or log_clear (deletion), and no prerequisites or exclusions are given.

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