Evaluating Aviation Safety Knowledge Extraction with SmolLM2: From Zero-Shot to Retrieval-Grounded Prompting
Authors: Aziida Nanyonga, Mustafa Tahsin Yilmaz, Amir Hussain, Ugur Turhan, Graham Wild
Organizations: SDAIA-KFUPM Joint Research Center for Artificial Intelligence, King Fahd University of Petroleum and Minerals (KFUPM), Dhahran, Saudi Arabia · Department of Industrial Engineering, Faculty of Engineering, King Abdulaziz University, Jeddah 21589, Saudi Arabia · Center for Research Excellence in Artificial Intelligence and Data Science (AIADS), King Abdulaziz University, Jeddah 21589, Saudi Arabia · School of Science, University of New South Wales Canberra, Australian Defence Force Academy, Canberra, Australia
Aviation accident narratives contain safety knowledge that is difficult to capture using structured occurrence fields alone. This study evaluates prompting-based knowledge extraction across four dimensions: concept accuracy, verbatim evidence grounding, structural compliance, and directed relation extraction. SmolLM2-1.7B-Instruct was evaluated under zero-shot, one-shot, fixed few-shot, and retrieval-grounded prompting using 300 National Transportation Safety Board narratives from 2000-2020, containing 3,763 reference concepts and 467 directed relations. Evaluation combined structural checks, verbatim evidence matching, expert-reviewed semantic matching, and paired bootstrap confidence intervals. No prompting strategy performed best across all dimensions. Retrieval-grounded prompting achieved the highest concept micro-F1 of 32.27%, although its advantage over fixed few-shot prompting was uncertain (95% CI: -0.92 to 2.40 percentage points). One-shot prompting achieved the highest relation F1 of 6.95%, identifying directed relation extraction as the principal SmolLM2 bottleneck. Compared with fixed few-shot prompting, retrieval improved verbatim grounding (59.45% vs. 54.02%) but reduced complete structural compliance (33.3% vs. 42.7%). Verbatim matching establishes source presence rather than evidential relevance. An exploratory comparison using 35 benchmark narratives showed that Qwen3-8B achieved higher concept micro-F1 across all prompting conditions and higher relation F1 under demonstration-based prompting, reaching 51.37% and 34.62%, respectively, under one-shot prompting. The small subset limits generalization. These findings support evaluating semantic correctness, source traceability, structural reliability, and directed relation accuracy separately.
Figures & tables
Figure 1: Experimental framework for aviation safety knowledge extraction, showing corpus preparation, the extraction schema, four prompting conditions, model inference, and four separate evaluation dimensions. The dashed box summarizes the supplementary matched model comparison.
Category
Unanimity (%)
Fleiss’ κ
95% CI
Event
94.40
0.052
−0.025 to 0.188
Phase of flight
93.97
0.279
−0.027 to 0.561
Hazard
70.26
0.494
0.382 to 0.593
Human factor
83.62
0.772
0.704 to 0.834
Technical factor
91.38
0.858
0.792 to 0.913
Environmental factor
59.48
0.456
0.366 to 0.539
Table 1: Pre-consensus category-presence agreement across 232 eligible narratives. Confidence intervals are narrative-level bootstrap intervals and are not adjusted for multiple comparisons.
Condition
Pred.
TP
FP
FN
P
R
Micro-F1
Macro-F1
Zero-shot
540
80
460
3683
14.81
2.13
3.72
3.72
One-shot
1603
825
778
2938
51.47
21.92
30.75
17.87
Fixed few-shot
1504
830
674
2933
55.19
22.06
31.52
20.73
Retrieval-grounded
1536
855
681
2908
55.66
22.72
32.27
20.76
Table 2: Concept-level extraction performance against the reconciled reference containing 3,763 concepts per condition. Precision, recall, micro-F1, and macro-F1 are percentages.
Figure 2: Concept-level precision, recall, and micro-F1 across the four prompting conditions, evaluated against the reconciled reference containing 3,763 concepts across 300 narratives. All values are percentages.
Example
Retrieved
E
P
H
HF
TF
EF
CF
C
DEV_01
118
1
1
1
0
0
0
0
4
DEV_02
86
1
1
1
1
0
0
0
3
DEV_03
218
1
2
1
0
0
0
0
2
DEV_04
44
1
1
1
0
0
1
0
2
DEV_05
78
1
1
1
1
0
1
0
3
DEV_06
149
1
1
1
0
0
1
0
3
Table 3: Development-example selection frequencies and annotated concept counts by category. The fixed few-shot condition used DEV_01, DEV_05, DEV_11, and DEV_12 in every prompt.
Condition
Category
Precision
Recall
F1
Zero-shot
Event
0.00
0.00
0.00
Phase of flight
29.41
4.89
8.39
Hazard
8.14
1.31
2.25
Human factor
7.69
2.36
3.61
Technical factor
4.35
1.95
2.69
Environmental factor
23.81
3.81
6.56
Table 4: Category-level precision, recall, and F1 against the reconciled reference across the four prompting conditions. All values are percentages.
Figure 3: Category-level concept F1 across the four prompting conditions, evaluated against the reconciled reference. Cell values are percentages.
Condition
Short
Medium
Long
Zero-shot
10.34
2.41
0.52
One-shot
43.86
29.39
22.67
Fixed few-shot
42.70
31.97
21.90
Retrieval-grounded
43.59
31.49
24.69
Narratives
76
150
74
Reference concepts
759
1902
1102
Table 5: Concept micro-F1 across narrative-length strata, evaluated against the reconciled reference. All performance values are percentages.
Figure 4: Concept micro-F1 across short ( ≤92 words; n=76 ), medium (93–195 words; n=150 ), and long ( >195 words; n=74 ) narratives, evaluated against the reconciled reference. Lines connect descriptive stratum-level estimates and do not represent a longitudinal trend.
Condition
JSON parsed
Complete compliance
Generated spans
Verbatim spans
Grounding (%)
Zero-shot
71/300
29/300 (9.7%)
0
0
–
One-shot
256/300
160/300 (53.3%)
1555
806
51.83
Fixed few-shot
272/300
128/300 (42.7%)
1516
819
54.02
Retrieval-grounded
268/300
100/300 (33.3%)
1519
903
59.45
Table 6: Structural compliance and verbatim evidence grounding across the four prompting conditions. JSON parsing and complete compliance are reported relative to 300 generation attempts per condition, while grounding is the percentage of generated evidence spans occurring verbatim in the corresponding source narrative.
Figure 5: Complete structural compliance and verbatim evidence grounding across the demonstration-based prompting conditions. Compliance is the percentage of generation attempts satisfying the complete schema, whereas grounding is the percentage of generated evidence spans occurring verbatim in the source narrative. Zero-shot prompting is omitted because its grounding rate is undefined in the absence of usable evidence spans. Verbatim presence does not establish evidential relevance.
Condition
Pred.
Ref.
TP
FP
FN
P
R
Zero-shot
129
467
0
129
467
0.00
0.00
One-shot
281
467
26
255
441
9.25
5.57
Fixed few-shot
743
467
31
712
436
4.17
6.64
Retrieval-grounded
651
467
25
626
442
3.84
5.35
Aggregate
1804
1868
82
1722
1786
4.55
4.39
Table 7: Directed relation extraction against the reconciled reference containing 467 relations per condition. Precision, recall, and F1 are percentages, while the aggregate row pools counts across all four conditions.
Figure 6: Directed relation precision, recall, and F1 across the four prompting conditions, evaluated against 467 reference relations in 300 narratives. Correct matches require compatible source and target concepts, the specified relation type, and the correct direction. All values are percentages.
Model
Condition
Concept F1
Relation F1
Structure
Grounding
SmolLM2
Zero-shot
3.43
0.00
5.71
–
SmolLM2
One-shot
35.68
5.36
60.00
56.50
SmolLM2
Fixed few-shot
36.07
7.32
34.29
58.66
SmolLM2
Retrieval-grounded
36.94
1.25
42.86
62.37
Qwen3-8B
Zero-shot
46.29
0.00
34.29
78.91
Qwen3-8B
One-shot
51.37
34.62
74.29
70.37
Table 8: Exploratory model comparison on the same 35 narratives against the reconciled reference containing 432 concepts and 77 directed relations. Concept micro-F1, relation F1, complete structural compliance, and verbatim evidence grounding are percentages.
Condition
Concept difference
95% CI
Relation difference
95% CI
Zero-shot
42.86
37.71–48.36
0.00
0.00–0.00
One-shot
15.69
8.66–22.78
29.26
14.88–43.19
Fixed few-shot
13.79
8.34–19.13
16.96
5.22–27.96
Retrieval-grounded
11.69
6.22–16.89
25.97
15.49–36.70
Table 9: Paired Qwen3-8B-minus-SmolLM2 differences on the same 35 narratives. Differences and confidence limits are expressed in percentage points; intervals are unadjusted for multiple comparisons and conditional on the finalized reference and matching decisions.
Relation extraction from aviation accident narratives is challenging because genuine safety relations are sparse among possible concept pairs. This study evaluates a decomposed framework separating relation classification from concept identification. A benchmark of 300 National Transportation Safety Board (NTSB) narratives containing 2,524 unique concept-text nodes was expanded into 21,038 ordered candidate pairs, with only 248 (1.18%) representing RESULTS_IN or CONTRIBUTES_TO relations. A TF-IDF Linear Support Vector Machine (SVM) and weighted RoBERTa classifier were developed using an independent graph-annotated resource with hard-negative sampling and frozen before sealed evaluation. Development Macro-F1 scores of 0.4738 (SVM) and 0.4809 (RoBERTa) declined to 0.2741 and 0.2420 under exhaustive evaluation, with Matthews correlation coefficients of 0.0128 and 0.0197. False positives dominated: the SVM recovered 96 reference relations but generated 7,018 false positives, while RoBERTa recovered 125 but generated 9,824. Post-test diagnostics revealed overlapping RoBERTa confidence distributions and false positives even within valid relation-category directions. Complementary end-to-end SmolLM2 evaluation identified missed and unsupported relations alongside malformed outputs. These findings demonstrate that known concept endpoints do not guarantee reliable relation extraction and that sampled-negative development performance may poorly reflect exhaustive evaluation. Controlling false positives and managing candidate-space sparsity remain essential for aviation safety knowledge extraction.
Aziida Nanyonga, Mustafa Tahsin Yilmaz, Saad Ezzini +2
SDAIA-KFUPM Joint Research Center for Artificial Intelligence, King Fahd University of Petroleum and Minerals (KFUPM), Dhahran 31261, Saudi Arabia · Department of Industrial Engineering, Faculty of Engineering, King Abdulaziz University, Jeddah 21589, Saudi Arabia · Department of Information and Computer Science, King Fahd University of Petroleum and Minerals, Dhahran 31261, Saudi Arabia +1
Aviation knowledge question answering cannot directly assess the operational effectiveness and safety compliance of large language models throughout aircraft emergency procedures. We introduce AeroCopilotBench and its executable cockpit environment, ACOE, which define state-transition rules, task goals, and trajectory-level safety constraints based on aircraft-specific Pilot's Operating Handbooks (POHs). The benchmark comprises 12 scenario templates and 73 tasks across two aircraft types, evaluating task completion, safety compliance, execution discipline, and repeatability. Across repeated evaluations of 12 models, the highest safety-gated success rate is 72.6%. Most failed episodes achieve all critical goals but do not satisfy all remaining terminal goals. Across repeated runs, models still omit steps that they execute in other runs of the same task. Analysis of failed trajectories further reveals that some reasons for actions that conflict with the aircraft's POH recur across models. These results expose shortcomings in complete procedure execution, consistency across runs, and aircraft-specific emergency response.
Yuchen Yuan, Zhenghuang Wu, Yuangan Li +2
School of Aeronautic Science and Engineering, Beihang University
Aviation accident and incident investigations generate extensive unstructured textual information containing evidence relevant to the causes and contributing factors of safety occurrences. Automatically extracting such information is challenging because causal evidence may be distributed across long and complex investigation narratives. This study proposes a semantic causal-factor inference framework combining natural language processing with a variational autoencoder (VAE) to learn the relationship between aviation investigation narratives and expert-reported probable causes. Investigation narratives and their corresponding probable causes are transformed into numerical representations, after which the encoder maps narrative representations to a probabilistic latent space. The decoder estimates representations of the corresponding probable causes and is trained using an objective that combines Kullback-Leibler divergence with cosine-similarity-based semantic reconstruction. The framework was evaluated using 20,919 finalized U.S. National Transportation Safety Board investigation reports from 2005 to 2020. On the held-out test set, the predicted and expert-reported probable-cause representations achieved a mean cosine similarity of 0.786 (SD = 0.120). The predicted representations also yielded interpretable terms associated with causal information in the reports. The results demonstrate the potential of probabilistic latent representation learning for AI-assisted extraction of causal information from aviation safety narratives while retaining expert investigation as the basis for formal causal determination.
AZIIDA NANYONGA1, HASSAN WASSWA, UGUR TURHAN +2
SDAIA-KFUPM Joint Research Center for Artificial Intelligence, King Fahd University of Petroleum and Minerals (KFUPM), Dhahran 31261, Saudi Arabia · School of Systems and Computing, University of New South Wales, Canberra, ACT 2600, Australia · School of Science, University of New South Wales, Canberra, ACT 2612, Australia +1