Agent skill

Lending

by JoelLewis in JoelLewis/finance_skills

Analyze lending products including mortgages, HELOCs, and personal loans with amortization and comparison tools.

MITAuto-check passedBusiness, Finance & HR

Install Lending

skills CLI
$ npx skills add JoelLewis/finance_skills --skill lending -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install JoelLewis/finance_skills lending --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/JoelLewis/finance_skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/plugins/wealth-management/skills/lending .claude/skills/lending && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
lending
GitHub stars
206
Token cost
~2.5k tokens
SKILL.md length
1,245 words
Files
2 (incl. scripts)
Skills in repo
91
Repo updated
First seen
Licence
MIT

At a glance

Analyze lending products including mortgages, HELOCs, and personal loans with amortization and comparison tools.

  • Works in 7 steps: 30-year monthly payment: PMT = $400,000… → 30-year total interest: 360 × $2,528 -… → 15-year monthly payment: PMT = $400,000… → …
  • The user asks about mortgage comparison
  • SKILL.md covers Core Concepts, Key Formulas, Worked Examples and Common Pitfalls, plus 2 more sections
  • Runs Python scripts from its folder; calls uv and python3

What it does

Lending is an agent skill from JoelLewis/finance_skills. Analyze lending products including mortgages, HELOCs, and personal loans with amortization and comparison tools. Use when the user asks about mortgage comparison, fixed vs ARM rates, loan qualification, amortization schedules, extra payments, or buying points. Also trigger when users mention 'monthly payment calculation', '15-year vs 30-year mortgage', 'PMI', 'APR vs interest rate', 'HELOC', 'home equity', 'should I buy down the rate', 'biweekly payments', or ask how much house they can afford.

Its SKILL.md is about 2.5k tokens, which your agent loads only when the skill is triggered. The skill folder holds 2 other files, including scripts (for example `scripts/lending.py`).

It sits in Business, Finance & HR, covering Banking and insurance and Real estate. The repository describes itself as: Claude Code skill plugins for financial services — 81 skills across 7 domain plugins covering investment management, compliance, advisory practice, trading, and operations. The licence is MIT.

When your agent uses it

  • The user asks about mortgage comparison
  • Fixed vs ARM rates
  • Loan qualification
  • Amortization schedules

Example prompts

  • “monthly payment calculation”
  • “15-year vs 30-year mortgage”
  • “APR vs interest rate”
  • “/lending”

Requirements

  • Python 3

Workflow steps

7 steps, taken from the first numbered list in SKILL.md.

  1. 30-year monthly payment: PMT = $400,000 × [0.005417 × (1.005417)^360] / [(1.005417)^360 - 1]
  2. 30-year total interest: 360 × $2,528 - $400,000 = $510,178
  3. 15-year monthly payment: PMT = $400,000 × [0.004917 × (1.004917)^180] / [(1.004917)^180 - 1]
  4. 15-year total interest: 180 × $3,354 - $400,000 = $203,694
  5. Payment difference: $3,354 - $2,528 = $826/month more for 15-year.
  6. Interest savings: $510,178 - $203,694 = $306,484 saved by choosing 15-year.
  7. The 15-year costs 33% more per month but saves 60% in total interest.

What it can do on your machine

Read from SKILL.md and the folder at commit 5c498ea. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Ships 1 file in scripts/ (Python), which the agent can run.

    Shell commands in SKILL.md call:

    • uv
    • python3

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use uv, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Lending loads about 2.5k tokens when it runs. Until then it costs about 127 tokens; SKILL.md has 1,245 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~127
When it runs · the whole SKILL.md, loaded when a task matches
~2.5k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); the scripts in this folder are not scanned.

SKILL.md

The full file from JoelLewis/finance_skills at commit 5c498ea, republished under its MIT licence (© JoelLewis). 1,245 words, ~2,548 tokens.

