Large Language Models as Implicit Sociological Models: Reconstructing Voting Behaviour from Sociodemographic Profiles
Authors: Roman Neruda, Martin Bakoš, Josef Šlerka, Vít Tuček, Petra Vidnerová, Gabriela Kadlecová
Organizations: Institute of Computer Science, Czech Academy of Sciences, Prague, Czech Republic. · Faculty of Arts, Charles University, Prague, Czech Republic. · distil labs, Berlin, Germany.
Large language models (LLMs) trained on large-scale internet corpora encode extensive statistical regularities about social identities, attitudes, and political behaviour. This paper introduces and evaluates a methodological framework that leverages these latent representations to reconstruct aggregate voting behaviour from individual-level sociodemographic profiles. We operationalize LLMs as implicit sociological models by conditioning them on demographic descriptions, eliciting probabilistic turnout and party preferences, and aggregating individual outputs via a soft voting procedure. Using the 2021 Czech parliamentary election as a validation case, we demonstrate that contemporary LLMs reproduce official election outcomes with low mean absolute error, recover known political bloc structures, and align with independently established sociodemographic gradients. The contribution of this work is methodological rather than predictive: we show how LLMs can be systematically interrogated as compressed representations of social reality, offering a novel exploratory instrument for computational social science while clearly delineating its epistemic and ethical limits.
Figures & tables
Model
Context Window
Max Output Tokens
Knowledge Cutoff
GPT-4o-mini
128,000
16,384
Oct 2023
GPT-4o
128,000
16,384
Oct 2023
GPT-4.1-nano
1,047,576
32,768
Jun 2024
GPT-4.1
1,047,576
32,768
Jun 2024
Table 1: Model Specifications
Parameter
Value
temperature
0
top_p
1
parallel_tool_calls
true
truncation
disabled
service_tier
auto
store
true
Table 2: OpenAI API Configuration Parameters
Model
P(voted)=0
Undefined Preference
Overlap (Undefined ∩P=0 )
GPT-4o-mini
2.65%
2.65%
100.0%
GPT-4o
0.00%
0.00%
–
GPT-4.1-nano
61.37%
62.14%
95.0%
GPT-4.1
0.00%
0.00%
–
Table 3: Distribution of Absolute Turnout Predictions and Undefined Party Preferences
Figure 1: Voting simulation results using soft voting, for the GPT-4o-mini model (left) and the GPT-4o model (right).
Figure 2: Voting simulation results using soft voting, for the GPT-4.1-nano model (left) and the GPT-4.1 model (right).
Figure 3: Mean Absolute Error (MAE) between Predicted, Claimed, and Actual voting behaviour in Czechia and across all 14 Czech regions for GPT-4o-mini model.
Figure 4: Mean Absolute Error (MAE) between Predicted, Claimed, and Actual voting behaviour in Czechia and across all 14 Czech regions for GPT-4o.
Figure 5: Correlation matrix of predicted vote shares for the GPT-4o-mini model.
Figure 6: Correlation matrix of predicted vote shares for the GPT-4o model.
Figure 7: The values are Pillai’s trace statistics, interpreted here as indicators of explained multivariate variance by each variable in MANOVA that was performed for each model. The values in the brackets are the p-values.
Figure 8: Mean absolute error to the real election outcomes. Columns Kantar CZ, Median and STEM stand for latest pre-election polls of three major Czech polling agencies. The column “claimed” is given by the self-reported values from the panel dataset.
Figure 9: MAE for the latent knowledge which was extracted by two different prompts.
Figure 10: Best 2D alignment between the inter-party distances in the CHES dataset and the LLMs output.