LLMs and Generated Variables: An Illusion of Direct Observation
Le brief IA que les pros lisent chaque soir
Les 7 actus IA du jour, décryptées en 5 min. Gratuit.
Inclus dès l'inscription : notre sélection des meilleurs guides & comparatifs IA.
Choisis ton rythme
Gratuit · Pas de spam · Désabonnement en 1 clic
The Themes of LLMs: A Conditional Construction
The themes generated by language models (LLMs) should not be interpreted as direct observations of customer states. They represent generated variables, arising from a complex and conditional process. This process depends on the existence of a textual action from the customer and the ability of the extraction model to capture this trace. Each step of this conditional process influences the meaning of the variable in a causal model, although these influences are often invisible in the final data.
The Four Major Issues
Several issues can affect the interpretation of LLM themes:
-
Selection: A theme is associated with a customer because they interacted in a specific way, such as calling or complaining. This action is often correlated with the treatment or outcome, altering the analyzed population. Filling in NULL values makes these four issues visible simultaneously, reducing "did not generate text" to a reference category. This means that the analysis no longer measures an effect on all customers but on a redefined population.
-
Timing: The timing of when the text is generated relative to the treatment is crucial. Pre-treatment text can be a confounding factor, while post-treatment text can be a mediator or an outcome, introducing biases if misinterpreted.
-
Measurement: Labels like "billing frustration" do not directly capture frustration but rather what the pipeline identifies as such. The accuracy of these classifications can vary across treatment groups.
-
Role: The role of a theme in a causal model is determined by the directed acyclic graph (DAG), not by the column name. This influences how the theme should be integrated into the analysis.
These four issues are not independent and interact with one another. A theme detected by an LLM inherits a selection footprint, a timing footprint, and a measurement footprint. Downstream regression sees a column of zeros and ones.
The problem does not lie in the fact that the pipeline produced a bad label, but in the fact that the label has inherited a data generation process that the downstream analysis never modeled.
Role and Timing: The Same Question
The first move an analyst makes with a theme derived from a transcription is implicit: they treat it as a covariate. Themes are integrated on the right side of the regression. The treatment is the variable of interest, the outcome is on the left, and the theme is "controlled for."
This phrase, "controlled for," implies work that the analyst has not verified. Controlling for a variable adjusts the part of the treatment-outcome relationship that passes through it. Whether this adjustment is beneficial or harmful entirely depends on the position of the variable in the causal graph, and this position is determined by timing.
Pre-treatment text can act as a confounding factor. If a customer called about billing in January and the retention offer was sent in March, the call captures something about the customer's state that may influence both who received the offer and who churned. Conditioning on the theme here can reduce omitted variable bias, provided that the theme truly proxies the relevant construct.
Concurrent text, generated as part of the treatment itself, is not a covariate. If the treatment is a call from a retention agent and the theme comes from that call, the theme is part of the intervention. Conditioning on it does not correct for bias; it removes part of the effect that the analyst is trying to measure.
Post-treatment text is the most dangerous category, as it is the most likely to be misclassified as a confounding factor by an analyst working from a flat table without a time index. A customer who received a retention offer in March and called to complain in April produced a transcription that reflects, at least in part, their response to the treatment. Conditioning on a theme extracted from that call is conditioning on a post-treatment variable.
A Concrete Example
Let’s consider a synthetic but realistic scenario. Customers are targeted for a retention offer based on a model that detects price sensitivity. Both the attribution of the offer and customer churn depend on this underlying price sensitivity, which the analyst cannot observe. Customers more sensitive to price are more likely to receive the offer and to churn, and they are also more likely to call support and express billing shock. The theme "billing shock" is generated from these post-treatment calls.
The naive analyst joins the theme to the customer table, fills NULL values with zero, and runs a logistic regression of churn on the offer plus billing shock.
The true effect of the offer on churn is −0.50 in log-odds. The offer is supposed to reduce churn, and in the data generation process, it does. Here’s what four specifications return:
-
Naive Specification (with billing shock): +0.12 (the offer appears harmful)
-
Removed Specification (without billing shock): +0.24 (the offer still appears harmful)
-
Oracle Specification (with price sensitivity): −0.55 (the offer reduces churn)
-
True Effect (DGP): −0.50 (the offer reduces churn)
Because the attribution of the offer is already confounded by price sensitivity, removing the bad control does not make the design valid. It merely eliminates an additional source of distortion.
The mechanism behind the sign reversal in the naive specification deserves examination. Churn influences the probability of calling, as customers who churn are more likely to call. Billing shock is only observed for customers who called, since the theme requires a transcription to exist. Conditioning on billing shock thus conditions on a downstream consequence of churn. Among customers with a billing shock equal to one, the relationship between the offer and price sensitivity has been distorted, as both variables now help explain why the customer was flagged.
The methodological point generalizes. A variable derived from a transcription has a position in the causal graph determined by when the text was generated relative to the treatment, who generated it, and what process produced the label. Role and timing are the same question viewed from different angles. These variables come with a structural footprint that the analyst must take into account.
Brief IA — L'actualité IA en français
L'essentiel de l'actualité de l'intelligence artificielle, décrypté et expliqué chaque jour.