We introduce
rnj-1.5-instruct
, a long-context follow-up to
rnj-1-instruct
, that extends the context window from 32k to 160k. For more context and details about the Rnj-1 family, and
rnj-1-instruct
in particular, please see
this page
and our
blog
.
rnj-1.5-instruct
extends rnj-1's long context abilities beyond 32k, scoring 77% on RULER on a 128k context window. This release also offers stronger coding abilities on a wider range of harnesses. We improve our SWE-Bench Verified performance on
mini-swe-agent
by 5% and we outperform, by a significant margin, the best known 8B model
results
on the SWE-Agent harness, achieving a 40% resolve rate.
The improvements in rnj-1.5 emerge from our work in a few key areas:
Architecture:
To ease inference compute and storage costs that grow with sequence length for global self-attention, we explore block-local attention layers [5, 6] which carry fixed compute and storage cost per position. Following [4], we interleave block-local self-attention with global attention, keeping layers predominantly local and a few global layers to enhance associative interactions over long distances. After careful ablations, we discovered a local-global layer pattern
LLLGLLLGLLLGLGGGGGLGLLLGLLLGLLLL
, where
L
and
G
stand for block-local and global self-attention layers respectively, that lumps global layers in the middle and retains the model's global attention capabilities while gaining the latency benefits of local self-attention. Our results support the findings from GLM-5 [1].
Evals:
We discovered that RULER's needle-in-a-haystack (NIAH) task has two fundamental issues. (a) The predominant focus on text-based evaluation overlooks measuring long context abilities necessary for coding tasks. (b) The needle is a foreign random string in a coherent English essay, which shifts the task from identifying an indistinguishable needle to picking the "odd one out." We thus created a granular NIAH eval called "lookback evals" from GitHub repositories. In lookback evals, the needles are semantically camouflaged within the haystack. We add a canary marker to the needles to distinguish between the model's recall from its weights versus retrieval capabilities. For granular insights on long-context abilities, we bucket performance for needle positions over (0–8k, 8k–16k, 16k–32k) distances from the end. Rnj-1.5's performance remains consistent across buckets, showcasing stronger retrieval capabilities throughout the long context.
Long context mid-training data:
STEM:
We convert a large collection of science-focused PDF documents into text using OlmOCR 2 (which gave strongest results on OCR benchmarks) unlocking ~75B high quality tokens [3].
Code:
Prior work [2] has shown that training on repository-level documents improves long-context code understanding. Following this approach, we concatenate files from code repositories in lexicographic order to expose the model to longer, repository-scale code contexts during mid-training. We also include repository-level fill-in-the-middle examples, using surrounding files and broader project structure to support infilling.
Long context tasks:
QA needles
— Similar to data created in [8], we take a document, split into paragraphs, and select a range of paragraphs adding up to 2k tokens. We then ask a strong model to create a QA pair that tests the reading comprehension. Task is to generate answer given question and document. We pack the pairs.
Practice Problems
— we create synthetic QA pairs with reasoning from practice problems in our PDFs. The context contains complete paragraphs, always ending with the page preceding the practice problem page.
Paragraph Swaps
— Similar to permutation data created in [9], we take (two|three) paragraphs in the document and (swap them|permute them so that each paragraph is in one of the others' place). If they were put back in their proper locations, the document would read more coherently and consistently. The task is to determine which paragraphs were permuted, and (without explanation), output (the paragraph | first five words of the paragraph) that should appear (earlier|later|first|second|third) in the document.
Common Word Extraction (Frequency Thresholds)
— Given a document (list of words), the task is to output a list of all words (longer than four characters) that occur with frequency above some threshold, sorted in alphabetical order. The threshold is chosen randomly subject to a constraint that the resulting list of words is not too long (≤ 10). Our task has some conceptual similarities to the CWE synthetic aggregation task used in [7]; however, our task does not require model prompting to generate QA pairs and is therefore simpler yet effective.
Expanded SWE trajectories:
We created a synthetic task generation pipeline that allowed us to mine ~200k SWE tasks from 3500 GitHub repositories. Each task consists of the issue description, dockerized repository at failing commit, pass-to-pass, and fail-to-pass tests. Three teacher models were used to generate ~600k synthetic trajectories in the mini-swe-agent environment, including both resolved and unresolved trajectories.
Software infrastructure:
For vLLM compatibility, we implement our block-local self-attention modifications in Triton.
SWE-Bench Verified number for
rnj-1.5-instruct
is reported with the SWE-Agent harness. With the mini-swe-agent harness, we report a 25% resolve rate. RULER (128k) is overall RULER score at 128k context length.
How to use
See the Rnj 1.0
model card
. You just need to replace
rnj-1.0-instruct
with
rnj-1.5-instruct
. We added support to
vLLM
in v0.20.0.
Known limitations
See the Rnj 1.0
model card
. In addition, we optimized our model for long-context comprehension and not long-context generation. Consequently, rarely we have seen some junk tokens show up with extremely longer generations.
[3] J. Poznanski et al., "olmOCR 2: Unit Test Rewards for Document OCR,"
arXiv preprint arXiv:2510.19817
, 2025.
https://arxiv.org/abs/2510.19817
[4] I. Beltagy et al., "Longformer: The long-document transformer."
arXiv preprint arXiv:2004.05150
(2020).
https://arxiv.org/abs/2004.05150
[5] N. Parmar, et al. "Image transformer."
International Conference on Machine Learning
. PMLR, 2018.
[6] A. Vaswani, et al. "Scaling local self-attention for parameter efficient visual backbones."
Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition
. 2021.
@misc{rnj1_5_instruct,
title = {{Rnj-1-5-Instruct}},
author = {{{Essential AI:}} Mike Callahan and Adarsh Chaluvaraju and Aleksa Gordić and Devaansh Gupta and Yash Jain and Philip Monk and Michael Pust and Tim Romanski and Peter Rushton and Ali Shehper and Divya Shivaprasad and Saurabh Srivastava and Anil Thomas and Alok Tripathy and Ameya Velingker and Ashish Vaswani},
year = {2026},
url = {https://huggingface.co/EssentialAI/rnj-1-5-instruct},
note = {Long-context Instruction-tuned model release}
}
Runs of EssentialAI rnj-1.5-instruct on huggingface.co
856
Total runs
-4
24-hour runs
35
3-day runs
94
7-day runs
335
30-day runs
More Information About rnj-1.5-instruct huggingface.co Model
rnj-1.5-instruct huggingface.co is an AI model on huggingface.co that provides rnj-1.5-instruct's model effect (), which can be used instantly with this EssentialAI rnj-1.5-instruct model. huggingface.co supports a free trial of the rnj-1.5-instruct model, and also provides paid use of the rnj-1.5-instruct. Support call rnj-1.5-instruct model through api, including Node.js, Python, http.
rnj-1.5-instruct huggingface.co is an online trial and call api platform, which integrates rnj-1.5-instruct's modeling effects, including api services, and provides a free online trial of rnj-1.5-instruct, you can try rnj-1.5-instruct online for free by clicking the link below.
EssentialAI rnj-1.5-instruct online free url in huggingface.co:
rnj-1.5-instruct is an open source model from GitHub that offers a free installation service, and any user can find rnj-1.5-instruct on GitHub to install. At the same time, huggingface.co provides the effect of rnj-1.5-instruct install, users can directly use rnj-1.5-instruct installed effect in huggingface.co for debugging and trial. It also supports api for free installation.