Skip to Content
  • Article
  • Open Access

1 December 2026

46 Pages

OERA-CVSS: Occurrence-Enriched Retrieval-Augmented CVSS Assessment with Probability Fusion

,
,
,
,
,
and
1
Electric Power Research Institute, State Grid Henan Electric Power Company, Zhengzhou 450052, China
2
School of Computer Science, Shanghai Jiao Tong University, Shanghai 200240, China
3
Luoyang Power Supply Company, State Grid Henan Electric Power Company, Luoyang 471023, China
*
Authors to whom correspondence should be addressed.

Abstract

Automated Common Vulnerability Scoring System (CVSS) assessment requires evidence about both exploitation conditions and security impact. However, existing methods primarily rely on vulnerability descriptions or isolated code fragments, making limited use of project-level call relationships and functional context. We propose OERA-CVSS, an occurrence-enriched retrieval-augmented framework for automated CVSS assessment with metric-level probability fusion. OERA-CVSS constructs a structured knowledge base linking CVE records and historical CVSS labels with vulnerability-related code, project-side trigger code, and functional context. For a target occurrence, it retrieves historical cases using complementary description and code representations, then reranks them separately for exploitability- and impact-related metrics. The retrieved cases serve as in-context demonstrations for a large language model to predict the eight CVSS v3.1 Base metrics. These predictions are then fused with class probabilities from a description-based CVSS-BERT model, and the Base Score and severity level are calculated using the official scoring procedure. The dataset contains 804 unique CVEs, with injected occurrence evidence requiring further validation. In stratified CVE-disjoint five-fold cross-validation, probability fusion increases Metric Macro-F1 from 0.5924 to 0.6771, exceeding standalone CVSS-BERT’s 0.6570. Unfused ablations support retrieval gains and Metric Accuracy improvements from reranking. Together, these findings support OERA-CVSS as an effective framework for automated CVSS assessment.

1. Introduction

Software security is an important consideration for future AI/6G air–ground systems, including low-altitude applications [1,2]. Their reliance on third-party software dependencies may expose applications to vulnerabilities inherited from underlying components. Assessing the severity of these vulnerabilities supports remediation prioritization, motivating automated vulnerability assessment.
The Common Vulnerability Scoring System (CVSS) provides a standardized approach to assessing software vulnerability severity. The CVSS v3.1 Base metric group characterizes a vulnerability using eight metrics: Attack Vector (AV), Attack Complexity (AC), Privileges Required (PR), User Interaction (UI), Scope (S), Confidentiality (C), Integrity (I), and Availability (A). These metrics are used to calculate the Base Score and severity level [3,4]. Accurate prediction of these metrics requires an understanding of exploitation conditions and security impacts, yet public CVE descriptions can be incomplete, omit important details, or contain inconsistencies [5,6,7]. For vulnerabilities in software dependencies, in particular, the actual call entry points, input sources, permission checks, and functional roles of affected components may not be apparent from a short vulnerability description, making automated CVSS assessment more difficult.
Existing automated CVSS assessment methods mainly use vulnerability descriptions, vulnerable code, or patch information, together with machine learning or large language models (LLMs), to predict CVSS metrics [8,9,10,11,12,13]. However, two limitations remain. First, assessment evidence is often insufficient: many methods treat an individual vulnerability record or code fragment as the assessment unit, without capturing vulnerability-related call relationships, trigger conditions, and functional context in real projects. Second, evidence use is not sufficiently targeted: different CVSS metrics require different kinds of evidence. AV, AC, PR, and UI primarily concern exploitation conditions, whereas S, C, I, and A require analysis of component functionality, security boundaries, and potential impacts. Existing retrieval-augmented approaches commonly select historical cases according to overall similarity, without explicitly matching evidence to the needs of these different metric groups [13]. It is, therefore, necessary to incorporate project-level vulnerability context and select evidence according to the requirements of individual CVSS metrics to improve automated assessment accuracy.
We propose OERA-CVSS, a framework for automated CVSS assessment that combines historical-case retrieval with metric-level probability fusion. OERA stands for Occurrence-Enriched Retrieval-Augmented; here, occurrence-enriched refers to organizing vulnerability-related code, project-side trigger code, and functional context into structured evidence. The framework uses retrieved historical cases to guide a large language model in predicting the eight CVSS v3.1 Base metrics, then fuses these predictions with class probabilities from a description-based CVSS-BERT model to calculate the Base Score and severity level. Ablation experiments separately examine the roles of retrieval, probability fusion, and occurrence evidence.
The main contributions of this work are summarized as follows:
  • We introduce a vulnerability occurrence representation that associates each CVE with vulnerability-related code, an identified or constructed project-side call site and the surrounding functional software context.
  • We construct a Vulnerability Occurrence Knowledge Base for the Java/Maven and Python/PyPI ecosystems, providing project-level vulnerability evidence and reporting its quality and limitations through manual sample auditing.
  • We propose a multi-view retrieval and metric-aware reranking strategy that distinguishes exploitability-oriented evidence from impact-oriented evidence when selecting historical cases.
  • We develop a retrieval-augmented framework with metric-level probability fusion that combines large language model predictions guided by retrieved historical cases with class probabilities from a description-based CVSS-BERT model. The framework produces fused predictions for the eight CVSS v3.1 Base metrics and calculates the Base Score and severity level using the official scoring procedure.
  • We conduct a systematic empirical analysis through baseline comparisons, ablation experiments, and cross-model evaluation to verify the predictive benefits of historical-case retrieval and probability fusion, analyze the effects of occurrence evidence and metric-aware reranking across evaluation metrics, and further examine cross-component performance and retrieval parameter sensitivity of the complete system.

2. Related Work

2.1. Vulnerability Severity Assessment

Automated vulnerability severity assessment uses vulnerability descriptions, source code, and other public information to predict CVSS metrics, Base Scores, or severity levels. Early approaches primarily used vulnerability descriptions to learn the relationship between textual features and severity labels. For example, Spanos et al. proposed a text-mining approach to severity prediction [14]. Subsequent studies introduced convolutional neural networks [15], multi-target learning [8], and character-level convolutional networks [16] to capture vulnerability semantics and dependencies among prediction targets. Aivatoglou et al. adopted a RAkEL-based method to estimate multiple vulnerability characteristics and scores from technical descriptions [17]. The CVSS-BERT (2021) model trained separate BERT classifiers for the eight CVSS v3.1 Base metrics and calculated the Base Score from the predicted vector [9]. In a separate 2025 study, Anggita and Badieah proposed CVSS-BERT (2025), which uses lightweight BERT models to classify the eight metrics and derives the corresponding CVSS vector, score, and severity level [18]. These studies established the feasibility of description-based assessment, although their predictions remain sensitive to the completeness of vulnerability descriptions and the quality of annotated data.
To supplement information missing from vulnerability descriptions, other studies incorporate source code and program context. DeepCVA uses code changes and surrounding context from vulnerability-related commits to predict CVSS metrics through deep multi-task learning [10]. Le and Babar further investigated fine-grained vulnerable statements together with program slices, neighboring code, and function context, demonstrating the benefits of contextual evidence for metric prediction [11]. DIFFCVSS analyzes vulnerability-related call paths and program differences between Linux versions and derivatives to identify changes in vulnerability severity [19]. These studies show that code context and call relationships provide assessment evidence beyond vulnerability descriptions. However, their analyses mainly focus on code commits, functions, or specific system environments, rather than reusing project-level vulnerability occurrences as historical cases for CVSS prediction.
Recent work has further explored language models and structured decision mechanisms for automated CVSS assessment. The Jev-CVSS implementation uses TypeSafe Jev to select discrete CVSS metric values from vulnerability descriptions and then calculates scores using the official formulas [20]. AutoCVSS predicts the eight CVSS v3.1 Base metrics with large language models (LLMs) and derives the Base Score and severity level from the resulting vector [21]. It systematically compares zero-shot, few-shot, and retrieval-augmented prompting strategies under different levels of available labeled data. Its findings highlight the potential of LLMs for CVSS assessment, particularly when labeled examples are limited or unavailable.
Other studies combine similarity-based retrieval with in-context learning (ICL) to improve vulnerability severity assessment. SVA-ICL fuses multiple similarity measures derived from source code and vulnerability descriptions, retrieving historical vulnerabilities as demonstrations for LLM-based severity prediction [12]. ReVul-CoT combines retrieval from a knowledge base enriched with information from the National Vulnerability Database (NVD) and CWE with chain-of-thought (CoT) prompting to support reasoning about exploitability and security impact [13]. These methods demonstrate the value of historical examples and external knowledge. However, their retrieved evidence is not explicitly organized around project-side vulnerability occurrences, and the selection process does not directly distinguish the evidence needs of different CVSS Base metrics.
To address these limitations, OERA-CVSS improves both historical case representation and retrieval. First, it integrates CVE information, vulnerability-related code, project-side trigger code, and software functional context into project-level vulnerability occurrences, providing evidence of how vulnerable components are used in actual projects. Second, it introduces metric-aware reranking after multi-view retrieval. Trigger-code similarity is emphasized for exploitability-related metrics, while component and project context is emphasized for impact-related metrics. In this way, the selected historical cases provide more targeted evidence for structured CVSS metric prediction.

2.2. Context-Preserving Vulnerability Instance Construction

High-quality vulnerability data remain scarce, limiting the training and evaluation of data-driven software-security models. Compared with isolated code snippets, vulnerability instances associated with real project structure, call relationships, and functional context provide richer evidence for software-security analysis. Prior studies have linked real vulnerabilities to project repositories to construct datasets for related tasks. CVEfixes associates CVE records with open-source fixing commits, files, functions, and vulnerable and fixed code, supporting vulnerability detection, severity prediction, and repair research [22]. Vul4J collects reproducible vulnerabilities from real Java projects and provides corresponding patches and proof-of-vulnerability tests for automated program repair research [23].
To increase the availability of vulnerability samples with realistic code context, researchers have also explored injecting vulnerabilities into existing programs. VULGEN combines historical vulnerability-edit patterns with context-aware localization of injection sites. Its generated samples improved the F1 scores of downstream vulnerability detectors by up to 31.8% [24]. VGX further uses value-flow information to locate suitable injection sites and produces samples that benefit vulnerability detection, localization, and repair [25]. Yi et al. introduced vulnerability-introducing code-change semantics to guide LLM-based sample generation and showed that the generated data can benefit both downstream vulnerability analysis models and retrieval-augmented vulnerability analysis [26].
Previous work mainly emphasizes collecting real vulnerability data, generating synthetic samples, and applying those samples to vulnerability detection and repair. OERA-CVSS instead focuses on vulnerability severity assessment. It constructs vulnerability occurrences using both existing vulnerability-related calls in real projects and context-preserving injection. Each occurrence associates CVE information and vulnerability-related code with project-side trigger code and functional software context. These occurrences serve as historical references for retrieval-augmented CVSS prediction, allowing the model to consider how vulnerable functionality is invoked and what role the affected component plays when assessing exploitation conditions and security impacts.

3. Background

3.1. CVSS-Based Vulnerability Assessment

The Common Vulnerability Scoring System (CVSS) provides a standardized representation of vulnerability severity through a structured vector and a numerical score [3,4]. In CVSS v3.1, the Base metric group comprises four exploitability metrics—Attack Vector (AV), Attack Complexity (AC), Privileges Required (PR), and User Interaction (UI)—together with Scope (S) and three impact metrics: Confidentiality (C), Integrity (I), and Availability (A). Their categorical values jointly determine the Base Score and its associated severity level.
Automated CVSS assessment can, therefore, be formulated as a structured prediction task that maps vulnerability evidence to the eight Base metrics, from which the Base Score is derived. Public CVE descriptions provide important evidence, but they may omit implementation details, triggering conditions, or the functional role of the affected component. Vulnerability-related code, project-side trigger code, and surrounding software context can supplement these descriptions when interpreting the evidence associated with individual CVSS metrics. This work focuses specifically on predicting the CVSS v3.1 Base vector and deriving the Base Score; Temporal and Environmental metrics, exploitation likelihood, and organization-specific prioritization factors fall outside the scope of the current evaluation.

