Skip to main content
Glama

Custom Solutions

Amortization schedule

compute_amortization
Read-onlyIdempotent

Amortization schedule of a loan: interest, principal and ending balance for each year, and the balance left after a chosen year, which is the payoff figure behind a refinance or a sale. Balances drift when a schedule mixes yearly and monthly compounding or skips interest-only months; this one sums the monthly schedule and holds principal at zero during interest-only months. Send loan_amount, rate_pct and amort_years (1 to 40); optionally io_months and year. The schedule covers the whole term.

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": {
      "loan_amount": "<loan_amount>",
      "rate_pct": "<rate_pct>",
      "amort_years": "<amort_years>"
    },
    "name": "compute_amortization"
  }
}

Input Schema

NameRequiredDescriptionDefault
yearNoYear whose ending balance to report, e.g. 7
rate_pctYesInterest rate in percent per year, e.g. 7.25
io_monthsNoInterest-only months at the start, e.g. 12
amort_yearsYesAmortization in years, 1 to 40, e.g. 30
loan_amountYesLoan amount in dollars, e.g. 300000

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A3.9/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent, non-destructive and closed-world, so the safety profile is covered. The description adds genuine behavioral context beyond that: it discloses the computation method (sums the monthly schedule, holds principal at zero during interest-only months) and warns about a known failure mode (balances drift when yearly and monthly compounding are mixed or interest-only months are skipped). It stops short of describing output shape or rounding, which keeps it at 4 rather than 5.

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

Conciseness4/5

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

Four sentences, front-loaded with what the tool returns before moving to the methodology caveat and then the call signature. Every sentence contributes, though the compounding-drift sentence is dense and could be tightened without losing meaning.

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?

With no output schema, the description carries the return-value burden and does so adequately by listing the per-year fields and the terminal balance, and by noting the schedule covers the whole term. It does not specify units, rounding, or the container format of the returned schedule, which is a minor remaining gap for a tool with five parameters.

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 the schema already documents all five parameters, and the description largely restates them (the 1-to-40 range, interest-only months at the start). The one piece of added meaning is framing `year` as the payoff balance used for a refinance or sale, which is a modest semantic gain over 'Year whose ending balance to report'. Baseline 3 applies when the schema carries the parameter burden.

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 names a specific computation (amortization schedule of a loan) and enumerates exactly what it produces: interest, principal and ending balance per year, plus the balance remaining after a chosen year. The output-level specificity ('the payoff figure behind a refinance or a sale') makes it unmistakable against a sibling like compute_mortgage_payment, which would return a single payment figure rather than a full schedule.

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?

It gives invocation guidance ('Send loan_amount, rate_pct and amort_years (1 to 40); optionally io_months and year') and a use context (refinance or sale payoff), but never states when to prefer this over a sibling such as compute_mortgage_payment or compute_irr, nor any when-not condition. Usage is implied by the described output rather than explicitly routed.

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