Modern LLMs know everything humanity has ever written. Edo-Cutoff LLM inverts that premise.
This model is pretrained exclusively on public-domain texts from the Edo period and earlier — Japanese woodblock-print books and the Chinese classics an educated person of that era would actually have read. It has never seen a modern webpage, a modern textbook, or a modern sentence. It does not know that the Earth orbits the Sun.
The interesting engineering problem is not building such a model — it is preventing contamination. Any modern text, any modern paraphrase, any modern tokenizer leaks 21st-century priors into the weights. This project therefore uses:
No modern text. Only pre-1868 public-domain sources.
No modern-model synthetic data. No rephrasing, no distillation.
A tokenizer trained from scratch on the period corpus (a modern tokenizer's vocabulary is itself a modern prior — and 2× less efficient here).
Everything is public domain by age, and re-distributable. No modern text is included.
Source
Scale
Content
License
NDL Next Digital Library — 古典籍 OCR
64,769 books · 2.49 B chars
Japanese woodblock books: literature, medicine, agriculture, travel, Buddhism, Confucian studies
Free reuse (copyright expired)
Kanseki Repository (KR1–5 經史子集叢)
3,943 texts · 0.78 B chars
Chinese classics read in Edo Japan: Four Books, Records of the Grand Historian, philosophers, poetry
CC BY-SA 4.0
Total
3.27 B chars ≈ 2.29 B tokens
CC BY-SA 4.0
Corpus composition
Notes on source selection. ctext.org was rejected despite covering the same public-domain works: its data is CC BY-NC-SA and bulk access is gated. The Kanseki Repository provides the same corpus under BY-SA with unrestricted bulk access. The Buddhist canon (KR6, 4,849 texts) was excluded because it is CBETA-derived and NC-encumbered — a real loss, since Edo scholars read it widely.
4. Tokenizer
A byte-level BPE trained from scratch on the period corpus. This is the single highest-leverage component: for a small model with a large vocabulary and long context, tokenizer efficiency directly buys training throughput and effective context.
Tokenizer efficiency
Tokenizer
Vocab
Japanese ↓
Literary Chinese ↓
Edo-mixed BPE (this work)
48,000
0.611
0.836
Edo JP-only BPE
32,000
0.673
0.935
GPT-4o (o200k_base)
~200,000
1.040
1.178
GPT-4 (cl100k_base)
~100,000
1.474
—
Fertility = tokens per character; lower is better. Measured on held-out Edo-period text.
~1.7× more efficient than GPT-4o and 2.4× more than GPT-4 on this domain. Byte-level construction means zero UNK by design — variant kana (変体仮名), rare glyphs, and kanbun are all representable. Normalization is NFC only; NFKC was rejected because it collapses the orthographic variants that define this corpus.
Fused cross-entropy is what makes this tractable: with a 48 K vocabulary at 2048 context, the logit tensor dominates activation memory and caps the micro-batch. Liger removes it, roughly doubling throughput over the naive configuration.
Checkpoints are pushed to the Hub every 100 steps, making the run resumable across ephemeral GPU rentals — training proceeds in whatever increments the budget allows.
6. Samples
Generated at step 500 (temperature 0.85, top-k 40). The model is deeply undertrained; these are stylistic fragments, not coherent prose.
The model has already internalized period-specific registers: court-rank genealogies (武鑑・系図体) from the first prompt, kanbun-kundoku expository prose (漢文訓読体) from the second, and Analects phrasing from the third. Learning the form of Edo writing precedes learning its content.
7. Quick Start
Colab (free GPU, public link)
Open edo_colab_demo.ipynb → set runtime to T4 GPU → Run all. A Gradio app with a public *.gradio.live URL launches automatically.
1hf download zary0/edo-cutoff-1b ckpt_last.pt --local-dir ckpt # full state (12.9 GB, incl. optimizer)2python scripts/train.py --config configs/edo_1b.json --liger --grad-ckpt \3 --device cuda --dtype bf16 --resume ckpt/ckpt_last.pt --hf-repo zary0/edo-cutoff-1b
Files
File
Size
Purpose
edo_1b_partial_bf16.pt
2.3 GB
Inference weights (bf16)
ckpt_last.pt
12.9 GB
Full training state (weights + optimizer), for resuming
edo_bpe_48000.json
4 MB
Tokenizer
edo_colab_demo.ipynb
—
One-click Colab demo
8. Limitations
Severely undertrained. 262 M of a planned 2.29 B tokens (11 % of one epoch). It cannot yet hold a coherent sentence. Training halted purely by compute budget, not by design.
OCR noise is learned.□ marks illegible characters in the source scans; the model reproduces them as a frequent token.
Not instruction-tuned. It is a raw base model — a continuation engine, not an assistant. It will not answer questions.
Not purely Japanese. ~24 % literary Chinese, deliberately: that reflects an Edo reader's actual diet.
The cutoff is a data property, not a guarantee. Contamination was controlled at the source and tokenizer level, but has not been adversarially audited.
9. License
CC BY-SA 4.0, inherited from the Kanseki Repository portion of the training data. Share-alike applies to derivatives.
10. Citation
bibtex
1@misc{edo-cutoff-llm-2026,
2 title = {Edo-Cutoff LLM: A Language Model with an 1868 Knowledge Cutoff},
3 author = {zary0},
4 year = {2026},
5 url = {https://huggingface.co/zary0/edo-cutoff-1b}
6}
Acknowledgements
Built on public infrastructure that made a project like this possible for one person:
National Diet Library (NDL Lab) — Next Digital Library, and NDL古典籍OCR for kuzushiji recognition (CC BY 4.0)
Kanseki Repository 漢籍リポジトリ — Christian Wittern and contributors