3.2. Retrieval-Augmented Generation

Retrieval-Augmented Generation (RAG) augments large language models with external knowledge retrieved from a structured knowledge base. Given a query q and a knowledge base K , the retrieval module identifies a set of relevant records C k ( q ) , which are then incorporated into model inference:
y ^ = F q , C k ( q ) .
The effectiveness of RAG depends on both retrieval coverage and relevance. Dense retrieval can identify historical cases with related vulnerability semantics or implementations beyond exact lexical overlap, while multiple evidence views can improve candidate coverage. Fine-grained reranking can then align the selected cases with the evidence required by different CVSS metrics.

3.3. In-Context Learning

In-Context Learning (ICL) enables LLMs to perform task-specific reasoning by conditioning on a small set of demonstrations without updating their parameters. In automated CVSS assessment, historical cases can illustrate how vulnerability descriptions, code, and contextual evidence map to structured CVSS vectors and scores.
The effectiveness of ICL largely depends on demonstration relevance. Highly relevant cases can provide useful points of comparison and help calibrate assessment criteria, whereas irrelevant examples may introduce noise or misleading analogies. OERA-CVSS, therefore, combines retrieval and reranking to select informative historical cases as contextual demonstrations. The selected cases are supplied as demonstrations alongside evidence from the target vulnerability.

4. Method

OERA-CVSS is a retrieval-augmented framework for automated CVSS assessment that provides large language models (LLMs) with project-level vulnerability context and evidence from historical cases. As shown in Figure 1, the framework has two stages. First, public vulnerability information is linked to project-side trigger code, component functions, and related software context to construct a vulnerability occurrence knowledge base. Second, for a target occurrence, multi-view retrieval and metric-aware reranking select relevant historical cases as in-context demonstrations to support CVSS metric prediction.
Figure 1. Overview of the OERA-CVSS framework for automated CVSS assessment.

4.1. Vulnerability Occurrence Knowledge Base Construction

OERA-CVSS links public vulnerability records with project-level code context to construct a vulnerability occurrence knowledge base. Each vulnerability occurrence includes vulnerability metadata, the vulnerability-related implementation in the affected component, project-side trigger code, and relevant functional context. Each occurrence o i is represented as
o i = CVE i , CVECode i , TriggerCode i , Context i ,
where CVE i contains vulnerability metadata and its historical CVSS assessment; CVECode i denotes vulnerability-related code in the affected component; TriggerCode i is the project-side code that invokes or triggers the vulnerable functionality and Context i captures the semantic context of the project, component, and associated functional modules. The knowledge base is defined as
K = { o 1 , o 2 , … , o N } .
Each retained CVE is associated with one representative project-level occurrence, so N is also the number of retained CVEs. By distinguishing the component-side vulnerability implementation from the project-side trigger context, this representation provides structured historical evidence for subsequent retrieval and CVSS assessment. Knowledge base construction comprises two steps: project-level vulnerability occurrence construction and context analysis.

4.1.1. Project-Level Vulnerability Occurrence Construction

Project-level occurrence construction consists of vulnerability information collection, candidate occurrence construction, and candidate validation and selection. It aims to associate public CVEs with vulnerability-related calls and trigger contexts in software projects.
Vulnerability Information Collection
We focus on the Java/Maven and Python/PyPI ecosystems and select commonly used third-party components from web frameworks, network communication, data serialization, logging, machine learning, and data processing. The selected set covers 24 Java components and 16 Python components.
For each component, we collect CVE descriptions, CWE information, affected versions, CVSS v3.1 vectors and scores, and patch references from the NVD [3,27]. Where fixing commits are available, we examine the modified files, functions, and code changes to identify the vulnerability-related implementation in the affected component and populate CVECode . This CVE-to-code linkage is consistent with the construction principle of datasets such as Big-Vul [28]. We also scan the top 1000 GitHub repositories relevant to the Java/Maven and Python/PyPI ecosystems to identify candidate project contexts.
Candidate Occurrence Construction
We employ an LLM-based Construction Agent that uses CVE descriptions, affected versions, and vulnerability-related code together with code search and abstract syntax tree (AST) analysis. The agent identifies API calls in candidate repositories and examines their relation to the target vulnerability. Depending on the available project code, it constructs candidates in two ways. The frozen configuration specifies deepseek-v4.1-flash for the Construction Agent, selected to combine code-generation capability with efficient processing of candidate projects.
  • Existing vulnerable-call identification. When a project already contains a call to the vulnerability-related API, the agent locates the call site, extracts the corresponding code and surrounding context, and labels the candidate already_vulnerable.
  • Context-preserving vulnerability injection. When no such call is found but a suitable modification site exists, the agent constructs an injected candidate by replacing an API call, inserting a vulnerability-related call near existing code, adding required imports and calls, or modifying relevant configuration. Changes are anchored to exact matches in the original project code to preserve the host project’s structure and existing functionality as far as possible. Candidates without a viable modification site are discarded. Figure A1 in Appendix C illustrates the component API and project-side calls for a representative candidate occurrence.
Candidate Occurrence Validation
A separate LLM-based Verification Agent examines the CVE description, affected versions, vulnerability-related implementation, and project-side call code. Using code search and static-analysis evidence, it inspects the relevant call relationships and checks whether a candidate satisfies the known call-site and trigger constraints of the vulnerability. For injected candidates, it additionally checks whether the modifications establish the required call relationship and remain consistent with the host project. The agent returns a verification verdict with supporting rationale and a high, medium, or low confidence level. The VulnTriage verification backend uses deepseek-v4-pro for its code-understanding and reasoning capabilities when assessing trigger conditions and project call relationships. This is a source-code-level consistency check against known trigger conditions, not dynamic proof that the vulnerability can be exploited at runtime. Figure A2 in Appendix C provides a method-aligned verification agent prompt example and an excerpt of the independently archived assessment; the appendix distinguishes this illustrative prompt from an archived execution request.
Target CVSS labels (Base metrics, score, and severity) are hidden from the Construction Agent, Verification Agent, and prediction model, and used only for evaluation. Labeled demonstrations come exclusively from the fold’s Development partition, excluding Test CVEs.
Code Validity Checks and Occurrence Selection
In addition to vulnerability-condition verification, we check whether candidate code remains valid. For Java projects, we identify the required JDK version and compile with Maven or Gradle; for Python projects, we run a py_compile syntax check. Modifications of valid candidates are saved as .patch files, after which the original repositories are restored to preserve the construction record and avoid affecting subsequent candidates.
Only qualified candidates for which the Verification Agent returns Yes are retained. We select one project-level occurrence per CVE. If a CVE has multiple qualified candidates, we sort them first by reported confidence in descending order (high > medium > low), then by the character length of the concatenated vulnerability name and trigger description in descending order, preferring longer descriptions. Remaining ties are resolved by ascending original record position, retaining the first candidate. This establishes a one-to-one mapping between retained CVEs and project-level occurrences.

4.1.2. Context Analysis

After a representative occurrence is selected, OERA-CVSS employs an LLM-based Context Analysis Agent, supported by code search and static-analysis tools, to extract project-level evidence related to the vulnerability. The resulting evidence is organized into three parts: reachability evidence, a trigger-code region, and vulnerability and project metadata.
Reachability Evidence
The agent locates the vulnerability-related function and its source-code position, then analyzes call relationships to identify candidate call paths from project entry points to that function. It records a source-level reachability judgment and the associated confidence.
Trigger-Code Region
Centered on the vulnerability-related function or injection site, the agent extracts the code containing key calls and surrounding logic. For injected occurrences, the relevant modifications are also retained to describe how the vulnerable functionality is triggered in the project.
Vulnerability and Project Metadata
The agent combines vulnerability type, root cause, affected components and versions, and the host project’s functionality. This evidence supplements the code-level observations with information about component roles and potential security impact.
From these three types of evidence, the Context Analysis Agent produces component descriptions, project descriptions, and business-context descriptions, which jointly constitute the Context field. Component and project descriptions are used for semantic retrieval and reranking of impact-related CVSS metrics, while business-context descriptions provide supplementary information to the scoring model. When structured information is incomplete, existing vulnerability records and repository documentation are used to supplement the context.
In this way, OERA-CVSS associates vulnerability trigger locations, project call relationships, and software functionality, providing project-grounded contextual evidence for retrieval-augmented CVSS assessment.

4.2. Retrieval-Augmented CVSS Assessment

Given a target vulnerability occurrence, OERA-CVSS retrieves relevant historical occurrences as empirical references for CVSS assessment. Since overall vulnerability similarity may not adequately reflect the evidence required by different CVSS metrics, we adopt a two-phase strategy consisting of Similar Vulnerability Occurrence Retrieval and Metric-aware Occurrence Reranking. Initial retrieval forms a candidate pool; reranking orders the candidates using exploitability- and impact-related evidence. The selected occurrences are then used in two separate reasoning channels to predict the eight CVSS Base metrics. The predictions are further combined with a description-based auxiliary branch through metric-level fusion to derive the Base Score and severity level.

4.2.1. Similar Vulnerability Occurrence Retrieval

OERA-CVSS first performs dense retrieval using two complementary vulnerability-level representations: project-side trigger code and trigger descriptions. Dense retrieval provides an efficient mechanism for identifying semantically related items [29]. Specifically, separate Facebook AI Similarity Search (FAISS) indices [30] are constructed for historical trigger-code representations and public CVE descriptions. The code view uses the target’s trigger code as the query, while the description view uses its trigger description. We use jinaai/jina-embeddings-v2-base-code, whose code–text representations support semantic matching of vulnerability descriptions and code. The encoder produces 768-dimensional embeddings with mean pooling and supports inputs of up to 8192 tokens, accommodating longer functions and their calling context. Retrieval uses cosine similarity.
For a target occurrence q, the two retrieval views independently produce candidate sets:
C code ( q ) = Top k c K ; S code ret ( q , · ) , C desc ( q ) = Top k d K ; S desc ( q , · ) ,
where S desc and S code ret denote embedding-based similarities between descriptions and trigger code, respectively. Here, Top k ( K ; S ) returns the first k occurrences after sorting by similarity function S in descending order. The parameters k c and k d specify the candidate counts for the two views, both set to 20 in our implementation. The retrieved results are merged and deduplicated to form the unified candidate pool:
C ( q ) = C desc ( q ) ∪ C code ( q ) .
This phase focuses on vulnerability-level relevance. Because the knowledge base contains one occurrence per CVE, the retrieved candidates correspond to distinct CVEs while still capturing similar vulnerability semantics or implementations. The use of both code and description views is supported by findings from prior multimodal assessment studies [12,31]. Occurrence-specific evidence is subsequently incorporated during reranking. To prevent data leakage, retrieval is restricted to historical occurrences permitted by the current data partition, excluding the target CVE itself.

4.2.2. Metric-Aware Occurrence Reranking

