Home

Awesome

FELM

<p align="center"> 🌐 <a href="https://hkust-nlp.github.io/felm/" target="_blank">Website</a> • 🤗 <a href="https://huggingface.co/datasets/hkust-nlp/felm" target="_blank">Hugging Face Dataset</a> • 📃 <a href="http://arxiv.org/abs/2310.00741" target="_blank">Paper</a> </p>

FELM is a meta benchmark to evaluate factuality evaluation for large language models. The benchmark comprises 847 questions that span five distinct domains: world knowledge, science/technology, writing/recommendation, reasoning, and math. We gather prompts corresponding to each domain by various sources including standard datasets like truthfulQA, online platforms like Github repositories, ChatGPT generation or drafted by authors.

We then obtain responses from ChatGPT for these prompts. For each response, we employ fine-grained annotation at the segment level, which includes reference links, identified error types, and the reasons behind these errors as provided by our annotators.

Download

Data Description

Dataset Snapshot

CategoryData
Number of Instances847
Number of Fields5
Labeled Classes2
Number of Labels4427

Descriptive Statistics

StatisticAllworld_knowledgeReasoningMathScience/techWritting/Recommendation
Segments442753210255996831588
Positive segments36423858774775821321
Negative segments785147148122101267

Data Fields

Field NameField ValueDescription
indexIntegerthe order number of the data point
sourcestringthe prompt source
promptstringthe prompt for generating response
responsestringthe response of ChatGPT for prompt
segmented_responselistsegments of reponse
labelslistfactuality labels for segmented_response
commentlisterror reasons for segments with factual error
typelisterror types for segments with factual error
reflistreference links

Typical Data Point

{"index": "0", 
 "source": "quora", 
 "prompt": "Which country or city has the maximum number of nuclear power plants?", 
 "response": "The United States has the highest number of nuclear power plants in the world, with 94 operating reactors. Other countries with a significant number of nuclear power plants include France, China, Russia, and South Korea.",
 "segmented_response": ["The United States has the highest number of nuclear power plants in the world, with 94 operating reactors.", "Other countries with a significant number of nuclear power plants include France, China, Russia, and South Korea."], 
 "labels": [false, true],
 "comment": ["As of December 2022, there were 92 operable nuclear power reactors in the United States.", ""], 
 "type": ["knowledge_error", null], 
 "ref": ["https://www.eia.gov/tools/faqs/faq.php?id=207&t=3"]}

Evaluation on FELM

Environment requirements:

transformers 4.32.0
openai 0.27.8
tenacity 8.2.2
tokenizer 3.4.2
pandas 2.0.3

To reproduce our results:

cd eval
#put "all.jsonl" here (Downloaded by Method 1)
bash eval.sh
#You can choose "vicuna_30B", "gpt-3.5-turbo" and "gpt-4" for the parameter "model".
#You can choose "raw", "cot", "link", "content" and "cot-cons"(cot-cons means cot self-consistency method) for the parameter "method".
#replace 'Your OPENAI KEY' with your openai api key if using GPT-3.5 or GPT-4

LEADBOARD (in segment level)

ModelF1 scoreBalanced accuracy
GPT448.367.1
Vicuna-33B32.556.5
ChatGPT25.555.9

We only report the highest scores in this table.

Licenses

MIT license

This work is licensed under a MIT License.

CC BY-NC-SA 4.0

The FELM dataset is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.

Citation

Please cite our paper if you use our dataset:

@inproceedings{
chen2023felm,
title={FELM: Benchmarking Factuality Evaluation of Large Language Models},
author={Chen, Shiqi and Zhao, Yiran and Zhang, Jinghan and Chern, I-Chun and Gao, Siyang and Liu, Pengfei and He, Junxian},
booktitle={Thirty-seventh Conference on Neural Information Processing Systems Datasets and Benchmarks Track},
year={2023},
url={http://arxiv.org/abs/2310.00741}
}