Skip to main content
Glama

MiaoToolbox (妙用盒)

房贷还款试算(妙用盒)

calculate_mortgage
Read-onlyIdempotent

固定名义年利率、整月期末还款模型房贷试算。支持等额本息(annuity)、等额本金(principal)及两者对比(both)。默认仅返回汇总结果,避免占用过多上下文;如需逐月明细可设置 includeSchedule=true 并分页(每次最多 24 期)。

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>",
      "months": "<months>",
      "annualRate": "<annualRate>"
    },
    "name": "calculate_mortgage"
  }
}

Input Schema

NameRequiredDescriptionDefault
modeNo还款方式:both(默认对比)/ annuity(等额本息)/ principal(等额本金)both
monthsYes贷款期限(整月,1 至 600 个月,即最多 50 年)
principalYes贷款本金(人民币元),大于 0 且不超过 100000000,最多 2 位小数
annualRateYes固定名义年利率(百分数,如 3.5 表示 3.5%),范围 0 至 30,最多 6 位小数
scheduleLimitNo明细返回期数上限(1 至 24 期)
scheduleStartNo明细起始期数(从 1 开始)
includeScheduleNo是否附带还款计划明细(默认 false)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already declare it read-only, idempotent, non-destructive and closed-world, so the description focuses on what structured data cannot convey: the fixed-nominal-rate / end-of-period modeling assumptions, the deliberate summary-only default to conserve context, and the 24-period pagination ceiling. It stops short of describing result precision or rounding, which is the only remaining behavioral gap.

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?

Three tight sentences, front-loaded with the model definition, then mode support, then the output/pagination contract. No filler and nothing that merely repeats the tool name.

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 7 parameters, no output schema and existing annotations, the description covers the invocation contract and the return-configuration options well. The one gap is that there is no output schema and the description does not enumerate what the summary result contains (e.g. total payment vs total interest), leaving the agent to discover return fields at call time.

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 the baseline is 3; the description earns above that by explaining the interaction between includeSchedule, scheduleStart and scheduleLimit as a pagination mechanism and by clarifying that the rate is a fixed nominal annual percentage. It adds conceptual meaning rather than restating field text.

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?

States a precise verb+resource (mortgage trial calculation) plus the exact model assumptions — fixed nominal annual rate, whole-month, end-of-period repayment — and enumerates the three supported modes (annuity / principal / both). An agent knows exactly what computation this performs without opening the schema.

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?

Clear context for the key behavioral switch: default returns summary only, and includeSchedule=true plus pagination is required for monthly detail capped at 24 periods per call. No explicit when-not-to-use or comparison to an alternative path is given, which keeps it below 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