Skip to main content
Glama

Compare stocks

compare_stocks

Compare 2-4 stocks side by side, each analysed fresh: conviction, the 5 cluster scores, P/E, revenue growth, DCF upside, Piotroski and days to the next earnings, sorted by conviction. COSTS 1 analysis credit per ticker that is scored (failed ones are free). Use for 'X vs Y'. Example: "AMD vs NVDA" → tickers ["AMD", "NVDA"].

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": {
      "tickers": "<tickers>"
    },
    "name": "compare_stocks"
  }
}

Input Schema

NameRequiredDescriptionDefault
tickersYes

Output Schema

NameRequiredDescriptionDefault
okYesfalse on an error; then `error` says what happened and what to do.
cardNoThe in-chat InvestIQ card, in English and French.
dataNoThe tool's own result fields.
toolYes
as_ofYesISO time the data was computed (a stored analysis: when it was computed).
errorNo
linksNoInvestIQ pages for this result.
degradedNotrue when part of the data was missing.
viz_specNoThe recommended chart's series (data only).
disclaimerYes
data_qualityNoWhat was requested, what was used, and why anything was left out.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.7/5.0
Behavior5/5

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

Beyond the annotations (which only declare it is non-read-only, non-idempotent, non-destructive), it discloses the credit cost model ('1 analysis credit per ticker that is scored'), the failure policy ('failed ones are free'), that analysis is fresh rather than cached, and the output ordering ('sorted by conviction'). These are the exact traits an agent needs to decide whether to spend credits.

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?

Two dense sentences plus an example, with the action and scope front-loaded, cost disclosed mid-sentence, and the invocation example last. No filler and nothing repeated from the schema.

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?

An output schema exists, so return structure need not be explained, yet the description still previews the key metrics and their ordering. Combined with the cost, failure, and cardinality notes, an agent has everything required to call this correctly on the first attempt.

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 0%, so the description must carry the burden, and it does: the 2-4 cardinality is stated in prose, the array-of-tickers shape is shown via the example, and ticker symbols are implied as the item format. It does not spell out ticker syntax constraints (exchange suffixes, case) that the schema leaves open.

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 verb and resource plus scope: 'Compare 2-4 stocks side by side, each analysed fresh', then enumerates the exact outputs (conviction, 5 cluster scores, P/E, revenue growth, DCF upside, Piotroski, days to earnings). That detail separates it from a single-ticker analysis sibling without needing to name one.

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?

It gives an explicit trigger phrase ('Use for "X vs Y"') and a concrete worked example mapping natural language to the tickers argument. It stops short of stating when NOT to use it or naming an alternative for single-stock or screening cases, which is why it is not a 5.

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.

Resources