neuralnets commited on
Commit
748e68e
·
verified ·
1 Parent(s): 5517201

Rewrite dataset card: launch post links, overview, citation

Browse files
Files changed (1) hide show
  1. README.md +90 -73
README.md CHANGED
@@ -1,5 +1,5 @@
1
  ---
2
- pretty_name: 'IndicGram: Private Extraction Snapshot'
3
  license: other
4
  license_name: source-specific-rights
5
  license_link: LICENSE.md
@@ -61,96 +61,113 @@ configs:
61
 
62
  # IndicGram
63
 
64
- ## Unicode recovery update
65
 
66
- **`pages_unicode` is now the default configuration.** Its `text` contains verified font-encoding repairs where available; `text_raw` retains the original selected text. All other page metadata, quarantine flags and review requirements remain. This is an agent-reviewed encoding layer, not human-validated language data.
 
 
67
 
68
- | New configuration | Rows | Meaning |
69
- |---|---:|---|
70
- | `pages_unicode` | 1,979 | All retained pages, with raw and recovered text |
71
- | `spans_unicode` | 1,006 | Only spans with recovery events; raw text, repaired text, per-character provenance and crop |
72
- | `recovery_records` | 1,478 | Existing candidates with linked evidence; original parsed fields remain uncorrected |
73
- | `recovery_mappings` | 32 | Used mappings scoped to exact source/font hashes |
74
- | `unresolved_recovery` | 1,198 | Image-backed OCR/layout candidates requiring review |
75
-
76
- The filtered update repairs **1,424 character occurrences on 63 pages** and provides **2,330 source-image crops**. The local recovery pass also inspected the 14 previously excluded pages; their text and images are still excluded here. Therefore the Hub counts differ from the larger local audit. The six uncertain release-mark occurrences are on excluded pages and are not silently reintroduced.
77
-
78
- The original six configurations remain byte-identical. Sentence/gloss roles, segmentation, table layout and standalone accent placement still require review. The six-source quarantine stays in place. Standard Unicode covers every confirmed recovered symbol; no invented custom font is included.
79
-
80
- Image paths in `spans_unicode`, `recovery_records` and `unresolved_recovery` are paths inside `evidence/source_crops.zip`. Each crop has its original page/bounding box and checksum. To inspect images:
81
-
82
- ```python
83
- from huggingface_hub import hf_hub_download
84
- from zipfile import ZipFile
85
- archive = hf_hub_download("neuralnets/IndicGram", "evidence/source_crops.zip", repo_type="dataset", token=True)
86
- with ZipFile(archive) as bundle:
87
- bundle.extractall("indicgram-evidence")
88
- ```
89
 
90
- Source-specific image rights are unchanged; this update remains private. See `metadata/recovery_summary.json` for exact filtered counts.
91
 
 
92
 
93
- Private research snapshot of page-grounded text, OCR spans, linguistic examples and grammar-rule candidates from Indian language documentation. **Every linguistic record is machine-produced and unreviewed. This is not a gold benchmark or a clean training corpus.**
94
 
95
- ## What is included
 
 
 
96
 
97
- | Configuration | Rows | Purpose |
98
- |---|---:|---|
99
- | `pages` | 1,979 | One row per retained physical PDF page; readable selected-layer text and provenance. |
100
- | `spans` | 127,590 | All retained native/OCR spans with coordinates; alternative layers are explicitly marked. |
101
- | `examples` | 5,527 | Machine-extracted native text, segmentation, glosses and translation candidates. |
102
- | `grammar_rules` | 1,842 | Machine-extracted grammatical statements with source evidence. |
103
- | `sources` | 19 | Acquired editions, authors, URLs, hashes, scope notes and source-specific rights. |
104
- | `languages` | 18 | Language/variety identity metadata and provisional inclusion status. |
105
 
106
- The retained pages comprise **1,365 native-text pages and 614 OCR pages**, across 18 language/variety labels and 19 source descriptions. Three Census chapter descriptions share one original volume. Physical PDF-page numbers are preserved; Milang scan pages can contain two printed pages.
 
 
 
 
 
 
 
 
 
107
 
108
- The requested **14 pending-OCR pages are excluded**, together with 691 spans, 59 example candidates and 10 rule candidates that depend on them. Their identifiers, without source text, are in `metadata/skipped_pages.json`. No new OCR was performed. The four extra Shergaon checkpoints and all other pages outside the current processed corpus are not added. This is a filtered snapshot, not all pages from every acquired book.
109
 
