File size: 4,289 Bytes
25dfeb9 0f16e07 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 | ---
license: apache-2.0
library_name: scikit-learn
pipeline_tag: tabular-classification
tags:
- ai-governance
- responsible-ai
- risk-classification
- scikit-learn
- synthetic-data
datasets:
- aigovdev/ai-governance-scenarios
---
# Governance Risk Classifier
A small experimental baseline for classifying synthetic AI governance scenarios into coarse engineering risk tiers.
The model is part of the AIGovDev public AI governance engineering portfolio.
## Model architecture
The pipeline uses:
- categorical feature preprocessing
- one-hot encoding
- logistic regression
- balanced class weights
Input features:
- sector
- impact
- decision autonomy
- human oversight
- post-deployment monitoring
- traceability
- technical documentation
## Target labels
The original governance labels are mapped into three coarse tiers:
- `low` and `limited` → `lower`
- `high` → `high`
- `unacceptable` → `unacceptable`
These labels are engineering annotations only.
They are **not legal classifications** and must not be interpreted as determining compliance with the EU AI Act or any other regulation.
## Training data
The model is trained on:
`aigovdev/ai-governance-scenarios`
The current dataset contains 12 synthetic scenarios:
- 6 `lower`
- 3 `high`
- 3 `unacceptable`
The scenarios were manually constructed for experimentation and demonstration.
They are not production data.
## Evaluation
The current prototype uses stratified 3-fold cross-validation.
Results:
| Metric | Score |
| --- | ---: |
| Accuracy | 1.000 |
| Macro precision | 1.000 |
| Macro recall | 1.000 |
| Macro F1 | 1.000 |
Confusion matrix:
lower 6 0 0
high 0 3 0
unacceptable 0 0 3
These results must be interpreted with extreme caution.
The dataset contains only 12 synthetic, manually constructed examples. The perfect cross-validation result is therefore primarily evidence that the current feature patterns are easily separable within this toy dataset.
It is **not evidence of real-world generalization**, production readiness, regulatory validity, or calibrated governance-risk estimation.
## Intended use
This model is suitable for:
- educational experiments
- AI governance pipeline prototyping
- demonstrating transparent tabular ML workflows
- testing governance-risk feature engineering
- portfolio and research-oriented demonstrations
## Not intended for
The model must not be used as:
- a legal compliance classifier
- an EU AI Act classification system
- a production governance decision engine
- a substitute for legal or technical risk assessment
- a validated risk-scoring system
## Reproducibility
The repository contains:
- `src/train.py`
- `requirements.txt`
- `model.joblib`
- `metrics.json`
The training script downloads the public dataset directly from Hugging Face and reproduces the model pipeline and evaluation.
## Limitations
Major limitations include:
- extremely small dataset
- synthetic scenarios
- manually constructed labels
- simplified governance dimensions
- no external validation set
- no calibration analysis
- no real deployment data
## Future work
Possible extensions include:
- larger governance scenario datasets
- independently annotated examples
- real-world control evidence
- lifecycle and incident features
- probability calibration
- external validation
- benchmark comparison
- legal-risk separation from engineering-risk signals
## AIGov
AIGov builds infrastructure for transparent, auditable, and accountable AI systems.
Website: https://govbase.dev
## License
Apache-2.0
## Inference
The repository includes `inference.py` for local predictions.
Example:
```bash
python inference.py --json '{
"sector": "financial_services",
"impact": "high",
"decision_autonomy": "automated",
"human_oversight": "none",
"monitoring": "none",
"traceability": "none",
"technical_documentation": "partial"
}'
```
Example output:
```json
{
"risk_tier": "unacceptable",
"class_probabilities": {
"high": 0.24612,
"lower": 0.08766,
"unacceptable": 0.66622
}
}
```
The returned class probabilities are model scores from the logistic-regression baseline. They should not be interpreted as calibrated probabilities of legal or real-world governance risk.
|