Skip to main content
Glama
lodetomasi

Portfolio Copilot

by lodetomasi

propose_replacement

Decide if a current stock should be replaced by a candidate or cash, scoring each against portfolio exposure and fees. Returns HOLD, REPLACE, or SELL_TO_CASH with fee-aware orders.

Instructions

Is current_symbol still worth its slot, versus one of candidate_tickers or plain cash? Utility blends each symbol's analyze_stock score/confidence with its fit against holdings' hidden exposure (portfolio.exposure) and, when a thesis was saved for it, its last check_thesis status. Returns HOLD/REPLACE/SELL_TO_CASH with fee-aware order(s) -- a good company is not automatically a good addition (CLAUDE.md), and the round-trip fee must be worth paying before rotating.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
holdingsNoParsed portfolio holdings (parse_portfolio_export's 'holdings' list) used to score each candidate's fit against existing hidden exposure. Omit to treat every candidate as fully diversifying (fit=1.0).
cash_utilityNo
fixed_fee_eurNo
max_fee_ratioNo
current_symbolYes
min_improvementNo
variable_fee_pctNo
candidate_tickersYes
current_value_eurYes
max_roundtrip_fee_ratioNo
Behavior4/5

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

With no annotations, the description carries the full burden, and it does substantial work: it discloses the inputs blended (analyze_stock score/confidence, holdings exposure, saved thesis status), the decision taxonomy, and the fee-aware rotation constraint. It does not explicitly state whether orders are executed or only proposed, but 'Returns ... order(s)' and the tool name imply a proposal.

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 sentences, front-loaded with the core question, followed by the decision output and a policy caveat. Every sentence carries useful content and there is no filler or redundant restatement of the tool name.

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?

Given 10 parameters, no annotations, and no output schema, the description covers the core selection logic and return categories but leaves gaps around side effects, exact semantics of numeric parameters, and when to prefer this over related planning/order tools. It is adequate for invoking with defaults, but not fully complete for this complexity.

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 description adds meaning for current_symbol, candidate_tickers, holdings, and fee-aware reasoning, which partially compensates for the very low schema coverage. However, it does not explain cash_utility, min_improvement, max_fee_ratio, max_roundtrip_fee_ratio, current_value_eur, or the fee parameters individually, leaving several optional parameters underspecified for an agent.

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 opens with a specific decision question — whether current_symbol still deserves its slot versus candidates or cash — and closes with the concrete outputs HOLD/REPLACE/SELL_TO_CASH plus fee-aware orders. This clearly distinguishes it from broader portfolio tools like rebalance_portfolio or generate_order_plan.

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 context is clear: use this when evaluating a single current holding against candidate tickers or cash, with utility based on analyze_stock scores, hidden exposure, thesis status, and fees. It does not explicitly name sibling tools or provide when-not-to-use guidance, but the use case is not ambiguous.

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/lodetomasi/portfolio-copilot'

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