Skip to main content
Glama

MaCalculatriceEnLigne

Calculate Compound Interest

calculate_compound_interest
Read-onlyIdempotent

Compute compound interest growth A=P(1+r/n)^(nt). Use for savings, retirement projections, investment forecasting. Returns final amount, total interest, and yearly breakdown.

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": {
      "principal": "<principal>",
      "annual_rate": "<annual_rate>",
      "years": "<years>"
    },
    "name": "calculate_compound_interest"
  }
}

Input Schema

NameRequiredDescriptionDefault
yearsYesInvestment duration in years
principalYesInitial amount
annual_rateYesAnnual interest rate in %
compounds_per_yearNoCompounding frequency per year

Output Schema

NameRequiredDescriptionDefault
resultNoComputed result (fields depend on the tool).
sourceNoLegal or official source.
formulaNoMethod used.
reference_urlNomacalculatriceenligne.com page to share.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changed
    • changedOutput schema / properties / formula / description
      Previous value: -"Human-readable formula or method used (e.g. \"I=P·r·t\", \"Magnus formula\")."New value: +"Method used."
    • changedOutput schema / properties / reference_url / description
      Previous value: -"Link to a calcul2 page documenting the calculation in detail."New value: +"macalculatriceenligne.com page to share."
    • changedOutput schema / properties / result / description
      Previous value: -"Computed result. Object whose fields depend on the tool (e.g. {tax, marginal_rate, brackets} for tax tools, {volume_l, gallons} for volume tools)."New value: +"Computed result (fields depend on the tool)."
    • changedOutput schema / properties / source / description
      Previous value: -"Authoritative source for the rule or formula (e.g. \"Article 197 CGI\", \"NF DTU 21\")."New value: +"Legal or official source."
  2. First observed

TDQS

A4.3/5.0
Behavior3/5

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

Annotations already declare this a safe, read-only, idempotent, closed-world calculation, so the safety profile is fully covered. The description adds only the return composition (final amount, total interest, yearly breakdown), which is also captured by the output schema, and says nothing about rounding, currency handling, or how the breakdown is structured.

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: purpose and formula first, then use cases, then return shape. No filler, no restatement of the title, and every clause carries information an agent can act on.

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?

All four parameters are schema-documented, required fields are marked, output shape exists and is summarized in the description, and annotations cover side-effect behavior. For a pure deterministic calculation tool, nothing an agent needs in order to call it correctly is missing.

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%, so each parameter is already documented, making 3 the baseline. The formula adds genuine meaning by mapping variables to parameters (P=principal, r=annual_rate, n=compounds_per_year, t=years), which clarifies how the four inputs combine beyond their individual field descriptions.

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?

"Compute compound interest growth" names a specific verb and a precise domain resource, and the inline formula A=P(1+r/n)^(nt) pins down exactly which computation is performed. No sibling in the calculator family covers compound growth, so an agent can route to this tool unambiguously.

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?

"Use for savings, retirement projections, investment forecasting" gives concrete positive contexts that clarify the intended domain. It stops short of exclusions, e.g. when to prefer calculate_loan_payment or a simple-interest variant, so the agent must still infer the boundary cases.

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.