Skip to main content
Glama

get_portfolio_performance

Read-onlyIdempotent

Retrieve portfolio performance statistics (total return, CAGR, max drawdown, Sharpe ratio, volatility, win rate) and benchmark comparison curves against TAIEX, S&P500, and retail investor index.

Instructions

取得投資組合的完整績效曲線與統計指標:總報酬率、CAGR、最大回撤、夏普比率、波動度、勝率;並附上與台股大盤(TWII)、S&P500、散戶指數的比較曲線及每筆交易標記。適合回答「我的整體投資績效如何」「跑贏大盤了嗎」。

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
daysNo回顧天數,252=1年 / 504=2年 / 1008=4年 / 2520=10年 / 5000=全部;預設 2520
benchmarkNo是否附上基準比較曲線,預設 true
Behavior5/5

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

Annotations already declare readOnlyHint=true, destructiveHint=false, idempotentHint=true, and the description adds valuable behavioral context: it returns a full performance curve, statistical metrics, and benchmark comparisons with trade markers. No contradictions.

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?

Three concise sentences: first lists metrics, second mentions comparisons, third gives use cases. Front-loaded with essential information. No unnecessary words.

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?

Given 2 optional params, no output schema, and annotations covering safety, the description is largely complete. It could be enhanced by noting the time-series nature of the output, but the current detail supports correct invocation.

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 100% with clear parameter descriptions. The description adds meaning by explaining that benchmark includes TWII, S&P500, and 散戶指數, and the default days value. This goes beyond the schema alone.

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 description clearly states it retrieves portfolio performance metrics (total return, CAGR, max drawdown, Sharpe, volatility, win rate) and benchmark comparisons. It includes example questions to illustrate usage, distinguishing it from sibling tools like get_portfolio.

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?

The description provides explicit use-case examples ('適合回答「我的整體投資績效如何」「跑贏大盤了嗎」') that guide when to invoke. However, it does not mention when not to use or directly reference sibling alternatives, which would improve clarity.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/kevinlin49361128-stack/stock-analyzer-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server