A candidate that is globally similar to the target does not necessarily provide equally useful evidence for every CVSS metric. Exploitability metrics mainly depend on how the vulnerable functionality is reached and triggered, whereas Scope and the impact metrics require evidence about component roles, system boundaries, and project-level consequences. OERA-CVSS, therefore, assigns each candidate two complementary relevance scores rather than relying on a single global ranking.
Exploitability-Oriented Relevance
For Attack Vector (AV), Attack Complexity (AC), Privileges Required (PR), and User Interaction (UI), OERA-CVSS compares the project-side trigger code of the target and candidate occurrences. It combines (i) semantic code similarity obtained from Jina embeddings, (ii) structural similarity between normalized code-token sequences, and (iii) lexical similarity between their code-token sets. Semantic similarity is computed from code embeddings, structural similarity measures sequence-level correspondence, and lexical similarity uses token-level Jaccard overlap. Lexical similarity captures overlap in API names, arguments, and other code tokens. The exploitability-oriented score is
S exp ( q , o i ) = w code S trigger sem ( q , o i ) + w str S str ( q , o i ) + w lex S lex ( q , o i ) ,
where S trigger sem denotes the cosine similarity between the trigger-code embeddings, and S lex denotes their token-level Jaccard similarity. The term S str measures structural similarity, while the three weights control the contributions of semantic, structural, and lexical evidence. The notation distinguishes the semantic similarity used in reranking from S code ret used for initial retrieval; both are based on trigger-code representations. A high S exp , therefore, indicates that two occurrences expose similar triggering structures and concrete usage patterns.
Impact-Oriented Relevance
For Scope (S), Confidentiality (C), Integrity (I), and Availability (A), OERA-CVSS instead compares the semantic contexts of the affected components and host projects. Although Scope is not itself an impact metric, determining whether exploitation crosses a security-authority boundary also depends on component roles and system boundaries. It is, therefore, grouped with the impact-oriented evidence. The corresponding score is
S imp ( q , o i ) = w comp S comp ( q , o i ) + w proj S proj ( q , o i ) ,
where S comp measures the semantic similarity between component descriptions and S proj measures the similarity between project descriptions. This score favors historical occurrences whose affected components play similar functional roles and whose host projects may face similar security consequences.
The unified candidate pool is sorted separately by S exp and S imp in descending order to select the respective top-d demonstration sets:
D exp ( q ) = Top d , o i ∈ C ( q ) S exp ( q , o i ) , D imp ( q ) = Top d , o i ∈ C ( q ) S imp ( q , o i ) .
The five reranking weights balance semantic, structural, lexical, component-level, and project-level similarities. Before the demonstrations are used, low-relevance candidates are filtered, and at most d valid examples are retained per channel. The weights and demonstration counts are selected using validation data and held fixed during testing. In the implementation, top_k_retrieval limits demonstrations returned per channel after reranking, while d (num_demos) limits valid examples in the final prompt. Both differ from the initial retrieval candidate counts k c and k d . A historical occurrence may rank differently for exploitability and impact assessment.

4.2.3. Retrieval-Augmented CVSS Reasoning and Fusion

The exploitability- and impact-oriented demonstration sets are used separately with the target occurrence to construct two prompts. The selected cases serve as in-context demonstrations. Prior studies have examined relevance-based demonstration selection and its effects on ICL [32,33,34,35,36], including retrieval-enhanced vulnerability assessment [12,13].
The retrieved occurrences serve as historical references for structured CVSS reasoning. Exploitability-oriented demonstrations primarily support the assessment of AV, AC, PR, and UI, whereas impact-oriented demonstrations provide contextual evidence for S, C, I, and A. The two groups of metrics are predicted independently using different input evidence.
Exploitability-Oriented Reasoning
The exploitability channel constructs its prompt using D exp ( q ) . Each demonstration contains trigger code, a trigger description, the corresponding AV, AC, PR, and UI labels, and the official exploitability subscore. For the target occurrence, the LLM uses trigger code, the trigger description, and business context to predict the four exploitability metrics:
v ^ exp = AV ^ , AC ^ , PR ^ , UI ^ .
Impact-Oriented Reasoning
The impact channel constructs its prompt using D imp ( q ) . Each demonstration contains a trigger description, the corresponding S, C, I, and A labels, and the official impact subscore, without code snippets. For the target occurrence, the LLM uses the trigger description and business context to predict the four impact-related metrics:
v ^ imp = S ^ , C ^ , I ^ , A ^ .
The two channels perform inference independently, followed by normalization and validation of the predicted metric labels. Their outputs are combined into the complete CVSS v3.1 Base metric vector, denoted by v ^ OERA . Figure A3 in Appendix C shows the two prompts side by side, each with a retrieved demonstration, target input, and corresponding metric output. The displayed case records the dual-channel ICL result before auxiliary probability fusion.
To incorporate complementary evidence, we introduce a description-based auxiliary branch that predicts class probabilities for each CVSS Base metric using CVSS-BERT with the prajjwal1/bert-small backbone (hidden size 512, four Transformer layers, and eight attention heads). The discrete OERA-CVSS prediction is represented as a one-hot vector and combined with the auxiliary probabilities through weighted fusion:
y ^ l = arg max c ∈ Y l ( 1 − λ f ) p l OERA ( c ) + λ f p l desc ( c ) ,
where p l OERA ( c ) is the one-hot representation of the OERA-CVSS prediction, and  p l desc ( c ) is the auxiliary classifier’s predicted probability for class c. In each outer fold, a Training-only checkpoint is trained on the Training partition, and its Validation probabilities are used to select λ f . With λ f fixed, the classifier is refitted on Development (Training ∪ Validation), and the resulting checkpoint supplies the Test probabilities for the primary results. The two checkpoints share the same architecture, hyperparameters, and input representation, but differ in training partition and learned weights.
The eight fused metrics are then used to calculate the Base Score and severity level according to the official CVSS v3.1 scoring procedure [3].

5. Experiments

This section evaluates OERA-CVSS through five research questions covering comparative performance, component contributions, cross-model robustness, performance across instance origins, and retrieval parameter sensitivity.

5.1. Research Questions

We investigate five research questions to assess OERA-CVSS, its component contributions, and the sensitivity of its retrieval procedure.
  • RQ1: Comparative Performance. How does OERA-CVSS compare with existing automated vulnerability assessment methods in predicting CVSS Base metrics, estimating Base Scores, and classifying severity levels?
  • RQ2: Ablation Study. How do vulnerability occurrences, multi-view retrieval, metric-aware reranking, and lexical and syntactic similarity contribute to CVSS assessment?
  • RQ3: Cross-Model Robustness. Does the full OERA-CVSS framework consistently improve predictions over zero-shot inference across different LLM backbones?
  • RQ4: Performance Across Instance Origins. How does OERA-CVSS perform on already-vulnerable and injected instances?
  • RQ5: Retrieval Parameter Sensitivity. How do the number of demonstrations, per-channel demonstration return limit, and dual-channel similarity weights affect Full OERA-CVSS? Do validation preferences carry over to held-out evaluation?
In addition, we conduct a supplementary component-disjoint five-fold evaluation on the same 804 CVEs to examine the sensitivity of the primary comparison to component overlap and the performance of transferred retrieval configurations on unseen components. This assessment complements RQ1; its protocol, results, and limitations are reported in Section 5.10. We select CVSS-BERT (2025) as the principal supervised comparator because it achieves the strongest overall baseline performance in RQ1, with the highest Metric Macro-F1 and Severity Macro-F1 and the lowest Base Score MAE among the external baselines.
All research questions use CVE-level five-fold evaluation. RQ4 uses frozen seed-42 OOF predictions. The validation parameter analysis in RQ5 uses seeds 42, 2026, and 3407, each independently generating a CVE-level five-fold partition, yielding 15 outer-fold validation results. Its fixed-weight held-out comparison uses only the 804 seed-42 OOF predictions. This three-seed summary applies only to the validation analysis and does not imply three repeated runs for every RQ. The resampling protocol and scope of the RQ5 comparisons are specified in Section 5.9.

5.2. Dataset

We evaluate OERA-CVSS on the vulnerability occurrence dataset constructed in Section 4.1.1, covering third-party component vulnerabilities in the Java/Maven and Python/PyPI ecosystems. The evaluation focuses on general-purpose software that can also be used in low-altitude systems, rather than on a dedicated low-altitude setting. Each occurrence includes a CVE description, vulnerability-related code, project-side trigger code, and functional context, together with the corresponding CVSS v3.1 Base metrics, score, and severity. After filtering and consistency checks, the final dataset contains 804 unique CVEs spanning identifier years 2010–2026, as shown in Figure 2. Appendix G provides the complete component list, ecosystem and project counts, the full first-label CWE distribution, and construction-stage counts with explicit units and exclusion reasons.
Figure 2. Distribution of CVE identifier years in the 804-CVE cohort. (a) Annual CVE counts stacked by CVSS severity; (b) annual severity counts and within-year proportions. The identifier year is not necessarily the disclosure year.
Figure 3 shows the distribution of severity levels and Base Scores. The dataset contains 82 Low (10.2%), 289 Medium (35.9%), 308 High (38.3%), and 125 Critical (15.5%) CVEs. Base Scores range from 2.5 to 10.0, with a mean of 6.79, a standard deviation of 2.05, a median of 7.25, and an interquartile range of 5.50–8.10. The distribution is uneven across severity levels and CVE identifier years. Therefore, we adopt severity-stratified cross-validation to reduce differences in class distributions across folds. A two-reviewer audit of 60 occurrences is reported in Appendix I, Table A32, separating final assessments from initial inter-rater agreement.
Figure 3. CVSS v3.1 severity and Base Score distributions in the 804-CVE evaluation cohort. (a) Severity counts and proportions; (b) Base Score histogram with 1-point bins and the cohort mean indicated by a dashed line.

5.3. Experimental Setup

Main scoring model. The main experiments use deepseek-v4.1-flash-1017, combining efficient inference with in-context learning and structured output for the eight CVSS Base metrics. The scoring configuration disables thinking; the injection requests use the endpoint’s default thinking behavior. The separate RQ3 configurations are specified below.
Model versions and release dates. RQ3 uses four models through the Alibaba Cloud Model Studio compatible API in the Beijing region. The model identifiers in the saved responses match those requested. Table 1 lists the identifiers and their documented release or service-availability dates; these dates are not used as training cut-offs.
Table 1. Model identifiers and documented release or service-availability dates.
Data partitioning and cross-validation. To reduce dependence on a single data split, we adopt stratified five-fold cross-validation at the CVE level over 804 unique CVEs. All occurrences of the same CVE are assigned to the same partition, with stratification based on severity. Each outer fold contains 160 to 161 test CVEs and 643 to 644 development CVEs. Within each development partition, 80 CVEs are selected through stratified sampling for validation, leaving 563 to 564 CVEs for training. The validation set is used for hyperparameter selection, including demonstration counts, per-channel demonstration return limits, and reranking weights. Once the configuration is fixed, models are refitted or retrieval knowledge bases are rebuilt using the complete development partition. All methods share identical data splits, and test CVEs are excluded from training, retrieval, and configuration selection.
Result aggregation. Each CVE appears in the test set exactly once across the five folds. We concatenate the test predictions into 804 out-of-fold (OOF) predictions and compute the overall evaluation metrics on the combined results rather than averaging the metrics across individual folds.

Statistical Analysis and Uncertainty Estimation

Confidence intervals. We bootstrap frozen OOF predictions at the CVE level and use the 2.5th and 97.5th percentiles to construct 95% confidence intervals. Methods evaluated on the same CVEs are resampled jointly, with both metrics and their difference recomputed in each resample. Severity comparisons use common valid CVEs. Table notes specify difference directions and evaluation protocols.
Significance tests. Paired permutation tests randomly exchange predictions between methods within each CVE, swapping the eight-metric vector as a whole. For Holm-adjusted comparisons, families are defined by experimental group, metric, and comparator; significance is assessed at adjusted p < 0.05 .
Statistical methods follow the comparison objective: method and configuration comparisons use paired analyses, instance-origin comparisons use independent resampling within groups, and parameter variation across partitions is summarized descriptively; multiple-comparison correction follows the family defined for each experiment.
Paired comparisons use 5000 CVE-level bootstrap resamples and 10,000 two-sided paired permutations; Holm correction follows the comparison families specified for each experiment.
Statistical settings.
  • RQ1: Marginal intervals use 5000 bootstrap resamples; paired statistics and comparison families appear in Appendix D.
  • RQ2: Marginal intervals use 5000 bootstrap resamples. All reported paired comparisons, including Top-1, use 5000 bootstrap resamples and 10,000 two-sided permutations. Applicable variants and Holm families appear in Appendix A.
  • RQ3: The four backbone-specific differences in Metric Macro-F1 use 5000 paired bootstrap resamples and 10,000 paired permutations, with Holm correction across these four comparisons.
  • RQ4: Each origin group is independently resampled 5000 times to estimate group performance and between-group difference intervals, without multiple-comparison adjustment (Appendix E).
  • RQ5: Full OERA-CVSS is evaluated with fusion coefficients frozen, reporting validation means and sample SDs across independently generated five-fold partitions for seeds 42, 2026, and 3407. Fixed-weight held-out comparisons use 804 seed-42 OOF predictions and 2000 paired bootstrap resamples; severity comparisons use common valid CVEs. Intervals are unadjusted for multiple comparisons (Appendix F).

