Skip to main content
Glama
mcp-server-worldquantbrain

mcp-server-worldquantbrain

Get alpha PnL

get_alpha_pnl
Read-onlyIdempotent

Summarize an alpha's PnL by year and optionally include recent daily cumulative values to review performance.

Instructions

Summarize an alpha's PnL by year, with optional recent daily cumulative values.

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": {
      "alpha_id": "<alpha_id>"
    },
    "name": "get_alpha_pnl"
  }
}

Input Schema

NameRequiredDescriptionDefault
last_nNoOnly the last N days.
alpha_idYesBRAIN alpha id, for example 'qMPjAxnO'.
include_dailyNoAdd daily rows, at most 500.

Output Schema

NameRequiredDescriptionDefault
dailyNo
yearlyNo
alpha_idYes
end_dateNo
total_pnlNo
truncatedNo
start_dateNo
total_rowsNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.2.2
    • removedOutput schema / properties / yearly / default
      Removed value: -[]
  2. First observedv0.1.0

TDQS

B3.4/5.0
Behavior3/5

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

Annotations already declare readOnlyHint, idempotentHint, destructiveHint=false and openWorldHint, so the safety profile is covered. The description adds that results are aggregated by year with an optional daily cumulative series, which hints at output shape, but says nothing about cost, rate limits, or what happens when the alpha has no PnL history.

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?

A single front-loaded sentence that states the operation and its optional extension with zero filler. Nothing could be removed without losing meaning.

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 and annotations are rich, so the description needn't explain return values; it correctly focuses on the aggregation scope. The remaining gap is the absence of any precondition (e.g., requiring a simulated alpha), which matters for correct invocation.

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 coverage is 100% and each parameter is individually documented, so the schema does the heavy lifting. The description's phrase "optional recent daily cumulative values" loosely ties to include_daily and last_n but adds no format, unit, or interaction detail beyond the schema.

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?

States a specific verb and resource ("Summarize an alpha's PnL") plus the aggregation granularity ("by year"), which lets an agent distinguish it from siblings like get_alpha or get_alpha_recordset. It stops short of explicitly contrasting with any sibling, but the resource+operation pair is unambiguous.

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?

Gives no when-to-use guidance, no prerequisites (e.g., whether the alpha must have a completed simulation), and names no alternative for related data such as correlations or recordsets. Usage is only implied by the phrase "PnL by year".

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