PulseExploreJournal ClubDebatesTrendingResearchersJournals
Instagram
HomeExploreJournal ClubTrending
Synapse
⌘+K
Synapse
February 2, 20260 citationsOpen Access

From embeddings to explainability: a tutorial on large-language-model-based text analysis for behavioral scientists

View Full Paper
DRDebelak RudolfTKT. KochMAMatthias Aßenmacher

Key Points

  • The aim is to provide an accessible introduction to LLMs and their application in behavioral science research.
  • Discussed the Transformer architecture and its role in text modeling.
  • Guided through the preparation of text data for analysis.
  • Demonstrated the generation of text embeddings using pretrained models.
  • Explained fine-tuning models for specific text classification tasks.
  • Introduced interpretability methods to explain model predictions.
  • Simplifying the integration process for behavioral scientists using LLMs.
  • Enhanced understanding of text analysis through practical applications of Transformer models.
  • Empowered researchers to analyze and interpret textual data effectively.

Abstract

Large language models (LLMs) are transforming research in psychology and the behavioral sciences by enabling advanced text analysis at scale. Their applications range from the analysis of social media posts to infer psychological traits to the automated scoring of open-ended survey responses. However, despite their potential, many behavioral scientists struggle to integrate LLMs into their research because of the complexity of text modeling. In this tutorial, we aim to provide an accessible introduction to LLM-based text analysis, focusing on the Transformer architecture. We guide researchers through the process of preparing text data, using pretrained Transformer models to generate text embeddings, fine-tuning models for specific tasks such as text classification, and applying interpretability methods, such as Shapley additive explanations and local interpretable model-agnostic explanations, to explain model predictions. By making these powerful techniques more approachable, we hope to empower behavioral scientists to leverage LLMs in their research, unlocking new opportunities for analyzing and interpreting textual data.

Ask AI
Helpful
Bookmark
Share
View Full Paper

Cite This Study

Rudolf et al. (2025) studied this question.

synapsesocial.com/papers/6980fbe1c1c9540dea80db39https://doi.org/10.5167/uzh-283735
Ask AI
Helpful
Bookmark
Share
View Full Paper