AI explainability (XAI)
🤖 الذكاء الاصطناعي والتكنولوجيا🎓 الصف الثاني عشر عام📌 هيكل الامتحان: AI L04 · slides 4–19
🎯 ذاكر الدرس وحل الكويز مجانًا في مذاكرتي| Key word | Meaning |
|---|---|
| Black-box AI (الصندوق الأسود) | A model whose internal decision-making is not visible or understandable to humans |
| Accountability (المساءلة) | Taking responsibility for the actions and outcomes of AI systems |
| Data governance | Policies and rules for how data is collected, stored, used and protected |
| AI auditing | Checking AI systems to ensure they work fairly, safely and correctly |
Explainable AI helps users: understand decisions · identify mistakes or bias · build trust · improve accountability and fairness. Without it, advanced systems behave like black boxes.
| Area | Why explainability matters |
|---|---|
| Healthcare | Doctors need to know which symptoms or test results led to a prediction before treating |
| Banking | People should know why a loan was rejected; helps find mistakes or bias |
| Education | Students can understand and question grades or decisions |
| Security | Shows why an alert was raised so humans can verify it |
| Government services | People can know why benefits were accepted or denied and appeal |
Five ways explainability supports responsible AI: Trust · Fairness (gives information that helps people identify bias – it does not detect bias on its own) · Accountability (people, not the AI, take responsibility) · Compliance (laws require transparency in high-risk AI) · Improvement (developers understand errors).
| Method | How it works | Example |
|---|---|---|
| 1 Feature importance | Shows which input features most influenced the decision | Income and repayment history affected loan approval |
| 2 Decision trees | A series of simple if–then questions | If attendance > 90% and grades are high → predict success |
| 3 Rule-based systems | Clear, predefined rules | If temperature > 38°C → send a heat warning |
| 4 Visual explanations | Highlight important areas of an image/input | Highlight X-ray regions behind a diagnosis |
| 5 Human review and oversight | Experts review, validate and question AI decisions | Doctors review AI recommendations |
SHAP = SHapley Additive exPlanations: estimates how much each feature contributes; positive values increase the prediction, negative values decrease it. Example: loan approved – high income increased the score, late payments reduced it.
Why are deep learning models black boxes? Neural networks contain millions of numbers (weights) spread across many layers. The decision comes from all of them together, so no single simple rule can be read off. Explainability methods are tools that reveal why the model made a specific decision.
Interpretable by design vs explained afterwards: decision trees and rule-based systems are understandable by design; LIME and SHAP are applied after training to explain complex models.
Activity 4.2 – loan with 50+ variables. Two suitable methods: feature importance / SHAP (shows that, e.g., late payments pulled the score down most) and LIME (explains this one customer's rejection locally). For a customer, a short list of the top reasons ("missed payments, high existing debt") is easier to understand than a full chart. Explainability is especially important in finance because decisions affect people's lives, must be fair, and regulations may require reasons.
Starter scenario: a business owner with a strong repayment history is rejected in seconds with no explanation – he cannot fix anything or appeal. Humans should review important decisions like this.
اختبر نفسك: أسئلة على AI explainability (XAI)
What is AI explainability (XAI)?
✅ الجواب: Understanding how and why an AI system makes a decision
XAI makes AI decisions understandable.
A model whose internal decision-making is not visible or understandable to humans is called:
✅ الجواب: Black-box AI
Deep learning models are often black boxes.
Which explainability method uses a series of simple if–then questions?
✅ الجواب: Decision trees
Decision trees follow clear decision paths.