Let's Think Var-by-Var: Large Language Models Enable Ad Hoc Probabilistic Reasoning
Shepard Xia, Brian Lu, Jason Eisner
TL;DR
This work investigates whether large language models can supply commonsense knowledge to build ad hoc probabilistic models for novel, data-scarce questions (guesstimation). It introduces a pipeline where an LLM proposes variables and constraint relationships, which are then integrated into a log-linear model via a fuzzy maximum-entropy objective that aims to satisfy moment constraints. The approach formalizes moment constraints and exact inference on a graphical model, producing p_ heta that respects LLM-derived information. Across three real-world tabular datasets (AIR, ATUS, WVS), the framework achieves performance comparable to direct LLM prompting and demonstrates robustness to noise, highlighting a principled path to augment probabilistic reasoning with learned commonsense. The results suggest the method is viable for harder questions and point to future directions in prompt design, regularization, and scaling to richer variable spaces.
Abstract
A hallmark of intelligence is the ability to flesh out underspecified situations using "common sense." We propose to extract that common sense from large language models (LLMs), in a form that can feed into probabilistic inference. We focus our investigation on $\textit{guesstimation}$ questions such as "How much are Airbnb listings in Newark, NJ?" Formulating a sensible answer without access to data requires drawing on, and integrating, bits of common knowledge about how $\texttt{Price}$ and $\texttt{Location}$ may relate to other variables, such as $\texttt{Property Type}$. Our framework answers such a question by synthesizing an $\textit{ad hoc}$ probabilistic model. First we prompt an LLM to propose a set of random variables relevant to the question, followed by moment constraints on their joint distribution. We then optimize the joint distribution $p$ within a log-linear family to maximize the overall constraint satisfaction. Our experiments show that LLMs can successfully be prompted to propose reasonable variables, and while the proposed numerical constraints can be noisy, jointly optimizing for their satisfaction reconciles them. When evaluated on probabilistic questions derived from three real-world tabular datasets, we find that our framework performs comparably to a direct prompting baseline in terms of total variation distance from the dataset distribution, and is similarly robust to noise.
