Artificial intelligence models predict household COVID-19 transmission risks using nationwide Swedish health data, revealing how demographic factors shape secondary infections.
- Researchers analyzed 252,472 Swedish households during the 2020 pre-vaccination period.
- The study integrated 287 demographic, socioeconomic, and clinical features per household.
- Transformer-based model TabPFN achieved a ROC-AUC performance comparable to standard XGBoost.
Researchers applied machine learning to linked population and healthcare registers across Sweden to examine how SARS-CoV-2 spreads within domestic environments. Published in Scientific Reports on November 26, 2026, the study evaluated over a quarter of a million households comprising 990,916 individuals. Because national registers record diagnoses without genomic sequencing, the team formulated the problem as a supervised binary classification task based on temporal infection windows.
The analysis examined whether at least one secondary case occurred within a household following an initial primary infection. Households lacking uninfected members after the index case were excluded from the target population. The resulting dataset captured nationwide infection patterns before the rollout of vaccines or the emergence of major variants.
To evaluate transmission risk, the research team deployed TabPFN, a transformer-based tabular foundation model that performs inference via in-context learning rather than conventional gradient-based training. To manage computational constraints, investigators implemented a bagging ensemble strategy with positive-class oversampling across 40,000-sample subsets.
The household-level AUC-ROC reached 0.645 for TabPFN compared to 0.641 for XGBoost, while individual-level susceptibility prediction scores stood at 0.717 and 0.726 respectively. The primary study in Scientific Reports noted an ensemble ROC-AUC of 0.625 ± 0.002, placing it within the narrow 0.605 to 0.630 range spanned by five distinct baseline models.
Mingtong Du, Jonas Björk, Amir Aminifar, and Atiye Sadat Hashemi reported that global explainability addresses the question “which features matter most to the model overall?”. In contrast, local explainability answers “why did the model assign this particular prediction to this specific household?”.
Explainability is achieved through a structured three-level KernelSHAP analysis, which covers global population-wide attribution, subgroup stratification, and local instance-level decomposition.
Each bag draws 20,000 positive households without replacement, together with 20,000 negative households.
To interpret how the models reach their conclusions, the investigators applied Kernel SHAP to decompose predictions into additive feature contributions. Global attributions highlighted household income, age composition, and living area as the single most influential features driving secondary transmission risk within domestic settings.
The framework also generated individual-level local explanations for single households, which an agent architecture translated into plain-language narratives. Because the underlying data derive exclusively from Sweden’s first pandemic year, the authors emphasized that applying these predictive models to later phases requires further validation.
Worth a look