KennethEnevoldsen commited on
Commit
560c6d0
Β·
1 Parent(s): 25445ec

Added changelog

Browse files
.gitignore CHANGED
@@ -14,3 +14,9 @@ tmp.png
14
 
15
  # MacOS
16
  .DS_Store
 
 
 
 
 
 
 
14
 
15
  # MacOS
16
  .DS_Store
17
+
18
+ # tmp files
19
+ tmp.py
20
+
21
+ ## to allow temporary data drops without pushing it to the hub
22
+ data/*/tmp/*
CHANGELOG.md ADDED
@@ -0,0 +1,22 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ # Changelog
3
+
4
+ All notable changes to this project will be documented in this file.
5
+
6
+ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/).
7
+
8
+ ## [v1.0.11] - 2025-03-29
9
+
10
+ ### Added
11
+
12
+ - Added new datasets (more that 1B tokens πŸŽ‰)
13
+ - AI Aktindsigt
14
+ - Cellar
15
+ - Danske Taler
16
+ - MiljΓΈportalen
17
+ - EUR-Lex SUM
18
+
19
+ ### Docs
20
+
21
+ - Sorted main table in readme
22
+ - Added Changelog
README.md CHANGED
@@ -158,7 +158,7 @@ https://github.com/huggingface/datasets/blob/main/templates/README_guide.md
158
  <!-- START README TABLE -->
159
  | | |
160
  | ------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------- |
161
- | **Version** | 1.0.10 |
162
  | **Language** | dan, dansk, Danish |
163
  | **License** | Permissible, See the respective dataset |
164
  | **Models** | For model trained used this data see [danish-foundation-models](https://huggingface.co/danish-foundation-models) |
 
158
  <!-- START README TABLE -->
159
  | | |
160
  | ------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------- |
161
+ | **Version** | 1.0.11 ([Changelog](/CHANGELOG.md)) |
162
  | **Language** | dan, dansk, Danish |
163
  | **License** | Permissible, See the respective dataset |
164
  | **Models** | For model trained used this data see [danish-foundation-models](https://huggingface.co/danish-foundation-models) |
data/danske-taler/create.py CHANGED
@@ -97,12 +97,12 @@ def fetch_license_div(
97
  retries += 1
98
 
99
  if retries > max_retries:
100
- print(f"Failed to fetch license after {max_retries} attempts: {str(e)}")
101
  return None
102
 
103
  # Calculate backoff time using exponential backoff
104
  wait_time = backoff_factor * (2 ** (retries - 1))
105
- print(f"Attempt {retries} failed. Retrying in {wait_time:.2f} seconds...")
106
  time.sleep(wait_time)
107
 
108
  return None
@@ -215,5 +215,13 @@ def main():
215
 
216
 
217
  if __name__ == "__main__":
218
- logging.basicConfig(level=logging.INFO)
 
 
 
 
 
 
 
 
219
  main()
 
97
  retries += 1
98
 
99
  if retries > max_retries:
100
+ logger.info(f"Failed to fetch license after {max_retries} attempts: {str(e)}")
101
  return None
102
 
103
  # Calculate backoff time using exponential backoff
104
  wait_time = backoff_factor * (2 ** (retries - 1))
105
+ logger.info(f"Attempt {retries} failed. Retrying in {wait_time:.2f} seconds...")
106
  time.sleep(wait_time)
107
 
108
  return None
 
215
 
216
 
217
  if __name__ == "__main__":
218
+ log_path = Path(__file__).parent / "danske-taler.log"
219
+ logging.basicConfig(
220
+ level=logging.INFO,
221
+ format="%(asctime)s - %(levelname)s - %(message)s",
222
+ handlers=[
223
+ logging.StreamHandler(),
224
+ logging.FileHandler(log_path),
225
+ ],
226
+ )
227
  main()
data/danske-taler/danske-taler.log ADDED
@@ -0,0 +1,57 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 2025-03-29 14:14:08,846 - INFO - Downloading speeches and saving to /work/githubs/tmp/danish-dynaword/data/danske-taler/tmp/danske-taler-all.parquet
2
+ 2025-03-29 14:14:08,847 - INFO - Fetching all speeches from Danske Taler API
3
+ 2025-03-29 14:15:19,326 - INFO - Found 4725 speeches
4
+ 13%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 597/4725 [01:22<11:15, 6.11it/s]Attempt 1 failed. Retrying in 0.50 seconds...
5
+ Attempt 2 failed. Retrying in 1.00 seconds...
6
+ Attempt 3 failed. Retrying in 2.00 seconds...
7
+ Failed to fetch license after 3 attempts: 500 Server Error: Internal Server Error for url: https://www.dansketaler.dk/tale/niels-hoejlund-pedersens-translokationstale-2020
8
+ 17%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ | 818/4725 [01:57<09:00, 7.23it/s]Attempt 1 failed. Retrying in 0.50 seconds...
9
+ Attempt 2 failed. Retrying in 1.00 seconds...
10
+ Attempt 3 failed. Retrying in 2.00 seconds...
11
+ Failed to fetch license after 3 attempts: 500 Server Error: Internal Server Error for url: https://www.dansketaler.dk/tale/katrine-lykke-pedersens-tale-til-unge-om-haab-i-en-coronatid
12
+ 17%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 820/4725 [02:01<1:05:16, 1.00s/it]Attempt 1 failed. Retrying in 0.50 seconds...
13
+ Attempt 2 failed. Retrying in 1.00 seconds...
14
+ Attempt 3 failed. Retrying in 2.00 seconds...
15
+ Failed to fetch license after 3 attempts: 500 Server Error: Internal Server Error for url: https://www.dansketaler.dk/tale/anastacia-halkens-tale-til-unge-om-haab-i-en-coronatid
16
+ 18%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 828/4725 [02:07<17:53, 3.63it/s]Attempt 1 failed. Retrying in 0.50 seconds...
17
+ Attempt 2 failed. Retrying in 1.00 seconds...
18
+ Attempt 3 failed. Retrying in 2.00 seconds...
19
+ Failed to fetch license after 3 attempts: 500 Server Error: Internal Server Error for url: https://www.dansketaler.dk/tale/thomas-vinterbergs-tale-ved-modtagelsen-af-oscar-prisen
20
+ 22%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‹ | 1042/4725 [02:41<10:04, 6.09it/s]Attempt 1 failed. Retrying in 0.50 seconds...
21
+ Attempt 2 failed. Retrying in 1.00 seconds...
22
+ Attempt 3 failed. Retrying in 2.00 seconds...
23
+ Failed to fetch license after 3 attempts: 500 Server Error: Internal Server Error for url: https://www.dansketaler.dk/tale/pernille-vermunds-tale-ved-folketingets-aabningsdebat-2021
24
+ 22%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–‰ | 1059/4725 [02:48<08:22, 7.30it/s]Attempt 1 failed. Retrying in 0.50 seconds...
25
+ Attempt 2 failed. Retrying in 1.00 seconds...
26
+ Attempt 3 failed. Retrying in 2.00 seconds...
27
+ Failed to fetch license after 3 attempts: 500 Server Error: Internal Server Error for url: https://www.dansketaler.dk/tale/pernille-vermunds-tale-ved-nye-borgerliges-aarsmoede-2021
28
+ 22%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 1061/4725 [02:52<1:01:08, 1.00s/it]Attempt 1 failed. Retrying in 0.50 seconds...
29
+ Attempt 2 failed. Retrying in 1.00 seconds...
30
+ Attempt 3 failed. Retrying in 2.00 seconds...
31
+ Failed to fetch license after 3 attempts: 500 Server Error: Internal Server Error for url: https://www.dansketaler.dk/tale/mette-thiesens-tale-ved-nye-borgerliges-aarsmoede-2021
32
+ 22%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–Œ | 1062/4725 [02:57<2:00:22, 1.97s/it]Attempt 1 failed. Retrying in 0.50 seconds...
33
+ Attempt 2 failed. Retrying in 1.00 seconds...
34
+ Attempt 3 failed. Retrying in 2.00 seconds...
35
+ Failed to fetch license after 3 attempts: 500 Server Error: Internal Server Error for url: https://www.dansketaler.dk/tale/peter-seier-christensens-tale-ved-nye-borgerliges-aarsmoede-2021
36
+ 34%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ– | 1617/4725 [04:25<07:09, 7.24it/s]Attempt 1 failed. Retrying in 0.50 seconds...
37
+ Attempt 2 failed. Retrying in 1.00 seconds...
38
+ Attempt 3 failed. Retrying in 2.00 seconds...
39
+ Failed to fetch license after 3 attempts: 500 Server Error: Internal Server Error for url: https://www.dansketaler.dk/tale/silke-ena-svares-tale-ved-demonstrationen-for-born-og-unge
40
+ 100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 4725/4725 [12:43<00:00, 6.19it/s]
41
+ 2025-03-29 14:28:02,454 - INFO - Saving 4725 speeches to dataset
42
+ 2025-03-29 14:28:03,330 - INFO - Unique licenses:
43
+ 2025-03-29 14:28:03,331 - INFO - None
44
+ 2025-03-29 14:28:03,331 - INFO - Materialet er beskyttet af ophavsret
45
+ 2025-03-29 14:28:03,331 - INFO - cc0
46
+ 2025-03-29 14:28:03,331 - INFO - Materialet er beskyttet af ophavsret, da talen ikke er holdt i offentligheden.
47
+ 2025-03-29 14:28:03,331 - INFO - Materialet er omfattet af ophavsret
48
+ 2025-03-29 14:28:03,331 - INFO - Manuskript taget fra ft.dk. med tilladelse fra udgiver.
49
+ 2025-03-29 14:28:03,331 - INFO - Materialet et beskyttet af ophavsret
50
+ 2025-03-29 14:28:03,331 - INFO - Manuskript taget fra ft.dk med tilladelse fra udgiver.
51
+ 2025-03-29 14:28:03,331 - INFO - Materialet er beskyttet af ophavsret
52
+ 2025-03-29 14:28:03,331 - INFO - Materialet er beskyttet af ophavsret
53
+ 2025-03-29 14:28:03,461 - INFO - Removed 2063 documents without a cc0 license
54
+ 2025-03-29 14:28:03,541 - INFO - Removed 0 duplicate ids
55
+ 2025-03-29 14:28:03,549 - INFO - Removed 2 rows with empty text
56
+ 2025-03-29 14:28:03,631 - INFO - Removed 2 rows with duplicate text
57
+ Creating parquet from Arrow format: 100%|β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 3/3 [00:00<00:00, 11.33ba/s]
data/danske-taler/danske-taler.parquet CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:654fbad07d68e4ec79dfa09aca5e6f9e96a889d336872b7b6d562fcbb83cbd94
3
- size 15091764
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:541b5692b2f9cd0a35eb179f2b1ec6786f819ac9f16c9d3c67f5265fc458cbdc
3
+ size 15090122
data/miljoeportalen/miljoeportalen.md CHANGED
@@ -2,7 +2,7 @@
2
  pretty_name: MiljΓΈportalen
3
  language:
4
  - da
5
- license: cc0
6
  license_name: CC-0
7
  task_categories:
8
  - text-generation
 
2
  pretty_name: MiljΓΈportalen
3
  language:
4
  - da
5
+ license: cc0-1.0
6
  license_name: CC-0
7
  task_categories:
8
  - text-generation
pyproject.toml CHANGED
@@ -1,6 +1,6 @@
1
  [project]
2
  name = "danish-dynaword"
3
- version = "1.0.10"
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.11"
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
src/bump_version.py CHANGED
@@ -26,6 +26,7 @@ def update_readme(version: str, readme_path: Path) -> None:
26
  """Find version in README table and update it."""
27
  start = "<!-- START README TABLE -->"
28
  end = "<!-- END README TABLE -->"
 
29
 
30
  with readme_path.open("r") as f:
31
  lines = f.readlines()
@@ -36,7 +37,7 @@ def update_readme(version: str, readme_path: Path) -> None:
36
  in_table = True
37
  if in_table:
38
  if "**Version**" in line:
39
- lines[i] = f"| **Version** | {version} |\n"
40
  break
41
  if end in line:
42
  raise ValueError("**Version** not found in README table.")
 
26
  """Find version in README table and update it."""
27
  start = "<!-- START README TABLE -->"
28
  end = "<!-- END README TABLE -->"
29
+
30
 
31
  with readme_path.open("r") as f:
32
  lines = f.readlines()
 
37
  in_table = True
38
  if in_table:
39
  if "**Version**" in line:
40
+ lines[i] = f"| **Version** | {version} ([Changelog](/CHANGELOG.md)) |\n"
41
  break
42
  if end in line:
43
  raise ValueError("**Version** not found in README table.")
src/tests/test_load.py CHANGED
@@ -4,6 +4,7 @@ from datasets import load_dataset
4
 
5
  from tests.readme_parsing import read_frontmatter_and_body
6
 
 
7
 
8
  def test_dataset_loads(repo_path: Path):
9
  """Ensures that the dataset can load as intended"""
@@ -26,4 +27,5 @@ def test_all_datasets_in_yaml(repo_path: Path):
26
  datasets = data_folder.glob("*")
27
 
28
  for dataset in datasets:
29
- assert dataset.name in ds_names
 
 
4
 
5
  from tests.readme_parsing import read_frontmatter_and_body
6
 
7
+ REMOVED_DATA = ["lexdk"] # data that has been removed due to legal disputes, question about legality, or similar
8
 
9
  def test_dataset_loads(repo_path: Path):
10
  """Ensures that the dataset can load as intended"""
 
27
  datasets = data_folder.glob("*")
28
 
29
  for dataset in datasets:
30
+ if dataset.name not in REMOVED_DATA:
31
+ assert dataset.name in ds_names