5.4. Evaluation Metrics and Statistical Analysis

Evaluation tasks and metrics. We evaluate three aspects of CVSS assessment: metric prediction, score estimation, and severity classification. For CVSS metric prediction, we report Accuracy, Macro-F1, and Matthews correlation coefficient (MCC), averaged across the eight CVSS v3.1 Base metrics. Vector Exact Match (VEM) measures the proportion of CVEs with all eight metrics correctly predicted. For score estimation, we use mean absolute error (MAE) and root mean squared error (RMSE) to evaluate Base Scores, whether predicted directly or derived using the official CVSS formula [3]. Severity classification is evaluated using Accuracy, Macro-F1, and MCC over four classes: Low, Medium, High, and Critical. All MCC values are reported as coefficients rather than percentages. The primary outcomes are Metric Macro-F1, Base Score MAE, and Severity Macro-F1; the remaining reported outcomes are secondary.
Statistical analysis. Confidence intervals, paired tests, and their RQ-specific scope are described in Section Statistical Analysis and Uncertainty Estimation. Comparison directions, evaluation protocols, and comparison families are specified in the corresponding result tables and appendices.

5.5. RQ1: Comparative Performance

Baseline methods. We select six representative method families covering LLM-based metric prediction, supervised metric classification, and retrieval-augmented severity classification, comparing each method on its supported outputs. Full OERA-CVSS denotes the metric-level probability fusion method. Complete RQ1 results and statistical analyses are provided in Appendix D.
Based on their original prediction targets, the baselines are divided into the following two categories.
(1) CVSS metric prediction methods. JEV-decision [20] uses TypeSafe Jev to make independent discrete decisions from vulnerability descriptions and derive Base Scores. Since the original Jev weights and local deployment implementation are unavailable, we adapt its decision workflow using an LLM, retaining the metric questions, candidate values, and scoring functions, for independent constrained prediction of the eight CVSS v3.1 Base metrics, without reproducing Jev’s native probability calibration. AutoCVSS [21] studies zero-shot, few-shot, and retrieval-augmented CVSS prediction. We evaluate its zero-shot vector prediction and retrieval-augmented few-shot settings using DeepSeek to predict the eight Base metrics. The retrieval-augmented few-shot setting is denoted AutoCVSS-FewShot-RAG. CVSS-BERT (2021) [9] and CVSS-BERT (2025) [18] both use eight independent BERT classifiers. The difference is that the former selects the training duration by Validation Macro-F1, whereas the latter uses a fixed frozen/unfrozen training schedule with class balancing. Both use BERT-Small and are retrained locally per fold. All these metric prediction methods derive Base Scores and severity levels from the predicted vectors.
(2) Severity classification methods. SVA-ICL [12] selects historical vulnerabilities as in-context examples based on code and description similarity. We retain its example-selection and severity-prediction workflow, replacing the original CodeBERT encoder with Jina code embeddings. ReVul-CoT [13] combines vulnerability knowledge retrieval with chain-of-thought prompting. We retain its retrieval and reasoning workflow, replacing PostgreSQL/pgvector with a local index.
Unified comparison protocol. All methods use the 804 CVEs and five-fold splits in Section 5.3; training, parameter selection, and retrieval index construction use only the current fold’s Development partition. Retrieval indices are rebuilt per fold and exclude the query CVE. Adapted baselines retain the original tasks and core workflows, with model, encoder, and retrieval-backend replacements described above. Raw predictions and failure records are retained, and each method is evaluated on its supported tasks.

Results Analysis

Metric prediction and score estimation. As shown in Figure 4, Full OERA-CVSS achieves better point estimates of Metric Macro-F1, VEM, MAE, and RMSE than all five external baselines. Improvements in Metric Macro-F1 and MAE remain statistically significant after Holm correction. Compared with CVSS-BERT (2025), Metric Macro-F1 increases by 0.0201 and MAE decreases by 0.1078.
Figure 4. CVSS metric prediction and Base Score estimation. Short vertical ticks and diamonds indicate point estimates; horizontal bands show marginal 95% CIs, with dark blue highlighting OERA-CVSS (Full). All methods use 804 seed-42 OOF predictions; intervals use 5000 CVE bootstrap resamples. Axes do not start at zero; ↑/↓ indicate higher/lower is better. Complete values and paired statistics appear in Table A14, Table A15 and Table A16.
RMSE and severity classification. Full achieves the lowest RMSE point estimate, although only the improvement over AutoCVSS Zero-shot is statistically significant after Holm correction across the common family of five external comparators. For severity classification (Figure 5), Full significantly outperforms six of the seven external baselines in Accuracy, Macro-F1, and MCC, while its differences from CVSS-BERT (2025) are not significant. Overall, Full performs well in Base metric prediction and score estimation, with severity classification performance close to that of CVSS-BERT (2025).
Figure 5. Severity classification: (a) Accuracy, (b) Macro-F1, and (c) MCC. Markers, colors, and interval settings follow Figure 4. The evaluation cohort contains 804 CVEs, with four severity classes: LOW, MEDIUM, HIGH, and CRITICAL. Calculation details are provided in Appendix D. Axes do not start at zero; ↑ indicates higher is better. Complete values and paired statistics appear in Table A17 and Table A18.
Majority-class reference. To examine whether predictions rely only on label distributions, we construct a constant majority-class baseline from Development labels. This baseline achieves Metric Accuracy of 0.6748 but Macro-F1 of only 0.3134. Full improves Metric Macro-F1 by 0.3637, reduces MAE by 0.5643, and improves Severity Macro-F1 by 0.4969; these differences remain significant after Holm correction. This indicates that Full’s predictive performance goes beyond the simple majority-class rule. Complete values, confidence intervals, and statistical tests are provided in Appendix D.
  • Answer to RQ1. Full OERA-CVSS significantly outperforms the evaluated external baselines in both Metric Macro-F1 and Base Score MAE, and outperforms most baselines in severity classification. Moreover, Full significantly outperforms the majority-class prediction baseline.

5.6. RQ2: Ablation Study

Experimental setup. Six core ablations examine retrieval, multi-view evidence, reranking, lexical and structural similarity, and project-level occurrence evidence. Four supplementary variants are Desc-only, Code-only, Random demo, and w/o Fusion. Single-channel variants modify initial candidate retrieval, whereas w/o Multi-view modifies downstream evidence views. Three unfused single-field ablations additionally examine Trigger Description, Trigger Code, and Business Context. All experiments follow the same 804-CVE, five-fold OOF protocol; complete configurations appear in Table A1 and Table A2.
Figure 6 and Figure 7 show Metric Macro-F1, VEM, and MAE with Full as a common visual reference. Connecting segments indicate point-estimate gaps, and axes do not start at zero. Statistical tests use each experiment’s reference from the same fusion stage; complete intervals and paired results appear in Appendix A.
Figure 6. Core component ablations. Points show absolute metric Macro-F1, VEM, and Base Score MAE; horizontal segments connect each variant to the dashed full-model reference, which terminates at the Full point in the shaded bottom row. Axes do not start at zero. These point-estimate comparisons do not isolate the effect of each named component because the retrieval- and evidence-related variants use the unfused pipeline, whereas Full includes auxiliary fusion.
Figure 7. Single-field prompt input ablations. Points are absolute Metric Macro-F1, VEM, and MAE estimates; dashed lines mark OERA-CVSS (Full). All three ablations use the unfused pipeline. Complete intervals and paired tests appear in Table A4 and Table A7.

5.6.1. Core Component Ablations

Results and analysis. Overall, relevant historical examples and prediction fusion support CVSS assessment. Against the unfused reference, removing retrieval reduces Metric Macro-F1 by 0.069645 (95% CI [0.051334, 0.089362], Holm p = 0.0009 ) and increases MAE by 0.182960 ([0.079098, 0.285706], p = 0.0099 ). Random demonstrations degrade all nine metrics (adjusted p ≤ 0.0018 ), whereas neither Desc-only nor Code-only differs significantly on any metric after correction. Complete results are in Table A3, Table A8 and Table A9.
Compared with the full fusion method (Full), w/o Occ. reduces Metric Macro-F1 from 0.6771 to 0.6415 (−0.0356), lowers VEM from 0.3993 to 0.2015, and increases MAE from 1.0889 to 1.4863. Disabling CVSS-BERT probability fusion reduces Metric Macro-F1 to 0.5924 and VEM to 0.2114, while increasing MAE to 1.4049, demonstrating clear gains from probability fusion. Together with the retrieval ablation results within the unfused branch, these findings also support the benefits of historical-example retrieval for metric prediction and score estimation.
With w/o Fusion as the unfused reference, removing reranking reduces Metric Macro-F1 from 0.5924 to 0.5779 and VEM from 0.2114 to 0.2052, while increasing MAE from 1.4049 to 1.4766. After Holm correction, only the decrease in mean Metric Accuracy is statistically significant ( p = 0.0015 ). These results indicate metric-dependent benefits from reranking.

5.6.2. Prompt Input Ablations

Single-field removals. In the unfused pipeline, removing Trigger Description increases MAE from 1.404851 to 1.614428. The unfused reference exceeds this variant in severity Macro-F1 by 0.063478. Both differences have Holm-adjusted p = 0.0003 . None of the three single-field removals has a significant Metric Macro-F1 difference after correction.
Code-source comparison. Figure 8 compares Description + Trigger Code, Description + CVECode, and Full. All three configurations retain probability fusion, and Description denotes Trigger Description. The first two configurations remove Business Context: the exploitability channel receives project trigger code or component vulnerability code snippets, respectively, while the impact channel retains only the description. Full retains Business Context.
Figure 8. Target code-source comparison. Points show OOF performance, dashed lines mark Full, and horizontal segments indicate gaps to Full.
Results and analysis. Full achieves the highest VEM among the three configurations (0.3993), alongside Metric Macro-F1 of 0.6771 and MAE of 1.0889. Compared with Description + CVECode, Full raises VEM from 0.3881 to 0.3993 and lowers MAE from 1.0989 to 1.0889, with a similar Macro-F1 point estimate (0.6771 versus 0.6799). These point estimates highlight the complete method’s performance in vector matching and score estimation. CVECode improves Macro-F1 over Trigger Code by 0.005961 (95% CI [−0.001735, 0.014704], Holm p = 0.5811 ); its paired differences from Full are also statistically nonsignificant. Complete results appear in Table A10 and Table A11.

5.6.3. Top-1 Label Copy Diagnosis

