Explainable Ai Scoring Legal Thresholds Spain Banking Law

1. What Counts as AI Scoring in Spanish Banking Law?

Three types, different threshold:

A. Credit Scoring / PD Scoring - For granting credit:

  • Consumer loan, mortgage, SME loan, credit card limit
  • Regulated as High-Risk AI under AI Act Annex III 1(a) - Creditworthiness assessment

B. Risk Scoring - For prudential purposes:

  • Internal Ratings Based - IRB models for capital - CRR Art 144-191
  • IFRS 9 provisioning models
  • Supervisory threshold higher - must be reconstructible by BdE

C. Conduct Scoring - For pricing, cross-selling, fraud:

  • Behavioral scoring, insurance scoring, anti-fraud
  • GDPR Art 22 applies

All three require explainability, but legal threshold differs.

2. Legal Framework - 5 Layers

Layer 1: EU AI Act 2024/1689 - Directly applicable in Spain

  • Art 5(1)(c): Prohibited - Social scoring by banks using behavior leading to detrimental treatment
  • Annex III 5(b): Credit scoring = High-Risk
  • Obligations for High-Risk - Arts 9-15: Risk management Art 9, Data governance Art 10, Technical documentation Art 11, Record-keeping Art 12, Transparency Art 13, Human oversight Art 14, Accuracy/robustness Art 15
  • Art 86: Right to explanation - For high-risk decision, affected person has right to obtain clear meaningful explanation on role of AI in decision-making procedure and main elements of decision taken
  • Fines from 2 Aug 2026: Up to €15M or 3% turnover for high-risk violations - Art 99(4)

Layer 2: GDPR + LOPDGDD 3/2018 Art 22

  • Art 22 GDPR: Right not to be subject to decision based solely on automated processing, including profiling, which produces legal effects or similarly significantly affects him/her
  • Credit denial = legal effect
  • LOPDGDD Art 22: Spanish implementation - allows automated decisions only with explicit consent or contract necessity + suitable measures including right to obtain human intervention, express point of view, contest decision

Layer 3: Spanish Banking Sector

  • Law 10/2014 LOSSEC Art 29 + Circular 2/2016: Governance of internal models
  • Law 16/2011 Consumer Credit + Law 5/2019 Real Estate Credit LCCI Art 12: Creditworthiness assessment must be based on sufficient information, cannot be solely automated without human review
  • Law 4/2022 Customer Service Financial Sector - Derecho a atención humana: Customer has right to human attention when automated system used. Enforceable before Servicio de Reclamaciones Banco de España. Complaint can go to BdE.

Layer 4: National AI Supervision

  • Royal Decree 729/2023: Creates AESIA - Agencia Española de Supervisión de Inteligencia Artificial - single point of contact EU, market surveillance authority
  • Draft Organic Law approved Council of Ministers 26 May 2026: Aligns Spain with AI Act - governance architecture places AESIA at heart, but Bank of Spain, CNMV, DGSFP retain sectoral supervision for financial AI tools such as algorithmic trading, credit risk models
  • Hybrid model: AESIA for AI matters, AEPD where personal data, BdE for banking models

Layer 5: Banco de España Doctrine - Explainability = Reconstructibility

  • Occasional Paper 2105 Alonso-Robisco & Carbó (2021): Understanding Performance of ML Models to Predict Credit Default - 6 phases under supervision of central Bank of Spain to mitigate black box effect and achieve explainability level
  • Bank of Spain: Financial entities should validate all AI-generated results before incorporating into risk management frameworks. Complexity of AI models: more focus on data and explainability
  • Working Papers 2024-2025: Introduce concept of reconstructibility - institutional capacity to recover causal chain linking data, models, outcomes to attributable responsibility when decisions challenged. In high-risk environments, explainability may not be sufficient.

3. Explainability Threshold - What Spanish Law Requires

Spanish doctrine rejects "black box with high accuracy". Threshold = 4 elements must be proven:

1. Meaningful Human-Interpretable Explanation - Not Code
AEPD jurisprudence: Automated decision affecting legal decisions requires clear explanation of criteria - not "model with 200 variables".

Must include:

  • Main data categories used - income, debt-to-income, credit history, employment stability
  • Relative importance / weight
  • Logic - if score < threshold then denial
  • Source of data - CIRBE, ASNEF, etc.

