Skip to content

edgemodelr

0.4.5Package record

Local Large Language Model Inference Engine

0packages depend
3.4Kdownloads / year
–test coverage
13/13flavors OK

Overview

About

Enables R users to run large language models locally using 'GGUF' model files and the 'llama.cpp' inference engine. Provides a complete R interface for loading models, generating text completions, extracting vector representations, and streaming responses in real-time. Includes grammar-constrained generation for structured output, text classification, and retrieval-augmented generation (RAG) pipelines. Supports local inference without requiring cloud APIs or internet connectivity, ensuring complete data privacy and control. Based on the 'llama.cpp' project by Georgi Gerganov (2023) https://github.com/ggml-org/llama.cpp.

Changes in 0.4.5

Bug fixes

  • **Each completion now starts from an empty context.** The KV cache was never cleared between calls, so every prompt was appended after the previous prompt and answer. Answers depended on earlier calls, and after a few calls the context filled up and every later call failed with "Failed to process prompt". This affected edge_completion(), edge_stream_completion(), edge_grammar_completion() and the functions built on them.
  • **Generation can be interrupted.** Esc/Ctrl-C now stops a long generation, and timeout_seconds in edge_completion() works: it used to have no effect until the call finished. A timeout raises a "timed out" error. The sampler is freed on every exit path.
Show all changes in 0.4.5Hide the rest of the changes in 0.4.5
  • **edge_index_documents() no longer hangs.** Splitting any document longer than chunk_size looped forever. chunk_overlap must now be smaller than chunk_size.
  • **edge_download_model() checks checksums for model names.** With a name from edge_list_models(), expected_sha256, verify_checksum and trust_first_use were silently ignored.
  • **trust_first_use = TRUE no longer fails after a download by URL.** Storing the hash raised an error once the file had been downloaded.
  • **edge_install_cuda() no longer times out.** The ~200 MB download used R's default 60 second timeout.
  • **edge_clean_cache() keeps the CUDA backend and checksum store.** Both were deleted once they were older than max_age_days. The size limit now removes the oldest files until the cache is under the limit; before, some caches could never get under it.
  • **Prompts longer than the batch size crashed the session.** The prompt was passed to the model in a single call, which llama.cpp only accepts up to n_batch tokens (512 with the default n_ctx = 2048), so any prompt between that and the context size hit an internal assertion, for example a long edge_ask() context. The prompt is now fed in n_batch-sized chunks in completion, streaming and grammar-constrained generation.
  • **Internal llama.cpp assertions no longer kill the R session.** No ggml abort callback was ever installed, so any GGML_ASSERT/GGML_ABORT hit on R's thread ended in raise(SIGABRT). These now surface as an ordinary R error ("llama.cpp internal error: ...") and the session keeps working. Assertions on ggml worker threads still abort, because R cannot be signalled from another thread.

From NEWS.md in the release

Install

Health

CRAN checks
13OK
Slowest check: 11.6 min · r-oldrel-windows-x86_64
Status changes
  • OK13 OK2026-10-14
  • WARNING12 OK, 1 WARNING2026-09-09
  • ERROR11 OK, 1 ERROR2026-04-25
  • NOTE11 OK, 3 NOTE2026-04-22
  • ERROR10 OK, 3 NOTE, 1 ERROR2026-04-18
Show 1 earlier changeHide 1 earlier change
  • NOTE11 OK, 3 NOTE2026-03-10
Advisories

none known

Documentation

In release 0.4.5
README· In the repository, left out of the releaseVignettesNoNEWSYes · 100% structured · mentions 0.4.5Citation fileYes · computed when R runs itWebsitenot declared in DESCRIPTION
Help pages
50 (10 internal)includes a package overview page
Examples that run
11%4 run in a plain check · 30 never run · 2 hold no code
Exported functions with examples
90%
Documented parameters
100%
Return-value docs
97%
Help pages citing references
0%

Downloads

3.4K
CRAN downloads in the past year
Rank #6,018 · ~9/day · ~287/mo
Daily download trend is not available in this view yet.
56830 days
1.4K90 days
3.4K1 year
Compare downloads with other packages →
Also on404 r2u6 autocran

Repository

18Stars
1Forks
4Open issues
0Open PRs
3Releases
294Commits
2Commit identities
294 commits · Last activity 2026-10-13 · Default branch at 0.5.0, ahead of CRAN 0.4.5 (checked 2026-10-21) · Discussions: 1 post
Responsiveness
How these are sampled
PRs merged (all time)
85%
Median days to close, 50 most recently updated closed issues
3
Median days to close, 50 most recently updated closed PRs
1

PRs over time

2026-07-14 · 32026-10-13 · 0
PracticesBeta

7 development-tooling and community-health practices detected across 5 families in the upstream repository