Experimental setup. Historical demonstrations provide both vulnerability evidence and CVSS labels, so part of the full system’s performance may arise from label transfer between similar cases. To test whether copying the labels of the most similar historical case can match full OERA-CVSS, we reuse the same retrieval results to construct three Top-1 Copy rules requiring no training or LLM calls. The primary variant copies all eight metrics from the first exploitability-channel result. Two sensitivity variants either copy the complete vector from the first impact-channel result or combine AV/AC/PR/UI from the exploitability channel with S/C/I/A from the impact channel. All three are compared with OERA-CVSS (Full), including CVSS-BERT probability fusion, to assess the performance gap between direct label copying and the complete system.
Results and analysis. As shown in Figure 9, the three copy rules obtain Metric Macro-F1 values of 0.4976–0.5445 and MAE values of 1.6434–1.8311, compared with 0.6771 and 1.0889 for OERA-CVSS (Full). Impact Top-1 Copy achieves the highest Metric Macro-F1 and lowest MAE among the copy variants, indicating that historical labels retrieved by the impact channel carry useful predictive information. Relative to this variant, Full has 0.1326 higher Metric Macro-F1 and 0.5545 lower MAE. VEM increases from 0.2177 to 0.3993, a gain of 18.16 percentage points. These point estimates show that copying a single historical vector does not match the complete system’s metric prediction, vector matching, or score estimation performance.
Figure 9. Top-1 label copy diagnosis. Points are frozen seed-42 OOF estimates. All methods are evaluated within the same 804-CVE OOF cohort. Dashed lines mark OERA-CVSS (Full); horizontal segments show point-estimate gaps, not confidence intervals or statistical significance. Higher Metric Macro-F1, VEM, and severity Macro-F1 and lower MAE are better. Complete marginal intervals and comparison details are provided in Appendix A.3, Table A5.
Severity results and interpretation. Full obtains severity Macro-F1 of 0.6361, compared with 0.3596–0.4378 for the copy variants. Marginal intervals appear in Table A5. Supplementary paired tests show that Full significantly outperforms all three copy variants on all nine outcomes within their respective post-hoc Holm families (adjusted p ≤ 0.002999 ; Table A6). Historical label copying has predictive value but does not reproduce the complete system’s performance. Since Full combines retrieval-augmented prediction and probability fusion, these gaps neither decompose the causal contributions of individual components nor isolate LLM reasoning.   
  • Answer to RQ2. The ablations support the roles of relevant historical-example retrieval, demonstration selection, and probability fusion in the complete method. Within the unfused branch, removing retrieval reduces Metric Macro-F1 by 0.0696 and increases MAE by 0.1830, with both differences significant after Holm correction. CVSS-BERT probability fusion increases Metric Macro-F1 from 0.5924 to 0.6771, exceeding standalone CVSS-BERT’s 0.6570, and reduces MAE from 1.4049 to 1.0889. Occurrence evidence and metric-aware reranking show metric-dependent effects. Trigger Description is particularly important for Base Score estimation. Full also outperforms all three Top-1 label-copying strategies in metric prediction and score estimation, supporting the complete pipeline’s effective use of historical cases.

5.7. RQ3: Cross-Model Robustness

Experimental setup. To evaluate the applicability of OERA-CVSS across large language models, we select DeepSeek-V4.1-Flash-1017, Qwen3.8-Max, GLM-5.3, and Kimi-K3 and compare the full method with Zero-shot for each backbone. Full includes CVSS-BERT probability fusion, whereas Zero-shot uses only the corresponding LLM, without historical demonstrations or probability fusion. All experiments use the same 804 CVEs and five-fold splits. Retrieval parameters are selected on validation data using the original DeepSeek model without thinking and held fixed across the other models without retuning. For inference, we enable thinking mode, set reasoning effort to low and temperature to 0, and generate one prediction per CVE. The primary metric is the paired difference in eight-metric mean Macro-F1. We estimate 95% confidence intervals using 5000 bootstrap resamples and assess statistical significance using 10,000 paired permutations and Holm correction.
Results and analysis. As shown in Table 2, OERA-CVSS consistently improves Metric Macro-F1 across all four models, with gains ranging from 0.1252 to 0.1506. All paired 95% confidence intervals exclude zero, and all improvements remain significant after Holm correction. GLM-5.3 shows the largest improvement, at 0.1506. Despite differences in Zero-shot performance, all models achieve Metric Macro-F1 of approximately 0.68 with OERA-CVSS.
Table 2. Paired comparison of eight-metric mean Macro-F1 between zero-shot inference and OERA-CVSS across four language models. Positive differences favor OERA-CVSS.
Further analysis of the complete OOF results shows improvements in Metric Accuracy, MCC, and VEM for all four models, together with reductions in Base Score MAE and RMSE and improvements in Severity Macro-F1. Detailed values appear in Table A12 and Table A13.
  • Answer to RQ3. OERA-CVSS significantly improves Metric Macro-F1, reduces Base Score errors, and increases Severity Macro-F1 across all four backbones. All four models achieve Metric Macro-F1 of approximately 0.68 with the framework, demonstrating consistent effectiveness and similar predictive performance across the evaluated backbones.

5.8. RQ4: Performance Across Instance Origins

Experimental setup. We partition the 804 CVEs into already-vulnerable and injected instances and evaluate Full OERA-CVSS separately on each group using the frozen seed-42 five-fold OOF predictions. Origin labels are used only for post-hoc grouping, not for training, retrieval, or configuration selection. Between-group differences are defined as injected minus already_vulnerable. The 95% intervals for between-group differences are estimated using 5000 CVE-level bootstrap resamples drawn independently within each group. Table 3 summarizes the group-level performance.
Table 3. OERA-CVSS performance across instance origins.
Results and analysis. The two groups have Metric Macro-F1 values of 0.6328 and 0.6515, differing by 0.0188 (95% CI [ − 0.0133 , 0.0550]). No clear between-group difference is observed, indicating similar mean metric-prediction performance across the two instance origins. However, the injected group has VEM higher by 10.88 percentage points, MAE lower by 0.2679, and Severity Macro-F1 higher by 0.2887. The corresponding difference intervals all exclude zero, indicating clear differences in exact vector matching, score estimation, and severity classification.
Further analysis shows that the between-group severity gap is affected by class distributions. The already-vulnerable group contains only five LOW cases, compared with 77 in the injected group. Excluding LOW from the macro-average reduces the Severity Macro-F1 gap from 0.2887 to 0.1174. Other CVSS label and project compositions also differ between the groups; therefore, these results primarily reflect performance distributions across instance origins rather than an independent effect of the instance generation process itself.
  • Answer to RQ4. No clear between-group difference in Metric Macro-F1 is observed. Full obtains higher VEM and Severity Macro-F1 and lower MAE on injected instances. The severity difference partly reflects the class distributions.

5.9. RQ5: Retrieval Parameter Sensitivity

To assess the sensitivity of Full OERA-CVSS to retrieval configurations, we examine demonstration counts, per-channel return limits, and dual-channel similarity weights. We first compare parameter settings on validation data, then evaluate fixed weights against validation-selected configurations on held-out data. Both analyses reuse saved predictions with fusion coefficients λ f frozen, without additional LLM inference or parameter selection.

5.9.1. Validation Parameter Sensitivity

Experimental setup. Seeds 42, 2026, and 3407 each independently generate a five-fold partition, yielding 15 outer-fold validation results rather than repeated inference on a fixed partition. The original search includes demonstration counts { 1 , 3 , 5 } , per-channel return limits { 5 , 10 , 20 } , six exploitability-channel weight combinations, and three impact-channel weight combinations. Including an additional default weight combination yields 171 configurations per fold. For this analysis, we average over the other parameters in the balanced grid to obtain each setting’s fold-level Metric Macro-F1, then compute the mean and sample standard deviation (SD) across 15 folds. Here, top_k_retrieval limits demonstrations returned per channel after reranking, whereas num_demos controls the final prompt. Initial FAISS retrieval remains fixed at 20 code and 20 description candidates, merged and deduplicated into a shared pool; its size is not varied.
Results and analysis. Table 4 shows mean Metric Macro-F1 of 0.6671, 0.6688, and 0.6677 for one, three, and five demonstrations, respectively, with no monotonic improvement as demonstrations increase. Return limits of 5, 10, and 20 produce identical results in every fold: because num _ demos ≤ 5 ≤ top _ k _ retrieval , the limit does not change the examples entering the prompt.
Table 4. Validation parameter sensitivity of Full OERA-CVSS: mean and sample SD across 15 folds.
Equal impact weights and project descriptions alone yield similar means, while component descriptions alone score slightly lower. The six exploitability weight settings range from 0.6668 to 0.6696, with low ranking consistency across folds (mean Kendall’s τ = 0.048 over 105 fold pairs). Mean differences between settings reach at most approximately 0.006, compared with a cross-fold SD of approximately 0.033. Thus, performance varies little within the evaluated coarse grid, with no consistently dominant weight configuration.

5.9.2. Held-Out Comparison of Fixed Weights

Experimental setup. Using 804 frozen seed-42 OOF predictions, we compare fixed default weights, project descriptions alone, and component descriptions alone with OERA-CVSS (Full), whose retrieval configuration is selected on each fold’s validation data. Fusion coefficients remain unchanged. Differences are fixed-setting minus Full.
Results and analysis. Metric Macro-F1 differences range from − 0.0007 to + 0.0029 , and MAE differences from − 0.0021 to + 0.0233 ; all intervals include zero. VEM and severity also mostly show small changes. The exception is component-only retrieval, which reduces VEM by 0.0224 (95% CI [ − 0.0361 , − 0.0087 ]), the only interval excluding zero among the three configurations and four metrics. Full OERA-CVSS, therefore, shows limited sensitivity to the evaluated fixed weights, although removing project descriptions entirely can reduce exact vector matching. Intervals including zero do not establish equivalence. Table 5 reports the Metric Macro-F1 and MAE differences.
Table 5. Fixed retrieval weights relative to Full OERA-CVSS: differences and 95% confidence intervals.
  • Answer to RQ5. Within the evaluated parameter grid and with fusion coefficients frozen, Full OERA-CVSS shows limited sensitivity to demonstration counts and similarity weights, with no consistently dominant validation weight setting. The per-channel return limit does not change the prompt at the evaluated demonstration counts. In held-out fixed-weight comparisons, only component-only retrieval shows a clear VEM decrease; all other difference intervals include zero.

5.10. Supplementary Component-Disjoint Robustness Evaluation

Experimental setup. In the original CVE-disjoint five-fold split, 796/804 (99.0%) test CVEs share components with Development, and 746/804 (92.8%) share host projects. To assess cross-component generalization, we add a seed-42 component-disjoint five-fold experiment on the same 804 CVEs, grouped by component. The five test folds contain 278, 132, 132, 131, and 131 CVEs, respectively, with TensorFlow accounting for 278. Training, Validation, and Test components are mutually disjoint. CVSS-BERT (2025) is retrained per fold; OERA-CVSS reuses the retrieval configurations selected in the original five-fold experiment and selects fusion coefficients on the new Validation data. Table 6 compares performance under the two evaluation splits.
Table 6. Performance comparison between the CVE-disjoint and component-disjoint five-fold splits.
Results and analysis. Both methods deteriorate under component isolation. OERA-CVSS’s Metric Macro-F1 decreases from 0.6771 to 0.5487, and CVSS-BERT (2025) decreases from 0.6570 to 0.4271. Under the component-disjoint setting, OERA-CVSS exceeds CVSS-BERT (2025) in Metric Macro-F1 by 0.1216 (95% CI [0.1006, 0.1423]) and reduces MAE by 0.4459 (95% CI [0.3132, 0.5789]), while all three paired severity intervals include zero. Excluding TensorFlow leaves OERA-CVSS with Metric Macro-F1 of 0.556. Averaging equally over the 37 components retains OERA-CVSS’s higher Metric Macro-F1 (0.4152 versus 0.3876), but its Severity Macro-F1 is slightly lower (0.2073 versus 0.2427).
Overall, OERA-CVSS retains advantages over CVSS-BERT (2025) in metric prediction and score estimation under component isolation, although both methods are affected by changes in component distribution. Because OERA-CVSS reuses the retrieval configurations from the original five-fold experiment, this evaluation mainly characterizes the cross-component transfer of existing configurations.

6. Discussion

The experiments demonstrate the roles of retrieval augmentation and probability fusion in CVSS metric prediction and score estimation. This section examines the main findings in terms of internal, construct, and external validity.

6.1. Internal Validity

The primary experiment uses CVE-disjoint five-fold cross-validation, with an independent validation set for configuration selection. Test CVEs are excluded from knowledge-base construction and parameter selection in the corresponding fold, yielding 804 OOF predictions. This design separates training, validation, and test data, reducing test-information leakage and configuration-selection bias.
Statistical analysis uses frozen OOF predictions and bootstrap confidence intervals to quantify uncertainty in the results. RQ5 further examines parameter performance across independent five-fold partitions generated with seeds 42, 2026, and 3407, providing additional evidence of configuration stability. The served API models and the coverage of their pretraining data may affect reproducibility over time. Pinning model versions and conducting repeated inference could further assess result stability.

