Skip to content

Historic English model v2 for Spacy 3.8

Choose a tag to compare

@clovis clovis released this 18 Oct 14:09
· 2 commits to main since this release

What Changed

  • Encoder: ModernBERT-base instead of RoBERTa-large. The model is as accurate (see below), about 1.6 times as fast on a GPU, 1.9 times with flash-attention, and less than half the size.
  • cannot: the tokenizer splits it into can + not, which RoBERTa saw as a single word, so v1 gave both tokens the same tag. A rule now tags them can AUX/MD and not PART/RB.
  • Attention: the model now uses PyTorch's SDPA attention, or flash-attention when it is installed, instead of the slower eager attention.

Compared with v1

Test set v1 POS / TAG / Lemma v2 POS / TAG / Lemma
Gold set 1 (100 sentences) 98.48% / 98.31% / 97.07% 98.42% / 98.42% / 97.10%
Gold set 2 (100 sentences) 98.26% / 98.12% / 97.25% 98.01% / 97.76% / 97.28%
Challenge set (39 sentences) 96.99% / 96.79% / 94.24% 96.85% / 96.72% / 94.11%
Held-out test set (4,996 sentences) 98.53% / 98.27% / 97.88% 98.50% / 98.25% / 97.90%
Penn historical corpora, 1500–1914 (5.1 million words) 98.41% / – / 98.27% 98.43% / – / 98.30%
Penn historical corpora, 1500–1600 97.34% / – / 94.56% 97.26% / – / 94.74%
UD English EWT (modern web English) 95.62% / 93.92% / 94.38% 95.40% / 93.72% / 94.08%

The Penn historical corpora (PPCEME and PPCMBE2, LDC2025T09) are a new test: annotated by hand, they are the only historic test independent of the annotating model. Their tags and lemmas are mapped to the model's conventions; TAG is not scored.

Performance by Century

Period POS TAG Lemma
1500-1600 97.80% 97.68% 95.64%
1600-1700 98.41% 98.30% 97.86%
1700-1800 98.59% 98.44% 98.48%
1800-1900 98.92% 98.52% 98.86%
1900-2000 98.80% 98.31% 98.78%

Requirements: spaCy >=3.8.5,<3.9.0, spacy-transformers 1.3 and transformers 4.48 or 4.49. Optionally, on a GPU, flash-attn 2.7.4 (install it only where the model runs on the GPU).