Skip to main content
Glama
chrischall
by chrischall

Calculate max affordable home price

redfin_calculate_affordability
Read-onlyIdempotent

Calculate the maximum home price you can afford using the 28/36 DTI rule, then see the binding constraint and full PITI breakdown.

Instructions

Solve for the maximum home price you can afford under the standard 28/36 DTI rule. Inputs: monthly income, recurring monthly debts (car loans, student loans, etc.), down payment, interest rate, and optional property-tax rate / insurance / HOA / loan term. Output: max home price, the binding constraint (front-end vs back-end), and the full PITI breakdown at that price. Same math across the realty MCP cohort (@chrischall/realty-core). No network — pure local math.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
hoa_monthlyNo
back_end_dtiNoBack-end DTI cap as decimal, default 0.36
down_paymentYes
front_end_dtiNoFront-end DTI cap as decimal, default 0.28
interest_rateYesAnnual %, e.g. 6.5
monthly_debtsNoSum of monthly debt payments (car, student loans, etc.)
monthly_incomeYes
loan_term_yearsNoDefault 30, max 50
insurance_annualNo
property_tax_rateNoAnnual % of home price, default 1.1

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed7 schema fields changedv1.1.5
    • addedInput schema / properties / back_end_dti / description
      Added value: +"Back-end DTI cap as decimal, default 0.36"
    • addedInput schema / properties / front_end_dti / description
      Added value: +"Front-end DTI cap as decimal, default 0.28"
    • addedInput schema / properties / interest_rate / description
      Added value: +"Annual %, e.g. 6.5"
    • addedInput schema / properties / loan_term_years / description
      Added value: +"Default 30, max 50"
    • changedInput schema / properties / loan_term_years / maximum
      Previous value: -9007199254740991New value: +50
    • addedInput schema / properties / monthly_debts / description
      Added value: +"Sum of monthly debt payments (car, student loans, etc.)"
    • addedInput schema / properties / property_tax_rate / description
      Added value: +"Annual % of home price, default 1.1"
  2. Changed1 schema field changedv1.0.0
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
  3. First observedv0.10.1

TDQS

A3.8/5.0
Behavior4/5

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

Annotations already cover the safety profile (readOnly, idempotent, openWorld=false), and the description reinforces this with 'No network — pure local math' and, importantly, describes the return structure (max price, binding constraint, PITI breakdown) that has no output schema. Adds real value beyond the annotations.

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?

Front-loads the purpose, then inputs, outputs, and a local-math note; every sentence is informative. The 'Same math across the realty MCP cohort' line is marginal filler but does not derail structure.

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 10-parameter tool with no output schema, the description adequately covers inputs, the deterministic local behavior, and the return shape. It is complete enough to invoke correctly, missing only explicit alternative-selection guidance.

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?

With 60% schema coverage, the description compensates by enumerating the undocumented parameters (down payment, HOA, insurance) and framing the DTI caps via the 28/36 rule. It adds meaning beyond the raw schema without fully documenting every field.

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+resource ('Solve for the maximum home price you can afford') scoped by the 28/36 DTI rule, so the agent immediately knows what computation it performs. However, it never differentiates from the close sibling redfin_calculate_mortgage, leaving the agent to infer the distinction.

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?

Usage is only implied by the input/output enumeration; there is no explicit 'use this when...' guidance nor any mention of when to prefer redfin_calculate_mortgage instead. Adequate context but no routing help.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.