110
- ## Load the data
111
 
112
  ```python
113
  from datasets import load_dataset
114
 
115
- pages = load_dataset("neuralnets/IndicGram", "pages_unicode", split="train", token=True)
116
- examples = load_dataset("neuralnets/IndicGram", "examples", split="train", token=True)
117
- rules = load_dataset("neuralnets/IndicGram", "grammar_rules", split="train", token=True)
118
 
119
- # Review one source variety without mixing related language labels.
120
- milang = pages.filter(lambda row: row["language_id"] == "milang")
121
  ```
122
 
123
- Authenticate locally with an account permitted to access this private repository. `token=True` uses your stored authentication; do not hardcode tokens in notebooks. All configurations use `train` as a storage split only. It does not define a validated training set or a train/test evaluation protocol. No random benchmark split has been invented.
124
-
125
- ## Fields and relationships
126
 
127
- - `source_id` joins all content tables to `sources`; `language_id` joins `languages`.
128
- - `page_id`, `pdf_page` and `source_sha256` identify exact physical source evidence. The SHA is for the PDF representation; `sources.original_sha256` distinguishes DjVu originals.
129
- - `pages.text` joins the chosen native/OCR lines with newlines, in the existing geometric order. It is not a human-corrected reading-order reconstruction. `native_text` preserves the PDF text layer separately.
130
- - `pages.text_span_ids` links to `spans.span_id`. Span `bbox` contains `[x0,y0,x1,y1]` in original PDF points, measured from the top left. `selected_for_page_text` distinguishes chosen lines from retained alternatives.
131
- - `in_extraction_scope` identifies evidence selected by the existing grammar extraction profiles. Raw pages/spans can include frontmatter, vocabulary, comparison languages and other non-grammar content; a document's language label is not a claim that every token is in that language.
132
- - Examples and rules retain `span_ids`, original wording, extraction method, confidence, quality flags and review state. Confidence is an uncalibrated heuristic. Linked record IDs are restricted to records present in this snapshot.
133
- - `source_diagnostic_quarantined=true` identifies sources excluded from local diagnostic tasks for demonstrated encoding/layout errors. This flag is not a complete record-quality filter.
134
- - `human_validated=false` on every content row. Full Arrow field types are in `metadata/schema.json`.
135
 
136
- ## Languages and varieties
137
-
138
- Barman Thar, Birhor, Bugun, Gorum-Parenga, Gta / Dideyi, Gutob / Bodo Gadaba, Hakhun Tangsa, Hill Korwa of Kado Pani, Kharia, Lotha Naga, Milang, Ollari Gadaba, Purum, Bonda / Remo, Sherdukpen, Shergaon variety, Tangam, Turi, Yimchungru Naga.
139
-
140
- Shergaon is separate from Rupa; Gorum-Parenga is separate from Pengo/Parji; Hill Korwa refers to Kado Pani; Gta uses the Plains source; the exact Remo source variety remains unresolved. Barman Thar identity and other source-variety uncertainties remain in the registry. No newly accepted core language or zero-resource claim is implied.
141
-
142
- ## Extraction quality and limitations
143
-
144
- English Tesseract OCR does not reliably recover Devanagari or all phonetic symbols. Column fusion, dropped lines, damaged legacy fonts and swapped native/gloss/translation roles are known failures. Gutob, Gta, Remo, Tangam, Shergaon and Gorum source profiles are quarantined from diagnostics. Their candidates remain in this private review snapshot with explicit flags. Milang spread partitions prevent cross-panel joins only where OCR spans did not already cross the gutter.
145
-
146
- Do not treat example counts, IGT fields, rule statements or source-author claims as independently verified linguistic facts. Source presence is not proof of novel NLP coverage. Existing ODIN/GlossLM, lexical, speech and typological resources overlap with several languages. Human correction, source comparison and task-specific sampling remain necessary.
147
-
148
- ## Rights and use
149
-
150
- This is a **private research copy**, uploaded at the repository owner's request. Private storage does not create redistribution rights. Most source editions have no verified downstream text-redistribution grant. Turi2024 and the separate Birhor2021 article have recorded CC BY4.0 grants; those grants do not cover the remaining works or the Birhor2022 book. Source-by-source attribution and evidence links are retained in every content row and in `sources`.
151
-
152
- Machine extraction, line joining, typed formatting, source-scope filtering and quality annotations are adaptations made by IndicGram; they may contain errors. Original copyrights and license conditions remain with their respective rights holders. No blanket MIT/CC license is applied to the source text. See [LICENSE.md](LICENSE.md). Keep this repository private until a separate source-specific rights and community review supports any intended public distribution. No claim of community consent or expert validation is made.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
153
 
