Closing Costs

Closing Costs

Calculates itemized state-specific closing costs for mortgage refinance transactions across 10 licensed states, with product-specific fees for Convent

Category: productivity Source: davepoon/buildwithclaude

What Is Closing Costs?

The "Closing Costs" skill is a specialized tool designed for mortgage professionals and financial technology platforms to accurately estimate itemized closing costs for mortgage refinance transactions. Built for integration with Claude Code, this skill provides state-specific and product-specific calculations, ensuring precise cost breakdowns and compliance with regulatory requirements. Covering ten licensed states, "Closing Costs" accommodates a variety of loan products including Conventional, FHA, FHA Streamline, VA IRRRL, and VA Cash-Out. The skill determines lender fees, third-party charges, title/settlement costs, and applicable taxes, presenting an itemized output that can be leveraged for borrower disclosures, internal analysis, and automated workflows.

Why Use Closing Costs?

Calculating closing costs for mortgage refinance transactions is a complex process involving numerous variables such as state-specific taxes, title insurance rates, and loan program fees. Manual calculations risk inaccuracies, compliance violations, and inconsistent borrower experiences. The "Closing Costs" skill streamlines this process with the following advantages:

  • Accuracy: Applies up-to-date fee structures for lender, third-party, and title fees, reducing errors in cost estimation.
  • State-Specific Compliance: Integrates local tax formulas and title insurance rates, ensuring all state regulations are met.
  • Product-Specific Logic: Handles unique rules for FHA UFMIP refunds and VA funding fees, including disability exemptions.
  • Efficiency: Automates calculations that would otherwise require extensive manual effort or custom scripting.
  • Transparency: Outputs full itemizations for clear communication with borrowers and compliance audit trails.

This automation is crucial for lenders, brokers, and technology providers seeking to enhance productivity, reduce risk, and deliver transparent, compliant refinance quotes.

How to Get Started

To use the "Closing Costs" skill, you should have a Claude Code environment set up with skill integration enabled. The skill is available as an open-source module and can be found on GitHub.

Installation Example:

git clone https://github.com/davepoon/buildwithclaude.git
cd buildwithclaude/plugins/mortgage/skills/closing-costs

Basic Usage Example:

Assume you are working within a Python environment that supports skill invocation:

from closing_costs import estimate_closing_costs

## Example refinance scenario
params = {
    "state": "FL",
    "loan_amount": 300000,
    "product": "FHA Streamline",
    "veteran_status": False,
    "fha_ufmip_refund": 1200,
    "va_disability_exempt": False
}

cost_breakdown = estimate_closing_costs(**params)

print(cost_breakdown)

The function returns a detailed dictionary with line items for lender fees, third-party charges, title and settlement costs, and taxes, all adapted to the state and loan product selected.

Key Features

1. Sectioned Fee Calculation

The skill segments closing costs by standardized mortgage disclosure sections:

  • Section A: Lender origination and underwriting fees
  • Section B: Third-party services (e.g., appraisal, credit report)
  • Section C: Title insurance, settlement/escrow fees
  • Section E: State/local taxes and recording fees

2. State-Specific Title Insurance Rates

Each of the ten supported states—Georgia, Alabama, Florida, Kentucky, North Carolina, South Carolina, Tennessee, Texas, Virginia, and West Virginia—has unique title insurance formulas. The skill programmatically applies these rates for each refinance scenario.

3. Product-Specific Handling

  • FHA Streamline: Calculates upfront mortgage insurance premium (UFMIP) refunds and nets them against new UFMIP requirements.
  • VA IRRRL and Cash-Out: Computes VA funding fees, including automated checks for disability exemption status.

4. Compliance and Disclosure

Outputs are formatted to meet compliance documentation standards, making it easier to integrate into loan estimate disclosures and maintain regulatory adherence.

5. Itemized Output

All cost components are broken down by category and line item, with supporting calculations visible for auditability.

Best Practices

  • Always Provide Accurate Input: Ensure that input parameters such as loan amount, state, and product type are up-to-date and accurate to avoid miscalculations.
  • Integrate with Workflow Automation: Use the skill within automated quoting or loan origination workflows to maximize efficiency and reduce manual errors.
  • Update Regulatory Data Regularly: While the skill comes with built-in state fee logic, periodically verify that tax rates and title insurance formulas are current, especially when states update their regulations.
  • Utilize Itemized Outputs for Disclosures: Present the skill’s itemized results directly to borrowers for transparency and to streamline compliance audits.
  • Test Across Scenarios: Run the module with various states and loan products to ensure edge cases (such as VA disability exemptions or FHA refund netting) are handled as expected.

Important Notes

  • Supported States: The skill currently supports closing cost calculations for Georgia, Alabama, Florida, Kentucky, North Carolina, South Carolina, Tennessee, Texas, Virginia, and West Virginia. Attempting to use other states will result in incomplete or missing fee calculations.
  • Limitations: While comprehensive, the skill may not capture lender-specific overlays or discounts unless explicitly coded. Always verify calculations for unusual fees or waivers.
  • Compliance Responsibility: This tool aids in compliance but does not replace legal or compliance review. Users are responsible for ensuring all regulatory requirements are met in their jurisdiction.
  • Customization: The skill can be extended for additional states or proprietary fee schedules by modifying its configuration files or logic modules as needed.
  • Open Source License: Review the repository’s licensing terms before incorporating the skill into commercial products.

By leveraging the "Closing Costs" skill, mortgage professionals can automate complex calculations, ensure compliance, and enhance the refinance experience for both staff and borrowers.