P045 Development and evaluation of machine learning algorithms for the prediction of opioid-related deaths among UK patients with non-cancer pain
Authors: Benitez-Aurioles Jose , Jenkins David , Huang Yun-Ting (Joyce) , Medina Carlos Ramirez , Peek Niels , Jani Meghna 
Published: April 2023

Abstract

Background/Aims
There has been a sharp rise in the use of opioids for non-cancer pain globally. Despite increased awareness of adverse effects, they remain commonly prescribed in the UK. Clinical prediction models offer the possibility of assessing individual risk for a given outcome allowing better allocation of resources towards those at risk. Machine learning (ML) approaches can address nonlinear relationships and complex interactions between variables and are increasingly used to develop these models.
Our objective is to develop, validate, and compare the performance of three clinical prediction models based on regression and ML, which leverage primary care data to estimate the risk of opioid-related death in patients prescribed opioids for non-cancer pain.

Methods
Patients ≥18 years old without prior cancer who were prescribed any opioid between 01/01/2006 and 31/12/2017 were identified in the Clinical Practice Research Datalink (CPRD). Only new opioid users were included. Index date was date of first prescription, with censoring at withdrawal from the CPRD or after not having an opioid prescription for two years. Baseline data were extracted from each patient’s records, including demographic information, comorbidities, concomitant medications, and the opioid type being prescribed, collecting 49 candidate predictors. These were used to train three competing risk models: a Fine&Gray regression model with LASSO regularisation, a survival random forest (RF), and a neural network (DeepHit). The outcome was opioid-related mortality and other cause mortality the competing event, defined using a curated ICD-10 codelist. Predictive performance of the models, such as the area under the receiver characteristic operator curve (AUC-ROC), were calculated using 5-fold cross validation.

Results
We included a total of 1,029,681 patients, of which 1,240 experienced an opioid-related death, and 52,833 experienced a competing death.
The Fine&Gray, RF and DeepHit models achieved average AUC-ROC values of 0.83(95% CI: 0.81-0.85), 0.78(0.77-0.79) and 0.81(0.80-0.82) respectively. At the optimum risk cut point, as per Youden’s index, the models achieved sensitivities of 0.82(0.78-0.85), 0.75(0.67-0.82) and 0.80(0.78-0.83), and specificities of 0.78(0.73-0.82), 0.75(0.68-0.83) and 0.78(0.75-0.80) when predicting 12-month risk, respectively.
In the Fine&Gray model, factors associated with an increased risk were history of substance use disorder (hazards ratio [HR]: 3.40, 95% CI:3.12-3.69) and alcohol abuse (HR:3.07, 95% CI:2.93-3.22). COPD (HR:1.53, 95% CI:1.48-1.58) and moderate liver disease (HR:1.31, 95% CI:0.99-1.63) were the comorbidities associated with highest risk. Morphine (HR:2.39, 95% CI:2.08-2.69) and oxycodone (HR:1.10, 95% CI:1.00-1.20) at initiation and concomitant gabapentinoids (HR:1.99, 95% CI:1.80-2.18) and benzodiazepines (HR:1.30, 95% CI:1.24-1.36) were associated with an increased risk. HR for rheumatologic diseases was 1.08 (95% CI:1.01-1.14).

Conclusion
The Fine&Gray and DeepHit models exhibited comparable discriminative performance. Substance abuse, lung and liver comorbidities, morphine or oxycodone at initiation and co-prescription of gabapentinoids and benzodiazepines, were some of the factors associated with a higher risk of opioid-related mortality.
Disclosure
J. Benitez-Aurioles: None. D. Jenkins: None. Y. Huang: None. C. Ramirez Medina: None. N. Peek: None. M. Jani: None.