From 390535ff00d61df63a15de6fba23761a2c57cead Mon Sep 17 00:00:00 2001 From: Lukasz Kasprzak Date: Wed, 29 Jul 2026 11:12:24 +0200 Subject: bible(wuj): rebuild from source, repair to exact Vulgate parity The Wujek corpus was missing text and mis-numbering what it had: 453 corpus-check warnings, 8 absent chapters, 84 duplicate rows, and 357 chapters holding fewer verses than the Vulgate. Most of it was never a sourcing problem. The original harvest of biblia.info.pl assumed one verse is one

, but many psalms print the superscription in the anchored paragraph and the psalm's opening line in an unanchored one behind a drop cap -- so 44 psalms lost their first line, and Acts 6:5 and others went the same way. Re-harvested with the anchor treated as a verse START rather than a whole verse (scripts/scrape-wujek.py), which also had to cope with four anchor shapes across books, hidden page markers opening paragraphs mid-verse, chapter ids that are simply wrong (Mark labels 87 anchors "15:*" across chapters 14-16), and Psalms heading its divisions "Psalm CXVII" where every other book says "Rozdzial N". Structure was then repaired against the Clementine Vulgate, by hand where a rule would have guessed: * The Acts 5 interleaved three streams -- Acts 4:27-37 duplicated, the real 5:1-37, and 5:38-39 mislabelled 28-29. Verified against the Latin, the duplicates dropped, the two renumbered. Acts 4:27 kept the site's own wording in place of a 1962 reading, removing a seam. * The site heads psalms by Hebrew division; its "Psalm 114" is two psalms. Split into Vulgate 113:9-26 and 114:1-9, confirmed at all four boundaries. * A corrupt anchor for 1 Chronicles 9:11 pushed 34 paragraphs of genealogy into chapter 10. Counts corroborate: 10 + 34 = 44 verses, remainder 14, both exactly the Vulgate's. * 16 chapters looked short at the end; only two verses were truly absent. The rest were merges, split at anchors read off the Latin -- including one across a chapter boundary (Colossians 4:1 sat inside 3:25) and four numbering offsets where a mid-chapter merge shifted everything after it. wuj now carries exactly the Vulgate's verse set: 35810 rows, every one of the 1334 chapters matching, no duplicates, no gaps. corpus-check: 0 warnings. The ~300 verses that could not come from biblia.info.pl are recorded in NOTICE; they are not public domain. --- scripts/scrape-wujek.py | 177 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 177 insertions(+) create mode 100644 scripts/scrape-wujek.py (limited to 'scripts/scrape-wujek.py') diff --git a/scripts/scrape-wujek.py b/scripts/scrape-wujek.py new file mode 100644 index 0000000..4940fdd --- /dev/null +++ b/scripts/scrape-wujek.py @@ -0,0 +1,177 @@ +#!/usr/bin/env python3 +"""Regenerate the bulk of the Wujek (wuj) corpus from biblia.info.pl. + +Why this exists: the original harvest silently lost text, because a verse is +not one

. Many psalms are printed as + +

1 Alleluja. [108]

+

Wyznawajcie Panu, i wzywajcie imienia jego, ...

+ +The second paragraph carries the rest of the verse and has NO anchor, so +taking one paragraph per anchor kept "Alleluja." and dropped the psalm's +opening line -- 44 psalms lost their first line that way, plus scattered +verses elsewhere (Acts 6:5 among them). A verse runs from its anchor to the +NEXT anchor, across however many paragraphs. + +Four further traps, each of which silently lost or invented verses: + + * The anchor's shape differs per book: Psalms 1, Sirach + (a drop cap replaces the numeral), Genesis no at all, and some carry + "2 ". Constraining it to a digit dropped whole books. + * Hidden page markers