## 4 Discussion  
The major findings of this study are as follows. The discriminative performance and calibration of the XGBoost-based model were satisfactory. The visualization of SHAP highlighted the effect of the BMI and albumin levels on delirium and the cut-off values  
Figure 8: Risk score revision details. Figure 7: SHAP dependence plot for age. Each dot denotes a patient. The x-axis is the age of patients, and the y-axis shows the SHAP values attributed to the age. Higher SHAP values represent higher risk of delirium due to age. of age (Figures 5-7). These factors have previously received limited attention, and their values were reflected in the revision of risk scores. Although the populations and predictors used in previous studies on the prediction of delirium using machine learning differ from those used in the present study, they exhibited higher AUROCs of 0.78-0.95 [15; 16; 17; 18; 19; 20; 21; 22; 23; 24; 25; 26]. However, most studies were conducted on Western subjects, and the results may differ for Asians. The current study yielded a certain value because of the numerous cases involving Asians. Because Japan has an aging population, many of its hospitalized patients are senior citizens. Therefore, risk factors for delirium may not necessarily match those of other countries. Comparing the risk factors presented in previous studies with those extracted in the current study, many factors such as age, functional status, cognitive impairment, and dementia are common [4; 5; 6; 7; 8; 9; 10; 11; 12; 13; 14; 15; 16; 17; 18; 19; 20; 21; 22; 23; 24; 25; 26]. However, reviewing the predictive contributing factors visualized in SHAP revealed that low BMI and albumin levels were risk factors for delirium (Figures 5 and 6). This result may reflect a low nutritional level associated with thinness, i.e., frailty. Thus, the development and utilization of individualized predictive models that reflect the unique domestic situation may exhibit certain benefits. In a previous study, we focused on the high prediction accuracy of machine learning and the disease management capability of electronic clinical pathways, and confirmed a deterrent effect on aspiration pneumonia by revising care items such as oral care in the electronic pathways for hemorrhagic stroke patients, using data analysis [28]. The combination of machine learning and electronic clinical pathways could be used to realize a learning health system; however, the black box nature of machine learning hinders its application. The ML interpretation method can enable experts to interpret the effect of various predictors of delirium and allow health care providers to make data-driven decisions. Figure 9 shows a schematic of a series of clinical workflows that incorporate the results of analyses based on ML interpretation methods. The analyst submits analysis results obtained using the interpretation method in an expert meeting on delirium. Specifically, the expert meeting is held based on the results, and if the results are judged to have clinical value, they are used in actual clinical practice. Note that an expert meeting including a psychiatist was conducted to validate the results of the analysis. SHAP and other ML interpretation methods are still in the nascent stage of development, and the interpretation of visualized results should be kept in mind. These results should only be used to detect anomalies in the input data or to understand the effect of predictors. Against this background, this study was limited to revising the risk score with reference to the results of the ML interpretability method. However, revising the risk score alone cannot accurately reflect the complex interactions among predictors and cannot improve the prediction accuracy. The false-positive rate would remain high even with a revised risk score. Therefore, predictive models based on machine learning must be implemented in the future; for example, in patient information systems for electronic medical records.