JanosAudran commited on
Commit
33f74eb
1 Parent(s): 605b488

Added files

Browse files
.gitattributes CHANGED
@@ -52,3 +52,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
52
  *.jpg filter=lfs diff=lfs merge=lfs -text
53
  *.jpeg filter=lfs diff=lfs merge=lfs -text
54
  *.webp filter=lfs diff=lfs merge=lfs -text
 
 
52
  *.jpg filter=lfs diff=lfs merge=lfs -text
53
  *.jpeg filter=lfs diff=lfs merge=lfs -text
54
  *.webp filter=lfs diff=lfs merge=lfs -text
55
+ *.jsonl filter=lfs diff=lfs merge=lfs -text
README.md CHANGED
@@ -1,3 +1,769 @@
1
  ---
2
- license: apache-2.0
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
+ annotations_creators:
3
+ - expert-generated
4
+ language:
5
+ - en
6
+ language_creators:
7
+ - expert-generated
8
+ license:
9
+ - apache-2.0
10
+ multilinguality:
11
+ - monolingual
12
+ pretty_name: US public firm Annual Reports (10-K)
13
+ size_categories:
14
+ - 10M<n<100M
15
+ source_datasets:
16
+ - extended|other
17
+ tags:
18
+ - "'finance"
19
+ - financial
20
+ - 10-K
21
+ - 10K
22
+ - 10k
23
+ - 10-k
24
+ - annual
25
+ - reports
26
+ - sec
27
+ - edgar
28
+ - sentiment
29
+ - firm
30
+ - public
31
+ - us'
32
+ task_categories:
33
+ - fill-mask
34
+ - text-classification
35
+ task_ids:
36
+ - masked-language-modeling
37
+ - multi-class-classification
38
+ - sentiment-classification
39
+ dataset_info:
40
+ - config_name: lite
41
+ features:
42
+ - name: cik
43
+ dtype: string
44
+ - name: sentence
45
+ dtype: string
46
+ - name: section
47
+ dtype:
48
+ class_label:
49
+ names:
50
+ "0": section_1
51
+ "1": section_10
52
+ "2": section_11
53
+ "3": section_12
54
+ "4": section_13
55
+ "5": section_14
56
+ "6": section_15
57
+ "7": section_1A
58
+ "8": section_1B
59
+ "9": section_2
60
+ "10": section_3
61
+ "11": section_4
62
+ "12": section_5
63
+ "13": section_6
64
+ "14": section_7
65
+ "15": section_7A
66
+ "16": section_8
67
+ "17": section_9
68
+ "18": section_9A
69
+ "19": section_9B
70
+ - name: labels
71
+ struct:
72
+ - name: 1d
73
+ dtype:
74
+ class_label:
75
+ names:
76
+ "0": positive
77
+ "1": negative
78
+ - name: 5d
79
+ dtype:
80
+ class_label:
81
+ names:
82
+ "0": positive
83
+ "1": negative
84
+ - name: 30d
85
+ dtype:
86
+ class_label:
87
+ names:
88
+ "0": positive
89
+ "1": negative
90
+ - name: filingDate
91
+ dtype: string
92
+ splits:
93
+ - name: train
94
+ num_bytes: 16424576472
95
+ num_examples: 67316227
96
+ - name: validation
97
+ num_bytes: 423527281
98
+ num_examples: 1585561
99
+ - name: test
100
+ num_bytes: 773116540
101
+ num_examples: 2965174
102
+ download_size: 13362319126
103
+ dataset_size: 17621220293
104
+ - config_name: full
105
+ features:
106
+ - name: cik
107
+ dtype: string
108
+ - name: sentence
109
+ dtype: string
110
+ - name: section
111
+ dtype:
112
+ class_label:
113
+ names:
114
+ "0": section_1
115
+ "1": section_10
116
+ "2": section_11
117
+ "3": section_12
118
+ "4": section_13
119
+ "5": section_14
120
+ "6": section_15
121
+ "7": section_1A
122
+ "8": section_1B
123
+ "9": section_2
124
+ "10": section_3
125
+ "11": section_4
126
+ "12": section_5
127
+ "13": section_6
128
+ "14": section_7
129
+ "15": section_7A
130
+ "16": section_8
131
+ "17": section_9
132
+ "18": section_9A
133
+ "19": section_9B
134
+ - name: labels
135
+ struct:
136
+ - name: 1d
137
+ dtype:
138
+ class_label:
139
+ names:
140
+ "0": positive
141
+ "1": negative
142
+ - name: 5d
143
+ dtype:
144
+ class_label:
145
+ names:
146
+ "0": positive
147
+ "1": negative
148
+ - name: 30d
149
+ dtype:
150
+ class_label:
151
+ names:
152
+ "0": positive
153
+ "1": negative
154
+ - name: filingDate
155
+ dtype: string
156
+ - name: name
157
+ dtype: string
158
+ - name: tickers
159
+ list: string
160
+ - name: exchanges
161
+ list: string
162
+ - name: entityType
163
+ dtype: string
164
+ - name: sic
165
+ dtype: string
166
+ - name: stateOfIncorporation
167
+ dtype: string
168
+ - name: tickerCount
169
+ dtype: int32
170
+ - name: acceptanceDateTime
171
+ dtype: string
172
+ - name: form
173
+ dtype: string
174
+ - name: reportDate
175
+ dtype: string
176
+ - name: returns
177
+ struct:
178
+ - name: 1d
179
+ struct:
180
+ - name: closePriceEndDate
181
+ dtype: float32
182
+ - name: closePriceStartDate
183
+ dtype: float32
184
+ - name: endDate
185
+ dtype: string
186
+ - name: startDate
187
+ dtype: string
188
+ - name: ret
189
+ dtype: float32
190
+ - name: 5d
191
+ struct:
192
+ - name: closePriceEndDate
193
+ dtype: float32
194
+ - name: closePriceStartDate
195
+ dtype: float32
196
+ - name: endDate
197
+ dtype: string
198
+ - name: startDate
199
+ dtype: string
200
+ - name: ret
201
+ dtype: float32
202
+ - name: 30d
203
+ struct:
204
+ - name: closePriceEndDate
205
+ dtype: float32
206
+ - name: closePriceStartDate
207
+ dtype: float32
208
+ - name: endDate
209
+ dtype: string
210
+ - name: startDate
211
+ dtype: string
212
+ - name: ret
213
+ dtype: float32
214
+ splits:
215
+ - name: train
216
+ num_bytes: 39306095718
217
+ num_examples: 67316227
218
+ - name: validation
219
+ num_bytes: 964030458
220
+ num_examples: 1585561
221
+ - name: test
222
+ num_bytes: 1785383996
223
+ num_examples: 2965174
224
+ download_size: 13362319126
225
+ dataset_size: 42055510172
226
+ - config_name: small_lite
227
+ features:
228
+ - name: cik
229
+ dtype: string
230
+ - name: sentence
231
+ dtype: string
232
+ - name: section
233
+ dtype:
234
+ class_label:
235
+ names:
236
+ "0": section_1
237
+ "1": section_10
238
+ "2": section_11
239
+ "3": section_12
240
+ "4": section_13
241
+ "5": section_14
242
+ "6": section_15
243
+ "7": section_1A
244
+ "8": section_1B
245
+ "9": section_2
246
+ "10": section_3
247
+ "11": section_4
248
+ "12": section_5
249
+ "13": section_6
250
+ "14": section_7
251
+ "15": section_7A
252
+ "16": section_8
253
+ "17": section_9
254
+ "18": section_9A
255
+ "19": section_9B
256
+ - name: labels
257
+ struct:
258
+ - name: 1d
259
+ dtype:
260
+ class_label:
261
+ names:
262
+ "0": positive
263
+ "1": negative
264
+ - name: 5d
265
+ dtype:
266
+ class_label:
267
+ names:
268
+ "0": positive
269
+ "1": negative
270
+ - name: 30d
271
+ dtype:
272
+ class_label:
273
+ names:
274
+ "0": positive
275
+ "1": negative
276
+ - name: filingDate
277
+ dtype: string
278
+ splits:
279
+ - name: train
280
+ num_bytes: 48766050
281
+ num_examples: 200000
282
+ - name: validation
283
+ num_bytes: 5581651
284
+ num_examples: 20000
285
+ - name: test
286
+ num_bytes: 5036956
287
+ num_examples: 20000
288
+ download_size: 13362319126
289
+ dataset_size: 59384657
290
+ - config_name: small_full
291
+ features:
292
+ - name: cik
293
+ dtype: string
294
+ - name: sentence
295
+ dtype: string
296
+ - name: section
297
+ dtype:
298
+ class_label:
299
+ names:
300
+ "0": section_1
301
+ "1": section_10
302
+ "2": section_11
303
+ "3": section_12
304
+ "4": section_13
305
+ "5": section_14
306
+ "6": section_15
307
+ "7": section_1A
308
+ "8": section_1B
309
+ "9": section_2
310
+ "10": section_3
311
+ "11": section_4
312
+ "12": section_5
313
+ "13": section_6
314
+ "14": section_7
315
+ "15": section_7A
316
+ "16": section_8
317
+ "17": section_9
318
+ "18": section_9A
319
+ "19": section_9B
320
+ - name: labels
321
+ struct:
322
+ - name: 1d
323
+ dtype:
324
+ class_label:
325
+ names:
326
+ "0": positive
327
+ "1": negative
328
+ - name: 5d
329
+ dtype:
330
+ class_label:
331
+ names:
332
+ "0": positive
333
+ "1": negative
334
+ - name: 30d
335
+ dtype:
336
+ class_label:
337
+ names:
338
+ "0": positive
339
+ "1": negative
340
+ - name: filingDate
341
+ dtype: string
342
+ - name: name
343
+ dtype: string
344
+ - name: tickers
345
+ list: string
346
+ - name: exchanges
347
+ list: string
348
+ - name: entityType
349
+ dtype: string
350
+ - name: sic
351
+ dtype: string
352
+ - name: stateOfIncorporation
353
+ dtype: string
354
+ - name: tickerCount
355
+ dtype: int32
356
+ - name: acceptanceDateTime
357
+ dtype: string
358
+ - name: form
359
+ dtype: string
360
+ - name: reportDate
361
+ dtype: string
362
+ - name: returns
363
+ struct:
364
+ - name: 1d
365
+ struct:
366
+ - name: closePriceEndDate
367
+ dtype: float32
368
+ - name: closePriceStartDate
369
+ dtype: float32
370
+ - name: endDate
371
+ dtype: string
372
+ - name: startDate
373
+ dtype: string
374
+ - name: ret
375
+ dtype: float32
376
+ - name: 5d
377
+ struct:
378
+ - name: closePriceEndDate
379
+ dtype: float32
380
+ - name: closePriceStartDate
381
+ dtype: float32
382
+ - name: endDate
383
+ dtype: string
384
+ - name: startDate
385
+ dtype: string
386
+ - name: ret
387
+ dtype: float32
388
+ - name: 30d
389
+ struct:
390
+ - name: closePriceEndDate
391
+ dtype: float32
392
+ - name: closePriceStartDate
393
+ dtype: float32
394
+ - name: endDate
395
+ dtype: string
396
+ - name: startDate
397
+ dtype: string
398
+ - name: ret
399
+ dtype: float32
400
+ splits:
401
+ - name: train
402
+ num_bytes: 116038677
403
+ num_examples: 200000
404
+ - name: validation
405
+ num_bytes: 12380261
406
+ num_examples: 20000
407
+ - name: test
408
+ num_bytes: 11898871
409
+ num_examples: 20000
410
+ download_size: 13362319126
411
+ dataset_size: 140317809
412
  ---