154
- ## Snapshot and reproducibility
155
 
156
- `manifest.json` records file SHA-256 values and hashes of the exact local inputs. `metadata/dataset_summary.json` records inclusion/exclusion counts. This package uses standard Parquet files and dataset-card configurations, with no remote-code loader. Full source PDF binaries, full-page image collections, model predictions and authentication credentials are not uploaded. The recovery update adds filtered source crops in `evidence/source_crops.zip`, indexed by `metadata/recovery_images.json`.
 
1
  ---
2
+ pretty_name: 'IndicGram: Grammar Databank for Low-Resource Indian Languages'
3
  license: other
4
  license_name: source-specific-rights
5
  license_link: LICENSE.md
 
61
 
62
  # IndicGram
63
 
64
+ **Grammar rules and interlinear glossed examples for 18 of India's least-resourced languages, recovered page by page from published grammars.**
65
 
66
+ 📝 **Launch post:** [IndicGram: a grammar databank for India's least-resourced languages](https://buildingbad.xyz/blog/indicgram/)
67
+ 🔎 **Source map:** [every number in the post, traced to its file](https://buildingbad.xyz/blog/indicgram/sources/)
68
+ 🧪 **Lab:** [Building Bad](https://buildingbad.xyz), an independent research lab by [neuralnets](https://cneuralnets.xyz)
69
 
70
+ ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
71
 
72
+ ## Why this exists
73
 
74
+ Hundreds of India's languages have almost no text on the internet. For many of them, the richest record that exists is a grammar: a book or dissertation written by a linguist, full of rules and carefully glossed sentences. That is exactly what a model needs to learn a language it has never seen, but it is locked in PDFs and decades-old scans.
75
 
76
+ IndicGram pulls two things out of those grammars: **grammar rules**, and **interlinear glossed text (IGT)**, the three-line format that shows a sentence, its word-by-word meaning and its translation. Every record points back to its source, its physical page and the exact spans it was read from.
77
 
78
+ > *miɑʔn dubɑ pɛndɑrɛ dubʔm-ɛn=ə=ɛ*
79
+ > one tree under sit.down-PST.MID=FIN=3SG.ANIM
80
+ > ‘He sat down under a tree.’
81
+ > — Turi, from Peterson et al. (2024), example 51
82
 
83
+ ## At a glance
 
 
 
 
 
 
 
84
 
85
+ | | |
86
+ |---|---:|
87
+ | Language varieties | 18 |
88
+ | Source works | 19 |
89
+ | Pages | 1,979 |
90
+ | Example sentences | 5,527 |
91
+ | Grammar rules | 1,842 |
92
+ | Text spans with page coordinates | 127,590 |
93
+ | Character repairs from broken fonts | 1,424 on 63 pages |
94
+ | Human-reviewed records | 0 (review is next) |
95
 
96
+ **Languages:** Barman Thar, Birhor, Bugun, Gorum-Parenga, Gta / Dideyi, Gutob / Bodo Gadaba, Hakhun Tangsa, Hill Korwa of Kado Pani, Kharia, Lotha Naga, Milang, Ollari Gadaba, Purum, Bonda / Remo, Sherdukpen (Shergaon), Tangam, Turi, Yimchungru Naga. Eight are Austroasiatic (Munda), eight Sino-Tibetan, one Dravidian, and one is still unresolved.
97
 
98
+ ## Load it
99
 
100
  ```python
101
  from datasets import load_dataset
102
 
103
+ pages = load_dataset("neuralnets/IndicGram", "pages_unicode", split="train") # default
104
+ examples = load_dataset("neuralnets/IndicGram", "examples", split="train")
105
+ rules = load_dataset("neuralnets/IndicGram", "grammar_rules", split="train")
106
 
107
+ turi = examples.filter(lambda r: r["language_id"] == "turi")
 
108
  ```
109
 
110
+ `train` is only a storage split. It is not a validated training set, and no evaluation split is defined here.
 
 
111
 
112
+ ## What's inside
 
 
 
 
 
 
 
113
 
114
+ | Configuration | Rows | What it holds |
115
+ |---|---:|---|
116
+ | `pages_unicode` *(default)* | 1,979 | Every retained page, with repaired text (`text`) and the original layer (`text_raw`) |
117
+ | `pages` | 1,979 | Page text and provenance as first extracted |
118
+ | `spans` | 127,590 | Native and OCR text spans with bounding boxes in PDF points |
119
+ | `examples` | 5,527 | Example sentences: native text, segmentation, glosses, translation |
120
+ | `grammar_rules` | 1,842 | Grammatical statements with their source evidence |
121
+ | `sources` | 19 | Editions, authors, URLs, hashes and source-specific rights |
122
+ | `languages` | 18 | Language and variety identities, with audit status |
123
+ | `spans_unicode` | 1,006 | Spans repaired from broken font encodings, with per-character provenance |
124
+ | `recovery_records` | 1,478 | Existing candidates linked to their repair evidence |
125
+ | `recovery_mappings` | 32 | Font repairs, each tied to an exact PDF and font hash |
126
+ | `unresolved_recovery` | 1,198 | OCR and layout candidates that still need a human eye |
127
+
128
+ Source-image crops for the recovery tables (2,330 of them) are in `evidence/source_crops.zip`.
129
+
130
+ **How the tables join:** `source_id` links content to `sources`, and `language_id` links it to `languages`. `page_id`, `pdf_page` and `source_sha256` pin the exact physical page. `span_ids` on examples and rules link back to `spans`.
131
+
132
+ ## The broken-font fix
133
+
134
+ The Gutob grammar was typeset with TIPA. On the page it shows perfect IPA, but its text layer stores symbols at private font positions, so a copied ʔ turns into a stray character. IndicGram repairs these with mappings scoped to the exact PDF and font. Every recovered character is standard Unicode, so no custom font is needed. The original text is always kept next to the repair.
135
+
136
+ ## Please read before using
137
+
138
+ - **Every linguistic record is machine-extracted and unreviewed.** Treat glosses, segmentations, translations and rule boundaries as candidates, not facts. Confidence values are heuristics and are not calibrated.
139
+ - **Known failure modes:** English OCR misses some phonetic symbols and Devanagari; columns can fuse; native, gloss and translation lines can swap. The Gutob, Gta, Remo, Tangam, Shergaon and Gorum sources are flagged with `source_diagnostic_quarantined=true`.
140
+ - Fourteen pages still waiting for OCR are excluded, along with everything extracted from them. Their IDs, without text, are in `metadata/skipped_pages.json`.
141
+ - Some of these languages already appear in ODIN, GlossLM and language archives. Being included here is not a claim of new coverage.
142
+
143
+ ## Rights
144
+
145
+ The extracted text belongs to the original authors and publishers. **No blanket licence applies to it.** The Turi (2024) and Birhor (2021) sources are openly licensed under CC BY 4.0; the other works are not cleared for redistribution. Rights are listed source by source in `sources` and in [LICENSE.md](LICENSE.md). Extraction, formatting and quality annotations are IndicGram's own work and may contain errors. If you are an author or publisher and want a work handled differently, please get in touch.
146
+
147
+ ## Cite
148
+
149
+ If you use IndicGram, please cite the launch post and the dataset. Please also cite the source grammar for every language you use; the full list is in the [launch post](https://buildingbad.xyz/blog/indicgram/#sources).
150
+
151
+ ```bibtex
152
+ @misc{neuralnets2026indicgram,
153
+ author = {neuralnets},
154
+ title = {{IndicGram}: A Grammar Databank for {India}'s Least-Resourced Languages},
155
+ howpublished = {Building Bad},
156
+ year = {2026},
157
+ month = nov,
158
+ url = {https://buildingbad.xyz/blog/indicgram/}
159
+ }
160
+
161
+ @misc{neuralnets2026indicgramdata,
162
+ author = {neuralnets},
163
+ title = {{IndicGram}: Grammar Rules and Interlinear Glossed Examples for Low-Resource {Indian} Languages},
164
+ publisher = {Hugging Face},
165
+ year = {2026},
166
+ url = {https://huggingface.co/datasets/neuralnets/IndicGram},
167
+ note = {Machine-extracted candidates; not human-reviewed}
168
+ }
169
+ ```
170
 
171
+ ## Get involved
172
 
173
+ If you are a linguist, speak one of these languages, or work on low-resource NLP, we'd love your help reviewing and extending IndicGram. Write to **cneuralnets@gmail.com**.