Abstract
BACKGROUND: Many U.S. institutions have adopted postsurgical opioid-prescribing guidelines to standardize prescribing practices, and yet there is inherent variability in patients' opioid consumption after surgery. The utility of these guidelines is limited by the fact that some patients' needs will inevitably exceed them, and yet there are no evidence-based tools to help providers identify these patients. In this study we aimed to maximize the value of these guidelines by training machine learning models to predict patients whose needs will be met by these smaller recommended prescriptions, and patients who may require an additional degree of personalization. The aim of the present study was to develop predictive models for determining whether a surgical patient's postdischarge opioid requirement will fall above or below common opioid prescribing guidelines.
METHODS: We conducted a retrospective cohort study of surgical patients at one institution from 2017 to 2018. Patients were called after discharge to collect opioid consumption data. Machine learning models were used to identify outlier opioid consumers (ie, exceeding our institutional prescribing guidelines) using diagnosis codes, medical history, in-hospital opioid use, and perioperative factors as predictors. External validation was performed on opioid consumption data collected at a second institution from 2020 to 2021, and sensitivity analysis was performed using a third institution's prescribing guidelines.
RESULTS: The development and external validation cohorts included 1,867 and 498 patients, respectively. Age, body mass index, tobacco use, preoperative opioid exposure, and in-hospital opioid consumption were the strongest predictors of postdischarge consumption. A lasso regression model exhibited an area under the receiver operating characteristic curve of 0.74 (95% confidence interval 0.67-0.81) in predicting postdischarge opioid consumption. External validation of a limited lasso model yielded an area under the receiver operating characteristic curve of 0.67 (0.60-0.74). Performance was preserved when evaluated on another institution's guidelines (area under the receiver operating characteristic curve 0.76 [0.72-0.80]).
CONCLUSION: Patient characteristics reliably predict postdischarge opioid consumption in relation to prescribing guidelines for both opioid-naive and exposed populations. This model may be used to help providers confidently follow prescribing guidelines for patients with typical opioid responsiveness and correctly pursue more personalized prescribing for others.