VLAI: Automated Vulnerability Severity Classification (Russian Text)
A fine-tuned ai-forever/ruRoberta-large model that predicts the severity of a vulnerability (Low, Medium, High, Critical) from its Russian description. It is trained on the CIRCL/Vulnerability-FSTEC dataset, built from the Data Bank of Security Threats (BDU) of FSTEC of Russia, as part of the VulnTrain project.
Note (November 2026): this version is trained on corrected labels. The previous version (April 2026) learned from CVSS 2.0 scores only: BDU stores its CVSS 3.x and 4.0 vectors without the
CVSS:3.x//CVSS:4.0/prefix, and the dataset builder dropped them silently. With the fix, 21,457 of the 82,960 rows of the previous dataset change label (25.9%), and the dataset now has a group-aware train/validation/test split. The issue was reported and fixed by Christian Bucher, see VulnTrain #28. Accuracy is lower than before (70.0% against 74.2%), but the two figures are not comparable: the labels and the split both changed.
You can read this page for more information.
Model description
Labels:
| Label | CVSS score |
|---|---|
| Low | < 4.0 |
| Medium | 4.0 – 6.9 |
| High | 7.0 – 8.9 |
| Critical | ≥ 9.0 |
How to get started with the model
from transformers import AutoModelForSequenceClassification, AutoTokenizer
import torch
model_name = "CIRCL/vulnerability-severity-classification-russian-ruRoberta-large"
revision = "5268240"
tokenizer = AutoTokenizer.from_pretrained(model_name, revision=revision)
model = AutoModelForSequenceClassification.from_pretrained(model_name, revision=revision)
model.eval()
# BDU:2017-02220 (CVE-2017-14421, CVSS 3.0 score 9.8), from the test split
description = (
"Уязвимость службы учетной записи Alphanetworks микропрограммного обеспечения "
"маршрутизатора D-Link DIR-850L связана с жёстким кодированием регистрационных данных "
"при перезагрузке устройства. Эксплуатация уязвимости может позволить нарушителю, "
"действующему удалённо, получить root доступ через TELNET-подключение"
)
inputs = tokenizer(description, return_tensors="pt", truncation=True)
with torch.no_grad():
probabilities = torch.softmax(model(**inputs).logits, dim=-1)
print("Probabilities:", probabilities)
print("Predicted severity:", model.config.id2label[int(probabilities.argmax())])
Output:
Probabilities: tensor([[0.0008, 0.0394, 0.2664, 0.6935]])
Predicted severity: Critical
Training data
Revision a104085 of CIRCL/Vulnerability-FSTEC, built with VulnTrain from the BDU records in Vulnerability-Lookup:
| Split | Rows | Labelled rows |
|---|---|---|
| train | 78,798 | 78,796 |
| validation | 10,027 | 10,027 |
| test | 9,698 | 9,698 |
- Group-aware split (80/10/10). Rows that share a description or a CVE id are kept in the same split, so the test rows have no twin in train.
- Labels come from the first available CVSS score, in the order v4.0, v3.x, v2.0: 77.3% from v3, 17.6% from v2, 5.1% from v4. CVSS 4.0 scores are read with base metrics only (CVSS-B), as for the other VLAI models.
- Class balance: Low 3.1%, Medium 39.9%, High 41.6%, Critical 15.4%.
Training procedure
Training hyperparameters
The following hyperparameters were used during training:
- learning_rate: 1e-05
- train_batch_size: 64
- eval_batch_size: 64
- seed: 42
- optimizer: Use OptimizerNames.ADAMW_TORCH_FUSED with betas=(0.9,0.999) and epsilon=1e-08 and optimizer_args=No additional optimizer arguments
- lr_scheduler_type: linear
- lr_scheduler_warmup_steps: 0.1 (10% of the steps)
- num_epochs: 5
A first run at a learning rate of 3e-5 without warmup, the setting of the previous version, collapsed: it predicted a single class for four of its five epochs. Since VulnTrain #29, large models are trained at 1e-5 with a warmup.
The checkpoint with the best validation accuracy (epoch 4) is the one published.
Training took 1 h 16 min on 4 × NVIDIA L40S and used 1.55 kWh, for 0.16 kg CO₂eq (measured with CodeCarbon, see emissions.csv).
Results
Evaluated once on the test split of CIRCL/Vulnerability-FSTEC (revision a104085, 9,698 labelled rows):
- Accuracy: 0.6995 (95% CI 0.6904 – 0.7087)
- F1 Macro: 0.5849
| Class | Precision | Recall | F1 |
|---|---|---|---|
| Low | 0.4553 | 0.1931 | 0.2712 |
| Medium | 0.7451 | 0.7592 | 0.7521 |
| High | 0.6915 | 0.7077 | 0.6995 |
| Critical | 0.6169 | 0.6164 | 0.6167 |
Low is the weakest class: it is only 3.1% of the data, and the model finds about one Low vulnerability in five.
Training results
Validation metrics at each epoch:
| Training Loss | Epoch | Step | Validation Loss | Accuracy | F1 Macro | Low Precision | Low Recall | Low F1 | Medium Precision | Medium Recall | Medium F1 | High Precision | High Recall | High F1 | Critical Precision | Critical Recall | Critical F1 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 3.1325 | 1.0 | 1232 | 2.9849 | 0.6874 | 0.5539 | 0.3357 | 0.1667 | 0.2227 | 0.7135 | 0.8102 | 0.7588 | 0.7179 | 0.6413 | 0.6774 | 0.5531 | 0.5603 | 0.5567 |
| 2.5692 | 2.0 | 2464 | 2.7760 | 0.7101 | 0.5791 | 0.4444 | 0.1667 | 0.2424 | 0.7452 | 0.7943 | 0.7689 | 0.7310 | 0.6921 | 0.7110 | 0.5693 | 0.6206 | 0.5939 |
| 2.5671 | 3.0 | 3696 | 2.7559 | 0.7219 | 0.5983 | 0.464 | 0.2014 | 0.2809 | 0.7913 | 0.7470 | 0.7685 | 0.6935 | 0.7761 | 0.7325 | 0.6344 | 0.5901 | 0.6114 |
| 2.3686 | 4.0 | 4928 | 2.7404 | 0.7260 | 0.6017 | 0.4754 | 0.2014 | 0.2829 | 0.7670 | 0.7859 | 0.7763 | 0.7183 | 0.7451 | 0.7314 | 0.6383 | 0.5952 | 0.6160 |
| 2.3102 | 5.0 | 6160 | 2.8082 | 0.7247 | 0.6040 | 0.4615 | 0.2083 | 0.2871 | 0.7780 | 0.7653 | 0.7716 | 0.7128 | 0.7532 | 0.7324 | 0.6269 | 0.6228 | 0.6249 |
Previous versions
The previous model, trained on CVSS 2.0 labels and a random split, is revision 5de95b3 (dataset revision 5bd7fba, test accuracy 74.17%).
Revision 00f08f5 is the collapsed first run mentioned above and should not be used.
Framework versions
- Transformers 5.22.1
- Pytorch 2.15.0+cu132
- Datasets 4.8.5
- Tokenizers 0.23.3
Acknowledgements
Thanks to Christian Bucher (christian140903-sudo) for finding and fixing the CVSS reading of the FSTEC dataset.
Funding
This work is part of AIPITCH.
Citation
@article{bonhomme2025vlai,
title = {{VLAI}: A {RoBERTa}-Based Model for Automated Vulnerability
Severity Classification},
author = {Bonhomme, C{\'e}dric and Dulaunoy, Alexandre},
journal = {arXiv preprint arXiv:2507.03607},
year = {2025}
}