Skip to main content
Glama

nestegg-calculators

ROI

roi
Read-onlyIdempotent

Return on investment: total percent gain, plus the annualized rate when a holding period in years is given.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
yearsNoOptional. Holding period in years, for the annualized rate.
initialYesAmount invested.
finalValueYesEnding value.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
roiPctNoTotal return, percent.
annualizedPctNoAnnualized return, percent (null if no years).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A3.6/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true and idempotentHint=true, so the safe read-only nature is covered. The description adds the behavioral nuance of conditional annualized rate, but doesn't disclose edge cases, rounding, or output structure, which is acceptable given the output schema exists.

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?

The description is a single, compact sentence that front-loads the tool's purpose and includes the key conditional. Every word earns its place, and there is no redundant padding or repetition of the title.

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?

For a simple calculation tool with three well-documented parameters and an output schema, the description suffices. It explains both the base and optional annualized behavior without needing to detail return values, as the output schema covers that. Slight deduction for not elaborating on what 'annualized rate' means mathematically, but this is minor.

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 description coverage is 100%, and the schema already explains each parameter. The description rephrases the formula relationship (percent gain from initial/finalValue, annualized with years) but doesn't add significant meaning beyond the schema, so the baseline of 3 applies.

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?

The description clearly states the tool computes 'total percent gain' and optionally 'annualized rate', which is specific and action-oriented. It distinguishes the core ROI calculation from related metrics like holding-period-return or percentage-change, though it doesn't explicitly name alternatives.

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?

The description implies usage by noting the annualized rate is provided 'when a holding period in years is given', but it doesn't explicitly state when to use this tool over siblings like CAGR or return-stats. No exclusions or alternative recommendations are offered.

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.