Datasets:
Tasks:
Text Generation
Formats:
parquet
Sub-tasks:
language-modeling
Languages:
Danish
Size:
1M - 10M
License:
Add Nota-tekster (#41)
Browse files- Adding the Nota dataset (dd7498844276f5f97f8a318b3def20f8b576dd91)
- Updated statistics for default dataset (58de27d838b853e797bb2fe1af90371100453ffe)
Co-authored-by: Kristian Nørgaard Jensen <[email protected]>
- .gitignore +1 -0
- .vscode/settings.json +2 -1
- README.md +36 -30
- data/nota/create.py +77 -0
- data/nota/descriptive_stats.json +1 -0
- data/nota/images/dist_document_length.png +3 -0
- data/nota/nota.md +98 -0
- data/nota/nota.parquet +3 -0
- descriptive_stats.json +1 -1
- images/dist_document_length.png +2 -2
- pyproject.toml +1 -1
- test_results.log +8 -33
- uv.lock +10 -10
.gitignore
CHANGED
@@ -11,3 +11,4 @@ cspell.json
|
|
11 |
# tmp files
|
12 |
tmp.py
|
13 |
tmp.png
|
|
|
|
11 |
# tmp files
|
12 |
tmp.py
|
13 |
tmp.png
|
14 |
+
**/.DS_Store
|
.vscode/settings.json
CHANGED
@@ -3,5 +3,6 @@
|
|
3 |
"src/tests"
|
4 |
],
|
5 |
"python.testing.unittestEnabled": false,
|
6 |
-
"python.testing.pytestEnabled": true
|
|
|
7 |
}
|
|
|
3 |
"src/tests"
|
4 |
],
|
5 |
"python.testing.unittestEnabled": false,
|
6 |
+
"python.testing.pytestEnabled": true,
|
7 |
+
"makefile.configureOnOpen": false
|
8 |
}
|
README.md
CHANGED
@@ -97,6 +97,10 @@ configs:
|
|
97 |
data_files:
|
98 |
- split: train
|
99 |
path: data/relig/*.parquet
|
|
|
|
|
|
|
|
|
100 |
annotations_creators:
|
101 |
- no-annotation
|
102 |
language_creators:
|
@@ -130,7 +134,7 @@ https://github.com/huggingface/datasets/blob/main/templates/README_guide.md
|
|
130 |
<!-- START README TABLE -->
|
131 |
| | |
|
132 |
| ------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
133 |
-
| **Version** | 1.0.
|
134 |
| **Language** | dan, dansk, Danish |
|
135 |
| **License** | Permissible, See the respective dataset |
|
136 |
| **Models** | For model trained used this data see [danish-foundation-models](https://huggingface.co/danish-foundation-models) |
|
@@ -164,9 +168,9 @@ https://github.com/huggingface/datasets/blob/main/templates/README_guide.md
|
|
164 |
|
165 |
<!-- START-DESC-STATS -->
|
166 |
- **Language**: dan, dansk, Danish
|
167 |
-
- **Number of samples**: 588.
|
168 |
-
- **Number of tokens (Llama 3)**: 1.
|
169 |
-
- **Average document length (characters)**:
|
170 |
<!-- END-DESC-STATS -->
|
171 |
|
172 |
|
@@ -271,32 +275,33 @@ This data generally contains no annotation besides the metadata attached to each
|
|
271 |
Below follows a brief overview of the sources in the corpus along with their individual license.
|
272 |
|
273 |
<!-- START-MAIN TABLE -->
|
274 |
-
| Source | Description | N. Tokens
|
275 |
-
|
276 |
-
| [lexdk] | Permissible use articles from [lex.dk](https://lex.dk) | 5.69M
|
277 |
-
| [opensubtitles] | Danish subsection of [OpenSubtitles](https://opus.nlpl.eu/OpenSubtitles/corpus/version/OpenSubtitles) | 271.60M
|
278 |
-
| [retsinformationdk] | [retsinformation.dk](https://www.retsinformation.dk) (legal-information.dk) the official legal information system of Denmark | 516.54M
|
279 |
-
| [ep] | The Danish subsection of [Europarl](https://aclanthology.org/2005.mtsummit-papers.11/) | 100.89M
|
280 |
-
| [ft] | Records from all meetings of The Danish parliament (Folketinget) in the parliament hall | 114.09M
|
281 |
-
| [wikisource] | The Danish subsection of [Wikisource](https://en.wikisource.org/wiki/Main_Page) | 5.34M
|
282 |
-
| [spont] | Conversational samples collected as a part of research projects at Aarhus University | 1.56M
|
283 |
-
| [tv2r] | Contemporary Danish newswire articles published between 2010 and 2019 | 21.67M
|
284 |
-
| [adl] | Danish literature from 1700-2023 from the Archive for Danish Literature (ADL) | 58.49M
|
285 |
-
| [hest] | Samples from the Danish debate forum www.heste-nettet.dk | 389.33M
|
286 |
-
| [skat] | Skat is the Danish tax authority. This dataset contains content from its website skat.dk | 122.12M
|
287 |
-
| [dannet] | [DanNet](https://cst.ku.dk/projekter/dannet) is a Danish WordNet | 1.52M
|
288 |
-
| [retspraksis] | Case law or judical practice in Denmark derived from [Retspraksis](https://da.wikipedia.org/wiki/Retspraksis) | 57.08M
|
289 |
-
| [wikibooks] | The Danish Subsection of [Wikibooks](https://www.wikibooks.org) | 6.24M
|
290 |
-
| [jvj] | The works of the Danish author and poet, [Johannes V. Jensen](https://da.wikipedia.org/wiki/Johannes_V._Jensen) | 3.55M
|
291 |
-
| [gutenberg] | The Danish subsection from Project [Gutenberg](https://www.gutenberg.org) | 6.76M
|
292 |
-
| [botxt] | The Bornholmsk Ordbog Dictionary Projec | 847.97K
|
293 |
-
| [depbank] | The Danish subsection of the [Universal Dependencies Treebank](https://github.com/UniversalDependencies/UD_Danish-DDT) | 185.45K
|
294 |
-
| [naat] | Danish speeches from 1930-2022 | 286.68K
|
295 |
-
| [synne] | Dataset collected from [synnejysk forening's website](https://www.synnejysk.dk), covering the Danish dialect sønderjysk | 52.51K
|
296 |
-
| [wiki] | The Danish subsection of [wikipedia](https://en.wikipedia.org/wiki/Main_Page) | 122.00M
|
297 |
-
| [nordjyllandnews] | Articles from the Danish Newspaper [TV2 Nord](https://www.tv2nord.dk) | 37.91M
|
298 |
-
| [relig] | Danish religious text from the 1700-2022 | 1.24M
|
299 |
-
|
|
|
|
300 |
|
301 |
[lexdk]: data/lexdk/lexdk.md
|
302 |
[opensubtitles]: data/opensubtitles/opensubtitles.md
|
@@ -321,6 +326,7 @@ Below follows a brief overview of the sources in the corpus along with their ind
|
|
321 |
[wiki]: data/wiki/wiki.md
|
322 |
[nordjyllandnews]: data/nordjyllandnews/nordjyllandnews.md
|
323 |
[relig]: data/relig/relig.md
|
|
|
324 |
|
325 |
|
326 |
[CC-0]: https://creativecommons.org/publicdomain/zero/1.0/legalcode.en
|
|
|
97 |
data_files:
|
98 |
- split: train
|
99 |
path: data/relig/*.parquet
|
100 |
+
- config_name: nota
|
101 |
+
data_files:
|
102 |
+
- split: train
|
103 |
+
path: data/nota/*.parquet
|
104 |
annotations_creators:
|
105 |
- no-annotation
|
106 |
language_creators:
|
|
|
134 |
<!-- START README TABLE -->
|
135 |
| | |
|
136 |
| ------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
137 |
+
| **Version** | 1.0.8 |
|
138 |
| **Language** | dan, dansk, Danish |
|
139 |
| **License** | Permissible, See the respective dataset |
|
140 |
| **Models** | For model trained used this data see [danish-foundation-models](https://huggingface.co/danish-foundation-models) |
|
|
|
168 |
|
169 |
<!-- START-DESC-STATS -->
|
170 |
- **Language**: dan, dansk, Danish
|
171 |
+
- **Number of samples**: 588.92K
|
172 |
+
- **Number of tokens (Llama 3)**: 1.85B
|
173 |
+
- **Average document length (characters)**: 9245.09
|
174 |
<!-- END-DESC-STATS -->
|
175 |
|
176 |
|
|
|
275 |
Below follows a brief overview of the sources in the corpus along with their individual license.
|
276 |
|
277 |
<!-- START-MAIN TABLE -->
|
278 |
+
| Source | Description | N. Tokens | License |
|
279 |
+
|:--------------------|:-----------------------------------------------------------------------------------------------------------------------------|:------------|:-----------------------|
|
280 |
+
| [lexdk] | Permissible use articles from [lex.dk](https://lex.dk) | 5.69M | [CC-BY-SA 4.0] |
|
281 |
+
| [opensubtitles] | Danish subsection of [OpenSubtitles](https://opus.nlpl.eu/OpenSubtitles/corpus/version/OpenSubtitles) | 271.60M | [CC-0] |
|
282 |
+
| [retsinformationdk] | [retsinformation.dk](https://www.retsinformation.dk) (legal-information.dk) the official legal information system of Denmark | 516.54M | [Danish Copyright Law] |
|
283 |
+
| [ep] | The Danish subsection of [Europarl](https://aclanthology.org/2005.mtsummit-papers.11/) | 100.89M | [CC-0] |
|
284 |
+
| [ft] | Records from all meetings of The Danish parliament (Folketinget) in the parliament hall | 114.09M | [CC-0] |
|
285 |
+
| [wikisource] | The Danish subsection of [Wikisource](https://en.wikisource.org/wiki/Main_Page) | 5.34M | [CC-0] |
|
286 |
+
| [spont] | Conversational samples collected as a part of research projects at Aarhus University | 1.56M | [CC-0] |
|
287 |
+
| [tv2r] | Contemporary Danish newswire articles published between 2010 and 2019 | 21.67M | [CC-BY-SA 4.0] |
|
288 |
+
| [adl] | Danish literature from 1700-2023 from the Archive for Danish Literature (ADL) | 58.49M | [CC-0] |
|
289 |
+
| [hest] | Samples from the Danish debate forum www.heste-nettet.dk | 389.33M | [CC-0] |
|
290 |
+
| [skat] | Skat is the Danish tax authority. This dataset contains content from its website skat.dk | 122.12M | [CC-0] |
|
291 |
+
| [dannet] | [DanNet](https://cst.ku.dk/projekter/dannet) is a Danish WordNet | 1.52M | [DanNet 1.0 License] |
|
292 |
+
| [retspraksis] | Case law or judical practice in Denmark derived from [Retspraksis](https://da.wikipedia.org/wiki/Retspraksis) | 57.08M | [CC-0] |
|
293 |
+
| [wikibooks] | The Danish Subsection of [Wikibooks](https://www.wikibooks.org) | 6.24M | [CC-0] |
|
294 |
+
| [jvj] | The works of the Danish author and poet, [Johannes V. Jensen](https://da.wikipedia.org/wiki/Johannes_V._Jensen) | 3.55M | [CC-BY-SA 4.0] |
|
295 |
+
| [gutenberg] | The Danish subsection from Project [Gutenberg](https://www.gutenberg.org) | 6.76M | [Gutenberg License] |
|
296 |
+
| [botxt] | The Bornholmsk Ordbog Dictionary Projec | 847.97K | [CC-0] |
|
297 |
+
| [depbank] | The Danish subsection of the [Universal Dependencies Treebank](https://github.com/UniversalDependencies/UD_Danish-DDT) | 185.45K | [CC-BY-SA 4.0] |
|
298 |
+
| [naat] | Danish speeches from 1930-2022 | 286.68K | [CC-0] |
|
299 |
+
| [synne] | Dataset collected from [synnejysk forening's website](https://www.synnejysk.dk), covering the Danish dialect sønderjysk | 52.51K | [CC-0] |
|
300 |
+
| [wiki] | The Danish subsection of [wikipedia](https://en.wikipedia.org/wiki/Main_Page) | 122.00M | [CC-0] |
|
301 |
+
| [nordjyllandnews] | Articles from the Danish Newspaper [TV2 Nord](https://www.tv2nord.dk) | 37.91M | [CC-0] |
|
302 |
+
| [relig] | Danish religious text from the 1700-2022 | 1.24M | [CC-0] |
|
303 |
+
| [nota] | The text only part of the [Nota lyd- og tekstdata](https://sprogteknologi.dk/dataset/nota-lyd-og-tekstdata) dataset | 7.30M | [CC-0] |
|
304 |
+
| **Total** | | 1.85B | |
|
305 |
|
306 |
[lexdk]: data/lexdk/lexdk.md
|
307 |
[opensubtitles]: data/opensubtitles/opensubtitles.md
|
|
|
326 |
[wiki]: data/wiki/wiki.md
|
327 |
[nordjyllandnews]: data/nordjyllandnews/nordjyllandnews.md
|
328 |
[relig]: data/relig/relig.md
|
329 |
+
[nota]: data/nota/nota.md
|
330 |
|
331 |
|
332 |
[CC-0]: https://creativecommons.org/publicdomain/zero/1.0/legalcode.en
|
data/nota/create.py
ADDED
@@ -0,0 +1,77 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
from collections import defaultdict
|
2 |
+
from io import BytesIO
|
3 |
+
from pathlib import Path
|
4 |
+
import requests
|
5 |
+
from zipfile import ZipFile
|
6 |
+
|
7 |
+
import pandas as pd
|
8 |
+
|
9 |
+
URL = "https://sprogtek-ressources.digst.govcloud.dk/nota/Nota-txt_only.zip"
|
10 |
+
|
11 |
+
column_order = [
|
12 |
+
"text",
|
13 |
+
"source",
|
14 |
+
"id",
|
15 |
+
"added",
|
16 |
+
"created",
|
17 |
+
"license",
|
18 |
+
"domain",
|
19 |
+
"metadata",
|
20 |
+
]
|
21 |
+
|
22 |
+
|
23 |
+
def convert_sample(id: str, text: str) -> dict:
|
24 |
+
year = id[4:8]
|
25 |
+
new_example = dict(
|
26 |
+
text=text,
|
27 |
+
id=id.split("_")[0],
|
28 |
+
source="nota",
|
29 |
+
domain="Readaloud",
|
30 |
+
license="Creative Commons Legal Code\n\nCC0 1.0 Universal",
|
31 |
+
added="2025-02-03",
|
32 |
+
created=f"{year}-01-01, {year}-12-31", # assuming v2018
|
33 |
+
metadata={"source-pretty": "Nota lyd- og tekstdata"},
|
34 |
+
)
|
35 |
+
|
36 |
+
return new_example
|
37 |
+
|
38 |
+
|
39 |
+
def download_and_process_zip(url):
|
40 |
+
response = requests.get(url)
|
41 |
+
response.raise_for_status() # Ensure we got a valid response
|
42 |
+
|
43 |
+
with ZipFile(BytesIO(response.content), "r") as z:
|
44 |
+
file_groups = defaultdict(list)
|
45 |
+
|
46 |
+
# Read all text files from the ZIP
|
47 |
+
for file_name in z.namelist():
|
48 |
+
if file_name.endswith(".txt"): # Process only text files
|
49 |
+
prefix = file_name.split("/")[1].split("_")[0]
|
50 |
+
with z.open(file_name) as f:
|
51 |
+
file_groups[prefix].append(f.read().decode("utf-8"))
|
52 |
+
|
53 |
+
# Combine files with the same prefix
|
54 |
+
combined_files = {
|
55 |
+
f"{prefix}_combined.txt": "\n".join(contents)
|
56 |
+
for prefix, contents in file_groups.items()
|
57 |
+
}
|
58 |
+
|
59 |
+
return combined_files # Dictionary with combined file names and contents
|
60 |
+
|
61 |
+
|
62 |
+
def main():
|
63 |
+
combined_results = download_and_process_zip(URL)
|
64 |
+
dataset = []
|
65 |
+
for filename, content in combined_results.items():
|
66 |
+
sample = convert_sample(filename, content)
|
67 |
+
dataset.append(sample)
|
68 |
+
|
69 |
+
df = pd.DataFrame(dataset)
|
70 |
+
df = df.drop_duplicates(keep="first", subset=["text"])
|
71 |
+
|
72 |
+
save_path = Path(__file__).parent / "nota.parquet"
|
73 |
+
df.to_parquet(save_path)
|
74 |
+
|
75 |
+
|
76 |
+
if __name__ == "__main__":
|
77 |
+
main()
|
data/nota/descriptive_stats.json
ADDED
@@ -0,0 +1 @@
|
|
|
|
|
1 |
+
{"number_of_samples": 446, "average_document_length": 38949.7802690583, "number_of_tokens": 7299012, "language": "dan, dansk, Danish", "revision": "b578ecd35a20bbabe5b0421d94d779d48e9cd4f4"}
|
data/nota/images/dist_document_length.png
ADDED
![]() |
Git LFS Details
|
data/nota/nota.md
ADDED
@@ -0,0 +1,98 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
pretty_name: Nota lyd- og tekstdata (Tekst only)
|
3 |
+
language:
|
4 |
+
- da
|
5 |
+
license: cc0-1.0
|
6 |
+
license_name: CC-0
|
7 |
+
task_categories:
|
8 |
+
- text-generation
|
9 |
+
- fill-mask
|
10 |
+
task_ids:
|
11 |
+
- language-modeling
|
12 |
+
source_datasets:
|
13 |
+
- https://sprogteknologi.dk/dataset/nota-lyd-og-tekstdata
|
14 |
+
---
|
15 |
+
|
16 |
+
# Dataset Card for Nota lyd- og tekstdata (Tekst only)
|
17 |
+
|
18 |
+
<!-- START-SHORT DESCRIPTION -->
|
19 |
+
The text only part of the [Nota lyd- og tekstdata](https://sprogteknologi.dk/dataset/nota-lyd-og-tekstdata) dataset.
|
20 |
+
<!-- END-SHORT DESCRIPTION -->
|
21 |
+
|
22 |
+
## Dataset Description
|
23 |
+
|
24 |
+
<!-- START-DESC-STATS -->
|
25 |
+
- **Language**: dan, dansk, Danish
|
26 |
+
- **Number of samples**: 446
|
27 |
+
- **Number of tokens (Llama 3)**: 7.30M
|
28 |
+
- **Average document length (characters)**: 38949.78
|
29 |
+
<!-- END-DESC-STATS -->
|
30 |
+
|
31 |
+
|
32 |
+
## Dataset Structure
|
33 |
+
An example from the dataset looks as follows.
|
34 |
+
|
35 |
+
<!-- START-SAMPLE -->
|
36 |
+
```py
|
37 |
+
{
|
38 |
+
"text": "Inspiration nr. 4, 2016\nBiblioteksbetjening \nTelefon: 39 13 46 00\nEmail: [email protected]\nInspira[...]",
|
39 |
+
"id": "INSL20160004",
|
40 |
+
"source": "nota",
|
41 |
+
"domain": "Readaloud",
|
42 |
+
"license": "Creative Commons Legal Code\n\nCC0 1.0 Universal",
|
43 |
+
"added": "2025-02-03",
|
44 |
+
"created": "2016-01-01, 2016-12-31",
|
45 |
+
"metadata": {
|
46 |
+
"source-pretty": "Nota lyd- og tekstdata"
|
47 |
+
}
|
48 |
+
}
|
49 |
+
```
|
50 |
+
|
51 |
+
### Data Fields
|
52 |
+
|
53 |
+
An entry in the dataset consists of the following fields:
|
54 |
+
|
55 |
+
- `text`(`str`): The content of the document.
|
56 |
+
- `source` (`str`): The source of the document (see [Source Data](#source-data)).
|
57 |
+
- `id` (`str`): An unique identifier for each document.
|
58 |
+
- `added` (`str`): An date for when the document was added to this collection.
|
59 |
+
- `created` (`str`): An date range for when the document was originally created.
|
60 |
+
- `license` (`str`): The license of the document. The licenses vary according to the source.
|
61 |
+
- `domain` (`str`): The domain of the source
|
62 |
+
- `metadata/source-pretty` (`str`): The long form version of the short-form source name
|
63 |
+
- `metadata/*`: Potentially additional metadata
|
64 |
+
<!-- END-SAMPLE -->
|
65 |
+
|
66 |
+
|
67 |
+
### Additional Processing
|
68 |
+
|
69 |
+
|
70 |
+
|
71 |
+
|
72 |
+
### Dataset Statistics
|
73 |
+
|
74 |
+
<!-- START-DATASET PLOTS -->
|
75 |
+
<img src="./images/dist_document_length.png" width="600" style="margin-right: 10px;" />
|
76 |
+
<img>
|
77 |
+
<!-- END-DATASET PLOTS -->
|
78 |
+
|
79 |
+
|
80 |
+
## Additional Information
|
81 |
+
|
82 |
+
|
83 |
+
### Citation Information
|
84 |
+
|
85 |
+
This dataset was initially published as part of the [Danish gigaword](https://huggingface.co/danish-foundation-models). We recommend that you cite and reference it if you use this dataset:
|
86 |
+
|
87 |
+
> Derczynski, L., Ciosici, M. R., et al. (2021). The Danish Gigaword Corpus. In Proceedings of the 23rd Nordic Conference on Computational Linguistics (NoDaLiDa 2021).
|
88 |
+
|
89 |
+
```bash
|
90 |
+
@inproceedings{dagw,
|
91 |
+
title = {{The Danish Gigaword Corpus}},
|
92 |
+
author = {Leon Derczynski and Manuel R. Ciosici and Rebekah Baglini and Morten H. Christiansen and Jacob Aarup Dalsgaard and Riccardo Fusaroli and Peter Juel Henrichsen and Rasmus Hvingelby and Andreas Kirkedal and Alex Speed Kjeldsen and Claus Ladefoged and Finn Årup Nielsen and Jens Madsen and Malte Lau Petersen and Jonathan Hvithamar Rystrøm and Daniel Varab},
|
93 |
+
year = 2021,
|
94 |
+
booktitle = {Proceedings of the 23rd Nordic Conference on Computational Linguistics},
|
95 |
+
publisher = {NEALT}
|
96 |
+
}
|
97 |
+
```
|
98 |
+
|
data/nota/nota.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:c18ea01538fb6f36303e26da870de0b220db358a1733b50ba0f669312f08cb9f
|
3 |
+
size 7905103
|
descriptive_stats.json
CHANGED
@@ -1 +1 @@
|
|
1 |
-
{"number_of_samples":
|
|
|
1 |
+
{"number_of_samples": 588922, "average_document_length": 9245.09222613521, "number_of_tokens": 1852293828, "language": "dan, dansk, Danish", "revision": "dd7498844276f5f97f8a318b3def20f8b576dd91"}
|
images/dist_document_length.png
CHANGED
![]() |
Git LFS Details
|
![]() |
Git LFS Details
|
pyproject.toml
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
[project]
|
2 |
name = "danish-dynaword"
|
3 |
-
version = "1.0.
|
4 |
description = "project code for the danish dynaword project"
|
5 |
readme = "README.md"
|
6 |
requires-python = ">=3.12,<3.13" # 3.13 have issues with spacy and pytorch
|
|
|
1 |
[project]
|
2 |
name = "danish-dynaword"
|
3 |
+
version = "1.0.8"
|
4 |
description = "project code for the danish dynaword project"
|
5 |
readme = "README.md"
|
6 |
requires-python = ">=3.12,<3.13" # 3.13 have issues with spacy and pytorch
|
test_results.log
CHANGED
@@ -1,38 +1,13 @@
|
|
1 |
============================= test session starts ==============================
|
2 |
-
platform darwin -- Python 3.12.
|
3 |
-
rootdir: /Users/
|
4 |
configfile: pyproject.toml
|
5 |
-
collected
|
6 |
|
7 |
-
src/tests/test_dataset_schema.py ....................................... [
|
8 |
-
|
9 |
-
src/tests/test_duplicates.py
|
10 |
-
src/tests/test_load.py
|
11 |
src/tests/test_unique_ids.py . [100%]
|
12 |
|
13 |
-
|
14 |
-
__________________________ test_all_datasets_in_yaml ___________________________
|
15 |
-
|
16 |
-
repo_path = PosixPath('/Users/au561649/Github/danish-dynaword')
|
17 |
-
|
18 |
-
def test_all_datasets_in_yaml(repo_path: Path):
|
19 |
-
frontmatter, _ = read_frontmatter_and_body(repo_path / "README.md")
|
20 |
-
|
21 |
-
ds_names = {
|
22 |
-
cfg["config_name"]
|
23 |
-
for cfg in frontmatter["configs"]
|
24 |
-
if cfg["config_name"] != "default"
|
25 |
-
}
|
26 |
-
|
27 |
-
data_folder = repo_path / "data"
|
28 |
-
datasets = data_folder.glob("*")
|
29 |
-
|
30 |
-
for dataset in datasets:
|
31 |
-
> assert dataset.name in ds_names
|
32 |
-
E AssertionError: assert 'miljoeportalen' in {'adl', 'botxt', 'dannet', 'depbank', 'ep', 'ft', ...}
|
33 |
-
E + where 'miljoeportalen' = PosixPath('/Users/au561649/Github/danish-dynaword/data/miljoeportalen').name
|
34 |
-
|
35 |
-
src/tests/test_load.py:29: AssertionError
|
36 |
-
=========================== short test summary info ============================
|
37 |
-
FAILED src/tests/test_load.py::test_all_datasets_in_yaml - AssertionError: as...
|
38 |
-
================== 1 failed, 71 passed, 24 skipped in 14.54s ===================
|
|
|
1 |
============================= test session starts ==============================
|
2 |
+
platform darwin -- Python 3.12.7, pytest-8.3.4, pluggy-1.5.0
|
3 |
+
rootdir: /Users/kristianjensen/Documents/danish-dynaword
|
4 |
configfile: pyproject.toml
|
5 |
+
collected 100 items
|
6 |
|
7 |
+
src/tests/test_dataset_schema.py ....................................... [ 39%]
|
8 |
+
................................. [ 72%]
|
9 |
+
src/tests/test_duplicates.py sssssssssssssssssssssssss [ 97%]
|
10 |
+
src/tests/test_load.py .. [ 99%]
|
11 |
src/tests/test_unique_ids.py . [100%]
|
12 |
|
13 |
+
======================== 75 passed, 25 skipped in 6.31s ========================
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
uv.lock
CHANGED
@@ -3,7 +3,7 @@ requires-python = "==3.12.*"
|
|
3 |
resolution-markers = [
|
4 |
"sys_platform == 'darwin'",
|
5 |
"platform_machine == 'aarch64' and sys_platform == 'linux'",
|
6 |
-
"(platform_machine != 'aarch64' and sys_platform
|
7 |
]
|
8 |
|
9 |
[[package]]
|
@@ -180,7 +180,7 @@ name = "click"
|
|
180 |
version = "8.1.8"
|
181 |
source = { registry = "https://pypi.org/simple" }
|
182 |
dependencies = [
|
183 |
-
{ name = "colorama", marker = "
|
184 |
]
|
185 |
sdist = { url = "https://files.pythonhosted.org/packages/b9/2e/0090cbf739cee7d23781ad4b89a9894a41538e4fcf4c31dcdd705b78eb8b/click-8.1.8.tar.gz", hash = "sha256:ed53c9d8990d83c2a27deae68e4ee337473f6330c040a31d4225c9574d16096a", size = 226593 }
|
186 |
wheels = [
|
@@ -275,7 +275,7 @@ wheels = [
|
|
275 |
|
276 |
[[package]]
|
277 |
name = "danish-dynaword"
|
278 |
-
version = "1.0.
|
279 |
source = { virtual = "." }
|
280 |
dependencies = [
|
281 |
{ name = "datasets" },
|
@@ -504,7 +504,7 @@ name = "ipykernel"
|
|
504 |
version = "6.29.5"
|
505 |
source = { registry = "https://pypi.org/simple" }
|
506 |
dependencies = [
|
507 |
-
{ name = "appnope", marker = "
|
508 |
{ name = "comm" },
|
509 |
{ name = "debugpy" },
|
510 |
{ name = "ipython" },
|
@@ -750,7 +750,7 @@ dependencies = [
|
|
750 |
{ name = "numpy" },
|
751 |
{ name = "pandas" },
|
752 |
{ name = "scipy" },
|
753 |
-
{ name = "tzdata", marker = "
|
754 |
]
|
755 |
sdist = { url = "https://files.pythonhosted.org/packages/91/c3/9f83c374314b2b42e7aec65f3bf87046415ab265f209fa8a04eb6da822ee/mizani-0.13.1.tar.gz", hash = "sha256:e3247ea12c746c8104767d7e42a2d16473173c7bc314f298d8294a58f4653353", size = 765181 }
|
756 |
wheels = [
|
@@ -851,7 +851,7 @@ name = "pandas"
|
|
851 |
version = "2.2.3"
|
852 |
source = { registry = "https://pypi.org/simple" }
|
853 |
dependencies = [
|
854 |
-
{ name = "numpy" },
|
855 |
{ name = "python-dateutil" },
|
856 |
{ name = "pytz" },
|
857 |
{ name = "tzdata" },
|
@@ -1383,7 +1383,7 @@ dependencies = [
|
|
1383 |
{ name = "jinja2" },
|
1384 |
{ name = "langcodes" },
|
1385 |
{ name = "murmurhash" },
|
1386 |
-
{ name = "numpy" },
|
1387 |
{ name = "packaging" },
|
1388 |
{ name = "preshed" },
|
1389 |
{ name = "pydantic" },
|
@@ -1495,7 +1495,7 @@ dependencies = [
|
|
1495 |
{ name = "confection" },
|
1496 |
{ name = "cymem" },
|
1497 |
{ name = "murmurhash" },
|
1498 |
-
{ name = "numpy" },
|
1499 |
{ name = "packaging" },
|
1500 |
{ name = "preshed" },
|
1501 |
{ name = "pydantic" },
|
@@ -1569,7 +1569,7 @@ name = "tqdm"
|
|
1569 |
version = "4.67.1"
|
1570 |
source = { registry = "https://pypi.org/simple" }
|
1571 |
dependencies = [
|
1572 |
-
{ name = "colorama", marker = "
|
1573 |
]
|
1574 |
sdist = { url = "https://files.pythonhosted.org/packages/a8/4b/29b4ef32e036bb34e4ab51796dd745cdba7ed47ad142a9f4a1eb8e0c744d/tqdm-4.67.1.tar.gz", hash = "sha256:f8aef9c52c08c13a65f30ea34f4e5aac3fd1a34959879d7e59e63027286627f2", size = 169737 }
|
1575 |
wheels = [
|
@@ -1653,7 +1653,7 @@ name = "wasabi"
|
|
1653 |
version = "1.1.3"
|
1654 |
source = { registry = "https://pypi.org/simple" }
|
1655 |
dependencies = [
|
1656 |
-
{ name = "colorama", marker = "sys_platform == 'win32'" },
|
1657 |
]
|
1658 |
sdist = { url = "https://files.pythonhosted.org/packages/ac/f9/054e6e2f1071e963b5e746b48d1e3727470b2a490834d18ad92364929db3/wasabi-1.1.3.tar.gz", hash = "sha256:4bb3008f003809db0c3e28b4daf20906ea871a2bb43f9914197d540f4f2e0878", size = 30391 }
|
1659 |
wheels = [
|
|
|
3 |
resolution-markers = [
|
4 |
"sys_platform == 'darwin'",
|
5 |
"platform_machine == 'aarch64' and sys_platform == 'linux'",
|
6 |
+
"(platform_machine != 'aarch64' and sys_platform != 'darwin') or (sys_platform != 'darwin' and sys_platform != 'linux')",
|
7 |
]
|
8 |
|
9 |
[[package]]
|
|
|
180 |
version = "8.1.8"
|
181 |
source = { registry = "https://pypi.org/simple" }
|
182 |
dependencies = [
|
183 |
+
{ name = "colorama", marker = "platform_system == 'Windows'" },
|
184 |
]
|
185 |
sdist = { url = "https://files.pythonhosted.org/packages/b9/2e/0090cbf739cee7d23781ad4b89a9894a41538e4fcf4c31dcdd705b78eb8b/click-8.1.8.tar.gz", hash = "sha256:ed53c9d8990d83c2a27deae68e4ee337473f6330c040a31d4225c9574d16096a", size = 226593 }
|
186 |
wheels = [
|
|
|
275 |
|
276 |
[[package]]
|
277 |
name = "danish-dynaword"
|
278 |
+
version = "1.0.8"
|
279 |
source = { virtual = "." }
|
280 |
dependencies = [
|
281 |
{ name = "datasets" },
|
|
|
504 |
version = "6.29.5"
|
505 |
source = { registry = "https://pypi.org/simple" }
|
506 |
dependencies = [
|
507 |
+
{ name = "appnope", marker = "platform_system == 'Darwin'" },
|
508 |
{ name = "comm" },
|
509 |
{ name = "debugpy" },
|
510 |
{ name = "ipython" },
|
|
|
750 |
{ name = "numpy" },
|
751 |
{ name = "pandas" },
|
752 |
{ name = "scipy" },
|
753 |
+
{ name = "tzdata", marker = "platform_system == 'Emscripten' or platform_system == 'Windows'" },
|
754 |
]
|
755 |
sdist = { url = "https://files.pythonhosted.org/packages/91/c3/9f83c374314b2b42e7aec65f3bf87046415ab265f209fa8a04eb6da822ee/mizani-0.13.1.tar.gz", hash = "sha256:e3247ea12c746c8104767d7e42a2d16473173c7bc314f298d8294a58f4653353", size = 765181 }
|
756 |
wheels = [
|
|
|
851 |
version = "2.2.3"
|
852 |
source = { registry = "https://pypi.org/simple" }
|
853 |
dependencies = [
|
854 |
+
{ name = "numpy", marker = "python_full_version == '3.12.*'" },
|
855 |
{ name = "python-dateutil" },
|
856 |
{ name = "pytz" },
|
857 |
{ name = "tzdata" },
|
|
|
1383 |
{ name = "jinja2" },
|
1384 |
{ name = "langcodes" },
|
1385 |
{ name = "murmurhash" },
|
1386 |
+
{ name = "numpy", marker = "python_full_version == '3.12.*'" },
|
1387 |
{ name = "packaging" },
|
1388 |
{ name = "preshed" },
|
1389 |
{ name = "pydantic" },
|
|
|
1495 |
{ name = "confection" },
|
1496 |
{ name = "cymem" },
|
1497 |
{ name = "murmurhash" },
|
1498 |
+
{ name = "numpy", marker = "python_full_version == '3.12.*'" },
|
1499 |
{ name = "packaging" },
|
1500 |
{ name = "preshed" },
|
1501 |
{ name = "pydantic" },
|
|
|
1569 |
version = "4.67.1"
|
1570 |
source = { registry = "https://pypi.org/simple" }
|
1571 |
dependencies = [
|
1572 |
+
{ name = "colorama", marker = "platform_system == 'Windows'" },
|
1573 |
]
|
1574 |
sdist = { url = "https://files.pythonhosted.org/packages/a8/4b/29b4ef32e036bb34e4ab51796dd745cdba7ed47ad142a9f4a1eb8e0c744d/tqdm-4.67.1.tar.gz", hash = "sha256:f8aef9c52c08c13a65f30ea34f4e5aac3fd1a34959879d7e59e63027286627f2", size = 169737 }
|
1575 |
wheels = [
|
|
|
1653 |
version = "1.1.3"
|
1654 |
source = { registry = "https://pypi.org/simple" }
|
1655 |
dependencies = [
|
1656 |
+
{ name = "colorama", marker = "sys_platform == 'win32' and python_full_version == '3.12.*'" },
|
1657 |
]
|
1658 |
sdist = { url = "https://files.pythonhosted.org/packages/ac/f9/054e6e2f1071e963b5e746b48d1e3727470b2a490834d18ad92364929db3/wasabi-1.1.3.tar.gz", hash = "sha256:4bb3008f003809db0c3e28b4daf20906ea871a2bb43f9914197d540f4f2e0878", size = 30391 }
|
1659 |
wheels = [
|