Upload knessetCorpus.py
Browse files- knessetCorpus.py +5 -0
knessetCorpus.py
CHANGED
@@ -1,6 +1,7 @@
|
|
1 |
import json
|
2 |
import os
|
3 |
from typing import List
|
|
|
4 |
|
5 |
import datasets
|
6 |
|
@@ -259,6 +260,10 @@ class KnessetCorpus(datasets.GeneratorBasedBuilder):
|
|
259 |
print(f'data_files:{data_files}')
|
260 |
if "all_features_sentences" in self.config.name:
|
261 |
id_field_name = "sentence_id"
|
|
|
|
|
|
|
|
|
262 |
elif self.config.name == "protocols":
|
263 |
id_field_name = "protocol_name"
|
264 |
elif self.config.name == "factions":
|
|
|
1 |
import json
|
2 |
import os
|
3 |
from typing import List
|
4 |
+
from huggingface_hub import hf_hub_url
|
5 |
|
6 |
import datasets
|
7 |
|
|
|
260 |
print(f'data_files:{data_files}')
|
261 |
if "all_features_sentences" in self.config.name:
|
262 |
id_field_name = "sentence_id"
|
263 |
+
url = hf_hub_url(repo_id="HaifaCLGroup/knessetCorpus",
|
264 |
+
filename="KnessetCorpus/protocols_sentences/committee_full_sentences.jsonl.bz2")
|
265 |
+
data_files = [url]
|
266 |
+
|
267 |
elif self.config.name == "protocols":
|
268 |
id_field_name = "protocol_name"
|
269 |
elif self.config.name == "factions":
|