Skip to main content
Glama
niuheilong

stock-mcp-server

get_usage_stats

Retrieve local tool call statistics for the stock MCP server, including total calls, errors, per-tool counts, and daily distribution over a chosen number of days.

Instructions

获取本 MCP 服务器的工具调用统计(本地记录)。

返回最近 N 天的调用总数、错误数、各工具调用次数、按天分布。 统计只覆盖有写入日志文件的实例;日志路径可用环境变量 STOCK_MCP_USAGE_LOG 指定。

Args: days: 统计最近多少天,默认 7,最大 365。

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
daysNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.1.2

TDQS

A4.4/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 reasonably well: it discloses that data is local, that coverage is limited to log-writing instances, and how the log path is configured. It does not state what happens when no log exists (empty result vs. error), which is the main remaining gap.

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?

Front-loaded purpose statement, then return contents, then the coverage caveat, then the argument block. No sentence is redundant and nothing important is buried.

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?

An output schema exists, so return shape need not be described, yet the description still outlines the aggregates returned (totals, errors, per-tool, per-day). Combined with the log-coverage caveat and parameter bounds, it is nearly complete; only the no-log-file edge case is unaddressed.

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 0%, so the description must compensate: it documents 'days' with its default (7) and a new bound not present in the schema (max 365). This adds real meaning beyond the bare integer property.

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+resource: retrieving tool-call usage statistics for this MCP server from local records. It is clearly distinguishable from the sibling stock-data tools (get_stock_quote, search_stock, etc.), which retrieve market data rather than server telemetry.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explains the operative condition for the tool being useful: statistics only cover instances that have written a log file, and the log path is configurable via STOCK_MCP_USAGE_LOG. It doesn't name alternatives, but none are needed given the unique purpose.

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