Downloads · 30 days
29
3% of all-time downloads
Quazim0t0/Escarda-86M-Base-JL
Escarda-86M-Base-JL is a text generation model from Quazim0t0. Use it when you need the model to write or continue text. It is set up for transformers. The card lists the license as apache-2.0.
Downloads · 30 days
29
3% of all-time downloads
All-time downloads
1.1K
Public
Parameters
97.3M
392 MB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors389 MB · 99%
From the Hugging Face model README
This is the Jet-Long edition of Escarda-86M-Base.
It extends the usable context from the native 4,096-token training window to
10,240 tokens with no fine-tuning and no change to short-context behaviour,
by adding dynamic bifocal RoPE from Jet-Long (arXiv:2607.07740, NVIDIA).
Jet-Long pairs a local window (w0 = 2048, classic RoPE) with a remote window
whose position map aliases far-apart tokens back onto the pretrained rotation grid:
f(x) = floor(x / G), G = max(1, ceil(L / 4096))
G adapts to the current sequence length L, so:
L ≤ 4096 → G = 1 → f is the identity → the model is bit-for-bit the base model.
(Verified: max |Δlogit| between Jet-Long on/off within the window is 0.000e+00.)L > 4096 → the remote window keeps every rotation in-distribution, so the model
extrapolates instead of collapsing.Implementation notes specific to this SpikeWhaleLM build:
use_derf=False) — the standard Jet-Long merge applies.use_jetlong=true, jetlong_w0=2048, jetlong_w_pretrained=4096,
max_position_embeddings=10240. Set use_jetlong=false to recover the exact base model.| Context length | Base model | This Jet-Long model |
|---|---|---|
| ≤ 4,096 (in-window) | (identical — Jet-Long is a no-op) | (identical) |
| 10,240 | 59.68 | 16.04 |
Beyond the training window the base model's perplexity blows up while Jet-Long stays flat — and long-context generation stays grammatical where the base model degrades into word-salad.
Jet-Long is on by default in this repo. Pass explicit position_ids so RoPE gets true
absolute positions during cached decode:
import torch
from transformers import AutoModelForCausalLM
m = AutoModelForCausalLM.from_pretrained("Quazim0t0/Escarda-86M-Base-JL", trust_remote_code=True)
ids = ... # up to ~10,240 tokens
pos = torch.arange(ids.shape[1]).unsqueeze(0)
out = m(input_ids=ids, position_ids=pos, use_cache=True) # prefill, then decode step-by-step
Method: Tang, Wang, Gu, Han, Cai — “Jet-Long: Efficient Long-Context Extension with Dynamic Bifocal RoPE”, arXiv:2607.07740. Applied here zero-shot to SpikeWhaleLM; no weights were retrained.
Escarda-86M-Base is a ~86M-parameter, from-scratch decoder-only language model — the
base sibling of Quazim0t0/Escarda-86M
(the chat-tuned model). It shares the same SpikeWhaleLM architecture (Multi-head Latent
Attention, an n-gram "engram" memory, hash-lookup layers, hyper-connections, an HRM
refinement step, and JEPA / multi-token-prediction training objectives) and the same
custom ChatML-aware tokenizer.
This checkpoint is a JEPA-distilled base. It is best used as a starting point for continued pretraining / fine-tuning rather than as a chat assistant.
Related models: SFT / chat model → Quazim0t0/Escarda-86M · live demo → Escarda-86M-Chat Space
Trained using Modal's credits during the Small Models, Big Adventures Hackathon.
| Parameters | ~85.7M (tie_word_embeddings=True) |
| Type | Decoder-only LM (SpikeWhaleLM, model_type: spike_whale) |
| Hidden size / layers | 640 / 16 |
| Attention | 10 heads (head_dim=64), 1 KV head (MQA), MLA low-rank Q/O, decoupled RoPE(16)+NoPE(48), QK-norm |
| Context length | 4096 tokens |
| Vocab | 16,512 (custom length-max tokenizer) |
| License | Apache-2.0 |
For the full architecture description see the chat model's card.
These models are built on SpikeWhaleLM, a custom ~86M-parameter decoder-only transformer (16 layers, hidden size 640, 4096-token context, 16,512 vocab, tied input/output embeddings). It combines several non-standard components:
<a href="https://hfviewer.com/Quazim0t0/Escarda-86M-Base?utm_source=huggingface&utm_medium=embedded_model_card&utm_campaign=Quazim0t0__Escarda-86M-Base_card&utm_content=embedded_card_open_viewer&from=embedded-model-card" target="_blank" rel="noopener"> <img src="https://hfviewer.com/api/card.svg?source=Quazim0t0%2FEscarda-86M-Base&granularity=auto&v=20260516-title-pills-card" alt="Architecture graph for Quazim0t0/Escarda-86M-Base. Open in hfviewer" width="100%" /> </a>JEPA vs HRM. The Escarda models are trained with both HRM refinement and a JEPA (Joint-Embedding Predictive Architecture) auxiliary objective (
use_hrm_refine=True,use_jepa=True) — the JEPA term predicts future latent states during training to shape the model's representations. The sibling Byrne models drop JEPA and use HRM refinement only.
These models use SpikeTokenizer, a custom byte-level "length-max" (greedy
longest-match) tokenizer with a 16,512-token vocabulary — not a standard BPE/HF
tokenizer. Text is UTF-8 encoded, each byte mapped to a latin-1 character, then greedily
matched against the vocab using the longest key that fits at each position. It is
ChatML-aware, with atomic special tokens for framing and reasoning/tool markers
(<|im_start|>, <|im_end|>, <think>/</think>, <begin_solution>/<end_solution>,
tool-call markers) plus <bos>/<eos>/<pad>/<unk>. It ships as a PreTrainedTokenizer
subclass (spike_tokenizer.py) and loads via
AutoTokenizer.from_pretrained(..., trust_remote_code=True).
splits. byte_ppl is exp(sum_NLL_nats / total_UTF8_bytes) on WikiText-2 test (tokenizer-
independent). BLiMP is fraction of minimal pairs with logprob(good) > logprob(bad)
(12 paradigms × 150). Stderr is binomial sqrt(p(1-p)/n).
| Metric | Value |
|---|---|
| WikiText-2 byte_ppl ↓ | 2.2228 |
| BLiMP acc ↑ | 0.7144 |
| Task | acc | ± | acc_norm | ± |
|---|---|---|---|---|
| arc_easy | 0.3801 | 0.0100 | 0.3615 | 0.0099 |
| arc_challenge | 0.1886 | 0.0114 | 0.2235 | 0.0122 |
| hellaswag | 0.2759 | 0.0045 | 0.2832 | 0.0045 |
| winogrande | 0.5162 | 0.0140 | — | — |
| piqa | 0.5843 | 0.0115 | 0.5631 | 0.0116 |
| openbookqa | 0.1300 | 0.0150 | 0.2500 | 0.0194 |
| boolq | 0.5138 | 0.0087 | — | — |
| Metric | Value |
|---|---|
| acc | 0.2536 ± 0.0087 |
| acc_norm | 0.2348 ± 0.0085 |
n = 2,500 · chance = 0.25.
Note: as a distilled base, this checkpoint has the lowest byte-perplexity of the Escarda family but trades off downstream task accuracy — a good reminder that perplexity alone is not a reliable capability ranking. For the strongest chat behaviour use Escarda-86M; use this model when you want a low-loss base to continue pretraining or fine-tune.
Fitting the Chinchilla data term to this model's own pretraining loss curve gives:
L(D) ≈ 2.611 + 77,715 · D^(−0.537) (nats/token, R² = 0.92)
From that fit:
Caveats: single-size fit (folds irreducible loss + capacity floor into one constant); the cosine-LR decay inflates the fitted exponent, so treat β as an upper bound; token counts are anchored to the ~20B figure and scale linearly if that differs.
Custom architecture — load with trust_remote_code=True (the modeling code ships in this
repo via auto_map):
from transformers import AutoModelForCausalLM
model = AutoModelForCausalLM.from_pretrained(
"Quazim0t0/Escarda-86M-Base", trust_remote_code=True)
The tokenizer is the custom SpikeTokenizer (tokenizer.json, algorithm: length-max);
load it with the spike_tokenizer.py helper from the project rather than AutoTokenizer.
Built with Modal credits during the Small Models, Big Adventures Hackathon, and released to the community as a base to build on.
<!-- CITE_START -->If you use this model, please cite:
@misc{escarda86mbase,
title = {Escarda-86M-Base: A ~86M-parameter SpikeWhaleLM},
author = {Dean Byrne (Quazim0t0)},
year = {2026},
howpublished = {HuggingFace, \url{https://huggingface.co/Quazim0t0/Escarda-86M-Base}},
note = {Quazim0t0/Escarda-86M-Base}
}
<!-- CITE_END -->
The Byrne family uses HRM refinement. Escarda = Byrne + JEPA (Joint-Embedding Predictive head) added alongside HRM in both the vision encoder and the LM trunk — auxiliary only, zero inference cost.
Vision encoder (DINOv2 teacher-alignment, n=1024 held-out):
| Byrne-VE | Escarda-VE | |
|---|---|---|
| Params | 39.34M | 39.60M (+JEPA head) |
| CLS cosine | 0.776 | 0.771 |
| PATCH cosine | 0.600 | 0.584 |
| JEPA self-consistency | — | 0.040 |
Docling (same held-out doc images, atomic DocTags): both emit well-formed DocTags;
Byrne-Docling is marginally more complete on the hardest samples (closes </formula>,
includes the <code> wrapper), consistent with its slightly higher teacher-alignment.
Escarda-Docling is structurally on par and adds the JEPA representation-learning trait.
Pros/cons. Byrne (HRM): higher teacher-alignment, all capacity on distillation fidelity; no self-supervised objective. Escarda (HRM+JEPA): self-supervised neighbour-prediction (richer spatial structure) at zero inference cost, trading ~1–3% teacher-alignment. Same size class.
Family repos: Byrne-VE · Escarda-VE · Byrne-Docling-131M · Escarda-Docling-126M
The n-gram Engram memory in the original weights was degenerate: with the frozen LSH compressor at init scale, every token hashed to bucket 0, so only one table row ever received gradient. This revision rescales the (frozen) compressor and broadcasts the learned bucket-0 vector across all table rows.
Outputs are bit-identical to the previous revision (verified: max logit difference 0.0 across a prompt battery). The only change: the Engram's hash now spreads across the full table and every bucket is independently trainable — so if you distill or SFT on top of this base, the n-gram memory will actually learn instead of staying a constant bias.