Datasets:

Languages:
Persian
Multilinguality:
monolingual
Size Categories:
1K<n<10K
Language Creators:
found
Annotations Creators:
found
Source Datasets:
original
Tags:
License:
system HF staff commited on
Commit
ebadc54
0 Parent(s):

Update files from the datasets library (from 1.2.0)

Browse files

Release notes: https://github.com/huggingface/datasets/releases/tag/1.2.0

Files changed (5) hide show
  1. .gitattributes +27 -0
  2. README.md +150 -0
  3. dataset_infos.json +58 -0
  4. dummy/1.0.0/dummy_data.zip +3 -0
  5. farsi_news.py +94 -0
.gitattributes ADDED
@@ -0,0 +1,27 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ *.7z filter=lfs diff=lfs merge=lfs -text
2
+ *.arrow filter=lfs diff=lfs merge=lfs -text
3
+ *.bin filter=lfs diff=lfs merge=lfs -text
4
+ *.bin.* filter=lfs diff=lfs merge=lfs -text
5
+ *.bz2 filter=lfs diff=lfs merge=lfs -text
6
+ *.ftz filter=lfs diff=lfs merge=lfs -text
7
+ *.gz filter=lfs diff=lfs merge=lfs -text
8
+ *.h5 filter=lfs diff=lfs merge=lfs -text
9
+ *.joblib filter=lfs diff=lfs merge=lfs -text
10
+ *.lfs.* filter=lfs diff=lfs merge=lfs -text
11
+ *.model filter=lfs diff=lfs merge=lfs -text
12
+ *.msgpack filter=lfs diff=lfs merge=lfs -text
13
+ *.onnx filter=lfs diff=lfs merge=lfs -text
14
+ *.ot filter=lfs diff=lfs merge=lfs -text
15
+ *.parquet filter=lfs diff=lfs merge=lfs -text
16
+ *.pb filter=lfs diff=lfs merge=lfs -text
17
+ *.pt filter=lfs diff=lfs merge=lfs -text
18
+ *.pth filter=lfs diff=lfs merge=lfs -text
19
+ *.rar filter=lfs diff=lfs merge=lfs -text
20
+ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
21
+ *.tar.* filter=lfs diff=lfs merge=lfs -text
22
+ *.tflite filter=lfs diff=lfs merge=lfs -text
23
+ *.tgz filter=lfs diff=lfs merge=lfs -text
24
+ *.xz filter=lfs diff=lfs merge=lfs -text
25
+ *.zip filter=lfs diff=lfs merge=lfs -text
26
+ *.zstandard filter=lfs diff=lfs merge=lfs -text
27
+ *tfevents* filter=lfs diff=lfs merge=lfs -text
README.md ADDED
@@ -0,0 +1,150 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ annotations_creators:
3
+ - found
4
+ language_creators:
5
+ - found
6
+ languages:
7
+ - fa
8
+ licenses:
9
+ - unknown
10
+ multilinguality:
11
+ - monolingual
12
+ size_categories:
13
+ - 1K<n<10K
14
+ source_datasets:
15
+ - original
16
+ task_categories:
17
+ - sequence-modeling
18
+ task_ids:
19
+ - language-modeling
20
+ ---
21
+
22
+ # Dataset Card Creation Guide
23
+
24
+ ## Table of Contents
25
+ - [Dataset Description](#dataset-description)
26
+ - [Dataset Summary](#dataset-summary)
27
+ - [Supported Tasks](#supported-tasks-and-leaderboards)
28
+ - [Languages](#languages)
29
+ - [Dataset Structure](#dataset-structure)
30
+ - [Data Instances](#data-instances)
31
+ - [Data Fields](#data-instances)
32
+ - [Data Splits](#data-instances)
33
+ - [Dataset Creation](#dataset-creation)
34
+ - [Curation Rationale](#curation-rationale)
35
+ - [Source Data](#source-data)
36
+ - [Annotations](#annotations)
37
+ - [Personal and Sensitive Information](#personal-and-sensitive-information)
38
+ - [Considerations for Using the Data](#considerations-for-using-the-data)
39
+ - [Social Impact of Dataset](#social-impact-of-dataset)
40
+ - [Discussion of Biases](#discussion-of-biases)
41
+ - [Other Known Limitations](#other-known-limitations)
42
+ - [Additional Information](#additional-information)
43
+ - [Dataset Curators](#dataset-curators)
44
+ - [Licensing Information](#licensing-information)
45
+ - [Citation Information](#citation-information)
46
+
47
+ ## Dataset Description
48
+
49
+ - **Homepage:** []()
50
+ - **Repository:** [link](https://github.com/sci2lab/Farsi-datasets)
51
+ - **Paper:** []()
52
+ - **Leaderboard:** []()
53
+ - **Point of Contact:** []()
54
+
55
+ ### Dataset Summary
56
+
57
+ https://github.com/sci2lab/Farsi-datasets
58
+ Contains Farsi (Persian) datasets for Machine Learning tasks, particularly NLP.
59
+ These datasets have been extracted from the RSS feed of two Farsi news agency websites:
60
+
61
+ - Hamshahri
62
+ - RadioFarda
63
+
64
+ ### Supported Tasks and Leaderboards
65
+
66
+ [More Information Needed]
67
+
68
+ ### Languages
69
+
70
+ [More Information Needed]
71
+
72
+ ## Dataset Structure
73
+
74
+ [More Information Needed]
75
+
76
+ ### Data Instances
77
+
78
+ [More Information Needed]
79
+
80
+ ### Data Fields
81
+
82
+ [More Information Needed]
83
+
84
+ ### Data Splits
85
+
86
+ [More Information Needed]
87
+
88
+ ## Dataset Creation
89
+
90
+
91
+ ### Curation Rationale
92
+
93
+ [More Information Needed]
94
+
95
+ ### Source Data
96
+
97
+ [More Information Needed]
98
+
99
+ #### Initial Data Collection and Normalization
100
+
101
+ [More Information Needed]
102
+
103
+ #### Who are the source language producers?
104
+
105
+ [More Information Needed]
106
+
107
+ ### Annotations
108
+
109
+ [More Information Needed]
110
+
111
+ #### Annotation process
112
+
113
+ [More Information Needed]
114
+
115
+ #### Who are the annotators?
116
+
117
+ [More Information Needed]
118
+
119
+ ### Personal and Sensitive Information
120
+
121
+ [More Information Needed]
122
+
123
+ ## Considerations for Using the Data
124
+
125
+ ### Social Impact of Dataset
126
+
127
+ [More Information Needed]
128
+
129
+ ### Discussion of Biases
130
+
131
+ [More Information Needed]
132
+
133
+ ### Other Known Limitations
134
+
135
+ [More Information Needed]
136
+
137
+ ## Additional Information
138
+
139
+ ### Dataset Curators
140
+
141
+ [More Information Needed]
142
+
143
+ ### Licensing Information
144
+
145
+ [More Information Needed]
146
+
147
+ ### Citation Information
148
+
149
+ https://github.com/sci2lab/Farsi-datasets
150
+
dataset_infos.json ADDED
@@ -0,0 +1,58 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "default": {
3
+ "description": "\n",
4
+ "citation": "",
5
+ "homepage": "https://github.com/sci2lab/Farsi-datasets",
6
+ "license": "",
7
+ "features": {
8
+ "title": { "dtype": "string", "id": null, "_type": "Value" },
9
+ "summary": { "dtype": "string", "id": null, "_type": "Value" },
10
+ "link": { "dtype": "string", "id": null, "_type": "Value" },
11
+ "tags": {
12
+ "feature": { "dtype": "string", "id": null, "_type": "Value" },
13
+ "length": -1,
14
+ "id": null,
15
+ "_type": "Sequence"
16
+ }
17
+ },
18
+ "post_processed": null,
19
+ "supervised_keys": null,
20
+ "builder_name": "farsi_news",
21
+ "config_name": "default",
22
+ "version": {
23
+ "version_str": "1.0.0",
24
+ "description": null,
25
+ "major": 1,
26
+ "minor": 0,
27
+ "patch": 0
28
+ },
29
+ "splits": {
30
+ "hamshahri": {
31
+ "name": "hamshahri",
32
+ "num_bytes": 1267659,
33
+ "num_examples": 2203,
34
+ "dataset_name": "farsi_news"
35
+ },
36
+ "radiofarda": {
37
+ "name": "radiofarda",
38
+ "num_bytes": 265272,
39
+ "num_examples": 284,
40
+ "dataset_name": "farsi_news"
41
+ }
42
+ },
43
+ "download_checksums": {
44
+ "https://raw.githubusercontent.com/sci2lab/Farsi-datasets/master/farsi_news/hamshahri.json": {
45
+ "num_bytes": 1369041,
46
+ "checksum": "45443c16aada96ebf33df7d40940a21373e15b9a9a142780e636f5fb6de76485"
47
+ },
48
+ "https://raw.githubusercontent.com/sci2lab/Farsi-datasets/master/farsi_news/radiofarda.json": {
49
+ "num_bytes": 279296,
50
+ "checksum": "c7ca5a63405227a70b612bcfab3fb852e22333cf04b74188b27306da0a82c243"
51
+ }
52
+ },
53
+ "download_size": 1648337,
54
+ "post_processing_size": null,
55
+ "dataset_size": 1532931,
56
+ "size_in_bytes": 3181268
57
+ }
58
+ }
dummy/1.0.0/dummy_data.zip ADDED
@@ -0,0 +1,3 @@
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9bf0d064778d649d0e348b70535e18b2d18782d41a761a6f23ee2e16e24f9f92
3
+ size 3926
farsi_news.py ADDED
@@ -0,0 +1,94 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright 2020 the HuggingFace Datasets Authors.
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at
6
+ #
7
+ # http://www.apache.org/licenses/LICENSE-2.0
8
+ #
9
+ # Unless required by applicable law or agreed to in writing, software
10
+ # distributed under the License is distributed on an "AS IS" BASIS,
11
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ # See the License for the specific language governing permissions and
13
+ # limitations under the License.
14
+
15
+ # Lint as: python3
16
+ """Farsi News Datasets: Hamshahri and RadioFarda"""
17
+
18
+ from __future__ import absolute_import, division, print_function
19
+
20
+ import json
21
+
22
+ import datasets
23
+
24
+
25
+ _CITATION = """\
26
+ """
27
+
28
+ _DESCRIPTION = """\
29
+ Contains Farsi (Persian) datasets for Machine Learning tasks, particularly NLP.
30
+ These datasets have been extracted from the RSS feed of two Farsi news agency websites:
31
+
32
+ - Hamshahri
33
+ - RadioFarda
34
+ """
35
+
36
+ _URL = "https://raw.githubusercontent.com/sci2lab/Farsi-datasets/master/farsi_news/"
37
+ _URLS = {
38
+ "hamshahri": _URL + "hamshahri.json",
39
+ "radiofarda": _URL + "radiofarda.json",
40
+ }
41
+
42
+
43
+ class FarsiNews(datasets.GeneratorBasedBuilder):
44
+ """Farsi News Datasets: Hamshahri and RadioFarda"""
45
+
46
+ VERSION = datasets.Version("1.0.0")
47
+
48
+ def _info(self):
49
+ return datasets.DatasetInfo(
50
+ # This is the description that will appear on the datasets page.
51
+ description=_DESCRIPTION,
52
+ # datasets.features.FeatureConnectors
53
+ features=datasets.Features(
54
+ {
55
+ "title": datasets.Value("string"),
56
+ "summary": datasets.Value("string"),
57
+ "link": datasets.Value("string"),
58
+ "tags": datasets.features.Sequence(datasets.Value("string")),
59
+ }
60
+ ),
61
+ # If there's a common (input, target) tuple from the features,
62
+ # specify them here. They'll be used if as_supervised=True in
63
+ # builder.as_dataset.
64
+ supervised_keys=None,
65
+ # Homepage of the dataset for documentation
66
+ homepage="https://github.com/sci2lab/Farsi-datasets",
67
+ citation=_CITATION,
68
+ )
69
+
70
+ def _split_generators(self, dl_manager):
71
+ """Returns SplitGenerators."""
72
+ # dl_manager is a datasets.download.DownloadManager that can be used to
73
+ # download and extract URLs
74
+ urls_to_download = _URLS
75
+ dl_dir = dl_manager.download_and_extract(urls_to_download)
76
+ return [
77
+ datasets.SplitGenerator(
78
+ name="hamshahri",
79
+ # These kwargs will be passed to _generate_examples
80
+ gen_kwargs={"filepath": dl_dir["hamshahri"], "split": "hamshahri"},
81
+ ),
82
+ datasets.SplitGenerator(
83
+ name="radiofarda",
84
+ # These kwargs will be passed to _generate_examples
85
+ gen_kwargs={"filepath": dl_dir["radiofarda"], "split": "radiofarda"},
86
+ ),
87
+ ]
88
+
89
+ def _generate_examples(self, filepath, split):
90
+ """Yields examples."""
91
+ with open(filepath, encoding="utf-8") as f:
92
+ data = json.load(f)
93
+ for id_, example in enumerate(data):
94
+ yield id_, example