aman-17 commited on
Commit
23e9417
1 Parent(s): 2b7986d
Files changed (3) hide show
  1. Fin-Fact.py +1 -0
  2. README.md +154 -7
  3. finfact.json +2 -2
Fin-Fact.py CHANGED
@@ -223,3 +223,4 @@ class PubmedQA(datasets.GeneratorBasedBuilder):
223
  "author": row["author"],
224
  "posted": row["posted"],
225
  }
 
 
223
  "author": row["author"],
224
  "posted": row["posted"],
225
  }
226
+
README.md CHANGED
@@ -1,11 +1,158 @@
1
  ---
2
- license: mit
3
  task_categories:
4
- - text-classification
5
- - summarization
6
- - text-generation
7
  language:
8
- - en
 
 
 
9
  size_categories:
10
- - 1K<n<10K
11
- ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
+ license: apache-2.0
3
  task_categories:
4
+ - text-classification
5
+ - text-generation
 
6
  language:
7
+ - en
8
+ tags:
9
+ - finance
10
+ pretty_name: FinFact
11
  size_categories:
12
+ - 1K<n<10K
13
+ dataset_info:
14
+ - config_name: generation
15
+ features:
16
+ - name: url
17
+ dtype: string
18
+ - name: claim
19
+ dtype: string
20
+ - name: author
21
+ dtype: string
22
+ - name: posted
23
+ dtype: string
24
+ # - name: sci_digest
25
+ # sequence: string
26
+ # - name: justification
27
+ # sequence: string
28
+ # - name: issues
29
+ # dtype: string
30
+ # - name: image_data
31
+ # sequence:
32
+ # - name: image_src
33
+ # dtype: string
34
+ # - name: image_caption
35
+ # dtype: string
36
+ # - name: evidence
37
+ # sequence:
38
+ # - name: sentence
39
+ # dtype: string
40
+ # - name: hrefs
41
+ # dtype: string
42
+ # - name: label
43
+ # dtype: string
44
+ # - name: visualization_bias
45
+ # dtype: int32
46
+
47
+ ---
48
+
49
+ <h1 align="center">Fin-Fact - Financial Fact-Checking Dataset</h1>
50
+
51
+
52
+ ## Table of Contents
53
+
54
+ - [Overview](#overview)
55
+ - [Dataset Description](#dataset-description)
56
+ - [Dataset Usage](#dataset-usage)
57
+ - [Leaderboard](#leaderboard)
58
+ - [Dependencies](#dependencies)
59
+ - [Run models for paper metrics](#run-models-for-paper-metrics)
60
+ - [Citation](#citation)
61
+ - [Contribution](#contribution)
62
+ - [License](#license)
63
+ - [Contact](#contact)
64
+
65
+ ## Overview
66
+
67
+ Welcome to the Fin-Fact repository! Fin-Fact is a comprehensive dataset designed specifically for financial fact-checking and explanation generation. This README provides an overview of the dataset, how to use it, and other relevant information. [Click here](https://arxiv.org/abs/2309.08793) to access the paper.
68
+
69
+ ## Dataset Description
70
+
71
+ - **Name**: Fin-Fact
72
+ - **Purpose**: Fact-checking and explanation generation in the financial domain.
73
+ - **Labels**: The dataset includes various labels, including Claim, Author, Posted Date, Sci-digest, Justification, Evidence, Evidence href, Image href, Image Caption, Visualisation Bias Label, Issues, and Claim Label.
74
+ - **Size**: The dataset consists of 3121 claims spanning multiple financial sectors.
75
+ - **Additional Features**: The dataset goes beyond textual claims and incorporates visual elements, including images and their captions.
76
+
77
+ ## Dataset Usage
78
+
79
+ Fin-Fact is a valuable resource for researchers, data scientists, and fact-checkers in the financial domain. Here's how you can use it:
80
+
81
+ 1. **Download the Dataset**: You can download the Fin-Fact dataset [here](https://github.com/IIT-DM/Fin-Fact/blob/FinFact/finfact.json).
82
+
83
+ 2. **Exploratory Data Analysis**: Perform exploratory data analysis to understand the dataset's structure, distribution, and any potential biases.
84
+
85
+ 3. **Natural Language Processing (NLP) Tasks**: Utilize the dataset for various NLP tasks such as fact-checking, claim verification, and explanation generation.
86
+
87
+ 4. **Fact Checking Experiments**: Train and evaluate machine learning models, including text and image analysis, using the dataset to enhance the accuracy of fact-checking systems.
88
+
89
+ ## Leaderboard
90
+
91
+ ## Dependencies
92
+ We recommend you create an anaconda environment:
93
+
94
+ `conda create --name finfact python=3.6 conda-build`
95
+
96
+ Then, install Python requirements:
97
+
98
+ `pip install -r requirements.txt`
99
+
100
+
101
+ ## Run models for paper metrics
102
+
103
+ We provide scripts let you easily run our dataset on existing state-of-the-art models and re-create the metrics published in paper. You should be able to reproduce our results from the paper by following these instructions. Please post an issue if you're unable to do this.
104
+ To run existing ANLI models for fact checking.
105
+
106
+ ### Run:
107
+ 1. BART
108
+ ```bash
109
+ python anli.py --model_name 'ynie/bart-large-snli_mnli_fever_anli_R1_R2_R3-nli' --data_file finfact.json --threshold 0.5
110
+ ```
111
+ 2. RoBERTa
112
+ ```bash
113
+ python anli.py --model_name 'ynie/roberta-large-snli_mnli_fever_anli_R1_R2_R3-nli' --data_file finfact.json --threshold 0.5
114
+ ```
115
+ 3. ELECTRA
116
+ ```bash
117
+ python anli.py --model_name 'ynie/electra-large-discriminator-snli_mnli_fever_anli_R1_R2_R3-nli' --data_file finfact.json --threshold 0.5
118
+ ```
119
+ 4. AlBERT
120
+ ```bash
121
+ python anli.py --model_name 'ynie/albert-xxlarge-v2-snli_mnli_fever_anli_R1_R2_R3-nli' --data_file finfact.json --threshold 0.5
122
+ ```
123
+ 5. XLNET
124
+ ```bash
125
+ python anli.py --model_name 'ynie/xlnet-large-cased-snli_mnli_fever_anli_R1_R2_R3-nli' --data_file finfact.json --threshold 0.5
126
+ ```
127
+ 6. GPT-2
128
+ ```bash
129
+ python gpt2_nli.py --model_name 'fractalego/fact-checking' --data_file finfact.json
130
+ ```
131
+
132
+
133
+ ## Citation
134
+
135
+ ```
136
+ @misc{rangapur2023finfact,
137
+ title={Fin-Fact: A Benchmark Dataset for Multimodal Financial Fact Checking and Explanation Generation},
138
+ author={Aman Rangapur and Haoran Wang and Kai Shu},
139
+ year={2023},
140
+ eprint={2309.08793},
141
+ archivePrefix={arXiv},
142
+ primaryClass={cs.AI}
143
+ }
144
+ ```
145
+
146
+ ## Contribution
147
+
148
+ We welcome contributions from the community to help improve Fin-Fact. If you have suggestions, bug reports, or want to contribute code or data, please check our [CONTRIBUTING.md](CONTRIBUTING.md) file for guidelines.
149
+
150
+ ## License
151
+
152
+ Fin-Fact is released under the [MIT License](/LICENSE). Please review the license before using the dataset.
153
+
154
+ ## Contact
155
+ For questions, feedback, or inquiries related to Fin-Fact, please contact `arangapur@hawk.iit.edu`.
156
+
157
+ We hope you find Fin-Fact valuable for your research and fact-checking endeavors. Happy fact-checking!
158
+
finfact.json CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:5f31cffc8bd16aa225f5f10ca9491b82f7508096cfb6f0436637a925735f5fc0
3
- size 32194291
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:53f3422b3e8644d69bbcc7d6c9ced5f99d8ca11e1f2fdae6453837d021874804
3
+ size 31099926