Skip to main content
Glama

ValuEdge MCP — Stock Valuation, Screener & Portfolio Research

Analyze my trading journal

analyze_trading_performance
Read-onlyIdempotent

Analyze matched historical stock and ETF SELL executions in the signed-in user's ValuEdge portfolio. Choose overview, daily, sale_weekday or holding_period breakdown, optionally selecting a ticker/currency. Use recorded transaction dates and calendar holding days, not verified execution hours. Compute FIFO gross P&L, P&L after recorded fees, fee impact and verified net only with fee evidence. Preserve eligible history before the first ambiguous date after all identity/source/inventory checks; disclose excluded later sales. One sale is not a full round trip. Keep currencies, matching coverage and fee coverage separate. Not account equity returns, tax reporting or trading instructions. For a daily, weekly or monthly period comparison, specify current from/to and period_review with previous from/to; optional same ticker/currency. This read-only report is included in Lite and higher paid plans or an active Trial. Request separately from other journal review options.

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": "analyze_trading_performance"
  }
}

Input Schema

NameRequiredDescriptionDefault
toNoEnd date in YYYY-MM-DD format.
fromNoStart date in YYYY-MM-DD format.
tickerNoOptional exact ticker. Applied after complete FIFO matching; prior purchases remain available.
currencyNoOptional currency code. Required when ranking realized P&L so currencies are never compared nominally.
breakdownNoRequested breakdown; default overview. Daily detail is bounded and reports truncation. Weekdays use recorded sale dates, not exchange-local execution times.
period_reviewNo
portfolio_nameNo

Output Schema

NameRequiredDescriptionDefault
dataNo
errorNo
metadataYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / period_review
      Added value: +{
      +  "additionalProperties": false,
      +  "properties": {
      +    "from": {
      +      "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
      +      "type": "string"
      +    },
      +    "to": {
      +      "$ref": "#/properties/period_review/properties/from"
      +    }
      +  },
      +  "required": [
      +    "from",
      +    "to"
      +  ],
      +  "type": "object"
      +}
  2. Changed3 schema fields changed
    • addedInput schema / properties / breakdown
      Added value: +{
      +  "description": "Requested breakdown; default overview. Daily detail is bounded and reports truncation. Weekdays use recorded sale dates, not exchange-local execution times.",
      +  "enum": [
      +    "overview",
      +    "daily",
      +    "sale_weekday",
      +    "holding_period"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / currency
      Added value: +{
      +  "description": "Optional currency code. Required when ranking realized P&L so currencies are never compared nominally.",
      +  "pattern": "^[A-Za-z]{3}$",
      +  "type": "string"
      +}
    • addedInput schema / properties / ticker
      Added value: +{
      +  "description": "Optional exact ticker. Applied after complete FIFO matching; prior purchases remain available.",
      +  "pattern": "^[A-Za-z0-9][A-Za-z0-9.\\-]{0,17}$",
      +  "type": "string"
      +}
  3. Added

TDQS

A4/5.0
Behavior4/5

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

Annotations already cover the safety profile (readOnly, idempotent, non-destructive, closed-world), and the description adds genuinely new behavior: entitlement gating ('included in Lite and higher paid plans or an active Trial'), FIFO cost-basis methodology, the rule that sales after the first ambiguous date are excluded and disclosed, and the caveat that one sale is not a full round trip. The remaining gap is that the exclusion logic ('after all identity/source/inventory checks', 'first ambiguous date') is too cryptic to act on.

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?

Purpose and scope are front-loaded in the first sentence, and the period-review instruction is placed late where it is needed. The middle is overpacked with internal jargon — 'Preserve eligible history before the first ambiguous date after all identity/source/inventory checks' — that an agent cannot operationalize and that crowds out plainer guidance.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With an output schema present, the description need not describe return values, and it instead covers methodology, currency/matching/fee coverage separation, entitlement, and the comparison mode — enough to call the tool correctly. The only notable hole is the unexplained portfolio_name parameter, which is a minor omission against an otherwise complete definition.

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?

The schema already documents ticker ('applied after complete FIFO matching') and currency ('required when ranking realized P&L'), so the description largely restates them. It does add value by explaining how period_review pairs with from/to for a comparison, which the schema leaves undocumented. However, portfolio_name (the one nullable/nested-adjacent parameter) is never explained in either place.

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?

The opening sentence gives a precise verb and resource — analyze matched historical stock/ETF SELL executions in the signed-in user's portfolio — plus the computed outputs (FIFO gross P&L, fee impact, verified net). It also carves out scope against adjacent capabilities ('Not account equity returns, tax reporting or trading instructions'), which separates it from portfolio-analysis and closed-trade siblings without naming them.

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?

There is real conditional guidance for the period-comparison mode ('specify current from/to and period_review with previous from/to') and a hint to keep it separate from other journal review options. But the routing advice is vague — 'Request separately from other journal review options' names no alternative — and nothing states when an agent should pick this over get_closed_trades or analyze_my_portfolio for a realized-P&L question.

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.