Skip to main content
Glama

ROI Calculator

finance_roi_calculator

Calculate return on investment: profit (or loss) and the percentage return relative to the initial amount invested. Use this when an agent needs to return on investment as a percentage. x402 price $0.01/call (USDC, eip155:8453).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
finalYesFinal value
initialYesAmount invested

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

B3.4/5.0
Behavior3/5

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

No annotations are provided, so the description carries the full behavioral burden. It does add genuinely useful non-schema context — the x402 payment requirement of $0.01/call in USDC on eip155:8453 — but says nothing about error behavior, precision/rounding of the percentage, or edge cases like a zero initial value.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The first sentence is efficient and front-loaded, and the pricing disclosure is a valuable final sentence. However, the middle sentence is malformed and redundant with the opening, so not every sentence earns its place.

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 two-number calculator with no output schema, the description covers what is computed (both profit/loss and percentage) and adds the unusual payment prerequisite. It is largely sufficient, though rounding/precision conventions and failure modes remain unstated.

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%, so both parameters ('initial' and 'final') are already documented. The description's phrase 'relative to the initial amount invested' reinforces the role of 'initial' but adds no format, unit, or constraint detail beyond the schema. Baseline 3 applies when the schema does the heavy lifting.

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 ('Calculate return on investment') and specifies the two outputs (profit/loss and percentage return relative to the initial amount). It is distinguishable from nearby siblings like finance_cagr_calculator and finance_margin_calculator, though it never names them explicitly.

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?

'Use this when an agent needs to return on investment as a percentage' gives a trigger condition but is grammatically broken and largely restates the purpose. It offers no exclusion or contrast against finance_cagr_calculator or finance_margin_calculator, which an agent could easily confuse with ROI.

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