Claude AI for XVA and CVA Trading Desks: Counterparty Credit Risk and Valuation Adjustments (2026)
How CVA desk analysts and derivatives traders use Claude AI for XVA calculations, counterparty credit risk modeling, SIMM margin estimation, SA-CCR exposure calculations, and Basel IV XVA capital analysis.
Claude for XVA and Counterparty Credit Risk
XVA — the family of valuation adjustments applied to derivatives portfolios — sits at the intersection of credit risk, funding, regulation, and pricing. CVA desks spend most of their time on three problems: calculating the adjustments accurately (CVA, DVA, FVA, MVA, KVA), explaining them to front office traders and risk managers who are skeptical of the charges, and navigating the regulatory requirements that keep changing around them. Basel IV finalized the CVA capital framework; FRTB changed how MVA is calculated; SA-CCR replaced CEM for EAD in most jurisdictions. Keeping up with all of it while also running daily hedge books is operationally intense.
Claude helps with the analytical layer — XVA component calculations, counterparty exposure modeling, SIMM estimation, regulatory capital analysis — so analysts can spend more time on the positions that need active management. The Compliance & Risk and Quantitative Finance templates cover the full XVA stack.
CVA and DVA Calculation
Credit Valuation Adjustment (CVA) is the market value of counterparty default risk — the amount you'd charge upfront (or adjust the mark-to-market) to account for the possibility the counterparty doesn't pay. DVA is the mirror: the value of your own default risk from the counterparty's perspective. The calculation requires expected exposure profile, default probability (from CDS spreads or ratings), and loss given default. For a bilateral netting set, you're modeling both legs simultaneously.
- "CVA calculation for an interest rate swap book: Counterparty is a BBB-rated corporate (CDS spread 85bps, LGD 60%). Netting set: 3 pay-fixed swaps with 5, 7, and 10 year tenors. Current MTM: +$4.2M, +$1.8M, -$0.9M (net +$5.1M exposure to us). Current notional: $50M, $30M, $25M. Using simplified unilateral CVA: CVA ≈ LGD × (1 - R) × sum of (EE × PD_marginal) over quarterly intervals. Assume exposure amortizes linearly to zero at maturity. Calculate: (1) expected exposure profile for the netting set at quarterly intervals, (2) marginal default probabilities from the 85bp flat CDS spread, (3) unilateral CVA in dollars, (4) CVA as a basis point spread on the 10-year notional, (5) how does CVA change if CDS spreads widen to 150bps?"
- "Wrong-way risk analysis: I have a $25M equity swap where we receive the return on a single stock — a large financial sector company — and pay LIBOR+150. The counterparty is another financial institution with CDS 95bps. Wrong-way risk exists because: if financial sector stress occurs, the stock likely declines AND the counterparty's credit deteriorates simultaneously. How should I adjust the standard CVA calculation to account for wrong-way risk? What stress scenarios should I model? How does wrong-way risk typically affect CVA magnitude in a financial-sector correlated name?"
- "FVA calculation for uncollateralized trades: We have $180M notional of FX forwards with an uncollateralized corporate counterparty. The trades are out of the money to us currently (we owe MTM of $3.2M). Our internal funding cost is SOFR+45bps. As the trades are uncollateralized, we must fund the potential future exposure ourselves at our funding cost. Explain: (1) what FVA measures and how it differs from CVA, (2) calculate FVA for a $180M uncollateralized FX forward portfolio assuming average tenor 18 months, average positive exposure $4.5M, funding cost SOFR+45bps, (3) what is the FVA as a spread on the portfolio, (4) should this FVA be charged to the front office when pricing new uncollateralized trades?"
SA-CCR and Exposure Calculations
SA-CCR (Standardized Approach for Counterparty Credit Risk) replaced the old Current Exposure Method in Basel III final rules and is now the standard for computing EAD (exposure at default) for derivatives in most jurisdictions. It's considerably more complex than CEM — it requires computing replacement cost, potential future exposure using supervisory factors and delta-adjusted notionals, and aggregating across netting sets with proper netting and hedging set recognition. For a mixed derivatives book, working through the SA-CCR calculation manually is error-prone.
- "SA-CCR calculation for a simple interest rate derivatives netting set: Single netting agreement with one counterparty. Trades: (1) pay-fixed 5Y IRS, $50M notional, 10-year maturity, ATM (delta≈0.5), (2) receive-fixed 7Y IRS, $30M notional, ATM, (3) long 3M SOFR cap, $25M notional, 1Y maturity, delta 0.3. No collateral (zero threshold CSA). SA-CCR components: Replacement Cost = max(V-C, 0) where V = net MTM. Assume net MTM = +$2.1M. PFE Add-on = multiplier × AddOn_aggregate. Walk through the full SA-CCR calculation: (1) replacement cost, (2) adjusted notionals for each trade, (3) maturity factor, (4) supervisory delta for each trade, (5) effective notional for each hedging set, (6) PFE add-on for IR asset class, (7) total EAD."
- "SIMM (ISDA Standard Initial Margin Model) estimation: I need to estimate initial margin under SIMM for a bilateral netting set not subject to mandatory clearing. Portfolio: 5 USD IRS trades and 2 EUR/USD cross-currency swaps. Net DV01: -$45,000 (duration-equivalent position). Cross-gamma between IRS and XCCY: correlated. Under SIMM: IM is calculated as risk-weighted sensitivities aggregated with prescribed correlations. Walk me through: (1) what sensitivities SIMM requires (delta, vega, curvature), (2) the risk weight for 10Y USD IR bucket, (3) how to aggregate across tenor buckets using SIMM correlation matrix, (4) what the estimated IM would be for a $45,000 DV01 IR position, (5) how the IM compares to CCP margin on equivalent cleared positions."
Basel IV CVA Capital Requirements
Basel IV (finalized 2023, implementing across jurisdictions through 2025-2028) substantially revised how banks hold capital against CVA risk. The new framework has three approaches: the Basic CVA (BA-CVA) approach for banks that can't model CVA risk internally, the Standardized CVA (SA-CVA) approach for banks with CVA hedging desks, and exemptions for certain counterparty types (corporates below certain thresholds, pension funds). Getting the right approach for your institution — and calculating the capital requirement correctly — has significant P&L implications through return on capital.
- "Basel IV CVA capital comparison: Our institution has $2.8B notional of OTC derivatives exposure (EAD $180M under SA-CCR). Counterparty breakdown: 40% financial institutions, 35% large corporates (no CVA exemption), 15% investment grade corporates eligible for CVA exemption, 10% SSA exempted. We run a CVA hedge book with single-name CDS hedges. Compare our capital requirement under: (1) BA-CVA approach — calculate reduced BA-CVA (for eligible hedges) using the SCVA formula, (2) SA-CVA approach — what additional requirements must we meet to qualify, (3) what is the approximate capital saving from SA-CVA vs. BA-CVA for a desk with active CDS hedging? Assume risk weight for BBB counterparties = 1.0%, aggregation at 50% correlation."
- "KVA (Capital Valuation Adjustment) analysis: Our desk runs an OTC derivatives book with $400M EAD. Under SA-CCR with Basel IV CVA capital: regulatory capital requirement $32M (8% of RWA where RWA = CVA capital charge + CCR RWA). Our cost of capital (return on equity target) is 14%. KVA represents the present value of the future capital costs locked up in the trade over its life. For a new 5-year IRS adding $5M EAD: (1) what is the incremental regulatory capital for this trade, (2) what is the KVA charge as a present value using 14% CoC, (3) how does KVA affect the pricing of this trade — what spread must the front office add to recover KVA over the 5-year life, (4) how does this compare to the CVA charge on the same trade for a BBB counterparty with 75bps CDS?"
XVA Desk P&L Attribution
XVA desks run a P&L that moves daily from market factors (credit spreads, rates, FX) even without any new trades. Explaining that P&L — what drove the day's CVA change, whether it's hedge performance or market movement, whether the book is adequately hedged — is what the daily P&L attribution report needs to answer. Claude structures the attribution and produces the narrative for risk management and senior management review.
- "CVA daily P&L attribution: Yesterday's CVA book moved by -$1.2M (loss). Decompose this change into: (1) credit spread delta — IG CDS index tightened 3bps, HY widened 8bps. Our counterparty book is 60% IG, 40% HY by MTM exposure. (2) rates delta — swap rates moved +12bps across the curve, affecting exposure profiles on pay-fixed swaps. (3) FX delta — EUR/USD moved from 1.085 to 1.092, affecting XCCY swap exposures. (4) new trades — we added $200M notional of EUR IRS for 2 new IG counterparties. (5) time decay — daily theta on CVA positions. Estimate the P&L attribution across these 5 factors and identify which drove most of the -$1.2M move."
Where to Start
For CVA analysts who are new to the XVA framework or working through a regulatory change, the Compliance & Risk category includes SA-CCR Exposure Calculator and Regulatory Capital Analyzer templates that handle the Basel IV ruleset. For front office derivatives traders trying to understand why XVA is being charged on their trades, start with the CVA explainer prompts — Claude can walk through the calculation with your actual trade parameters. All templates work in Claude.ai Pro or Teams with the system prompt in a Project. For desks managing large netting sets, the ability to paste in trade-level data and get a structured attribution analysis is where the time savings are largest.