413
+
414
+ # Dataset Card for [financial-reports-sec]
415
+
416
+ ## Table of Contents
417
+
418
+ - [Table of Contents](#table-of-contents)
419
+ - [Dataset Description](#dataset-description)
420
+ - [Dataset Summary](#dataset-summary)
421
+ - [Dataset Configurations](#dataset-configurations)
422
+ - [Usage](#usage)
423
+ - [Supported Tasks](#supported-tasks)
424
+ - [Languages](#languages)
425
+ - [Dataset Structure](#dataset-structure)
426
+ - [Data Instances](#data-instances)
427
+ - [Data Fields](#data-fields)
428
+ - [Data Splits](#data-splits)
429
+ - [Dataset Summary Statistics](#dataset-summary-statistics)
430
+ - [Dataset Creation](#dataset-creation)
431
+ - [Curation Rationale](#curation-rationale)
432
+ - [Source Data](#source-data)
433
+ - [Annotations](#annotations)
434
+ - [Personal and Sensitive Information](#personal-and-sensitive-information)
435
+ - [Considerations for Using the Data](#considerations-for-using-the-data)
436
+ - [Social Impact of Dataset](#social-impact-of-dataset)
437
+ - [Discussion of Biases](#discussion-of-biases)
438
+ - [Other Known Limitations](#other-known-limitations)
439
+ - [Additional Information](#additional-information)
440
+ - [Dataset Curators](#dataset-curators)
441
+ - [Licensing Information](#licensing-information)
442
+ - [References](#references)
443
+ - [Citation Information](#citation-information)
444
+
445
+ ## Dataset Description
446
+
447
+ - **Point of Contact: Aman Khan**
448
+
449
+ ### Dataset Summary
450
+
451
+ The dataset contains the annual report of US public firms filing with the SEC EDGAR system from 1993-2020. Each annual report (**10K filing**) is broken into 20 sections. Each section is split into individual sentences. Sentiment labels are provided on a **per filing basis** from the market reaction around the filing date for 3 different time windows _[t-1, t+1]_, _[t-1, t+5]_ and _[t-1, t+30]_. Additional metadata for each filing is included in the dataset.
452
+
453
+ ### Dataset Configurations
454
+
455
+ **Four** configurations are available:
456
+
457
+ - _**lite**_:
458
+ - Contains only the basic features needed. Extra metadata is ommitted.
459
+ - Features List:
460
+ - **cik**
461
+ - **sentence**
462
+ - **section**
463
+ - **labels**
464
+ - **filingDate**
465
+ - _**full**_:
466
+ - All features are included.
467
+ - Features List (excluding those already in the lite verison above):
468
+ - **name**
469
+ - **tickers**
470
+ - **exchanges**
471
+ - **entityType**
472
+ - **sic**
473
+ - **stateOfIncorporation**
474
+ - **tickerCount**
475
+ - **acceptanceDateTime**
476
+ - **form**
477
+ - **reportDate**
478
+ - **returns**
479
+ - _**small_lite**_:
480
+ - Same as _**lite**_ version except that only (200,000/20,000/20,000) sentences are loaded for (train/test/validation) splits.
481
+ - _**small_full**_:
482
+ - Same as _**full**_ version except that only (200,000/20,000/20,000) sentences are loaded for (train/test/validation) splits.
483
+
484
+ ### Usage
485
+
486
+ ```python
487
+ import datasets
488
+
489
+ # Load the lite configuration of the dataset
490
+ raw_dataset = datasets.load_dataset("JanosAudran/financial-reports-sec", "lite")
491
+
492
+ # Load a specific split
493
+ raw_dataset = datasets.load_dataset("JanosAudran/financial-reports-sec", "full", split="train")
494
+ ```
495
+
496
+ ### Supported Tasks
497
+
498
+ The tasks the dataset can be used directly for includes:
499
+
500
+ - _Masked Language Modelling_
501
+ - A model like BERT can be fine-tuned on this corpus of financial text.
502
+ - _Sentiment Analysis_
503
+ - For each annual report a label ["positive", "negative"] is provided based on the market reaction around the filing date (refer to [Annotations](#annotations)).
504
+ - _Next Sentence Prediction/Sentence Order Prediction_
505
+ - Sentences extracted from the filings are in their original order and as such the dataset can be adapted very easily for either of these tasks.
506
+
507
+ ### Languages
508
+
509
+ All sentences are in English.
510
+
511
+ ## Dataset Structure
512
+
513
+ ### Data Instances
514
+
515
+ Refer to dataset preview.
516
+
517
+ ### Data Fields
518
+
519
+ **Feature Name**
520
+
521
+ - Description
522
+ - Data type
523
+ - Example/Structure
524
+
525
+ **cik**
526
+
527
+ - 10 digit identifier used by SEC for a firm.
528
+ - _string_
529
+ - '0000001750'
530
+
531
+ **sentence**
532
+
533
+ - A single sentence from the 10-K filing.
534
+ - _string_
535
+ - 'The finance agreement is secured by a first priority security interest in all insurance policies, all unearned premium, return premiums, dividend payments and loss payments thereof.'
536
+
537
+ **section**
538
+
539
+ - The section of the 10-K filing the sentence is located.
540
+ - _ClassLabel_
541
+ - ```python
542
+ ClassLabel(names=['section_1', 'section_10', 'section_11', 'section_12', 'section_13', 'section_14', 'section_15', 'section_1A', 'section_1B', 'section_2','section_3', 'section_4', 'section_5', 'section_6', 'section_7', 'section_7A','section_8', 'section_9', 'section_9A', 'section_9B'], id=None)
543
+ ```
544
+
545
+ **labels**
546
+
547
+ - The sentiment label for the entire filing (_**positve**_ or _**negative**_) based on different time windows.
548
+ - _Dict of ClassLables_
549
+ - ```python
550
+ {
551
+ '1d': ClassLabel(names=['positive', 'negative'], id=None),
552
+ '5d': ClassLabel(names=['positive', 'negative'], id=None),
553
+ '30d': ClassLabel(names=['positive', 'negative'], id=None)
554
+ }
555
+ ```
556
+
557
+ **filingDate**
558
+
559
+ - The date the 10-K report was filed with the SEC.
560
+ - _string_
561
+ - '2021-03-10'
562
+
563
+ **name**
564
+
565
+ - The name of the filing entity
566
+ - _string_
567
+ - 'Investar Holding Corp'
568
+
569
+ **tickers**
570
+
571
+ - List of ticker symbols for the filing entity.
572
+ - _List of strings_
573
+ - ['ISTR']
574
+
575
+ **exchanges**
576
+
577
+ - List of exchanges for the filing entity.
578
+ - _List of strings_
579
+ - ['Nasdaq']
580
+
581
+ **entityType**
582
+
583
+ - The type of entity as identified in the 10-K filing.
584
+ - _string_
585
+ - 'operating'
586
+
587
+ **sic**
588
+
589
+ - Four digit SIC code for the filing entity.
590
+ - _string_
591
+ - '6022'
592
+
593
+ **stateOfIncorporation**
594
+
595
+ - Two character code for the state of incorporation for the filing entity.
596
+ - _string_
597
+ - 'LA'
598
+
599
+ **tickerCount**
600
+
601
+ - _**Internal use**_. Count of ticker symbols. Always 1.
602
+ - _int_
603
+ - 1
604
+
605
+ **acceptanceDateTime**
606
+
607
+ - The full timestamp of when the filing was accepted into the SEC EDGAR system.
608
+ - _string_
609
+ - '2021-03-10T14:26:11.000Z'
610
+
611
+ **form**
612
+
613
+ - The type of filing. Always 10-K in the dataset.
614
+ - _string_
615
+ - '10-K'
616
+
617
+ **reportDate**
618
+
619
+ - The last date in the fiscal year for which the entity is filing the report.
620
+ - _string_
621
+ - '2020-12-31'
622
+
623
+ **returns**
624
+
625
+ - _**Internal use**_. The prices and timestamps used to calculate the sentiment labels.
626
+ - _Dict_
627
+ - ```python
628
+ {'1d': {
629
+ 'closePriceEndDate': 21.45746421813965,
630
+ 'closePriceStartDate': 20.64960479736328,
631
+ 'endDate': '2021-03-11T00:00:00-05:00',
632
+ 'startDate': '2021-03-09T00:00:00-05:00',
633
+ 'ret': 0.03912226855754852
634
+ },
635
+ '5d': {
636
+ 'closePriceEndDate': 21.743167877197266,
637
+ 'closePriceStartDate': 20.64960479736328,
638
+ 'endDate': '2021-03-15T00:00:00-04:00',
639
+ 'startDate': '2021-03-09T00:00:00-05:00',
640
+ 'ret': 0.052958063781261444
641
+ },
642
+ '30d': {
643
+ 'closePriceEndDate': 20.63919448852539,
644
+ 'closePriceStartDate': 20.64960479736328,
645
+ 'endDate': '2021-04-09T00:00:00-04:00',
646
+ 'startDate': '2021-03-09T00:00:00-05:00',
647
+ 'ret': -0.0005041408003307879}}
648
+ ```
649
+
650
+ ### Data Splits
651
+
652
+ | Config | train | validation | test |
653
+ | ---------- | ---------: | ---------: | --------: |
654
+ | full | 67,316,227 | 1,585,561 | 2,965,174 |
655
+ | lite | 67,316,227 | 1,585,561 | 2,965,174 |
656
+ | small_full | 200,000 | 20,000 | 20,000 |
657
+ | small_lite | 200,000 | 20,000 | 20,000 |
658
+
659
+ ### Dataset Summary Statistics
660
+
661
+ | Variable | count | mean | std | min | 1% | 25% | 50% | 75% | 99% | max |
662
+ | :-------------------------------- | ---------: | ----: | -----: | -----: | -----: | -----: | ----: | ----: | ----: | --------: |
663
+ | Unique Firm Count | 4,677 | | | | | | | | | |
664
+ | Filings Count | 55,349 | | | | | | | | | |
665
+ | Sentence Count | 71,866,962 | | | | | | | | | |
666
+ | Filings per Firm | 4,677 | 12 | 9 | 1 | 1 | 4 | 11 | 19 | 27 | 28 |
667
+ | Return per Filing - 1d | 55,349 | 0.008 | 0.394 | -0.973 | -0.253 | -0.023 | 0 | 0.02 | 0.367 | 77.977 |
668
+ | Return per Filing - 5d | 55,349 | 0.013 | 0.584 | -0.99 | -0.333 | -0.034 | 0 | 0.031 | 0.5 | 100 |
669
+ | Return per Filing - 30d | 55,349 | 0.191 | 22.924 | -0.999 | -0.548 | -0.068 | 0.001 | 0.074 | 1 | 5,002.748 |
670
+ | Sentences per Filing | 55,349 | 1,299 | 654 | 0 | 110 | 839 | 1,268 | 1,681 | 3,135 | 8,286 |
671
+ | Sentences by Section - section_1 | 55,349 | 221 | 183 | 0 | 0 | 97 | 180 | 293 | 852 | 2,724 |
672
+ | Sentences by Section - section_10 | 55,349 | 24 | 40 | 0 | 0 | 4 | 6 | 20 | 173 | 1,594 |
673
+ | Sentences by Section - section_11 | 55,349 | 16 | 47 | 0 | 0 | 3 | 3 | 4 | 243 | 808 |
674
+ | Sentences by Section - section_12 | 55,349 | 9 | 14 | 0 | 0 | 3 | 4 | 8 | 56 | 1,287 |
675
+ | Sentences by Section - section_13 | 55,349 | 8 | 20 | 0 | 0 | 3 | 3 | 4 | 79 | 837 |
676
+ | Sentences by Section - section_14 | 55,349 | 22 | 93 | 0 | 0 | 3 | 3 | 8 | 413 | 3,536 |
677
+ | Sentences by Section - section_15 | 55,349 | 177 | 267 | 0 | 0 | 9 | 26 | 315 | 1104 | 4,140 |
678
+ | Sentences by Section - section_1A | 55,349 | 197 | 204 | 0 | 0 | 3 | 158 | 292 | 885 | 2,106 |
679
+ | Sentences by Section - section_1B | 55,349 | 4 | 31 | 0 | 0 | 1 | 3 | 3 | 13 | 2,414 |
680
+ | Sentences by Section - section_2 | 55,349 | 16 | 45 | 0 | 0 | 6 | 8 | 13 | 169 | 1,903 |
681
+ | Sentences by Section - section_3 | 55,349 | 14 | 36 | 0 | 0 | 4 | 5 | 12 | 121 | 2,326 |
682
+ | Sentences by Section - section_4 | 55,349 | 7 | 17 | 0 | 0 | 3 | 3 | 4 | 66 | 991 |
683
+ | Sentences by Section - section_5 | 55,349 | 20 | 41 | 0 | 0 | 10 | 15 | 21 | 87 | 3,816 |
684
+ | Sentences by Section - section_6 | 55,349 | 8 | 29 | 0 | 0 | 3 | 4 | 7 | 43 | 2,156 |
685
+ | Sentences by Section - section_7 | 55,349 | 265 | 198 | 0 | 0 | 121 | 246 | 373 | 856 | 4,539 |
686
+ | Sentences by Section - section_7A | 55,349 | 18 | 52 | 0 | 0 | 3 | 9 | 21 | 102 | 3,596 |
687
+ | Sentences by Section - section_8 | 55,349 | 257 | 296 | 0 | 0 | 3 | 182 | 454 | 1105 | 4,431 |
688
+ | Sentences by Section - section_9 | 55,349 | 5 | 33 | 0 | 0 | 3 | 3 | 4 | 18 | 2,330 |
689
+ | Sentences by Section - section_9A | 55,349 | 17 | 16 | 0 | 0 | 8 | 15 | 23 | 50 | 794 |
690
+ | Sentences by Section - section_9B | 55,349 | 4 | 18 | 0 | 0 | 2 | 3 | 4 | 23 | 813 |
691
+ | Word count per Sentence | 71,866,962 | 28 | 22 | 1 | 2 | 16 | 24 | 34 | 98 | 8,675 |
692
+
693
+ ## Dataset Creation
694
+
695
+ ### Curation Rationale
696
+
697
+ To create this dataset multiple sources of information have to be cleaned and processed for data merging. Starting from the raw filings:
698
+
699
+ - Useful metadata about the filing and firm was added.
700
+ - Time windows around the filing date were carefully created.
701
+ - Stock price data was then added for the windows.
702
+ - Ambiguous/duplicate records were removed.
703
+
704
+ ### Source Data
705
+
706
+ #### Initial Data Collection and Normalization
707
+
708
+ Initial data was collected and processed by the authors of the research paper [**EDGAR-CORPUS: Billions of Tokens Make The World Go Round**](#references). Market price and returns data was collected from Yahoo Finance. Additional metadata was collected from SEC.
709
+
710
+ #### Who are the source language producers?
711
+
712
+ US public firms filing with the SEC.
713
+
714
+ ### Annotations
715
+
716
+ #### Annotation process
717
+
718
+ Labels for sentiment classification are based on buy-and-hold returns over a fixed time window around the filing date with the SEC i.e. when the data becomes public. Returns are chosen for this process as it reflects the combined market intelligence at parsing the new information in the filings. For each filing date **t** the stock price at **t-1** and **t+W** is used to calculate returns. If, the returns are positive a label of **positive** is assigned else a label of **negative** is assigned. Three different windows are used to assign the labels:
719
+
720
+ - **1d**: _[t-1, t+1]_
721
+ - **5d**: _[t-1, t+5]_
722
+ - **30d**: _[t-1, t+30]_
723
+
724
+ The windows are based on calendar days and are adjusted for weekends and holidays. The rationale behind using 3 windows is as follows:
725
+
726
+ - A very short window may not give enough time for all the information contained in the filing to be reflected in the stock price.
727
+ - A very long window may capture other events that drive stock price for the firm.
728
+
729
+ #### Who are the annotators?
730
+
731
+ Financial market participants.
732
+
733
+ ### Personal and Sensitive Information
734
+
735
+ The dataset contains public filings data from SEC. Market returns data was collected from Yahoo Finance.
736
+
737
+ ## Considerations for Using the Data
738
+
739
+ ### Social Impact of Dataset
740
+
741
+ Low to none.
742
+
743
+ ### Discussion of Biases
744
+
745
+ The dataset is about financial information of public companies and as such the tone and style of text is in line with financial literature.
746
+
747
+ ### Other Known Limitations
748
+
749
+ NA
750
+
751
+ ## Additional Information
752
+
753
+ ### Dataset Curators
754
+
755
+ **Aman Khan**
756
+
757
+ ### Licensing Information
758
+
759
+ This dataset is provided under Apache 2.0.
760
+
761
+ ### References
762
+
763
+ - Lefteris Loukas, Manos Fergadiotis, Ion Androutsopoulos, & Prodromos Malakasiotis. (2021). EDGAR-CORPUS [Data set]. Zenodo. https://doi.org/10.5281/zenodo.5589195
764
+
765
+ ### Citation Information
766
+
767
+ Please use the following to cite this dataset:
768
+
769
+ - Aman Khan, _**financial-reports-sec**_, https://huggingface.co/datasets/JanosAudran/financial-reports-sec
data/test/shard_0.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:5d8899cb9468c5735324c220d3b7b09d5a2161129bb3647d576c4c30aa7b0044
3
+ size 64539746
data/test/shard_1.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:95006316030a5e066ddd78999157d6b06189ebfa2456a2af44265c94a64ea9be
3
+ size 57674513
data/test/shard_2.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:870dbf9bc8997167101a3b457bf09fe23b4ed6301617a2b740e532e43df24214
3
+ size 52337171
data/test/shard_3.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:3fca7933a8535ed657f28d4047abe3efe37f95da52b35dbddccbe3b8a720bd85
3
+ size 62355122
data/test/shard_4.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:2a8df2e023576930ebdcbb3196d508a2b9f28f4ff81dff7197a5f580914c157b
3
+ size 51273739
data/test/shard_5.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9105f1e85acad1e610e65d035f919972aa6c8cc803b61f31addd1558317b3bc6
3
+ size 64330866
data/test/shard_6.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:4a6ca78cf7a7a4436780be60df62525d06028c68e335fc285b21e8ee70d9d5a3
3
+ size 61733984
data/test/shard_7.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:ad40a88eebacb367da56cd551ab2d6812304ea32cb203f187748734125157165
3
+ size 62311170
data/test/shard_8.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:22ab94c2fb26de029df59b6dae50572240336cea4b7ac863bccc02bd0ed237ed
3
+ size 65551221
data/test/shard_9.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:887790c707bc598677531214eb95c1c442177ea6b8231a09a98e7a6c65751f1a
3
+ size 55160397
data/train/shard_0.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:3048c49fb91161ec81e1a99af0413a7cf9ee023f8ccf2e3a9dcd09bd1e0de9a2
3
+ size 1204251749
data/train/shard_1.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:1369d4acd90bbdc55bc28d35ed3be196834e1cb06f385049c0159db4923a4abb
3
+ size 1203396935
data/train/shard_2.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:29e2488d05a8d3907d3230cb7722ba1a9b7f8c1fdaa0f3d37198df5962398134
3
+ size 1209761048
data/train/shard_3.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:ef9b4ca52cfcc469656cf6502b5468a7b182930c13a4392be4726eb7b1e7b470
3
+ size 1206577691
data/train/shard_4.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e8119d5d029b07bb2e505f5b09350fb7aeab99e69b248532f39c783d4a2f80ed
3
+ size 1239703991
data/train/shard_5.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e5b1cf56098d44ce6bc536ae48400745490098e608d9ee8fcc9567dd978b2117
3
+ size 1363504839
data/train/shard_6.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:0d5b9c9f85116528cbd3d666e7e21e0307dd1f98bede5c0f2c021d4e0b0043ce
3
+ size 1214415693
data/train/shard_7.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:890fa73335a5a0969de6400431ddb2dbbdf493d7ce2dcf58a8d60d792a287f33
3
+ size 1245340015
data/train/shard_8.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:3bce647ce4a05b543e053d0f245852e0aedf6bf65c3462d16939b9b6d4ce5300
3
+ size 1283636791
data/train/shard_9.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9c94469bf008640b9ae8656dc0b8b3f64df69621fcaaf1ef3134b49d7b614742
3
+ size 1264987344
data/validate/shard_0.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:ce879211e916760cba76f74bb4de2ed31388fa14097764b9ce34a7b1599fe1f4
3
+ size 33800838
data/validate/shard_1.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:b90857513dda3685e7e9507dc5442a710f90d1d59aa0ca5c26cd7b9cdc76e615
3
+ size 34550313
data/validate/shard_2.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:89251fe5cff248c69614de91d061e38bd599cb660ac1212156d8258e087fa295
3
+ size 36190230
data/validate/shard_3.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:6331df1cc7c00109341d5b6adee24f4477302d10f81bde67d2e059ab0747c04d
3
+ size 34117152
data/validate/shard_4.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:95b1a55dda317372cfc0a50e9f870b958dc8189eda096e4af2b6b5118feaa9b3
3
+ size 29154413
data/validate/shard_5.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:a1bbe2dfa8b7ef577c71328fdc585fe6b74f327f5902e549f5f33b7579a137fe
3
+ size 31900190
data/validate/shard_6.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:16693757380b0290338c63e045eed1d77945717433490e937eea2ed6d1050dda
3
+ size 31525226
data/validate/shard_7.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:ff71a54b4017199c200b8aa4200b35c1a69d0bc5b79dd460b0c67c7d3fe25520
3
+ size 37039729
data/validate/shard_8.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:22c81933e3eb31db389a50819c2142ffb9f469603b9deab0d29952ed9404ad7d
3
+ size 32049746
data/validate/shard_9.jsonl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:b2f0258106bdc8da29e678435387df87e4527e0471c8d794f737e9b67bffa67f
3
+ size 29147264
financial-reports-sec.py ADDED
@@ -0,0 +1,190 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright 2023 The HuggingFace Datasets Authors and the current dataset script contributor.
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
+ import json
16
+
17
+ import datasets
18
+
19
+ _DESCRIPTION = """\
20
+ The dataset contains the annual report of US public firms filing with the SEC EDGAR system.
21
+ Each annual report (10K filing) is broken into 20 sections. Each section is split into individual sentences.
22
+ Sentiment labels are provided on a per filing basis from the market reaction around the filing data.
23
+ Additional metadata for each filing is included in the dataset.
24
+ """
25
+
26
+ _LICENSE = "apache-2.0"
27
+
28
+ _NOS_SHARDS = 10
29
+
30
+ _SMALL_THRESHOLD_TRAIN = 200_000
31
+
32
+ _SMALL_THRESHOLD_OTHERS = 20_000
33
+
34
+ _URLS = {item: ["data/"+item+"/shard_"+str(shard)+".jsonl" for shard in range(_NOS_SHARDS)] for item in ['test', 'train', 'validate']}
35
+
36
+ _ALL_FEATURES = {
37
+ "cik": datasets.Value("string"),
38
+ "sentence": datasets.Value("string"),
39
+ "section": datasets.ClassLabel(num_classes=20,
40
+ names=['section_1', 'section_10',
41
+ 'section_11', 'section_12',
42
+ 'section_13', 'section_14',
43
+ 'section_15', 'section_1A',
44
+ 'section_1B', 'section_2',
45
+ 'section_3', 'section_4',
46
+ 'section_5', 'section_6',
47
+ 'section_7', 'section_7A',
48
+ 'section_8', 'section_9',
49
+ 'section_9A', 'section_9B']),
50
+ "labels": {
51
+ "1d": datasets.ClassLabel(num_classes=2, names=["positive", "negative"]),
52
+ "5d": datasets.ClassLabel(num_classes=2, names=["positive", "negative"]),
53
+ "30d": datasets.ClassLabel(num_classes=2, names=["positive", "negative"]),
54
+ },
55
+ "filingDate": datasets.Value("string"),
56
+ "name": datasets.Value("string"),
57
+ "tickers": [datasets.Value("string")],
58
+ "exchanges": [datasets.Value("string")],
59
+ "entityType": datasets.Value("string"),
60
+ "sic": datasets.Value("string"),
61
+ "stateOfIncorporation": datasets.Value("string"),
62
+ "tickerCount": datasets.Value("int32"),
63
+ "acceptanceDateTime": datasets.Value("string"),
64
+ "form": datasets.Value("string"),
65
+ "reportDate": datasets.Value("string"),
66
+ "returns": {
67
+ "1d": {
68
+ "closePriceEndDate": datasets.Value("float32"),
69
+ "closePriceStartDate": datasets.Value("float32"),
70
+ "endDate": datasets.Value("string"),
71
+ "startDate": datasets.Value("string"),
72
+ "ret": datasets.Value("float32"),
73
+ },
74
+ "5d": {
75
+ "closePriceEndDate": datasets.Value("float32"),
76
+ "closePriceStartDate": datasets.Value("float32"),
77
+ "endDate": datasets.Value("string"),
78
+ "startDate": datasets.Value("string"),
79
+ "ret": datasets.Value("float32"),
80
+ },
81
+ "30d": {
82
+ "closePriceEndDate": datasets.Value("float32"),
83
+ "closePriceStartDate": datasets.Value("float32"),
84
+ "endDate": datasets.Value("string"),
85
+ "startDate": datasets.Value("string"),
86
+ "ret": datasets.Value("float32"),
87
+ }
88
+ },
89
+ }
90
+
91
+
92
+ class FinancialReportsSec(datasets.GeneratorBasedBuilder):
93
+
94
+ VERSION = datasets.Version("1.1.0")
95
+
96
+ BUILDER_CONFIGS = [
97
+ datasets.BuilderConfig(name="lite", version=VERSION, description="This returns the dataset with only the critical data needed for analysis."),
98
+ datasets.BuilderConfig(name="full", version=VERSION, description="This returns the dataset with all metadata included."),
99
+ datasets.BuilderConfig(name="small_lite", version=VERSION, description="This returns a smaller version of the dataset with only the critical data needed for analysis."),
100
+ datasets.BuilderConfig(name="small_full", version=VERSION, description="This returns a smaller version of the dataset with all metadata included."),
101
+ ]
102
+
103
+ def _info(self):
104
+
105
+ lite_features = datasets.Features({k: v for k, v in _ALL_FEATURES.items() if k in ["cik", "sentence", "section", "labels", "filingDate"]})
106
+ full_features = datasets.Features(_ALL_FEATURES)
107
+
108
+ features = full_features if self.config.name == "full" or self.config.name == 'small_full' else lite_features
109
+ return datasets.DatasetInfo(
110
+ # This is the description that will appear on the datasets page.
111
+ description=_DESCRIPTION,
112
+ # This defines the different columns of the dataset and their types
113
+ features=features,
114
+ # License for the dataset if available
115
+ license=_LICENSE,
116
+ )
117
+
118
+ def _split_generators(self, dl_manager):
119
+ urls = _URLS
120
+ data_dir = dl_manager.download_and_extract(urls)
121
+ return [
122
+ datasets.SplitGenerator(
123
+ name=datasets.Split.TRAIN,
124
+ # These kwargs will be passed to _generate_examples
125
+ gen_kwargs={
126
+ "filepaths": data_dir["train"],
127
+ "split": "train",
128
+ },
129
+ ),
130
+ datasets.SplitGenerator(
131
+ name=datasets.Split.VALIDATION,
132
+ # These kwargs will be passed to _generate_examples
133
+ gen_kwargs={
134
+ "filepaths": data_dir["validate"],
135
+ "split": "validate",
136
+ },
137
+ ),
138
+ datasets.SplitGenerator(
139
+ name=datasets.Split.TEST,
140
+ # These kwargs will be passed to _generate_examples
141
+ gen_kwargs={
142
+ "filepaths": data_dir["test"],
143
+ "split": "test"
144
+ },
145
+ ),
146
+ ]
147
+
148
+ # method parameters are unpacked from `gen_kwargs` as given in `_split_generators`
149
+ def _generate_examples(self, filepaths, split):
150
+ reads = 0
151
+ threshold = _SMALL_THRESHOLD_TRAIN if split == 'train' else _SMALL_THRESHOLD_OTHERS
152
+ for filepath in filepaths:
153
+ with open(filepath, encoding="utf-8") as f:
154
+ for firmIdx, row in enumerate(f):
155
+ data = json.loads(row)
156
+ for filing in data["filings"]:
157
+ for sec_id, section in filing["report"].items():
158
+ for idx, sentence in enumerate(section):
159
+ reads += 1
160
+ if self.config.name == 'small_full' or self.config.name == 'small_lite':
161
+ if reads > threshold:
162
+ return None
163
+ key = data["cik"]+'_'+filing["form"]+'_'+filing["reportDate"].split('-')[0]+'_'+sec_id+'_'+str(idx)
164
+ if self.config.name == "lite" or self.config.name == 'small_lite':
165
+ yield key, {
166
+ "cik": data["cik"],
167
+ "sentence": sentence,
168
+ "section": sec_id,
169
+ "labels": filing["labels"],
170
+ "filingDate": filing["filingDate"],
171
+ }
172
+ else:
173
+ yield key, {
174
+ "cik": data["cik"],
175
+ "sentence": sentence,
176
+ "section": sec_id,
177
+ "labels": filing["labels"],
178
+ "filingDate": filing["filingDate"],
179
+ "name": data["name"],
180
+ "tickers": data["tickers"],
181
+ "exchanges": data["exchanges"],
182
+ "entityType": data["entityType"],
183
+ "sic": data["sic"],
184
+ "stateOfIncorporation": data["stateOfIncorporation"],
185
+ "tickerCount": data["tickerCount"],
186
+ "acceptanceDateTime": filing["acceptanceDateTime"],
187
+ "form": filing["form"],
188
+ "reportDate": filing["reportDate"],
189
+ "returns": filing["returns"],
190
+ }