Skip to main content
Glama
longbridge

longbridge

Official

Profit Analysis Detail

profit_analysis_detail
Read-onlyIdempotent

Get detailed profit and loss analysis for a specific security symbol. Optionally filter by date range; provide both start and end dates together to avoid empty results.

Instructions

Get detailed profit and loss analysis for a specific symbol. start/end: optional date range in yyyy-mm-dd format. Both must be provided together — passing only one returns empty results.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
_jqNoOptional jq filter (jaq syntax) applied to this tool's JSON response before it is returned; it never changes the upstream request. One output is returned as-is, several as a JSON array, none as []. Module imports and the `env`/`debug`/`stderr` builtins are unavailable. Example: .data | map({symbol}). Omit for the full response.
endNoEnd date (yyyy-mm-dd). Must be paired with `start`; passing only one returns empty results.
startNoStart date (yyyy-mm-dd). Must be paired with `end`; passing only one returns empty results.
symbolYesSecurity symbol, e.g. "700.HK". Use the canonical form — a padded code like "00700.HK" returns an empty record, not an error.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv0.12.0
    • addedInput schema / properties / _jq / description
      Added value: +"Optional jq filter (jaq syntax) applied to this tool's JSON response before it is returned; it never changes the upstream request. One output is returned as-is, several as a JSON array, none as []. Module imports and the `env`/`debug`/`stderr` builtins are unavailable. Example: .data | map({symbol}). Omit for the full response."
    • changedInput schema / properties / symbol / description
      Previous value: -"Security symbol, e.g. \"700.HK\""New value: +"Security symbol, e.g. \"700.HK\". Use the canonical form — a padded code like \"00700.HK\" returns an empty record, not an error."
  2. Changed1 schema field changedv0.10.6
    • addedInput schema / properties / _jq
      Added value: +{
      +  "type": "string"
      +}
  3. Changed1 schema field changedv0.7.1
    • removedInput schema / title
      Removed value: -"ProfitAnalysisDetailParam"
  4. Addedv0.4.5
  5. Removedv0.4.0
  6. Addedv0.3.2
  7. Removedv0.3.1
  8. First observedv0.1.12

TDQS

B3.4/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, idempotentHint, and non-destructive behavior. The description adds two concrete behavioral quirks: start/end must be paired or results are empty, and non-canonical symbol forms return empty records instead of errors. These are valuable beyond the annotations.

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?

The description is two sentences, front-loaded with the main purpose. The second sentence reiterates parameter constraints already present in the schema, which is slightly redundant but not verbose. It is concise and efficient.

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?

For a read-only tool with safety covered by annotations, the description covers the essential call behaviors (symbol, date pairing). However, it does not clarify how this 'detailed' analysis differs from other profit_analysis siblings, which is a gap for an agent deciding between tools. No output schema is provided, so return format is left 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?

Schema description coverage is 100%, and the schema already explains the pairing rule and canonical symbol format. The description does not add any new parameter semantics beyond what is in the schema, so it meets the baseline of 3.

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 states a clear verb and resource: 'Get detailed profit and loss analysis for a specific symbol.' It is specific and actionable, but does not explicitly differentiate from siblings like profit_analysis or profit_analysis_realized, so it misses the top score for sibling distinction.

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?

No guidance is given on when to choose this tool over profit_analysis or profit_analysis_realized. The description mentions parameter pairing rules, but that is a usage constraint, not a selection guideline among alternatives.

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

Deploy Server

Other Tools