Download SKILL.mdSave it as .claude/skills/lending/SKILL.md (or your agent's skills folder). This skill also uses 1 other file; get the full folder from GitHub.
name
lending
description
Analyze lending products including mortgages, HELOCs, and personal loans with amortization and comparison tools. Use when the user asks about mortgage comparison, fixed vs ARM rates, loan qualification, amortization schedules, extra payments, or buying points. Also trigger when users mention 'monthly payment calculation', '15-year vs 30-year mortgage', 'PMI', 'APR vs interest rate', 'HELOC', 'home equity', 'should I buy down the rate', 'biweekly payments', or ask how much house they can afford.

Lending Analysis

Core Concepts

Fixed-Rate Mortgage

The interest rate and monthly payment remain constant for the life of the loan:

  • Advantages: Predictable payments, protection against rising rates, simpler budgeting
  • Disadvantages: Higher initial rate than ARM, no benefit if rates decline (must refinance)
  • Most common terms: 30-year and 15-year fixed
Adjustable-Rate Mortgage (ARM)

Rate is fixed for an initial period, then adjusts periodically based on an index plus a margin:

  • Notation: 5/1 ARM = fixed for 5 years, adjusts annually thereafter; 7/1, 10/1 similarly
  • Fully indexed rate: Index (e.g., SOFR, 1-year Treasury) + margin (e.g., 2.75%)
  • Rate caps protect against extreme adjustments:
    • Initial adjustment cap (e.g., 2%): maximum first adjustment
    • Periodic cap (e.g., 2%): maximum change per adjustment period
    • Lifetime cap (e.g., 5%): maximum total increase over initial rate
  • When ARM may be appropriate: Planning to sell or refinance before the fixed period ends, expecting rates to decline, or comfortable with rate variability
Monthly Payment Calculation

The standard amortization formula for a fixed-rate loan:

  • PMT = P × [r(1+r)^n] / [(1+r)^n - 1]
  • Where: P = principal (loan amount), r = monthly interest rate (annual rate / 12), n = total number of payments (term in months)
  • Each payment splits into interest (decreasing) and principal (increasing) components:
    • Interest portion: remaining balance × monthly rate
    • Principal portion: PMT - interest portion
Total Interest Paid
  • Total interest = (n × PMT) - P
  • For a $400K, 30-year loan at 6.5%: PMT = $2,528, total payments = $910,178, total interest = $510,178
Extra Payments

Additional principal payments reduce the outstanding balance, shorten the loan term, and reduce total interest:

  • Each extra dollar goes entirely to principal reduction
  • Impact compounds: earlier extra payments save more interest than later ones
  • Methods: lump sum, fixed monthly extra, biweekly payments (26 half-payments = 13 full payments per year)
Mortgage Points

Prepaid interest that reduces the loan's interest rate:

  • 1 point = 1% of the loan amount (e.g., 1 point on $400K = $4,000)
  • Typically reduces the rate by approximately 0.25% (varies by lender and market)
  • Breakeven calculation: Points cost / monthly savings = months to recoup
  • Points make sense when: planning to hold the loan beyond breakeven, itemizing deductions (points may be tax-deductible in year of purchase)
APR vs Interest Rate
  • Interest rate: The cost of borrowing the principal, expressed annually
  • APR (Annual Percentage Rate): Includes the interest rate plus certain fees and costs (origination fees, points, PMI), annualized over the loan term
  • APR > interest rate (always, when there are fees)
  • APR is the better metric for comparing loan offers with different fee structures
HELOC (Home Equity Line of Credit)

A revolving credit line secured by home equity:

  • Combined LTV (CLTV): (First mortgage balance + HELOC limit) / home value
    • Most lenders require CLTV ≤ 80-90%
  • Draw period (typically 10 years): borrow and repay flexibly, often interest-only payments
  • Repayment period (typically 20 years): no new draws, fully amortizing payments
  • Variable rate: Typically prime rate + margin; rate fluctuates with market
  • Use cases: Home improvements, debt consolidation, emergency backup (but not as primary emergency fund)
  • Risk: Home is collateral — default means foreclosure
Loan Qualification Criteria
  • FICO score: 620+ for conventional, 580+ for FHA, 700+ for best rates
  • DTI: Front-end ≤ 28%, back-end ≤ 36-43% (varies by program)
  • LTV (Loan-to-Value): Loan amount / property value; lower LTV = lower risk = better terms
  • Reserves: Months of payments held in liquid assets after closing (2-6 months typical)
  • Employment/income: Stable income history, typically 2 years documentation
PMI (Private Mortgage Insurance)

Required when conventional loan LTV exceeds 80%:

  • Cost: 0.5-1.5% of loan amount annually, added to monthly payment
  • Removal: Automatic at 78% LTV (based on original amortization), requestable at 80% LTV
  • Avoidance strategies: 20% down payment, piggyback loan (80/10/10), lender-paid PMI (higher rate), VA loan (no PMI)
  • PMI benefits the lender, not the borrower — it is pure cost to the borrower
15-Year vs 30-Year Comparison
  • 15-year: Higher monthly payment, lower interest rate (typically 0.5-0.75% less), dramatically less total interest, builds equity faster
  • 30-year: Lower required payment, more flexibility, higher total interest cost
  • Hybrid approach: Take a 30-year for flexibility, make extra payments as if it were a 15-year

Key Formulas

FormulaExpressionUse Case
Monthly paymentPMT = P × [r(1+r)^n] / [(1+r)^n - 1]Fixed-rate loan payment
Total interestn × PMT - PTotal cost of borrowing
Remaining balance after k paymentsB_k = P × [(1+r)^n - (1+r)^k] / [(1+r)^n - 1]Balance at any point
Points breakevenCost of points / monthly savingsMonths to recoup points
LTVLoan amount / property valueRisk and PMI assessment
CLTV(First mortgage + HELOC) / home valueCombined leverage
ARM fully indexed rateIndex + marginRate after fixed period

Worked Examples

Show full SKILL.md (512 more words)Show less
Example 1: 30-year vs 15-year mortgage comparison

Given: Home price $500K, down payment $100K, loan amount $400K. 30-year rate: 6.5%. 15-year rate: 5.9%. Calculate: Monthly payments, total interest, and interest savings. Solution:

  1. 30-year monthly payment: PMT = $400,000 × [0.005417 × (1.005417)^360] / [(1.005417)^360 - 1]
    • r = 6.5%/12 = 0.005417, n = 360
    • PMT = $2,528/month
  2. 30-year total interest: 360 × $2,528 - $400,000 = $510,178
  3. 15-year monthly payment: PMT = $400,000 × [0.004917 × (1.004917)^180] / [(1.004917)^180 - 1]
    • r = 5.9%/12 = 0.004917, n = 180
    • PMT = $3,354/month
  4. 15-year total interest: 180 × $3,354 - $400,000 = $203,694
  5. Payment difference: $3,354 - $2,528 = $826/month more for 15-year.
  6. Interest savings: $510,178 - $203,694 = $306,484 saved by choosing 15-year.
  7. The 15-year costs 33% more per month but saves 60% in total interest.
Example 2: Extra payment impact

Given: $300K 30-year mortgage at 6.5% (payment = $1,896.20/month). Borrower adds $200/month extra to principal, making the total payment $2,096.20/month. Calculate: Time saved and interest saved. Solution:

  1. Without extra payments: 360 months, total interest = 360 × $1,896.20 - $300,000 = $382,633.
  2. New term (closed-form estimate): n = -ln(1 - P × r / PMT_total) / ln(1+r) with r = 0.065/12 = 0.005417:
    • n = -ln(1 - $300,000 × 0.005417 / $2,096.20) / ln(1.005417) ≈ 276.3 payments.
  3. Exact amortization (month-by-month simulation, final payment partial): payoff in 277 months = 23 years 1 month (~23.1 years), total interest = $279,185. The closed form and the exact schedule agree closely.
  4. Interest saved: $382,633 - $279,185 = $103,449.
  5. Time saved: 360 - 277 = 83 months ≈ 6.9 years.
  6. Total extra principal paid ≈ 276 × $200 = $55,200. Interest saved per dollar of extra payment: $103,449 / $55,200 ≈ $1.87.

Common Pitfalls

  • Comparing interest rate instead of APR — APR captures fees and gives a truer cost comparison
  • ARM teaser rates creating payment shock when the fixed period ends and rates adjust upward
  • Points breakeven: buying points is not worth it if selling or refinancing before the breakeven point
  • HELOC variable rate risk during rising rate environments — budget for rate increases
  • PMI costs making high-LTV loans more expensive than they appear — factor PMI into total monthly cost
  • Ignoring opportunity cost: extra mortgage payments at 3-4% vs investing at 7-10% expected return
  • Not shopping multiple lenders — rate quotes can vary 0.5%+ for the same borrower
  • Resetting to a 30-year term when refinancing — extends total payoff even if rate is lower
  • Ignoring closing costs in refinancing decisions (see debt-management refinance breakeven)

Cross-References

  • debt-management (wealth-management plugin): refinancing analysis, debt payoff vs investing decisions, DTI calculations
  • emergency-fund (wealth-management plugin): adequate reserves required for loan qualification and financial safety
  • tax-efficiency (wealth-management plugin): mortgage interest deductibility, points deduction
  • savings-goals (wealth-management plugin): down payment saving is a common goal-based savings target
  • liquidity-management (wealth-management plugin): mortgage payments are the largest fixed obligation in most household cash flow plans

Running the script

Run the reference implementation directly:

uv run scripts/lending.py          # PEP 723 header resolves dependencies automatically
python3 scripts/lending.py         # after: pip install numpy scipy

A bare run prints a demo covering payment calculation, extra-payment impact, LTV/PMI, DSCR, balloon payments, refinance analysis, points breakeven, and ARM resets. Use --verify to recompute the demo figures and assert they match this skill's worked examples (prints PASS/FAIL, exits nonzero on mismatch), and --help to list the available classes and functions. The file is primarily meant to be imported as a module (from lending import LendingAnalysis) rather than run standalone.

© JoelLewis, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 1 other file (scripts) in plugins/wealth-management/skills/lending of JoelLewis/finance_skills.

  • SKILL.md
  • scripts/lending.py

Open the folder on GitHubat commit 5c498ea

Compare with similar skills

Lending next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Lending compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Lending this skillJoelLewis/finance_skills206—~2.5kAutomated safety check: PassMIT
Master Builderibuilder/massing122—~2.6kAutomated safety check: PassMIT
Cre Industrialahacker-1/cre-agent-skills113—~1.2kAutomated safety check: PassApache-2.0
Cre Legalahacker-1/cre-agent-skills113—~1.3kAutomated safety check: PassApache-2.0
Cre Officeahacker-1/cre-agent-skills113—~1.3kAutomated safety check: PassApache-2.0
Mortgage Compliancedavepoon/buildwithclaude3.6k—~448Automated safety check: PassMIT

Similar skills

  • Master Builder

    ibuilder/massing

    Reason like a master builder — one mind holding an entire built-asset project from raw land through design, construction, handover, operations, and disposition, anywhere in the world.

    122 GitHub stars~2.6k tokensUpdated yesterday
    Business, Finance & HRAuto-check passed
  • Cre Industrial

    ahacker-1/cre-agent-skills

    CRE Industrial analysis suite - 8 specialist skills for U.S.

    113 GitHub stars~1.2k tokensUpdated 1 mo ago
    Business, Finance & HRAuto-check passed
  • Cre Legal

    ahacker-1/cre-agent-skills

    CRE Legal review suite — 6 specialist skills for PSA review, title & survey analysis, estoppel tracking, loan document review, insurance coordination, and transfer document preparation for…

    113 GitHub stars~1.3k tokensUpdated 1 mo ago
    Business, Finance & HRAuto-check passed
  • Cre Office

    ahacker-1/cre-agent-skills

    CRE Office analysis suite - 8 specialist skills for U.S. An agent skill from ahacker-1/cre-agent-skills.

    113 GitHub stars~1.3k tokensUpdated 1 mo ago
    Business, Finance & HRAuto-check passed
  • Mortgage Compliance

    davepoon/buildwithclaude

    Enforces mortgage regulatory compliance — TRID, RESPA, TILA, ECOA/Fair Lending, state licensing, required disclosures, and data privacy rules for all borrower interactions.

    3.6k GitHub stars~448 tokensUpdated yesterday
    Business, Finance & HRAuto-check passed
  • Cap Rate Calculator

    revfactory/harness-100

    Real estate yield calculator. An agent skill from revfactory/harness-100.

    1.3k GitHub stars~1k tokensUpdated 6 mo ago
    Business, Finance & HRAuto-check passed

More from JoelLewis/finance_skills

All 91 skills in this repo
  • Asset Allocation

    JoelLewis/finance_skills

    Determine how to distribute capital across asset classes using strategic and tactical allocation frameworks.

    206 GitHub stars~2.5k tokensUpdated 2 mo ago
    Auto-check passed
  • Bet Sizing

    JoelLewis/finance_skills

    Determine how much capital to allocate to individual positions within a portfolio.

    206 GitHub stars~2.5k tokensUpdated 2 mo ago
    Auto-check passed
  • Commodities

    JoelLewis/finance_skills

    Analyze commodity markets including futures curve dynamics, roll yield, and supply/demand fundamentals.

    206 GitHub stars~1.9k tokensUpdated 2 mo ago
    Auto-check passed
  • Currencies And Fx

    JoelLewis/finance_skills

    Analyze currency markets, exchange rate mechanics, and FX risk management for international portfolios.

    206 GitHub stars~1.9k tokensUpdated 2 mo ago
    Auto-check passed
  • Debt Management

    JoelLewis/finance_skills

    Provide frameworks for managing and paying off personal debt effectively.

    206 GitHub stars~2.5k tokensUpdated 2 mo ago
    Auto-check passed
  • Diversification

    JoelLewis/finance_skills

    Build diversified portfolios using correlation analysis, efficient frontier construction, and factor-based diversification.

    206 GitHub stars~2.3k tokensUpdated 2 mo ago
    Auto-check passed

Questions about Lending

What does Lending do?

Analyze lending products including mortgages, HELOCs, and personal loans with amortization and comparison tools. Lending is an agent skill from JoelLewis/finance_skills. Analyze lending products including mortgages, HELOCs, and personal loans with amortization and comparison tools.

When should I use Lending?

Lending fits situations like: the user asks about mortgage comparison; fixed vs ARM rates; loan qualification; amortization schedules.

How do I install Lending in Claude Code?

Run `npx skills add JoelLewis/finance_skills --skill lending -a claude-code`. Or copy the skill folder (plugins/wealth-management/skills/lending in JoelLewis/finance_skills) into .claude/skills/lending in your project. Claude Code loads it when a task matches its description.

How do I install Lending in Codex?

Run `npx skills add JoelLewis/finance_skills --skill lending -a codex`. Or copy the skill folder (plugins/wealth-management/skills/lending in JoelLewis/finance_skills) into .agents/skills/lending in your project. Codex loads it when a task matches its description.

Can I use Lending in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add JoelLewis/finance_skills --skill lending -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/lending, .gemini/skills/lending, .github/skills/lending and .opencode/skills/lending in your project.

What does Lending need to run?

Going by SKILL.md and its folder, Lending needs Python for the scripts in its folder and the command-line tools its instructions call (uv and python3). Our summary lists: Python 3.

Does Lending access the network?

SKILL.md contains no URLs. Its commands use uv, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is Lending safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.

What licence does Lending use?

Lending is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Lending use?

About 2.5k tokens (SKILL.md is roughly 10k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Lending?

Skills that share tags, products or a category with Lending: Master Builder (ibuilder/massing, 122 stars), Cre Industrial (ahacker-1/cre-agent-skills, 113 stars), Cre Legal (ahacker-1/cre-agent-skills, 113 stars) and Cre Office (ahacker-1/cre-agent-skills, 113 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Lending?

JoelLewis (a GitHub user) maintains it in JoelLewis/finance_skills, which has 206 GitHub stars. The repository holds 91 skills in this directory. The repository was last updated on July 18, 2026.

Source: JoelLewis/finance_skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.