2. Counterfactual Explanation
What to change to obtain different outcome?
Example compliant: "Your scoring was 520/1000, threshold 600. Main factors: debt-to-income 48% (threshold 35%), 3 incidents in ASNEF in last 12 months. If debt-to-income reduced to 35% and no new incidents for 6 months, score would be 610."

This derives from GDPR Recital 71 + AI Act Art 86.

3. Human Oversight + Right to Contest

  • Human must be able to override - AI Act Art 14
  • Customer must have button/ channel to request human review - Law 4/2022 + LOPDGDD Art 22
  • Human must have competence to understand and ability to intervene - not rubber-stamp

4. Reconstructibility for Supervisor
For BdE/ECB supervision, bank must be able to, within reasonable time if challenged:

  • Recover data lineage
  • Show model version used at time of decision
  • Show SHAP values / feature importance for that specific decision
  • Show validation that model not discriminatory
  • AEPD Rule of 2 - new 71-page guidance 18 Feb 2026 on agentic AI: Systems should be designed assuming failures will occur. Means defining performance metrics, structured testing, reviewing provider contracts, building in explainability and ensuring meaningful human intervention always possible where required. For builders: memory compartmentalization, defined retention periods, compartmentalized access, chain-of-thought explainability.

4. Case Laws - Spanish Explainability Jurisprudence

CASE 1: AEPD v Banco Santander (2020) - Automated Credit Scoring - Landmark

Issue: Whether AI systems must provide meaningful human-interpretable explanations under GDPR and Spanish data protection law.

Facts: Client applied for €15,000 consumer loan online. Denied in 3 seconds by algorithm. Bank response to access request: "Decision based on internal scoring model using statistical methods."

AEPD Decision:
Violation of Art 13, 14, 22 GDPR + Art 22 LOPDGDD.

Requirements set:

  • Clear explanation of criteria used
  • Significance and envisaged consequences
  • Right to obtain human intervention

Bank ordered to provide: list of main variables, scoring range, threshold, possibility of human review.

Doctrine: Explainability threshold = customer must understand why denied, not need to understand algorithm mathematics. Level 2 explanation required.

This case is basis for AI Act Art 86.

CASE 2: AEPD vs CaixaBank S.A. - PS/00100/2019 - €6M - 13 Jan 2021

Largest GDPR banking fine in Spain for explainability failure.

Facts:

  • CaixaBank used client transactional data to train AI models for profiling without valid legal basis
  • Used black-box scoring for pre-approved product offers and pricing
  • Privacy policy generic: "we may use data to improve products"

AEPD Findings:

  • Violation Art 6 lawfulness, Art 5(1)(a) transparency, Art 22 automated decisions
  • Transparency and explainability for automated decisions - LOPDGDD Art 22 + AI Act Art 86: Explainable credit scoring - give meaningful logic, human review button

Fine €6M.

Threshold clarified: For banking AI scoring, transparency at time of data collection must include that data will be used for AI scoring, logic involved. Cannot hide behind legitimate interest. Need explicit information.

CASE 3: BOSCO Algorithm Rulings - Contencioso-Administrativo - Source Code Access Doctrine

Spain BOSCO rulings - algorithmic transparency.

BOSCO = algorithm used by Spanish Administration to decide energy social bonus - similar logic to banking scoring - automated eligibility.

Jurisprudence 2021-2024 - Juzgados Contencioso-Administrativo Madrid + STS Contencioso 2022:

Facts: Citizens denied social bonus by BOSCO, administration said "algorithm says no".

Courts:

  • Algorithmic and AI transparency work deals with transparency and access to source code, with analysis of existing Spanish BOSCO rulings, participation, explainability and motivation of administrative decisions and finally transparency and algorithmic regulation.
  • Administrative decision based on AI must be motivated per Art 35 Law 39/2015 + Art 103 CE
  • Citizen has right to know criteria, weight, data. If needed for effective judicial protection Art 24 CE, court can order disclosure of source code or audit trail under confidentiality

Import to Banking: Banks acting as collaborators for ICO loans, social housing scoring, etc., subject to same doctrine. Even for purely private banking, doctrine of motivation applies via BdE Circular - customer has right to explanation of denial under Law 5/2019 Art 12 + transparency order EHA/2899/2011.

STS 23 Jan 2023 on motivation: insufficient generic motivation void - same for scoring.

CASE 4: Banco de España Occasional Paper 2105 - Alonso & Carbó - Supervisory Explainability Threshold

Facts: Spanish bank submitted ML model - gradient boosting - for PD prediction - accuracy AUC 0.85 vs logistic regression AUC 0.81.

