Diplaysbook commited on
Commit
b93c735
·
verified ·
1 Parent(s): 8ab8ce0

Upload folder using huggingface_hub

Browse files
.gitattributes CHANGED
@@ -58,3 +58,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
58
  # Video files - compressed
59
  *.mp4 filter=lfs diff=lfs merge=lfs -text
60
  *.webm filter=lfs diff=lfs merge=lfs -text
 
 
58
  # Video files - compressed
59
  *.mp4 filter=lfs diff=lfs merge=lfs -text
60
  *.webm filter=lfs diff=lfs merge=lfs -text
61
+ data/lexicon/concepts.jsonl filter=lfs diff=lfs merge=lfs -text
LICENSE-NOTES-LEXICON.md ADDED
@@ -0,0 +1,43 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 许可与来源说明(wordlist 数据集)
2
+ ================================================================
3
+
4
+ 一、词表(data/wordlists)
5
+ 1. 23 种语言:hermitdave/FrequencyWords(OpenSubtitles 2018 词频)
6
+ 许可:CC BY-SA 4.0
7
+ 要求:署名 + 相同方式共享。
8
+ 来源页:https://github.com/hermitdave/FrequencyWords
9
+ 2. 斯瓦希里语:Leipzig Corpora Collection(swa_news_2020_10K)
10
+ 许可:CC BY 4.0
11
+ 来源页:https://wortschatz.uni-leipzig.de/en/download/
12
+ 本项目改动:去纯标点、去含数字、按文字系统过滤、去重、每语上限 5 万、
13
+ 日语≥2 字符、泰语≥3 字符。
14
+
15
+ 二、概念表(data/concepts)
16
+ 1. Open Multilingual WordNet 1.4 + Princeton WordNet
17
+ 覆盖:ar en es fr id it ja nl pl pt th zh
18
+ 许可:各词网分别授权(多数为 CC BY 3.0/4.0,Princeton WordNet 为 WordNet 许可)
19
+ 来源:https://omwn.org/ 与 https://wordnet.princeton.edu/
20
+ 2. OdeNet(德语)
21
+ 许可:CC BY-SA 4.0
22
+ 来源:https://github.com/hdaSprachtechnologie/odenet
23
+ 3. RuWordNet(俄语,bagratte/russian-wordnet 0.2)
24
+ 许可:CC BY 4.0
25
+ 来源:https://github.com/bagratte/russian-wordnet
26
+ 4. Ukrajinet(乌克兰语)
27
+ 许可:CC BY-SA 4.0
28
+ 来源:https://github.com/hdaSprachtechnologie/ukrajinet
29
+ 概念 ID 采用 Princeton WordNet synset 编号,经 CILI 的 ili-map-pwn30.tab 对齐。
30
+
31
+ 三、人工词典(data/dictionary)
32
+ 912 概念 × 24 语、21,888 条,由本项目撰写(同语定义 + 例句),
33
+ 与本仓库的语料、词表同源,可自由使用;若再分发请注明出处。
34
+
35
+ 四、使用建议
36
+ · 词表部分(CC BY-SA)若用于训练模型,模型权重是否受传染需自行判断;
37
+ 保守做法:在模型卡中署名并注明数据来源。
38
+ · 概念表部分按各词网许可分别署名。
39
+
40
+ 五、已知风险
41
+ 1. 字幕词表含口语与专名,不代表“标准书面语”;
42
+ 2. 概念映射经抽样检查(12 条)通过,但未逐条人工校验;
43
+ 3. 乌尔都、他加禄、印地语词表明显偏小(源数据限制)。
README.md CHANGED
@@ -62,9 +62,30 @@ configs:
62
  path: data/cjk_textbooks/train-*.jsonl.gz
63
  - split: validation
64
  path: data/cjk_textbooks/validation-*.jsonl.gz
 
 
 
 
 
 
 
 
 
 
 
 
65
  ---
66
 
67
- # Public-Domain Multilingual Base Corpus (1850–1928)
 
 
 
 
 
 
 
 
 
68
 
69
  A pretraining corpus assembled from public-domain sources, covering **24 languages** and **57 academic disciplines**, plus a dedicated textbook subset and an East-Asian textbook subset.
70
 
