Coding Open-Ended Survey Text Without Leaving Stata: the catllm Package for LLM-Assisted Content Coding
Poster · 2026 Stata Conference · Boston, MA (shared in conference proceedings) · October 1, 2026
Open-ended survey items capture what closed-ended items cannot, and are routinely dropped from analysis because hand-coding them does not scale. catllm puts the whole coding loop inside Stata: extract/explore discover categories directly from the data, classify applies a category scheme and returns ordinary Stata indicator variables ready for tabulate or regress. It supports OpenAI, Anthropic, and Google models as well as local open-weight models through Ollama, so restricted-use data need never leave the analyst’s machine.
