Package: fathom 0.1.0

fathom: Qualitative Coding and Measurement with Local Language Models

Qualitatively code a corpus by asking a local language model a set of questions about each document and reading the answer from the model's next-token probability distribution rather than parsing its text. Extraction never fails to parse, returns a probability per label, and reports the probability mass the model placed outside the label set. Includes the auditing steps that separate usable annotation from plausible-looking output. These inspect the documents that fired on an item and draw blinded samples for human coding. Requires a running Ollama server.

Authors:Jose J. Alcocer [aut, cre], Ewon Baik [ctb], Karen Borglund [ctb], Alain S. Muñoz [ctb], Sandra S. Muñoz [ctb]

fathom_0.1.0.tar.gz
fathom_0.1.0.zip(r-4.7-any)fathom_0.1.0.zip(r-4.6-any)fathom_0.1.0.zip(r-4.5-any)
fathom_0.1.0.tgz(r-4.6-any)fathom_0.1.0.tgz(r-4.5-any)
fathom_0.1.0.tar.gz(r-4.7-any)fathom_0.1.0.tar.gz(r-4.6-any)
fathom_0.1.0.tgz(r-4.6-emscripten)
manual.pdf |manual.html✨
DESCRIPTION
card.svg |card.png
fathom/json (API)

# Install 'fathom' in R:
install.packages('fathom', repos = c('https://alcocer-jj.r-universe.dev', 'https://cloud.r-project.org'))

Bug tracker:https://github.com/alcocer-jj/fathom/issues

Pkgdown/docs site:https://alcocer-jj.github.io

Datasets:
  • ati - Mexican access-to-information requests
  • parlasent - UK parliamentary sentences, coded for sentiment on a six-level scale

On CRAN:

Conda:

quarto

3.18 score 4 scripts 16 exports 27 dependencies

Last updated from:fd309ad473. Checks:6 OK, 3 ERROR. Indexed: yes.

TargetResultTimeFilesSyslog
linux-develOK163
source / vignettesOK209
linux-releaseOK161
macos-releaseOK227
macos-oldrelOK296
windows-develERROR130
windows-releaseERROR116
windows-oldrelERROR161
wasm-releaseOK101

Exports:as_widecoder_referencecoding_sampleinspect_casesinstrumentitem_reportmeasureollama_backendprepare_audioprepare_imageprepare_videopreviewread_checkpointstemplate_itemsthreshold_sensitivityvalidate_sample

Dependencies:askpassclicpp11curldigestdplyrgenericsgluehttr2jsonlitelifecyclemagrittropensslpillarpkgconfigpurrrR6rlangstringistringrsystibbletidyrtidyselectutf8vctrswithr

A complete run
Overview | The corpus | Step 1. Select a model | Step 2. Code the qualitative instrument | Previewing the model call | Step 3. Extract response probabilities | Step 4. Read the results | Probabilities ($probs) | Calls ($calls) | Summarizing the results by question and label | Inspecting question-document pairs | The analysis matrix | Step 5. Validate the LLM results | Validating the sample using two coders | Validating the model against the coders | References

Last update: 2026-10-30
Started: 2026-10-30

Quick start
Installation | Tested Ollama models | Checking the server and the model | Working with an audio or video corpus | ffmpeg | macOS | Windows | Linux | whisperx | HuggingFace read token | Workflow summary

Last update: 2026-10-30
Started: 2026-10-30

What Mexicans ask their government for
Overview | The corpus | Step 1. Preprocess the corpus | Step 2. Code the qualitative instrument | Previewing the model call | Step 3. Extract response probabilities | Step 4. Read the results | Summarizing the results by question and label | The analysis matrix | Step 5. Check sensitivity to the cut point | References

Last update: 2026-10-30
Started: 2026-10-30