IDEAS home Printed from https://ideas.repec.org/p/arx/papers/2606.07392.html

Online Pandora's Box for Contextual LLM Cascading

Author

Listed:
  • Alexandre Belloni
  • Yan Chen
  • Yehua Wei

Abstract

Motivated by Large Language Model (LLM) cascading, we propose an online contextual Pandora's Box model for adaptively querying and selecting LLM APIs. In each period, a decision-maker observes a request context and faces a two-phase decision problem. In the query phase, the decision-maker sequentially queries APIs, where each query reveals a generated output and the decision-maker incurs an (output-dependent) cost. In the selection phase, the decision-maker selects one of the generated outputs to deploy and observes only the downstream reward of the deployed output. This output-mediated feedback structure differs from classical online contextual Pandora's Box models, in which opening a box directly reveals its reward. Rather than estimating the full conditional output and cost distributions of each API, we directly model the reservation index and develop a learning approach for the query phase. Specifically, we impose a parametric structure on the contextual reservation index functions induced by the classical Weitzman's policy. Our policy combines generalized method of moments (GMM) type estimation of these reservation indices with UCB-style confidence bounds for both these indices and the shared output-level reward evaluator. Under regularity conditions, we prove that the resulting policy achieves dimension-dependent $\widetilde O(\sqrt T)$ cumulative regret over a horizon of $T$ periods.

