# LoRA's capacity can be predicted from a dataset's bit count

Original title: Predicting LoRA size for any dataset

> Hacker News story 50635783 · language: en · submitted 2026-11-24
> Web version: https://zeli.app/story/50635783
> About this feed: https://zeli.app/llms.txt · Agent guide: https://zeli.app/skill.md

▲ 99 · by [jxmorris12](<https://news.ycombinator.com/user?id=jxmorris12>) · 💬 11
[original](<https://engram.com/blog/lora-size>) · [HN discussion](<https://news.ycombinator.com/item?id=50635783>)

## Summary

Engram researchers derive a formula for how many bits a rank-r LoRA adapter can store, then validate it by generating synthetic datasets of exactly N bits via arithmetic coding and training adapters on them. Capacity rises roughly linearly at low rank before plateauing, and a single layer stores about 1.5 bits per parameter while 24 layers reach 3.3. The predictions let you pick the smallest rank that fits a real dataset.

## Key quote

> It turns out that models with more layers can store more per-parameter: a single layer with LoRA stores just 1.5 bits-per-parameter, while a 24-layer model can store 3.3 bits-per-parameter.

## HN discussion (11 comments)

### [augment_me](<https://news.ycombinator.com/item?id=50645749>)

> Memorizing a dataset =/= learning a task.
>
> Cross entropy of a finite dataset measures signal + noise(redundancy, quirks, typos, etc)
>
> If you have 10MB of math data, the underlying task of learning the reasoning pattern might have low entropy and fit in a much lower LoRA rank, even though memorizing the dataset requires more.
>
> On any task like GSM, Math500, Openthought3 this would just be massive overfitting.
>
> Also they assume that the 2M-token context chunking is independent but for example logs are usually not.
>
> \---
>
> I think this is good to point out, because the company seems to sell a solution to cram private company wikis into the Lora adapters, so the measures are upper bounds in terms of info due to their assumption of memorization.

### [Samin100](<https://news.ycombinator.com/item?id=50647536>)

> The arithmetic coding widget halfway down the blog post is honestly really great. I'm surprised I haven't seen token probabilities expressed as bits of entropy before this.

### [bee_rider](<https://news.ycombinator.com/item?id=50645422>)

> Are there related questions along the lines of “what elements could I add to the dataset that would most increase the LoRA size.”
>
> Is there a metric other than size that can describe a LoRA’s… usefulness? Trueness to the original? (Is trueness to the original a positive or negative in this context, anyway?). Then maybe we can formulate questions about things like <usefulness>/<size>.

---

## Cite

- Page: https://zeli.app/story/50635783
- Date: 2026-11-24
- Source: engram.com (https://engram.com/blog/lora-size)
- Hacker News: https://news.ycombinator.com/item?id=50635783

## Other languages

- zh: https://zeli.app/zh/story/50635783 · markdown: https://zeli.app/zh/story/50635783.md
- ja: https://zeli.app/ja/story/50635783 · markdown: https://zeli.app/ja/story/50635783.md
- ko: https://zeli.app/ko/story/50635783 · markdown: https://zeli.app/ko/story/50635783.md
- de: https://zeli.app/de/story/50635783 · markdown: https://zeli.app/de/story/50635783.md
- es: https://zeli.app/es/story/50635783 · markdown: https://zeli.app/es/story/50635783.md
- ru: https://zeli.app/ru/story/50635783 · markdown: https://zeli.app/ru/story/50635783.md