BdE supervisory evaluation under IRB:

BdE rejected despite higher accuracy because:

  • Could not mitigate black box effect and achieve explainability level
  • No SHAP, no partial dependence plots
  • Could not explain to supervisor why borrower X classified default

Doctrine established: For supervisory AI, explainability overrides accuracy. Trade-off between explainability and accuracy as important issue for AI-based services because increased level of explanation limits performance - but Spanish regulator says in banking, explainability mandatory even if accuracy lower.

BdE requires 6 phases:

  1. Data quality assessment
  2. Feature engineering justification
  3. Model development with interpretability built-in
  4. Validation - including explainability validation
  5. Human oversight structure
  6. Monitoring and drift explanation

CASE 5: AEPD Agentic AI Guidance 18 Feb 2026 - Rule of 2 - Chain-of-Thought Explainability

Spanish Data Protection Agency released 71-page formal supervisory authority guidance on agentic AI and GDPR - first EU supervisory authority guidance on agentic AI architecture.

Rule of 2 - risk framework adapted from browser-security:

  • Agentic AI that makes autonomous credit decisions must have 2 independent checks
  • Compliance must be integrated into design through memory compartmentalization, defined retention periods, compartmentalized access, chain-of-thought explainability

For banking scoring agents:

  • Agent that automatically collects data, scores, decides, must keep explainable chain-of-thought log
  • That log is subject to data subject access request
  • Must ensure meaningful human intervention always possible where required

Failure = violation Art 22 + Art 25 data protection by design.

CASE 6: Digital Human Rights in Financial Ecosystems - Right to Algorithmic Non-Discrimination

4. Right to Algorithmic Non-Discrimination and Explainability

Facts: Mortgage denied - bank scoring used postal code as proxy. Postal code correlates with ethnicity in certain Madrid neighborhoods. Bank claimed not using ethnicity.

AEPD + BdE doctrine: No court sentence yet, but Bank of Spain Circular and Ministry Economy Order creates enforceable right under Law 4/2022 to human attention.

Explainability must include fairness audit: Bank must be able to demonstrate that scoring not discriminatory, including indirect discrimination via proxies.

Complaints can go to Servicio de Reclamaciones del Banco de España.

If proxy discrimination found, explainability threshold fails even if technical explanation provided.

5. Current Sanction Risk 2026-2027

RegulatorThreshold FailureSanction
AESIANo transparency Art 13, no human oversight Art 14, no Art 86 explanationUp to €15M or 3% turnover - from 2 Aug 2026 high-risk obligations enforceable
AEPDArt 22 automated decision without meaningful logic + human reviewUp to €20M or 4% turnover GDPR + PS/00100/2019 precedent €6M
Banco de España / ECBModel not reconstructible, IRB validation failsArt 92 Law 10/2014 very serious infringement - up to €5M or 10% revenue, IRB model rejected, capital add-on
Servicio Reclamaciones BdENo human attention Law 4/2022Reputational, order to rectify, basis for civil nullity of contract

 

6. How to Comply - Explainability Dossier for Credit Scoring

Spanish compliant scoring must keep Explainability File per decision:

  1. Data Sheet: What data used - list, source, date, legal basis
  2. Model Card: Version, training data period, accuracy, bias test
  3. Decision Explanation: Score, threshold, top 3 negative factors, weight
  4. Counterfactual: What change leads to approval - quantified
  5. Human Oversight Log: Name/role of human reviewer if contest, override possibility
  6. Retention: Chain-of-thought log for agentic AI per AEPD Rule of 2 - 5 years per Circular 4/2017

Template language for customer - compliant with Art 86 + LOPDGDD 22:

"Su solicitud ha sido evaluada mediante sistema de scoring regulado como Sistema de IA de Alto Riesgo conforme Reglamento UE 2024/1689. Puntuación obtenida: [X]/1000. Umbral mínimo: [Y]. Factores determinantes: 1) Ratio endeudamiento [X]% 2) Historial crediticio [X] incidencias 3) Estabilidad laboral [X] meses. Lógica: modelo estadístico supervisado por Banco de España. Puede solicitar revisión humana en [canal] conforme Ley 4/2022 y Art 22 LOPDGDD. Si mejora [factor] en [cantidad], su puntuación pasaría a [Y+]."

LawGratis provides pro bono legal aid and resources to empower communities. Join us in making justice reachable for everyone! Follow our community on Instagram, YouTube, Facebook, and LinkedIn.

LEAVE A COMMENT