Suggested Citation

  • Alexandre Belloni & Yan Chen & Yehua Wei, 2026. "Online Pandora's Box for Contextual LLM Cascading," Papers 2606.07392, arXiv.org.
  • Handle: RePEc:arx:papers:2606.07392
    as

    Download full text from publisher

    File URL: https://arxiv.org/pdf/2606.07392
    File Function: Latest version
    Download Restriction: no
    ---><---

    References listed on IDEAS

    as
    1. Weitzman, Martin L, 1979. "Optimal Search for the Best Alternative," Econometrica, Econometric Society, vol. 47(3), pages 641-654, May.
    2. Yang Chen & Samuel N. Kirshner & Anton Ovchinnikov & Meena Andiappan & Tracy Jenkin, 2025. "A Manager and an AI Walk into a Bar: Does ChatGPT Make Biased Decisions Like We Do?," Manufacturing & Service Operations Management, INFORMS, vol. 27(2), pages 354-368, March.
    3. Lee, Lung-fei & Yu, Jihai, 2010. "Estimation of spatial autoregressive panel data models with fixed effects," Journal of Econometrics, Elsevier, vol. 154(2), pages 165-185, February.
    4. Paat Rusmevichientong & John N. Tsitsiklis, 2010. "Linearly Parameterized Bandits," Mathematics of Operations Research, INFORMS, vol. 35(2), pages 395-411, May.
    5. Doval, Laura, 2018. "Whether or not to open Pandora's box," Journal of Economic Theory, Elsevier, vol. 175(C), pages 127-158.
    6. Zenan Chen & Jason Chan, 2024. "Large Language Model in Creative Work: The Role of Collaboration Modality and User Expertise," Management Science, INFORMS, vol. 70(12), pages 9101-9117, December.
    7. Wang Chi Cheung & Will Ma & David Simchi-Levi & Xinshang Wang, 2022. "Inventory Balancing with Online Learning," Management Science, INFORMS, vol. 68(3), pages 1776-1807, March.
    8. Lin Fan & Peter W. Glynn, 2025. "The Fragility of Optimized Bandit Algorithms," Operations Research, INFORMS, vol. 73(6), pages 3173-3198, November.
    9. Lin, Xu & Lee, Lung-fei, 2010. "GMM estimation of spatial autoregressive models with unknown heteroskedasticity," Journal of Econometrics, Elsevier, vol. 157(1), pages 34-52, July.
    Full references (including those not matched with items on IDEAS)

    Most related items

    These are the items that most often cite the same works as this one and are cited by the same works as this one.
    1. Zihao Chen & Xingyu Fu & Pin Gao & Ying-Ju Chen, 2026. "Sound of Silence: When to Conceal Attribute Information? The Roles of Consumer Search, Inventory, and Channel Structure," Manufacturing & Service Operations Management, INFORMS, vol. 28(3), pages 783-801, May.
    2. Michele Aquaro & Natalia Bailey & M. Hashem Pesaran, 2015. "Quasi Maximum Likelihood Estimation of Spatial Models with Heterogeneous Coefficients," CESifo Working Paper Series 5428, CESifo.
    3. Ziv Scully & Laura Doval, 2024. "Local hedging approximately solves Pandora's box problems with nonobligatory inspection," Papers 2410.19011, arXiv.org, revised Jan 2025.
    4. Pak Hung Au & Mark Whitmeyer, 2018. "Attraction versus Persuasion: Information Provision in Search Markets," Papers 1802.09396, arXiv.org, revised May 2022.
    5. Hedyeh Beyhaghi & Linda Cai, 2023. "Recent Developments in Pandora's Box Problem: Variants and Applications," Papers 2308.12242, arXiv.org.
    6. Tizheng Li & Xiaojuan Kang, 2022. "Variable selection of higher-order partially linear spatial autoregressive model with a diverging number of parameters," Statistical Papers, Springer, vol. 63(1), pages 243-285, February.
    7. Badi H. Baltagi & Peter H. Egger & Michaela Kesina, 2022. "Bayesian estimation of multivariate panel probits with higher‐order network interdependence and an application to firms' global market participation in Guangdong," Journal of Applied Econometrics, John Wiley & Sons, Ltd., vol. 37(7), pages 1356-1378, November.
    8. Michele Aquaro & Natalia Bailey & M. Hashem Pesaran, 2015. "Quasi Maximum Likelihood Estimation of Spatial Models with Heterogeneous Coefficients," Working Papers 749, Queen Mary University of London, School of Economics and Finance.
    9. Baltagi, Badi H. & Yang, Zhenlin, 2013. "Heteroskedasticity and non-normality robust LM tests for spatial dependence," Regional Science and Urban Economics, Elsevier, vol. 43(5), pages 725-739.
    10. Andre Chagas & Carlos Azzoni & Alexandre Almeida, 2015. "A Spatial Difference-in-Difference Analysis to Measure the Sugarcane Producing Impact in Respiratory Health," ERSA conference papers ersa15p511, European Regional Science Association.
    11. Petrikaitė, Vaiva, 2022. "Escaping search when buying," International Journal of Industrial Organization, Elsevier, vol. 82(C).
    12. Áureo de Paula, 2015. "Econometrics of network models," CeMMAP working papers CWP52/15, Centre for Microdata Methods and Practice, Institute for Fiscal Studies.
    13. Haller, Peter & Heuermann, Daniel F., 2016. "Job search and hiring in local labor markets: Spillovers in regional matching functions," Regional Science and Urban Economics, Elsevier, vol. 60(C), pages 125-138.
    14. Rafael P. Greminger, 2022. "Optimal Search and Discovery," Management Science, INFORMS, vol. 68(5), pages 3904-3924, May.
    15. Liu, Shew Fan & Yang, Zhenlin, 2015. "Modified QML estimation of spatial autoregressive models with unknown heteroskedasticity and nonnormality," Regional Science and Urban Economics, Elsevier, vol. 52(C), pages 50-70.
    16. Natalia Bailey & Sean Holly & M. Hashem Pesaran, 2016. "A Two‐Stage Approach to Spatio‐Temporal Analysis with Strong and Weak Cross‐Sectional Dependence," Journal of Applied Econometrics, John Wiley & Sons, Ltd., vol. 31(1), pages 249-280, January.
    17. Mohammad Reza Aminian & Vahideh Manshadi & Rad Niazadeh, 2025. "Markovian Search with Ex-Ante Constraints: Theory and Applications to Socially Aware Algorithmic Hiring," Papers 2501.13346, arXiv.org, revised Oct 2025.
    18. Shalpegin, Timofey & Browning, Tyson R. & Kumar, Ajay & Shang, Guangzhi & Thatcher, Jason & Fransoo, Jan C. & Holweg, Matthias & Lawson, Benn, 2025. "Generative AI and empirical research methods in operations management," Other publications TiSEM 0eb52ee8-35d0-4c97-8732-8, Tilburg University, School of Economics and Management.
    19. Manuel Mueller-Frank & Mallesh M. Pai, 2016. "Social Learning with Costly Search," American Economic Journal: Microeconomics, American Economic Association, vol. 8(1), pages 83-109, February.
    20. Luis Chanci & Subal C. Kumbhakar & Luis Sandoval, 2024. "Crime under-reporting in Bogotá: a spatial panel model with fixed effects," Empirical Economics, Springer, vol. 66(5), pages 2105-2136, May.

    More about this item

    Statistics

    Access and download statistics

    Corrections

    All material on this site has been provided by the respective publishers and authors. You can help correct errors and omissions. When requesting a correction, please mention this item's handle: RePEc:arx:papers:2606.07392. See general information about how to correct material in RePEc.

    If you have authored this item and are not yet registered with RePEc, we encourage you to do it here. This allows to link your profile to this item. It also allows you to accept potential citations to this item that we are uncertain about.

    If CitEc recognized a bibliographic reference but did not link an item in RePEc to it, you can help with this form .

    If you know of missing items citing this one, you can help us creating those links by adding the relevant references in the same way as above, for each refering item. If you are a registered author of this item, you may also want to check the "citations" tab in your RePEc Author Service profile, as there may be some citations waiting for confirmation.

    For technical questions regarding this item, or to correct its authors, title, abstract, bibliographic or download information, contact: arXiv administrators (email available below). General contact details of provider: https://arxiv.org/ .

    Please note that corrections may take a couple of weeks to filter through the various RePEc services.

    IDEAS is a RePEc service. RePEc uses bibliographic data supplied by the respective publishers.