CIRCL/vulnerability-attack-technique-classification-roberta-base

Model

1

stars

7

commits

1

repos using this model

3

linked in READMEs

Jul 29, 2026

updated

cti
cve
endpoints_compatible
generated_from_trainer
mitre-attack
model-index
multi-label-classification
roberta
safetensors
security
text-classification
text-embeddings-inference
transformers
vulnerability
Browse cluster: Transformer Text Classification & Embeddings

README

vulnerability-attack-technique-classification-roberta-base

Suggests MITRE ATT&CK (Enterprise) techniques from a free-text vulnerability description. This is a multi-label classifier (roberta-base with a sigmoid head, one output per technique) fine-tuned on CIRCL/vulnerability-attack-techniques, a gold dataset of 1,207 CVEs whose labels come from expert MITRE CTID mappings. Given a CVE description it scores 53 parent techniques (e.g. T1190 Exploit Public-Facing Application, T1505 Server Software Component), for use as a ranked list of candidate techniques for analyst review.

The model is trained with VulnTrain and runs in production on the public Vulnerability-Lookup instance operated by CIRCL, served locally by ML-Gateway: every vulnerability page has an ATT&CK tab with the model's suggestions (example: CVE-2021-44077).

The methodology, evaluation protocol, and the negative result on LLM-assisted label expansion are described in the paper Mapping CVEs to MITRE ATT&CK Techniques: A Curated Gold-Set Classifier and the Limits of LLM-Assisted Label Expansion (arXiv:2607.25572).

DOI: 10.57967/hf/9623

How to use

With VulnTrain, against a live CVE:

vulntrain-infer-attack-classification --cve CVE-2021-44077 \
    --model CIRCL/vulnerability-attack-technique-classification-roberta-base

With plain Transformers:

import torch
from transformers import AutoModelForSequenceClassification, AutoTokenizer

model_id = "CIRCL/vulnerability-attack-technique-classification-roberta-base"
tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForSequenceClassification.from_pretrained(model_id)
model.eval()

description = (
    "Zoho ManageEngine ServiceDesk Plus before 11306, ServiceDesk Plus MSP "
    "before 10530, and SupportCenter Plus before 11014 are vulnerable to "
    "unauthenticated remote code execution."
)
inputs = tokenizer(description, truncation=True, max_length=512, return_tensors="pt")
with torch.no_grad():
    probs = torch.sigmoid(model(**inputs).logits)[0]

for i in probs.argsort(descending=True)[:5]:
    print(f"{model.config.id2label[int(i)]}  {probs[i]:.4f}")

Technique IDs map to names via the ATT&CK Enterprise matrix; sigmoid >= 0.5 is the prediction threshold used in evaluation, but the model is most useful as a ranker (see the recall@k numbers below).

Intended uses & limitations

Intended: triage assistance — given a vulnerability description, surface a short ranked list of candidate ATT&CK techniques for a human analyst to confirm or reject. This is how it is deployed in Vulnerability-Lookup, where the UI explicitly flags the output as unverified AI-generated suggestions.