6.2. Construct Validity

This study addresses CVE-level CVSS v3.1 Base assessment by predicting the eight Base metrics and calculating the Base Score and severity using the official formula [3]. Occurrence evidence supplies project-side triggering conditions, code implementations, and functional context, allowing prediction to account for how vulnerabilities manifest in specific software. Temporal metrics, Environmental metrics, and deployment-specific risk constitute distinct assessment objectives that could be explored by extending the framework.
The quality of occurrence evidence directly affects its assessment value. The current construction process combines LLM analysis, code anchors, and compilation or syntax checks, with manual auditing used to assess generation quality. The audit in Appendix I reports that all 20 already-vulnerable occurrences passed; among 40 injected occurrences, 10 passed, 18 failed, and 12 were inconclusive. These findings indicate good evidence reliability among the audited already-vulnerable occurrences, while injected occurrences require more rigorous construction and verification mechanisms. Runtime validation, provenance tracking, and the retention of multiple occurrences could improve evidence quality and coverage.
Ablation experiments further reveal the contributions of different evidence sources and modules. Within the unfused branch, retrieving relevant historical demonstrations improves metric prediction and score estimation. Building on these retrieval-guided predictions, CVSS-BERT probability fusion combines them with supervised class probabilities and is a key contributor to the full method’s performance. Metric-aware reranking also provides a significant gain in mean Metric Accuracy within the unfused branch. For the other metrics, reranking differences in Macro-F1, VEM, and MAE are not statistically significant after Holm correction. CVECode shows no significant differences from Trigger Code or Full under fixed retrieval and fusion configurations.

6.3. External Validity

The dataset covers Java/Maven and Python/PyPI components in public GitHub repositories, with candidate projects selected from the top-1000 repositories by popularity. It captures component-usage scenarios in mainstream open-source projects. Across the four evaluated large language models, OERA-CVSS yields consistent predictive gains with fixed retrieval configurations, demonstrating its adaptability to different model backbones.
The primary experiment evaluates prediction for new vulnerabilities through CVE-disjoint splits. However, components associated with 99.0% of test CVEs and 92.8% of their host projects are represented in Development, so the results mainly reflect new-vulnerability assessment within familiar software ecosystems. The component-disjoint experiment further examines cross-component generalization: OERA-CVSS retains metric-prediction and score-estimation advantages over locally retrained CVSS-BERT (2025), whereas paired severity intervals include zero and the severity ordering changes under equal weighting of components. These findings indicate task-dependent benefits in cross-component transfer.
The component-disjoint experiment separates training data and retrieval pools by component while reusing the retrieval configurations selected in the primary experiment, thus evaluating cross-component transfer with fixed configurations. Given the remaining host-project overlap of 60.1%, project-disjoint evaluation and independent configuration selection would provide a more complete understanding of generalization to unfamiliar software environments. Extending this evaluation to software dependencies in AI/6G low-altitude air–ground systems will also require domain-specific data and validation.

7. Conclusions

In this work, we present OERA-CVSS, an occurrence-enriched retrieval-augmented framework for automated CVSS v3.1 Base assessment. OERA-CVSS links CVE information, vulnerability-related code, project-side trigger code, and software functional context to construct a knowledge base of project-level vulnerability occurrences. It retrieves relevant historical cases through complementary description- and code-based views, then reranks them according to the evidence needed for exploitability- and impact-related metrics. The selected cases serve as in-context demonstrations for an LLM to predict the eight CVSS v3.1 Base metrics. The metric predictions are fused with class probabilities from a description-based CVSS-BERT model, and the Base Score and severity level are derived from the fused vector using the official scoring procedure.
We evaluate OERA-CVSS on 804 unique CVEs using stratified CVE-disjoint five-fold cross-validation, with a separate validation set for configuration selection. The results show that OERA-CVSS outperforms the evaluated external baselines in metric prediction and score estimation. Ablation experiments further explain this overall performance: probability fusion increases Metric Macro-F1 from 0.5924 to 0.6771, exceeding standalone CVSS-BERT’s 0.6570. Retrieval benefits for metric prediction and score estimation are supported by ablations within the unfused branch. Metric-aware reranking significantly improves mean Metric Accuracy.
Further experiments examine the method’s consistency and scope across model backbones, parameter settings, and software components. The full fusion system yields consistent predictive gains over zero-shot inference across four large language models. With fusion coefficients frozen, the complete method also shows limited sensitivity to demonstration counts and reranking weights within the evaluated grid. When the existing retrieval configurations are transferred to a component-disjoint split, OERA-CVSS retains metric-prediction and score-estimation advantages over locally retrained CVSS-BERT (2025), while severity-classification results vary with the aggregation scheme. Together, these findings support the framework’s effectiveness for structured CVSS assessment and motivate further evaluation with configuration selection on component-disjoint validation data.
Despite these predictive gains, the manual audit found that, among 40 injected occurrences, 10 passed, 18 failed, and 12 were inconclusive, indicating limitations in the reliability of injected evidence. Future work will further develop the framework by improving evidence quality, applicability across software environments, and prediction reliability. Runtime validation and multiple project-level occurrences of the same CVE will be explored to improve the accuracy and coverage of vulnerability evidence. Building on this foundation, we will extend evaluation to additional software ecosystems and application scenarios such as AI/6G air–ground systems, and investigate adaptive demonstration selection and runtime-aware CVSS assessment to improve adaptability to different software environments. We will also examine stability across data splits and repeated inference, together with confidence calibration, to provide stronger evidence of prediction reliability for practical use.

Author Contributions

Conceptualization, Z.L., J.C., Z.C., J.L., H.L. and Q.H.; methodology, Z.L., J.C. and Q.K.; software, Q.K.; validation, Z.L., J.C. and J.L.; formal analysis, Z.C., H.L. and Q.H.; investigation, Z.L.; visualization, Q.K.; writing—original draft preparation, Z.L.; writing—review and editing, J.C., Z.C., J.L. and H.L.; supervision, Z.C., H.L. and Q.H. All authors have read and agreed to the published version of the manuscript.

Funding

This work was supported by the Science and Technology Project of State Grid Henan Electric Power Company: Research on Automatic Discovery and Assessment Technologies for Vulnerability Threats in Power System Terminals (52170226000H).

Institutional Review Board Statement

Not applicable.

Data Availability Statement

The core implementation is publicly available at https://github.com/b2eeze/OERA-CVSS (accessed on 19 November 2026). Data will be made available on request.

Conflicts of Interest

Zhuo Lv, Junfei Cai and Junchen Li are employed by the Electric Power Research Institute, State Grid Henan Electric Power Company. Qilong Kou is employed by Luoyang Power Supply Company, State Grid Henan Electric Power Company. The remaining authors declare no conflicts of interest. The funder provided financial support only and had no role in the study design, data collection, analysis or interpretation, manuscript preparation, or the decision to publish.

Appendix A. Supplementary Results for RQ2

This appendix provides configurations, complete five-fold OOF point estimates, marginal intervals, and paired inference for the ablations in Section 5.6. Results for the full OERA-CVSS method include probability fusion. The other retrieval, demonstration, evidence, and single-field target-input ablations were measured on the underlying unfused pipeline; its reference result is reported as w/o Fusion. The three target-input ablations are post-hoc exploratory experiments.

Appendix A.1. Ablation Configurations

Table A1 summarizes six core ablations and four supplementary variants; Table A2 covers three single-field removals.
Table A1. Core component and supplementary ablation configurations.
Table A2. Target prompt-input ablation configurations (post-hoc).
The w/o Multi-view variant changes downstream evidence views, whereas Desc-only and Code-only change initial candidate retrieval sources. The Top-1 label-copy diagnosis appears in Appendix A.3, Table A5.

Appendix A.2. Detailed Ablation Results

All nine metrics use 5000 CVE percentile bootstrap resamples for marginal intervals (frozen seed-42 OOF). Paired comparisons use 5000 bootstrap resamples and 10,000 two-sided permutations. For higher-is-better metrics, Δ = reference minus variant; for MAE/RMSE, Δ = variant minus reference. Positive differences favor the reference. Core Holm families contain six ablations and prespecified baselines for the same task; the families contain 9 comparisons for each metric-prediction outcome and VEM, 10 for each score-error outcome, and 12 for each severity outcome. Single-field and retrieval-source families each contain three variants per metric and remain separate post-hoc families. Marginal intervals are not multiplicity-adjusted. Severity follows the four-class protocol excluding None predictions; marginal estimates use each method’s valid set, and paired comparisons use common valid CVEs.
Table A3. Core and supplementary ablations: nine-metric OOF estimates and 95% intervals.
Table A4. Single-field prompt removals: OOF estimates and 95% intervals.

Appendix A.3. Detailed Top-1 Label-Copying Results

Top-1 Copy reuses each fold’s Development-only retrieval results without training, additional retrieval, or LLM calls. The primary variant copies exploitability top-1; sensitivity variants copy impact top-1 or combine AV/AC/PR/UI and S/C/I/A from the respective channels. The comparison reference is OERA-CVSS (Full), including probability fusion. Scores and severity are derived from the copied vectors.
Table A5. Top-1 label copying versus full OERA-CVSS: estimates and marginal 95% intervals.
Full significantly outperforms all three copy variants on all nine outcomes within their respective Holm families (adjusted p ≤ 0.002999 ), supporting the value of the complete pipeline beyond direct Top-1 label transfer. These differences reflect the combined effect of retrieval augmentation and probability fusion. The Top-1 paired diagnosis uses a separate post-hoc protocol. All nine outcomes use 5000 paired CVE bootstrap resamples and 10,000 two-sided paired permutations. Within each variant, Holm correction is applied separately to the three primary outcomes (Metric Macro-F1, Score MAE, and Severity Macro-F1) and the remaining six secondary outcomes, without pooling variants or entering the original prespecified families. Differences are Full minus Top-1 for classification and VEM, and Top-1 minus Full for MAE/RMSE; positive values favor Full. Severity is recomputed on common valid CVEs; marginal estimates remain in Table A5.
Table A6. Full OERA-CVSS versus Top-1 copying: paired differences, 95% intervals, and Holm-adjusted p-values.

Appendix A.4. Paired Single-Field Input Ablations

Table A7. Unfused reference versus single-field removals: paired differences, 95% intervals, and Holm p-values.

Appendix A.5. Paired Core and Retrieval-Source Ablations

Table A8. Unfused reference versus six core ablations: paired differences, 95% intervals, and Holm p-values.
Table A9. Unfused reference versus retrieval-source variants: paired differences, 95% intervals, and Holm p-values.

Appendix A.6. Target Code-Source Comparison

This subsection supplements Section 5.6.2. All configurations use the same retrieved demonstrations, model, and fusion settings. This post-hoc analysis is separate from the predeclared comparison family: for each metric, the two contrasts in Table A11 form a two-comparison Holm family.
Table A10. Code-source comparison: OOF estimates and marginal 95% intervals (seed 42).
Table A11. CVECode comparison: paired differences, 95% intervals, and p-values.
This comparison evaluates target-code substitution within a fixed retrieval and fusion configuration, with occurrence information retained in historical demonstrations and Trigger Description. CVECode comprises function or patch snippets without independent annotation of complete vulnerable functions, while 11 Trigger Code samples use Business Context to fill missing code.

Appendix B. Supplementary Results for RQ3

Detailed Out-of-Fold Results

