The hardware and bandwidth for this mirror is donated by dogado GmbH, the Webhosting and Full Service-Cloud Provider. Check out our Wordpress Tutorial.
If you wish to report a bug, or if you are interested in having us mirror your free-software or open-source project, please feel free to contact us at mirror[@]dogado.de.

relm: Local Large Language Models as Base-R Objects

Load and run local large language models (through a vendored, patched 'llama.cpp') from R and work with them as plain data frames and matrices in base-R idiom. Provides model loading and tokenization (llm(), llm_tokens()), text generation (llm_generate()), next-token distributions (llm_logits()), embeddings (llm_embed()), and mechanistic interpretability tools – activation tracing (llm_trace()), activation steering (llm_steer()), neuron ablation (llm_ablate()), and grouped statistical probes (llm_probe()). Vision-language models loaded with their projector take image input in generation and embeddings. A checksum-verified downloader (llm_download()) fetches pinned models.

Version: 0.5.0
Depends: R (≥ 4.5.0)
Imports: methods, nanoarrow
Suggests: testthat (≥ 3.0.0), later (≥ 1.4.8), promises (≥ 1.5.0), glmnet, uwot, dbscan, quarto
Published: 2026-10-29
DOI: 10.32614/CRAN.package.relm
Author: Alessandro Vadala [aut, cre, cph], ggml authors [ctb, cph] (Bundled llama.cpp and ggml (MIT)), Authors of the bundled Rust and native dependencies [ctb, cph] (Individual authors, copyrights and licenses are listed in AUTHORS, RUST-NOTICES and THIRD-PARTY-NOTICES)
relm author details
Maintainer: Alessandro Vadala <vadale93 at gmail.com>
BugReports: https://github.com/Vadale/R-ebirth/issues
License: MIT + file LICENSE | Apache License (== 2.0)
Copyright: See inst/AUTHORS, inst/RUST-NOTICES and inst/THIRD-PARTY-NOTICES for bundled source authorship, copyrights and licenses.
URL: https://github.com/Vadale/R-ebirth, https://vadale.r-universe.dev/relm
NeedsCompilation: yes
SystemRequirements: Cargo (Rust's package manager) >= 1.85.0, rustc >= 1.85.0, cmake (>= 3.28), xz
Materials: README, NEWS
CRAN checks: relm results [issues need fixing before 2026-11-20]

Documentation:

Reference manual: relm.html , relm.pdf
Vignettes: The anatomy lab: locating sentiment in a language model (source, R code)
Build, preserve and evaluate a contrast direction (source, R code)
See, compare and record model interventions (source, R code)
Generation as a stream of R data (source, R code)
Topic modelling without Python (source, R code)
Seeing machines: a VLM answering questions about an image, locally (source, R code)

Downloads:

Package source: relm_0.5.0.tar.gz
Windows binaries: r-devel: not available, r-release: relm_0.5.0.zip, r-oldrel: relm_0.5.0.zip
macOS binaries: r-release (arm64): relm_0.5.0.tgz, r-oldrel (arm64): relm_0.5.0.tgz, r-release (x86_64): relm_0.5.0.tgz, r-oldrel (x86_64): relm_0.5.0.tgz

Linking:

Please use the canonical form https://CRAN.R-project.org/package=relm to link to this page.

These binaries (installable software) and packages are in development.
They may not be fully stable and should be used with caution. We make no claims about them.
Health stats visible at Monitor.