Adaptive Uncertainty Quantification for Generative AI

Jungeum Kim,Sean O'Hagan,Veronika Rockova
2024-08-17
Abstract:This work is concerned with conformal prediction in contemporary applications (including generative AI) where a black-box model has been trained on data that are not accessible to the user. Mirroring split-conformal inference, we design a wrapper around a black-box algorithm which calibrates conformity scores. This calibration is local and proceeds in two stages by first adaptively partitioning the predictor space into groups and then calibrating sectionally group by group. Adaptive partitioning (self-grouping) is achieved by fitting a robust regression tree to the conformity scores on the calibration set. This new tree variant is designed in such a way that adding a single new observation does not change the tree fit with overwhelmingly large probability. This add-one-in robustness property allows us to conclude a finite sample group-conditional coverage guarantee, a refinement of the marginal guarantee. In addition, unlike traditional split-conformal inference, adaptive splitting and within-group calibration yields adaptive bands which can stretch and shrink locally. We demonstrate benefits of local tightening on several simulated as well as real examples using non-parametric regression. Finally, we consider two contemporary classification applications for obtaining uncertainty quantification around GPT-4o predictions. We conformalize skin disease diagnoses based on self-reported symptoms as well as predicted states of U.S. legislators based on summaries of their ideology. We demonstrate substantial local tightening of the uncertainty sets while attaining similar marginal coverage.
Methodology,Artificial Intelligence,Machine Learning
What problem does this paper attempt to address?
The problem that this paper attempts to solve is how to achieve adaptive uncertainty quantification when using black - box models for prediction in modern applications (including generative AI) in the case where users have no access to the training data. Specifically, the authors designed a wrapper around the black - box algorithm to achieve this by locally calibrating the consistency score. This method can not only provide global coverage guarantees but also adjust locally according to the prediction difficulty, thereby improving the accuracy and efficiency of the prediction interval. ### Core Problems of the Paper 1. **Uncertainty Quantification of Black - box Models**: - Black - box models such as generative AI are usually pre - trained on a large amount of data, but this data is invisible to users. Therefore, how to effectively quantify the uncertainty of the prediction results of these models without refitting the models is a challenge. 2. **Locally Adaptive Prediction Intervals**: - The prediction intervals provided by standard conformance prediction methods are often globally conservative and cannot well reflect the local prediction difficulty. The paper proposes a locally adaptive method. By dividing the prediction space into multiple groups and calibrating the consistency score separately within each group, more accurate prediction intervals are achieved. ### Method Overview - **Adaptive Partitioning**: Adaptive partitioning is achieved by fitting a robust regression tree, ensuring that the tree structure remains almost unchanged after adding new observations, thereby guaranteeing local conditional coverage. - **Local Calibration**: Independently calibrate the consistency score within each partition to generate locally adjusted prediction intervals. - **Robust Regression Tree**: A new tree - splitting criterion is proposed, which selects the splitting point based on the reduction of the response range to ensure that the tree structure remains stable after adding new observations. ### Application Examples - **Legislator Status Prediction**: Use ChatGPT to predict the status of legislators based on their ideological positions. - **Skin Disease Diagnosis**: Simulate the situation where users query skin disease diagnosis based on self - reported symptoms and provide a set of possible diagnosis results to convey uncertainty. ### Theoretical Contributions - **High - Probability Invariance**: Prove the lower bound of the probability that the tree partition remains almost unchanged after adding new observations, thereby guaranteeing conditional coverage. - **Local Conditional Coverage**: Through adaptive partitioning and local calibration, local conditional coverage close to the predetermined level is achieved. ### Conclusion The method proposed in the paper not only provides strict guarantees theoretically but also shows better performance in practical applications. Especially in the application scenarios of generative AI, it can effectively convey the uncertainty of prediction.