In Table A12 and Table A13, DeepSeek, Qwen, GLM, and Kimi denote DeepSeek-V4.1-Flash-1017, Qwen3.8-Max, GLM-5.3, and Kimi-K3, respectively. The OERA-CVSS setting includes CVSS-BERT probability fusion; Zero-shot uses only the corresponding LLM, without historical demonstrations or probability fusion.
For the cross-model paired comparisons in Table 2, the raw p-values for DeepSeek-V4.1-Flash, Qwen3.8-Max, GLM-5.3, and Kimi-K3 are all 0.0001. Joint Holm correction across these four comparisons gives adjusted p-values of 0.0004 for all four models. Paired inference concerns Metric Macro-F1; the other outcomes are descriptive OOF comparisons.
Table A12 and Table A13 report results from the shared evaluation cohort of 804 CVEs. The OOF point estimates are calculated from valid predictions for each setting, whereas the paired results in Table 2 are calculated on common valid CVEs. The two summaries may, therefore, differ slightly. Derived severity metrics follow the four-class protocol, excluding predictions mapped to None.
Table A12. Complete OOF results for CVSS Base metric prediction across language models.
Table A13. Derived Base Score estimation and four-class severity classification across language models. Severity MCC is calculated after mapping scores to severity classes.
The largest reductions in MAE and RMSE are observed for GLM-5.3 (0.5418 and 0.4053), while DeepSeek shows smaller reductions (0.3175 and 0.2166). Derived severity Macro-F1 increases across all four backbones, by 0.2300 for DeepSeek, 0.2610 for Qwen, 0.2815 for GLM, and 0.2290 for Kimi.

Appendix C. Representative Occurrence and Prompt Examples

This appendix follows CVE-2017-15095 through candidate construction, source-level verification, and dual-channel CVSS prediction. The archived candidate uses Jackson 2.2.3 in apache/kylin at tag v0.6.2 and is recorded as injected. The exported vulnerability description concerns unsafe polymorphic deserialization enabled by Jackson default typing, which can permit code execution when additional exploitation conditions are met.

Appendix C.1. Component and Project Code

Figure A1 distinguishes the affected component API from project-side calls. The JsonUtil initializer enables default typing, while CubeController passes cubeDescData to JsonUtil.readValue. The scoring code input is mapper.enableDefaultTyping();. The figure adds the official Jackson 2.2.3 ObjectMapper source and controller call path to explain the component mechanism and project context; it is unverified whether the upstream excerpt was included in the historical scoring input.
Figure A1. Component API and project-side call evidence for CVE-2017-15095. Arrow 1 denotes the initialization call to the component API; arrow 2 denotes the controller call to the project deserialization utility.

Appendix C.2. Verification Prompt and Recorded Assessment

Figure A2 pairs a prompt example reconstructed from the method description, source code, patch, version, and static traces with the independently archived Verification Agent output. The original request was not archived. The recorded verdict is Yes, with Agent-reported confidence high and supporting source evidence. Verification in this case was static, with no runtime exploitation recorded.
Figure A2. Illustrative Verification Agent prompt and independently recorded assessment for the candidate. Repository metadata is shown outside the input.

Appendix C.3. Independent Scoring Prompts and Outputs

Figure A3 shows the independently constructed exploitability and impact prompts from the archived fold-4 prediction. Each channel used five retrieved demonstrations; the figure displays Demo 1 and marks Demos 2–5 as omitted. The exploitability demonstration is CVE-2019-14379, with code, description, AV/AC/PR/UI labels, and exploitability subscore 3.9. The impact demonstration is CVE-2018-19360, with a description, S/C/I/A labels, and impact subscore 5.9, without a code field. Target inputs contain no target ground-truth labels. The impact prompt receives the trigger description and business context, whereas the exploitability prompt additionally receives target code. Descriptions and instructions are condensed for presentation.
The recorded channel outputs form the vector shown in Figure A3, yielding a formula-derived Base Score of 9.8 and severity CRITICAL. This result represents the dual-channel output before fusion. The PR:N prediction conflicts with the authentication requirement identified during verification.
Figure A3. Two independent scoring prompts and their corresponding outputs. Tinted blocks contain historical demonstrations; white regions contain the target inputs. Each channel predicts its own four metrics. The lower panel shows the CVSS formula calculation from the combined labels.

Appendix D. Supplementary Results for RQ1

This appendix retains all RQ1 marginal intervals, paired comparisons, and majority-class diagnostics. Marginal intervals use 5000 CVE percentile bootstrap resamples of frozen seed-42 OOF predictions and the 2.5th/97.5th percentiles. Full uses the fused configuration. AutoCVSS-FewShot-RAG denotes the evaluated setting excluding same-component demonstrations. Paired comparisons use the families specified below. All statistical inferences are conditional on the frozen OOF predictions. Severity excludes None predictions: marginal results use method-specific valid sets, while paired results are recomputed on their common valid CVEs.

Appendix D.1. Complete Performance and Marginal Intervals

Table A14. CVSS Base metric prediction: point estimates and marginal 95% intervals.
Table A15. Derived Base Score estimation: point estimates and marginal 95% intervals.

Appendix D.2. Paired Metric and Score Comparisons

Table A16. Full minus five external comparators: paired differences, 95% intervals, and Holm p-values.

Appendix D.3. Severity Results and Paired Comparisons

Table A17. Severity classification: point estimates and marginal 95% intervals.
Table A18. Full minus seven external comparators: paired severity differences, 95% intervals, and Holm p-values.

Appendix D.4. Majority-Class Reference

Majority-class uses each fold’s Development labels to select the most frequent class for each metric and severity, then predicts that class on Test. It uses no input features, training, retrieval, or LLM. This is a class-prior reference. Constant predictions yield MCC zero under the evaluation convention in every resample, producing the interval [0, 0]. Table A19 reports paired comparisons with the majority-class reference.
Table A19. Full minus Majority-class: paired differences, 95% intervals, and Holm p-values.

Appendix E. Complete Confidence Intervals for RQ4

This appendix reports Full OERA-CVSS group performance and between-group differences on frozen seed-42 OOF predictions. Intervals use 5000 CVE percentile bootstrap resamples, taking the 2.5th and 97.5th percentiles. The two groups are resampled independently at the CVE level, with group metrics and between-group differences recomputed in each resample. These intervals are not adjusted for multiple comparisons. This is an observational comparison of occurrence-origin groups. Table A20 reports group estimates and between-group differences.
Table A20. Performance by instance origin and differences (injected minus already-vulnerable): estimates and 95% intervals.

Appendix F. Complete Parameter Sensitivity Statistics for RQ5

Appendix F.1. Validation Variation

Table A21. Full OERA-CVSS parameter statistics across 15 validation folds.

Appendix F.2. Held-Out Paired Intervals

Table A22. Fixed retrieval weights minus Full OERA-CVSS: complete paired differences and 95% confidence intervals.

Appendix G. Dataset Composition and Construction Accounting

This appendix describes the frozen 804-CVE evaluation cohort and the available construction records. Each retained CVE contributes one representative occurrence. Table A23 lists 40 selected components: 37 with retained CVEs and three with none; the final cohort spans 125 distinct host projects. These are general-purpose software components, not a separately validated low-altitude deployment dataset.

Appendix G.1. Component and Ecosystem Composition

Table A23. Complete component inventory and ecosystem totals.

Appendix G.2. CWE Distribution

Table A24 reports all 70 first-label categories in the frozen metadata. For records with multiple CWE labels, the first stored label provides a consistent counting rule; the table describes recorded labels. Each CVE contributes exactly once and percentages use 804 as the denominator. There are 327 CVEs (40.67%) with a specific CWE label; 477 (59.33%) have nonspecific or missing labels: UNKNOWN (411), NVD-CWE-noinfo (52), and NVD-CWE-Other (14). The label coverage limits conclusions about weakness diversity; missing labels are not inferred from model-generated descriptions.
Table A24. Complete CWE distribution using the first stored label per CVE.

Appendix G.3. Construction Stages and Exclusions

Table A25 reports counts from the available upstream database, matching and injection outputs, triage directories, and successive dataset snapshots. Stages count records, unique combinations, directories, dataset rows, and CVEs in their respective units. One combination may have multiple injection records. The CVEs excluded from the final cohort are listed below.
Table A25. Construction accounting with explicit units.
Among the 809 unique CVEs after the Yes-verdict filter, CVE-2023-45960 and CVE-2024-7804 were excluded because their NVD records were rejected, leaving 807 CVEs after representative-occurrence selection. CVE-2012-5616, CVE-2014-2600, and CVE-2026-56130 were then excluded because their labels could not be verified, yielding 804 CVEs. Sixteen retained rows initially lacked embedded code; code completion filled these fields without changing the final cohort membership. All final 804 CVEs have a recorded Yes outcome from Agent-assisted static verification. This provides a consistent source-level screening criterion for cohort inclusion; manual sample audit results appear in Appendix I. Table A26 summarizes the raw injection statuses.
Table A26. Recorded statuses of the raw injection entries.

Appendix H. Component-Disjoint Robustness Results

This post-hoc evaluation complements RQ1. All metric and score point estimates use 804 merged OOF predictions. OERA-CVSS uses probability fusion throughout this appendix. CVSS-BERT (2025) is retrained locally without loading its authors’ released weights. Component-disjoint marginal and paired intervals use 5000 CVE percentile bootstrap resamples (2.5th/97.5th percentiles). Original RQ1 marginal intervals retain their 5000-resample settings. These intervals do not account for within-component dependence or uncertainty from refitting and repeated inference.
In Table A27, Table A28 and Table A29, CVE denotes the primary CVE-disjoint split; Component denotes the supplementary component-disjoint split. The first four rows report point estimates with marginal 95% intervals. The final row reports Component-disjoint Δ = OERA-CVSS minus CVSS-BERT (2025), with paired 95% intervals. Intervals are not multiplicity-adjusted. Table A30 reports the partitions, host-project overlap, and fold-level performance. Table A31 reports performance averaged equally across components.
Table A27. Base metric prediction and vector matching: performance and component-disjoint paired differences.
Table A28. Base Score estimation: performance and component-disjoint paired differences.
Table A29. Severity classification: performance and component-disjoint paired differences.
Table A30. Component-disjoint partitions, residual host-project overlap, and fold-level Metric Macro-F1.
Table A31. Equal-weight averages over the 37 represented components.

Appendix I. Manual Sample Audit

Audit results. Two reviewers independently audited 60 vulnerability occurrences and resolved their final assessments through discussion. All 20 audited already_vulnerable occurrences passed. Of the 40 audited injected occurrences, 10 passed, 18 failed, and 12 were inconclusive. Initial inter-rater agreement was 70.0%, with Cohen’s κ = 0.538 , indicating moderate initial agreement.
Table A32. Manual audit outcomes and initial inter-rater agreement by occurrence origin.
The manual audit complements automated screening with source-level quality evidence for the sampled occurrences. Its findings are limited to the audited sample.

