{"slug": "relm-local-llms-as-base-r-objects-with-interpretability", "title": "Relm – local LLMs as base-R objects, with interpretability", "summary": "The R-ebirth project released relm, an R package with a Rust native core that embeds llama.cpp to expose local LLMs as base-R objects, supporting loading, generation, embeddings, activation tracing, steering, and ablation. The package aims to make R a first-class environment for scientific research on AI interpretability and machine learning, with all numerical features validated against an independent reference.", "body_md": "**R-ebirth** aims to make R a first-class environment for scientific research on\ndata and AI — mechanistic interpretability (\"AI neuroscience\"), machine learning\nincluding topic modelling, and the life sciences — while staying simple for\nresearchers.\n\nIt is delivered as ** relm**: an R package with a Rust native core that\nembeds a patched\n\n`llama.cpp`\n\n, exposing local LLMs (loading, generation,\nembeddings, activation tracing, steering, and ablation) as base-R-idiom functions\nreturning plain `data.frame`\n\ns and `matrix`\n\nes.*Topic modelling with no Python: llm_embed() → UMAP → HDBSCAN → the model names\neach cluster. One of two runnable demos — see the package README.*\n\nUsing the package?Start with the[package README](quickstart, examples, the two demos) and[docs/getting-started.md](install options — binaries or from source — a first run, and troubleshooting). This page is the repository/developer overview.\n\nThe first public release is here. `relm`\n\nloads local GGUF models and exposes,\nas base-R objects:\n\nmodel loading,`llm()`\n\ntokenization;`llm_tokens()`\n\ntext generation,`llm_generate()`\n\nnext-token distributions;`llm_logits()`\n\ntext embeddings;`llm_embed()`\n\nactivation tracing,`llm_trace()`\n\nsteering,`llm_steer()`\n\nablation — the mechanistic-interpretability core;`llm_ablate()`\n\nchecksum-verified fetch of pinned models.`llm_download()`\n\nEvery numerical feature is validated value-for-value against an independent\nreference (harness B). Vision (image inputs) is the next release (v0.2.0); v0.1.0\nis text-only. The full plan is in `ROADMAP.md`\n\n.\n\n```\nrebirth/            the R package (R/, src/ + src/rust/ extendr crate, tests/, vignettes/)\nrust/               Cargo workspace: rebirth-ffi (R <-> Rust boundary), rebirth-llm (engine)\nrebirth/src/llama.cpp/   pinned, patched llama.cpp (vendored; see its VENDORING.md)\ntests/llm-golden/   Harness B numerical goldens\ntests/demos/        the two reference demos (anatomy lab; topics without Python)\n```\n\n`CLAUDE.md`\n\n, `SOLO-PHASE-PLAN.md`\n\n, `ROADMAP.md`\n\n, `API-GRAMMAR.md`\n\n,\n`ARCHITECTURE.md`\n\n, `DECISIONS.md`\n\n, and `THESIS-PLAN.md`\n\n. If anything else\ndisagrees with these files, the files win.\n\nEnd users install prebuilt binaries from r-universe (no toolchain required).\nBuilding from source requires R (>= 4.5), a C toolchain, a Rust toolchain\n(`rustup`\n\n; the pinned channel is in `rust-toolchain.toml`\n\n), and CMake (>= 3.28)\nfor the vendored engine.\n\n```\n# native workspace\ncd rust && cargo test && cargo clippy --all-targets -- -D warnings\n\n# R package\nR CMD build rebirth && R CMD check relm_0.1.0.tar.gz\n```\n\nDual-licensed **MIT OR Apache-2.0** — see [LICENSE.md](/Vadale/R-ebirth/blob/main/LICENSE.md). The vendored\n`llama.cpp`\n\nis MIT (see `NOTICE`\n\n). The name is protected: modified redistributions\nmust rename (see [TRADEMARK.md](/Vadale/R-ebirth/blob/main/TRADEMARK.md)).", "url": "https://wpnews.pro/news/relm-local-llms-as-base-r-objects-with-interpretability", "canonical_source": "https://github.com/Vadale/R-ebirth", "published_at": "2026-07-09 09:58:28+00:00", "updated_at": "2026-07-09 10:12:58.414330+00:00", "lang": "en", "topics": ["large-language-models", "ai-tools", "ai-research", "developer-tools"], "entities": ["R-ebirth", "relm", "llama.cpp", "R", "Rust"], "alternates": {"html": "https://wpnews.pro/news/relm-local-llms-as-base-r-objects-with-interpretability", "markdown": "https://wpnews.pro/news/relm-local-llms-as-base-r-objects-with-interpretability.md", "text": "https://wpnews.pro/news/relm-local-llms-as-base-r-objects-with-interpretability.txt", "jsonld": "https://wpnews.pro/news/relm-local-llms-as-base-r-objects-with-interpretability.jsonld"}}