@@ -132,21 +153,95 @@ Not suitable for: instruction tuning, factual QA benchmarks (the knowledge is a
132
  5. **Historical bias.** Content reflects the views of 1850–1928 authors, including colonial, racial, and eugenic framings. Filter before any user-facing deployment.
133
  6. **Duplicate-looking passages across disciplines.** The same book may have been classified into several disciplines; chunk-level dedup keeps only one copy, but document metadata may differ.
134
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
135
  ## Loading
136
 
137
  ```python
138
  from datasets import load_dataset
139
 
 
140
  ds = load_dataset("Diplaysbook/Mini-llm-base", "academic", split="train", streaming=True)
141
  for row in ds.take(3):
142
  print(row["lang"], row["discipline"], row["text"][:120])
 
 
 
 
 
143
  ```
144
 
145
  ## Licence
146
 
147
- Source texts are public domain (published ≤1928 in the US / copyright expired in Japan).
148
- Wikisource transcriptions are CC BY-SA 4.0 — attribution to Wikisource is required when redistributing those parts.
149
- See `LICENSE-NOTES.md` for details and per-source notes.
 
 
 
 
 
 
 
150
 
151
  ## Citation
152
 
 
62
  path: data/cjk_textbooks/train-*.jsonl.gz
63
  - split: validation
64
  path: data/cjk_textbooks/validation-*.jsonl.gz
65
+ - config_name: wordlists
66
+ data_files:
67
+ - split: train
68
+ path: data/lexicon/wordlists/*.jsonl
69
+ - config_name: concepts
70
+ data_files:
71
+ - split: train
72
+ path: data/lexicon/concepts.jsonl
73
+ - config_name: dictionary
74
+ data_files:
75
+ - split: train
76
+ path: data/lexicon/dictionary.jsonl
77
  ---
78
 
79
+ # Public-Domain Multilingual Corpus + Lexicon
80
+
81
+ Two resource families in one repository:
82
+
83
+ * **corpus** (`novels`, `academic`, `textbooks`, `cjk_textbooks`) — public-domain
84
+ text from 1850–1928, 24 languages, 57 disciplines;
85
+ * **lexicon** (`wordlists`, `concepts`, `dictionary`) — 24-language vocabulary,
86
+ 110k WordNet-aligned concepts, and a 912-concept hand-written dictionary.
87
+
88
+ ## Corpus configs
89
 
90
  A pretraining corpus assembled from public-domain sources, covering **24 languages** and **57 academic disciplines**, plus a dedicated textbook subset and an East-Asian textbook subset.
91
 
 
153
  5. **Historical bias.** Content reflects the views of 1850–1928 authors, including colonial, racial, and eugenic framings. Filter before any user-facing deployment.
154
  6. **Duplicate-looking passages across disciplines.** The same book may have been classified into several disciplines; chunk-level dedup keeps only one copy, but document metadata may differ.
155
 
156
+
157
+ ## Lexicon configs
158
+
159
+ ### `wordlists`
160
+
161
+ One JSONL per language in `data/lexicon/wordlists/<lang>.jsonl` — **24 languages,
162
+ 1,108,218 word forms** (~50k per language):
163
+
164
+ ```json
165
+ {"word": "good", "rank": 118, "count": 1234567, "per_million": 6421.3}
166
+ ```
167
+
168
+ Two merged frequency sources: OpenSubtitles 2018 via `hermitdave/FrequencyWords`
169
+ (CC BY-SA 4.0, weight 0.6) and Leipzig Corpora Collection news 2020
170
+ (CC BY 4.0, weight 0.4). Cleaned for script, punctuation, digits, duplicates;
171
+ Japanese >=2 characters, Thai >=3 characters.
172
+
173
+ ### `concepts`
174
+
175
+ `data/lexicon/concepts.jsonl` — **110,148 concepts x 24 languages**. Concept IDs
176
+ are Princeton WordNet synset offsets, so the same ID is the same concept in every
177
+ language; synonyms are joined by `;`. Each row carries a `sources` object:
178
+
179
+ ```json
180
+ {"concept": "02139199-n", "langs": 4,
181
+ "en": "bat;chiropteran", "ru": "летучая мышь", "uk": "кажан",
182
+ "ja": "コウモリ;蝙蝠",
183
+ "sources": {"en": "wordnet", "ru": "wordnet", "uk": "wordnet", "ja": "wordnet"}}
184
+ ```
185
+
186
+ `sources` values:
187
+
188
+ | value | languages | nature |
189
+ |---|---|---|
190
+ | `wordnet` | en es fr id it ja nl pl pt th zh ru uk fa | sense-level alignment (WordNet synsets / ILI) |
191
+ | `wiktionary` | ko hi bn ur tr vi tl sw | word-level translations from English Wiktionary |
192
+ | `mixed` | de ar | WordNet lemmas + Wiktionary translations |
193
+
194
+ Per-language row counts are in `metadata/concept_sources.tsv`.
195
+
196
+ ### `dictionary`
197
+
198
+ `data/lexicon/dictionary.jsonl` — the curated **912-concept x 24-language**
199
+ dictionary (21,888 rows), each entry with a definition written in the target
200
+ language itself:
201
+
202
+ ```json
203
+ {"concept_id": "001", "headword": "好", "lang": "en", "word": "good",
204
+ "reading": "", "definition": "adjective: of high quality or satisfactory. Example: This book is good."}
205
+ ```
206
+
207
+ ## Lexicon issues
208
+
209
+ 1. Wordlists come from subtitles and news: spoken-language bias, names and
210
+ interjections are over-represented. They are **not** official national word lists.
211
+ 2. The 8 `wiktionary` languages are word-level translations, not sense-aligned —
212
+ expect some wrong-sense words; use only `wordnet` rows for strict evaluation.
213
+ 3. No POS, IPA or inflection tables in `wordlists` / `concepts`.
214
+ 4. Urdu (21k), Hindi (29k), Tagalog (33k) and Swahili (29k) are below the 50k cap
215
+ because both sources are shorter for them.
216
+
217
  ## Loading
218
 
219
  ```python
220
  from datasets import load_dataset
221
 
222
+ # corpus
223
  ds = load_dataset("Diplaysbook/Mini-llm-base", "academic", split="train", streaming=True)
224
  for row in ds.take(3):
225
  print(row["lang"], row["discipline"], row["text"][:120])
226
+
227
+ # lexicon
228
+ wl = load_dataset("Diplaysbook/Mini-llm-base", "wordlists", split="train", streaming=True)
229
+ cs = load_dataset("Diplaysbook/Mini-llm-base", "concepts", split="train", streaming=True)
230
+ dd = load_dataset("Diplaysbook/Mini-llm-base", "dictionary", split="train", streaming=True)
231
  ```
232
 
233
  ## Licence
234
 
235
+ **Corpus:** source texts are public domain (published ≤1928 in the US /
236
+ copyright expired in Japan). Wikisource transcriptions are CC BY-SA 4.0 —
237
+ attribution to Wikisource is required when redistributing those parts. See
238
+ `LICENSE-NOTES.md`.
239
+
240
+ **Lexicon:** wordlists are CC BY-SA 4.0 (FrequencyWords) and CC BY 4.0
241
+ (Leipzig); concepts come from OMW / WordNet projects under their respective
242
+ CC BY / CC BY-SA licences plus Wiktionary translations (CC BY-SA); the curated
243
+ 912-concept dictionary is original work of this project. See
244
+ `LICENSE-NOTES-LEXICON.md`.
245
 
246
  ## Citation
247
 
data/lexicon/concepts.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:29e5e3238beb037e6a58e45b00ac1734e253f6f27d580124de850a98d72fdadd
3
+ size 64471248
data/lexicon/dictionary.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/ar.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/bn.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/de.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/en.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/es.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/fa.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/fr.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/hi.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/id.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/it.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/ja.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/ko.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/nl.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/pl.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/pt.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/ru.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/sw.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/th.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/tl.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/tr.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/uk.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/ur.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/vi.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
data/lexicon/wordlists/zh_cn.jsonl ADDED
The diff for this file is too large to render. See raw diff
 
metadata/concept_sources.tsv ADDED
@@ -0,0 +1,25 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ lang source rows nature
2
+ ar mixed 38084 词网 + 维基词典译文
3
+ en wordnet 110148 义项级对齐(WordNet synset / ILI)
4
+ es wordnet 38512 义项级对齐(WordNet synset / ILI)
5
+ fr wordnet 59089 义项级对齐(WordNet synset / ILI)
6
+ id wordnet 38085 义项级对齐(WordNet synset / ILI)
7
+ it wordnet 38535 义项级对齐(WordNet synset / ILI)
8
+ ja wordnet 57184 义项级对齐(WordNet synset / ILI)
9
+ nl wordnet 30176 义项级对齐(WordNet synset / ILI)
10
+ pl wordnet 33825 义项级对齐(WordNet synset / ILI)
11
+ pt wordnet 43894 义项级对齐(WordNet synset / ILI)
12
+ th wordnet 73345 义项级对齐(WordNet synset / ILI)
13
+ zh wordnet 44717 义项级对齐(WordNet synset / ILI)
14
+ de mixed 62259 词网 + 维基词典译文
15
+ ru wordnet 18020 义项级对齐(WordNet synset / ILI)
16
+ uk wordnet 100125 义项级对齐(WordNet synset / ILI)
17
+ fa wordnet 17387 义项级对齐(WordNet synset / ILI)
18
+ ko wiktionary 36079 词条级翻译(非义项级)
19
+ hi wiktionary 29499 词条级翻译(非义项级)
20
+ bn wiktionary 14687 词条级翻译(非义项级)
21
+ ur wiktionary 16708 词条级翻译(非义项级)
22
+ tr wiktionary 39147 词条级翻译(非义项级)
23
+ vi wiktionary 28397 词条级翻译(非义项级)
24
+ tl wiktionary 23670 词条级翻译(非义项级)
25
+ sw wiktionary 15791 词条级翻译(非义项级)
metadata/stats.json CHANGED
@@ -93,5 +93,22 @@
93
  "ko": 506,
94
  "zh": 148
95
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
96
  }
97
  }
 
93
  "ko": 506,
94
  "zh": 148
95
  }
96
+ },
97
+ "lexicon": {
98
+ "wordlists_languages": 24,
99
+ "wordlists_rows": 1108218,
100
+ "concepts": 110148,
101
+ "concept_languages": 24,
102
+ "dictionary_entries": 21888,
103
+ "dictionary_concepts": 912,
104
+ "wordlist_sources": [
105
+ "OpenSubtitles 2018 (CC BY-SA 4.0)",
106
+ "Leipzig Corpora 2020 (CC BY 4.0)"
107
+ ],
108
+ "concept_source_tiers": {
109
+ "wordnet": 16,
110
+ "wiktionary": 8,
111
+ "mixed": 2
112
+ }
113
  }
114
  }