References

  1. International Telecommunication Union. Framework and Overall Objectives of the Future Development of IMT for 2030 and Beyond; Recommendation ITU-R M.2160-0; International Telecommunication Union: Geneva, Switzerland, 2023. [Google Scholar]
  2. Fang, Z.; Savkin, A.V. Strategies for Optimized UAV Surveillance in Various Tasks and Scenarios: A Review. Drones 2024, 8, 193. [Google Scholar] [CrossRef] [Scilit]
  3. FIRST.Org, Inc. Common Vulnerability Scoring System Version 3.1: Specification Document; FIRST.Org, Inc.: Cary, NC, USA, 2019. [Google Scholar]
  4. FIRST.Org, Inc. Common Vulnerability Scoring System Version 3.1: User Guide; FIRST.Org, Inc.: Cary, NC, USA, 2019. [Google Scholar]
  5. Dong, Y.; Guo, W.; Chen, Y.; Xing, X.; Zhang, Y.; Wang, G. Towards the Detection of Inconsistencies in Public Security Vulnerability Reports. In Proceedings of the 28th USENIX Security Symposium (USENIX Security 19); USENIX Association: Berkeley, CA, USA, 2019; pp. 869–885. [Google Scholar]
  6. Anwar, A.; Abusnaina, A.; Chen, S.; Li, F.; Mohaisen, D. Cleaning the NVD: Comprehensive Quality Assessment, Improvements, and Analyses. IEEE Trans. Dependable Secur. Comput. 2022, 19, 4255–4269. [Google Scholar] [CrossRef] [Scilit]
  7. Guo, H.; Chen, S.; Xing, Z.; Lin, X.; Bai, Y.; Sun, J. Detecting and Augmenting Missing Key Aspects in Vulnerability Descriptions. ACM Trans. Softw. Eng. Methodol. 2022, 31, 49:1–49:27. [Google Scholar] [CrossRef] [Scilit] [PubMed]
  8. Spanos, G.; Angelis, L. A Multi-Target Approach to Estimate Software Vulnerability Characteristics and Severity Scores. J. Syst. Softw. 2018, 146, 152–166. [Google Scholar] [CrossRef] [Scilit]
  9. Shahid, M.R.; Debar, H. CVSS-BERT: Explainable Natural Language Processing to Determine the Severity of a Computer Security Vulnerability from Its Description. In Proceedings of the 2021 20th IEEE International Conference on Machine Learning and Applications (ICMLA); IEEE: Piscataway, NJ, USA, 2021; pp. 1600–1607. [Google Scholar] [CrossRef] [Scilit]
  10. Le, T.H.M.; Hin, D.; Croft, R.; Babar, M.A. DeepCVA: Automated Commit-Level Vulnerability Assessment with Deep Multi-Task Learning. In Proceedings of the 2021 36th IEEE/ACM International Conference on Automated Software Engineering (ASE); IEEE: Piscataway, NJ, USA, 2021; pp. 717–729. [Google Scholar] [CrossRef] [Scilit]
  11. Le, T.H.M.; Babar, M.A. On the Use of Fine-Grained Vulnerable Code Statements for Software Vulnerability Assessment Models. In Proceedings of the 19th International Conference on Mining Software Repositories; Association for Computing Machinery: New York, NY, USA, 2022; pp. 621–633. [Google Scholar]
  12. Gao, C.; Chen, X.; Zhang, G. SVA-ICL: Improving LLM-Based Software Vulnerability Assessment via In-Context Learning and Information Fusion. Inf. Softw. Technol. 2025, 186, 107803. [Google Scholar] [CrossRef] [Scilit]
  13. Chen, Z.; Chen, X.; Li, Z.; Xue, J.; Gao, C. ReVul-CoT: Towards Effective Software Vulnerability Assessment with Retrieval-Augmented Generation and Chain-of-Thought Prompting. J. Syst. Softw. 2026, 237, 112855. [Google Scholar] [CrossRef] [Scilit]
  14. Spanos, G.; Angelis, L.; Toloudis, D. Assessment of Vulnerability Severity Using Text Mining. In Proceedings of the 21st Pan-Hellenic Conference on Informatics; Association for Computing Machinery: New York, NY, USA, 2017; pp. 49:1–49:6. [Google Scholar] [CrossRef] [Scilit]
  15. Han, Z.; Li, X.; Xing, Z.; Liu, H.; Feng, Z. Learning to Predict Severity of Software Vulnerability Using Only Vulnerability Description. In Proceedings of the 2017 IEEE International Conference on Software Maintenance and Evolution (ICSME); IEEE: Piscataway, NJ, USA, 2017; pp. 125–136. [Google Scholar] [CrossRef] [Scilit]
  16. Nakagawa, S.; Nagai, T.; Kanehara, H.; Furumoto, K.; Takita, M.; Shiraishi, Y.; Takahashi, T.; Mohri, M.; Takano, Y.; Morii, M. Character-Level Convolutional Neural Network for Predicting Severity of Software Vulnerability from Vulnerability Description. IEICE Trans. Inf. Syst. 2019, E102.D, 1679–1682. [Google Scholar] [CrossRef] [Scilit]
  17. Aivatoglou, G.; Anastasiadis, M.; Spanos, G.; Voulgaridis, A.; Votis, K.; Tzovaras, D.; Angelis, L. A RAkEL-Based Methodology to Estimate Software Vulnerability Characteristics and Score: An Application to EU Project ECHO. Multimed. Tools Appl. 2022, 81, 9459–9479. [Google Scholar] [CrossRef] [Scilit]
  18. Anggita, B.; Badieah, B. BERT-Based Classification of CVSS Metrics from Vulnerability Descriptions. In Proceedings of the 2025 12th International Conference on Electrical Engineering, Computer Science and Informatics (EECSI); IEEE: Piscataway, NJ, USA, 2025; pp. 508–513. [Google Scholar]
  19. Wu, Q.; Xiao, Y.; Liao, X.; Lu, K. OS-Aware Vulnerability Prioritization via Differential Severity Analysis. In Proceedings of the 31st USENIX Security Symposium (USENIX Security 22); USENIX Association: Berkeley, CA, USA, 2022; pp. 395–412. [Google Scholar]
  20. Red5d. Jev-CVSS: Fast CVSS Scoring from Vulnerability Descriptions Using TypeSafe Jev. GitHub Software Repository. Available online: https://github.com/Red5d/jev-cvss (accessed on 30 October 2026).
  21. Sanvito, D.; Arriciati, G.; Siracusano, G.; Bifulco, R.; Carminati, M. AutoCVSS: Assessing the Performance of LLMs for Automated Software Vulnerability Scoring. In Proceedings of the 2025 Conference on Empirical Methods in Natural Language Processing: Industry Track; Association for Computational Linguistics: Kerrville, TX, USA, 2025; pp. 564–575. [Google Scholar] [CrossRef] [Scilit]
  22. Bhandari, G.; Naseer, A.; Moonen, L. CVEfixes: Automated Collection of Vulnerabilities and Their Fixes from Open-Source Software. In Proceedings of the 17th International Conference on Predictive Models and Data Analytics in Software Engineering (PROMISE); Association for Computing Machinery: New York, NY, USA, 2021; pp. 30–39. [Google Scholar] [CrossRef] [Scilit]
  23. Bui, Q.C.; Scandariato, R.; Díaz Ferreyra, N.E. Vul4J: A Dataset of Reproducible Java Vulnerabilities Geared Towards the Study of Program Repair Techniques. In Proceedings of the 2022 IEEE/ACM 19th International Conference on Mining Software Repositories (MSR); Association for Computing Machinery: New York, NY, USA, 2022; pp. 464–468. [Google Scholar] [CrossRef] [Scilit]
  24. Nong, Y.; Ou, Y.; Pradel, M.; Chen, F.; Cai, H. VULGEN: Realistic Vulnerability Generation Via Pattern Mining and Deep Learning. In Proceedings of the 2023 IEEE/ACM 45th International Conference on Software Engineering; IEEE: Piscataway, NJ, USA, 2023; pp. 2527–2539. [Google Scholar] [CrossRef] [Scilit]
  25. Nong, Y.; Fang, R.; Yi, G.; Zhao, K.; Luo, X.; Chen, F.; Cai, H. VGX: Large-Scale Sample Generation for Boosting Learning-Based Software Vulnerability Analyses. In Proceedings of the 2024 IEEE/ACM 46th International Conference on Software Engineering; Association for Computing Machinery: New York, NY, USA, 2024; pp. 1–13. [Google Scholar] [CrossRef] [Scilit]
  26. Yi, G.; Nong, Y.; Li, M.; Cai, H. Exploring and Improving Real-World Vulnerability Data Generation via Prompting Large Language Models. In Proceedings of the 48th International Conference on Software Engineering (ICSE); Association for Computing Machinery: New York, NY, USA, 2026; pp. 2032–2044. [Google Scholar] [CrossRef] [Scilit]
  27. National Institute of Standards and Technology. National Vulnerability Database. Online Database. 2026. Available online: https://nvd.nist.gov/ (accessed on 30 July 2026).
  28. Fan, J.; Li, Y.; Wang, S.; Nguyen, T.N. A C/C++ Code Vulnerability Dataset with Code Changes and CVE Summaries. In Proceedings of the 17th International Conference on Mining Software Repositories; Association for Computing Machinery: New York, NY, USA, 2020; pp. 508–512. [Google Scholar] [CrossRef] [Scilit]
  29. Karpukhin, V.; Oguz, B.; Min, S.; Lewis, P.; Wu, L.; Edunov, S.; Chen, D.; Yih, W.t. Dense Passage Retrieval for Open-Domain Question Answering. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing; Association for Computational Linguistics: Stroudsburg, PA, USA, 2020; pp. 6769–6781. [Google Scholar] [CrossRef] [Scilit]
  30. Johnson, J.; Douze, M.; Jégou, H. Billion-Scale Similarity Search with GPUs. IEEE Trans. Big Data 2021, 7, 535–547. [Google Scholar] [CrossRef] [Scilit]
  31. Du, X.; Zhang, S.; Zhou, Y.; Du, H. A Vulnerability Severity Prediction Method Based on Bimodal Data and Multi-Task Learning. J. Syst. Softw. 2024, 213, 112039. [Google Scholar] [CrossRef] [Scilit]
  32. Liu, J.; Shen, D.; Zhang, Y.; Dolan, B.; Carin, L.; Chen, W. What Makes Good In-Context Examples for GPT-3? In Proceedings of the Deep Learning Inside Out (DeeLIO 2022); Association for Computational Linguistics: Stroudsburg, PA, USA, 2022; pp. 100–114. [Google Scholar] [CrossRef] [Scilit]
  33. Rubin, O.; Herzig, J.; Berant, J. Learning to Retrieve Prompts for In-Context Learning. In Proceedings of the 2022 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies; Association for Computational Linguistics: Stroudsburg, PA, USA, 2022; pp. 2655–2671. [Google Scholar] [CrossRef] [Scilit]
  34. Zhang, Y.; Feng, S.; Tan, C. Active Example Selection for In-Context Learning. In Proceedings of the 2022 Conference on Empirical Methods in Natural Language Processing; Association for Computational Linguistics: Kerrville, TX, USA, 2022; pp. 9134–9148. [Google Scholar] [CrossRef] [Scilit]
  35. Yang, Z.; Zhang, Y.; Sui, D.; Liu, C.; Zhao, J.; Liu, K. Representative Demonstration Selection for In-Context Learning with Two-Stage Determinantal Point Process. In Proceedings of the 2023 Conference on Empirical Methods in Natural Language Processing; Association for Computational Linguistics: Stroudsburg, PA, USA, 2023; pp. 5443–5456. [Google Scholar]
  36. Min, S.; Lyu, X.; Holtzman, A.; Artetxe, M.; Lewis, M.; Hajishirzi, H.; Zettlemoyer, L. Rethinking the Role of Demonstrations: What Makes In-Context Learning Work? In Proceedings of the 2022 Conference on Empirical Methods in Natural Language Processing; Association for Computational Linguistics: Kerrville, TX, USA, 2022; pp. 11048–11064. [Google Scholar] [CrossRef] [Scilit]
  37. DeepSeek. DeepSeek-V4.1-Flash-1017: Wish-Driven Programming Made Real. 2026. Available online: https://api-docs.deepseek.com/news/news261017/ (accessed on 4 November 2026).
  38. Alibaba Cloud. Model Lifecycle and Updates. 2026. Available online: https://help.aliyun.com/zh/model-studio/newly-released-models (accessed on 4 November 2026).
  39. Z.AI. GLM-5.3: Frontier Coding with Emergent Cyber Capabilities. 2026. Available online: https://z.ai/blog/glm-5.3 (accessed on 4 November 2026).
  40. Moonshot AI. Kimi Code: What Is New. 2026. Available online: https://www.kimi.com/code/docs/en/kimi-code/whats-new.html (accessed on 4 November 2026).
  41. Alibaba Cloud. Qwen3.8-Max Model Information. 2026. Available online: https://help.aliyun.com/zh/model-studio/qwen3-8-max (accessed on 4 November 2026).
  42. Z.AI. New Released. 2026. Available online: https://docs.z.ai/release-notes/new-released (accessed on 4 November 2026).
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Article Metrics

Citations

Article Access Statistics

Multiple requests from the same IP address are counted as one view.