Limitations:

  • The label space is the 53 parent techniques with at least 5 training examples; sub-techniques are collapsed to their parent, and techniques outside this vocabulary can never be suggested.
  • The gold set skews toward exploited-in-the-wild CVEs (CTID's corpus and the KEV catalog), so coverage is best for the techniques common there.
  • Trained on 972 CVEs — deliberately label-quality-bound rather than data-bound (see the paper's gold-size scaling curve: every metric still improves monotonically with more curated rows).
  • English descriptions only; input is truncated at 512 tokens.
  • Scores are not calibrated probabilities.
  • Suggestions are not verified mappings; treat them as guidance, never as authoritative CTI.

Training and evaluation data

Labels come from the two public expert sources of CVE→ATT&CK mappings, both following the CTID Mapping ATT&CK to CVE for Impact methodology: the CTID attack_to_cve mappings and the CTID Mappings Explorer KEV mappings (ATT&CK 16.1). Technique IDs revoked since publication are remapped to their successors via the ATT&CK STIX revoked-by relationships. Descriptions are joined from CIRCL/vulnerability-scores (Vulnerability-Lookup). Full details in the dataset card and the VulnTrain documentation.

Splits: 972 train / 106 validation / 118 test examples. Checkpoint selection uses the validation split; the test split is touched once, for the numbers reported here. The paper documents why this matters: selecting the best checkpoint on the test split inflates and destabilizes small-test-split metrics enough to produce spurious conclusions.

Notably, this model was not trained on LLM-generated labels: the paper's controlled experiments show that folding in LLM-labeled CVEs at ≈0.39 agreement with the experts yields no reliable ranking improvement and measurably degrades rare-technique coverage at scale (the comparison checkpoint is published as ...-llm-expanded).

Evaluation

Held-out test split, this checkpoint (seed 42):

MetricValue
Recall@50.6440
Recall@30.5181
F1 micro0.3899
F1 macro0.1910
Precision micro0.2740
Recall micro0.6756

Recall@5 = 0.64 means that on average 64% of an unseen CVE's expert-assigned techniques appear in the model's top five suggestions — roughly double the zero-shot embedding-similarity baseline reported in the paper. Across five seeds under the identical protocol, the numbers of record are recall@5 0.673 ± 0.019, recall@3 0.536 ± 0.032, micro-F1 0.410 ± 0.006, macro-F1 0.177 ± 0.014. The complete trainer logs are published in the paper repository.

Training procedure

Binary cross-entropy over 53 sigmoid outputs, with per-label pos_weight balancing (capped at 20) to keep rare techniques trainable. Trained with vulntrain-train-attack-classification (VulnTrain).

Training hyperparameters

The following hyperparameters were used during training:

  • learning_rate: 1e-05
  • train_batch_size: 32
  • eval_batch_size: 32
  • 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
  • num_epochs: 40
  • max_length: 512
  • loss: BCEWithLogitsLoss, balanced pos_weight (min 2.447, max 20.0)
  • checkpoint selection: best macro-F1 on the validation split

Training results

Training LossEpochStepValidation LossF1 MicroF1 MacroPrecision MicroRecall MicroRecall At 3Recall At 5
0.93111.0310.84130.18330.04010.12580.33760.17980.2611
0.83662.0620.78760.14520.02340.10650.22780.10470.2086
0.81163.0930.77170.20540.05180.16410.27430.19380.3234
0.79414.01240.75760.32040.08040.23820.48950.33870.5009
0.77435.01550.74350.30440.08410.21190.54010.33130.4696
0.76456.01860.72900.32080.09060.21740.61180.39690.5391
0.74727.02170.71630.35510.11300.25710.57380.40680.5741
0.72198.02480.70560.32240.10790.21730.62450.40790.5521
0.71959.02790.69330.35760.14950.24490.66240.42520.5663
0.683510.03100.68450.37050.16650.25790.65820.47080.6090
0.653911.03410.67680.40630.18100.29470.65400.52270.6318
0.648412.03720.67250.36320.17340.25200.64980.44490.6200
0.624913.04030.66640.39740.17820.28620.64980.50340.6396
0.610914.04340.65850.38010.17210.27240.62870.48340.6491
0.600415.04650.65390.38720.16780.27810.63710.47520.6347
0.589616.04960.65020.40490.17770.29960.62450.47680.6397
0.566717.05270.64780.38660.16820.27370.65820.49410.6472
0.566118.05580.64250.41080.19100.30220.64140.51280.6667
0.550119.05890.63940.38800.18610.27580.65400.48220.6561
0.546120.06200.63770.40970.18040.30100.64140.50690.6687
0.535121.06510.63380.40280.17150.30020.61180.49870.6624
0.521522.06820.63510.41460.19640.30540.64560.49430.6875
0.515523.07130.63150.40560.17370.30230.61600.49940.6553
0.506324.07440.62690.42860.18790.32080.64560.51950.6923
0.506125.07750.62640.41780.18690.30690.65400.52460.6656
0.499626.08060.63010.40730.17920.30530.61180.52740.6958
0.495027.08370.62250.41330.17710.30790.62870.53760.6593
0.492828.08680.62280.41730.17680.31660.61180.51870.7048
0.481929.08990.62420.42630.18710.32250.62870.54940.6970
0.476630.09300.61940.41660.18620.30940.63710.52260.6871
0.469431.09610.62130.420.19140.31750.62030.53990.6918
0.478132.09920.62090.42920.18930.32810.62030.54390.7060
0.463633.010230.62180.43470.19620.32760.64560.5250.6797
0.464134.010540.62160.43140.18870.32610.63710.54150.6797
0.459235.010850.62060.43130.19160.32820.62870.54660.6858
0.452636.011160.62080.43570.19260.33330.62870.54470.6863
0.464337.011470.61910.42180.18990.31960.62030.53920.6863
0.450138.011780.61910.42420.18850.32240.62030.53680.6929
0.457039.012090.62060.43500.19320.33260.62870.52810.6910
0.443640.012400.61990.43250.19160.32960.62870.53290.6882

Framework versions

  • Transformers 5.13.0
  • Pytorch 2.12.1+cu130
  • Datasets 4.8.5
  • Tokenizers 0.22.2

Citation

@misc{bonhomme2026mappingcvesmitreattck,
      title={Mapping CVEs to MITRE ATT&CK Techniques: A Curated Gold-Set Classifier and the Limits of LLM-Assisted Label Expansion},
      author={Cédric Bonhomme and Alexandre Dulaunoy},
      year={2026},
      eprint={2607.25572},
      archivePrefix={arXiv},
      primaryClass={cs.CR},
      url={https://arxiv.org/abs/2607.25572},
}

Acknowledgements

Developed at CIRCL in the context of the AIPITCH project, co-funded by the European Union.

Contributors

CIRCL/vulnerability-attack-technique-classification-roberta-base

Model

1

stars

7

commits

1

repos using this model

3

linked in READMEs

Jul 29, 2026

updated

cti
cve
endpoints_compatible
generated_from_trainer
mitre-attack
model-index
multi-label-classification
roberta
safetensors
security
text-classification
text-embeddings-inference
transformers
vulnerability
Browse cluster: Transformer Text Classification & Embeddings

README

vulnerability-attack-technique-classification-roberta-base

Suggests MITRE ATT&CK (Enterprise) techniques from a free-text vulnerability description. This is a multi-label classifier (roberta-base with a sigmoid head, one output per technique) fine-tuned on CIRCL/vulnerability-attack-techniques, a gold dataset of 1,207 CVEs whose labels come from expert MITRE CTID mappings. Given a CVE description it scores 53 parent techniques (e.g. T1190 Exploit Public-Facing Application, T1505 Server Software Component), for use as a ranked list of candidate techniques for analyst review.

The model is trained with VulnTrain and runs in production on the public Vulnerability-Lookup instance operated by CIRCL, served locally by ML-Gateway: every vulnerability page has an ATT&CK tab with the model's suggestions (example: CVE-2021-44077).

The methodology, evaluation protocol, and the negative result on LLM-assisted label expansion are described in the paper Mapping CVEs to MITRE ATT&CK Techniques: A Curated Gold-Set Classifier and the Limits of LLM-Assisted Label Expansion (arXiv:2607.25572).

DOI: 10.57967/hf/9623

How to use

With VulnTrain, against a live CVE:

vulntrain-infer-attack-classification --cve CVE-2021-44077 \
    --model CIRCL/vulnerability-attack-technique-classification-roberta-base

With plain Transformers:

import torch
from transformers import AutoModelForSequenceClassification, AutoTokenizer

model_id = "CIRCL/vulnerability-attack-technique-classification-roberta-base"
tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForSequenceClassification.from_pretrained(model_id)
model.eval()

description = (
    "Zoho ManageEngine ServiceDesk Plus before 11306, ServiceDesk Plus MSP "
    "before 10530, and SupportCenter Plus before 11014 are vulnerable to "
    "unauthenticated remote code execution."
)
inputs = tokenizer(description, truncation=True, max_length=512, return_tensors="pt")
with torch.no_grad():
    probs = torch.sigmoid(model(**inputs).logits)[0]

for i in probs.argsort(descending=True)[:5]:
    print(f"{model.config.id2label[int(i)]}  {probs[i]:.4f}")

Technique IDs map to names via the ATT&CK Enterprise matrix; sigmoid >= 0.5 is the prediction threshold used in evaluation, but the model is most useful as a ranker (see the recall@k numbers below).

Intended uses & limitations

Intended: triage assistance — given a vulnerability description, surface a short ranked list of candidate ATT&CK techniques for a human analyst to confirm or reject. This is how it is deployed in Vulnerability-Lookup, where the UI explicitly flags the output as unverified AI-generated suggestions.

Limitations:

  • The label space is the 53 parent techniques with at least 5 training examples; sub-techniques are collapsed to their parent, and techniques outside this vocabulary can never be suggested.
  • The gold set skews toward exploited-in-the-wild CVEs (CTID's corpus and the KEV catalog), so coverage is best for the techniques common there.
  • Trained on 972 CVEs — deliberately label-quality-bound rather than data-bound (see the paper's gold-size scaling curve: every metric still improves monotonically with more curated rows).
  • English descriptions only; input is truncated at 512 tokens.
  • Scores are not calibrated probabilities.
  • Suggestions are not verified mappings; treat them as guidance, never as authoritative CTI.

Training and evaluation data

Labels come from the two public expert sources of CVE→ATT&CK mappings, both following the CTID Mapping ATT&CK to CVE for Impact methodology: the CTID attack_to_cve mappings and the CTID Mappings Explorer KEV mappings (ATT&CK 16.1). Technique IDs revoked since publication are remapped to their successors via the ATT&CK STIX revoked-by relationships. Descriptions are joined from CIRCL/vulnerability-scores (Vulnerability-Lookup). Full details in the dataset card and the VulnTrain documentation.

Splits: 972 train / 106 validation / 118 test examples. Checkpoint selection uses the validation split; the test split is touched once, for the numbers reported here. The paper documents why this matters: selecting the best checkpoint on the test split inflates and destabilizes small-test-split metrics enough to produce spurious conclusions.

Notably, this model was not trained on LLM-generated labels: the paper's controlled experiments show that folding in LLM-labeled CVEs at ≈0.39 agreement with the experts yields no reliable ranking improvement and measurably degrades rare-technique coverage at scale (the comparison checkpoint is published as ...-llm-expanded).

Evaluation

Held-out test split, this checkpoint (seed 42):

MetricValue
Recall@50.6440
Recall@30.5181
F1 micro0.3899
F1 macro0.1910
Precision micro0.2740
Recall micro0.6756

Recall@5 = 0.64 means that on average 64% of an unseen CVE's expert-assigned techniques appear in the model's top five suggestions — roughly double the zero-shot embedding-similarity baseline reported in the paper. Across five seeds under the identical protocol, the numbers of record are recall@5 0.673 ± 0.019, recall@3 0.536 ± 0.032, micro-F1 0.410 ± 0.006, macro-F1 0.177 ± 0.014. The complete trainer logs are published in the paper repository.

Training procedure

Binary cross-entropy over 53 sigmoid outputs, with per-label pos_weight balancing (capped at 20) to keep rare techniques trainable. Trained with vulntrain-train-attack-classification (VulnTrain).

Training hyperparameters

The following hyperparameters were used during training:

  • learning_rate: 1e-05
  • train_batch_size: 32
  • eval_batch_size: 32
  • 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
  • num_epochs: 40
  • max_length: 512
  • loss: BCEWithLogitsLoss, balanced pos_weight (min 2.447, max 20.0)
  • checkpoint selection: best macro-F1 on the validation split

Training results

Training LossEpochStepValidation LossF1 MicroF1 MacroPrecision MicroRecall MicroRecall At 3Recall At 5
0.93111.0310.84130.18330.04010.12580.33760.17980.2611
0.83662.0620.78760.14520.02340.10650.22780.10470.2086
0.81163.0930.77170.20540.05180.16410.27430.19380.3234
0.79414.01240.75760.32040.08040.23820.48950.33870.5009
0.77435.01550.74350.30440.08410.21190.54010.33130.4696
0.76456.01860.72900.32080.09060.21740.61180.39690.5391
0.74727.02170.71630.35510.11300.25710.57380.40680.5741
0.72198.02480.70560.32240.10790.21730.62450.40790.5521
0.71959.02790.69330.35760.14950.24490.66240.42520.5663
0.683510.03100.68450.37050.16650.25790.65820.47080.6090
0.653911.03410.67680.40630.18100.29470.65400.52270.6318
0.648412.03720.67250.36320.17340.25200.64980.44490.6200
0.624913.04030.66640.39740.17820.28620.64980.50340.6396
0.610914.04340.65850.38010.17210.27240.62870.48340.6491
0.600415.04650.65390.38720.16780.27810.63710.47520.6347
0.589616.04960.65020.40490.17770.29960.62450.47680.6397
0.566717.05270.64780.38660.16820.27370.65820.49410.6472
0.566118.05580.64250.41080.19100.30220.64140.51280.6667
0.550119.05890.63940.38800.18610.27580.65400.48220.6561
0.546120.06200.63770.40970.18040.30100.64140.50690.6687
0.535121.06510.63380.40280.17150.30020.61180.49870.6624
0.521522.06820.63510.41460.19640.30540.64560.49430.6875
0.515523.07130.63150.40560.17370.30230.61600.49940.6553
0.506324.07440.62690.42860.18790.32080.64560.51950.6923
0.506125.07750.62640.41780.18690.30690.65400.52460.6656
0.499626.08060.63010.40730.17920.30530.61180.52740.6958
0.495027.08370.62250.41330.17710.30790.62870.53760.6593
0.492828.08680.62280.41730.17680.31660.61180.51870.7048
0.481929.08990.62420.42630.18710.32250.62870.54940.6970
0.476630.09300.61940.41660.18620.30940.63710.52260.6871
0.469431.09610.62130.420.19140.31750.62030.53990.6918
0.478132.09920.62090.42920.18930.32810.62030.54390.7060
0.463633.010230.62180.43470.19620.32760.64560.5250.6797
0.464134.010540.62160.43140.18870.32610.63710.54150.6797
0.459235.010850.62060.43130.19160.32820.62870.54660.6858
0.452636.011160.62080.43570.19260.33330.62870.54470.6863
0.464337.011470.61910.42180.18990.31960.62030.53920.6863
0.450138.011780.61910.42420.18850.32240.62030.53680.6929
0.457039.012090.62060.43500.19320.33260.62870.52810.6910
0.443640.012400.61990.43250.19160.32960.62870.53290.6882

Framework versions

  • Transformers 5.13.0
  • Pytorch 2.12.1+cu130
  • Datasets 4.8.5
  • Tokenizers 0.22.2

Citation

@misc{bonhomme2026mappingcvesmitreattck,
      title={Mapping CVEs to MITRE ATT&CK Techniques: A Curated Gold-Set Classifier and the Limits of LLM-Assisted Label Expansion},
      author={Cédric Bonhomme and Alexandre Dulaunoy},
      year={2026},
      eprint={2607.25572},
      archivePrefix={arXiv},
      primaryClass={cs.CR},
      url={https://arxiv.org/abs/2607.25572},
}

Acknowledgements

Developed at CIRCL in the context of the AIPITCH project, co-funded by the European Union.

Contributors