Checks run against github.com/pawanramamali/edgemodelr on 2026-10-21.

Continuous integration (2)
GitHub ActionsR CMD check workflow

The R CMD check workflow runs on Linux, macOS and Windows, and on R-devel

Governance and community (1)

The repository owner accepts GitHub Sponsors

Coverage (1)
Coverage reporting (Codecov)
CRAN release process (1)
cran-comments.md
Show all practicesHide 1 practice
Lint, format, editor (2)
lintrRStudio project
How this is detected·Detection ruleset v4 (2026-10-20)
AI coding toolsBeta

This repository shows signs of AI coding tools.

  • Codexfirst seen 2025-08-30
    Pull request it wrote: opened by a project member
  • Claude Codefirst seen 2025-09-02
    Named in .Rbuildignore: .claude, CLAUDE.md
    Named in .gitignore: .claude
How this is detected·Detection ruleset v4 (updated 2026-09-27)

Dependencies

Declared dependencies
11 external dependencies (excludes base and recommended)

Installing edgemodelr adds 1 package (1 with compiled code, 1.8 MB of source tarballs). Heaviest: Rcpp 1.8 MB.

Depends (1)
R >= 4.0
Imports (3)
Rcpputilstools
LinkingTo (1)
Enhances (0)
none
Reverse dependencies
0direct
0indirect

Nothing depends on this yet.

People & History

People (8)
Author, Maintainer since 0.1.0 (2025), Copyright holder
Author, Copyright holder · added in 0.1.4
Author of llama.cpp and GGML library
Contributor · added in 0.1.4
DRY sampler from Koboldcpp
Contributor, Reviewer · added in 0.1.4
Contributor, Copyright holder · added in 0.1.4
YaRN RoPE implementation
Contributor, Copyright holder · added in 0.1.4
YaRN RoPE implementation
Contributor · added in 0.1.4
Z-algorithm implementation
Copyright holder · added in 0.1.4
llama.cpp and GGML contributors
Releases (8)

Pick two releases to compare their code metrics.

  • 0.4.5Latest
    record
    2026-10-12 · current release · diff ↗ ·
    3 hours in CRAN's queue
    Listed in CRAN's incoming queue from 2026-10-11 22:36 to 2026-10-12 01:57 UTC, in 2 readings.
  • 0.4.3
    record
    2026-09-08 · diff ↗
  • 0.4.1
    record
    2026-05-26 · diff ↗ ·
    added 19 exports
    edge_install_cuda, edge_install_cuda_toolkit, edge_reload_cuda, edge_cuda_info, edge_grammar_completion, edge_json_grammar, edge_extract, edge_classify, edge_embeddings, edge_similarity, edge_model_n_embd, edge_similarity_matrix, edge_map, edge_extract_batch, edge_index_documents, edge_search, edge_ask, edge_chat_completion, edge_serve
  • R
    R 4.6.0 released · 2026-04-24
  • 0.2.0
    record
    2026-02-26 · diff ↗ ·
    added 2 exports
    edge_cache_info, edge_simd_info
  • 0.1.6
    record
    2026-02-07 · diff ↗
  • 0.1.5
    record
    2026-01-29 · diff ↗
  • unarchivedReturned to CRAN
    2026-01-22
  • 0.1.4
    record
    2026-01-22 · diff ↗ ·
    added 6 exports
    edge_download_url, edge_benchmark, edge_find_gguf_models, edge_find_ollama_models, edge_load_ollama_model, edge_small_model_config
  • archivedRemoved from CRAN
    2025-10-02
    repeated policy violation Misrepresentation of authorship Repeated submissions with platform-dependent code, incorrectly documented Repeated submissions whilst one is under consideration,
  • 0.1.0
    record
    2025-09-22
  • R
    R 4.5.0 released · 2025-04-11
Across CRAN, the median accepted release of the past year spent 23 hours in the queue, 90% under 11 days.How queue time is measured

Package metadata

First published
2025-09-22
Total releases
8 / 1 yrs
License
MIT + file LICENSE OSI
Minimum R
≥ 4.0
Download size
1.0 MB

Cite

Cite this package

Run in R for the authors' preferred citation:

citation("edgemodelr")

The package provides a citation file that builds its entry when R runs it. Run citation() to see it.

Cite the R Observatory

For a number measured here: a download total, a coverage figure, an archival date.

APA

Balamuta, J. J. (2026). R Observatory: Metrics for edgemodelr version 0.4.5 [Data set]. HJJB, LLC. Data release v2026-10-23. https://doi.org/10.5281/zenodo.21843040

From data release v2026-10-23, which the citation names so these numbers can be found later. More on citing and the projects behind them.

Report a problem with this page →

Privacy choices

These apply to this browser and are stored on this device only. Nothing about your choice is sent to us.

Read the privacy policy