Skip to main content
Glama

Journal statistics

get_journal_stats
Read-only

The journal page's figures for one market: closed trades, the total return after fees, the average holding time, and the win rate and average return of trades bought on a strategy signal, on a price alert and manually, with how they compare, all worked out from the user's own records.

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": {
      "market": "<market>"
    },
    "name": "get_journal_stats"
  }
}

Input Schema

NameRequiredDescriptionDefault
fromNoOnly positions opened on or after, YYYY-MM-DD.
marketYeshk = Hong Kong, us = United States, cn = China A-shares.
group_byNotag: the same figures for each tag as well.

Output Schema

NameRequiredDescriptionDefault
fromNo
errorNo
by_gutNo
by_tagNo
closedNo
marketNo
tradesNo
by_rulesNo
warningsNo
comparisonNo
by_price_alertNo
avg_hold_trading_daysNo
cumulative_return_pctNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • addedOutput schema / properties / error / properties / reason
      Added value: +{
      +  "type": "string"
      +}
    • addedOutput schema / properties / warnings
      Added value: +{
      +  "items": {
      +    "type": "string"
      +  },
      +  "type": "array"
      +}
  2. Added

TDQS

B3.2/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true, openWorldHint=false and destructiveHint=false, so the safety profile costs the description nothing. The description does add one piece of real behavioral context — the figures are 'worked out from the user's own records', telling the agent the result is a computed aggregate over recorded positions rather than live market data. It says nothing about how the 'from' cutoff or the 'group_by' tag breakdown alters the result shape, which is the remaining behavioral gap.

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 sentence, front-loaded with the resource and then the metric inventory, so the agent hits the identifier first. It is dense but every clause describes a returned figure. Rendering the metric list as a comma-separated enumeration inside one sentence makes it slightly harder to scan than it needs to be.

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 the description is not obliged to explain return values — yet it usefully previews what the payload contains, which supports tool selection. Annotations carry the safety profile and the schema carries all three parameters, leaving little an agent needs that is missing. The only shortfall is the absence of any routing hint toward or away from get_journal.

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%, with both enums documented in-schema (hk/us/cn mapped to region names, tag for per-tag breakdown), so the baseline is 3. The description reinforces the market scoping but adds no meaning beyond the schema for 'from' or 'group_by'. The one implicit addition is that the metrics are per-market aggregates, which frames how the market parameter behaves.

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 names a specific verb and resource — it returns the journal page's figures for one market — and enumerates the returned metrics (closed trades, total return after fees, average holding time, win rate by signal source). The scope ('one market', 'from the user's own records') makes the resource unambiguous. It stops short of distinguishing itself from the sibling get_journal, so an agent cannot tell from the text alone which of the two to reach for.

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

Usage Guidelines2/5

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

There is no statement of when to use this tool versus alternatives; the sibling named get_journal plausibly overlaps and is never mentioned. The only usage-adjacent signal is the implicit constraint that the call is scoped to a single market. The agent must infer the when-to-use from the tool name and the metric list.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.