Datasets:
Upload folder using huggingface_hub
Browse files- README.md +70 -0
- UPLOAD_STEPS.md +40 -0
- data/claims.csv +157 -0
- data/dataset_summary.json +31 -0
- data/evaluation_instances.csv +0 -0
- data/judgments.csv +0 -0
- data/wvs_group_priors.csv +0 -0
- scripts/prepare_release.py +437 -0
README.md
ADDED
|
@@ -0,0 +1,70 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
pretty_name: BeliefSim
|
| 3 |
+
language:
|
| 4 |
+
- en
|
| 5 |
+
task_categories:
|
| 6 |
+
- text-classification
|
| 7 |
+
- tabular-classification
|
| 8 |
+
tags:
|
| 9 |
+
- misinformation
|
| 10 |
+
- belief-modeling
|
| 11 |
+
- survey-data
|
| 12 |
+
- demographic-analysis
|
| 13 |
+
license: other
|
| 14 |
+
---
|
| 15 |
+
|
| 16 |
+
# BeliefSim Dataset Release
|
| 17 |
+
|
| 18 |
+
This folder contains an anonymized, Hugging Face-ready data package for **BeliefSim: Towards Belief-Driven Simulation of Demographic Misinformation Susceptibility**.
|
| 19 |
+
|
| 20 |
+
## Content Note
|
| 21 |
+
|
| 22 |
+
This dataset studies real misinformation and rumor examples. Some claims may contain offensive, stigmatizing, or otherwise harmful wording. Examples are included for research transparency and should be handled with care.
|
| 23 |
+
|
| 24 |
+
## Files
|
| 25 |
+
|
| 26 |
+
- `data/claims.csv`: claim text from PANDORA and MIST-1, with source labels and gold labels where available.
|
| 27 |
+
- `data/judgments.csv`: anonymized participant-level claim judgments.
|
| 28 |
+
- `data/evaluation_instances.csv`: target claim judgments paired with two same-participant observed belief judgments.
|
| 29 |
+
- `data/wvs_group_priors.csv`: WVS-derived group belief distributions by demographic axis.
|
| 30 |
+
- `data/dataset_summary.json`: generated counts and privacy notes.
|
| 31 |
+
- `scripts/prepare_release.py`: reproducible script used to regenerate the release files from local raw sources.
|
| 32 |
+
|
| 33 |
+
## Current Generated Counts
|
| 34 |
+
|
| 35 |
+
- Claims: 156 total, including 56 PANDORA and 100 MIST-1 claims.
|
| 36 |
+
- Judgments: 40,964 total, including 64 PANDORA and 40,900 MIST-1 judgments.
|
| 37 |
+
- Evaluation instances: 40,135 total, including 53 PANDORA and 40,082 MIST-1 instances.
|
| 38 |
+
- WVS group prior rows: 976.
|
| 39 |
+
|
| 40 |
+
These counts are generated from the local files available in this workspace at preparation time.
|
| 41 |
+
|
| 42 |
+
## Anonymization
|
| 43 |
+
|
| 44 |
+
The release script removes direct identifiers and sensitive survey metadata before writing the public CSV files. In particular, it drops response IDs, Prolific IDs, IP addresses, latitude/longitude, raw timestamps, and free-text notes/comments. Participant identifiers are replaced with deterministic salted SHA-256 hashes. Demographic fields are kept only as broad categories such as gender, age group, education bucket, and living-area group where available.
|
| 45 |
+
|
| 46 |
+
Before public upload, verify that the upstream PANDORA, MIST-1, and WVS data-use terms permit redistribution of the fields included here. If redistribution is not permitted for any source, upload only the scripts/metadata and provide instructions for authorized users to reconstruct the dataset locally.
|
| 47 |
+
|
| 48 |
+
## Loading
|
| 49 |
+
|
| 50 |
+
```python
|
| 51 |
+
from datasets import load_dataset
|
| 52 |
+
|
| 53 |
+
claims = load_dataset("MichiganNLP/beliefsim", data_files="data/claims.csv")
|
| 54 |
+
judgments = load_dataset("MichiganNLP/beliefsim", data_files="data/judgments.csv")
|
| 55 |
+
instances = load_dataset("MichiganNLP/beliefsim", data_files="data/evaluation_instances.csv")
|
| 56 |
+
wvs_priors = load_dataset("MichiganNLP/beliefsim", data_files="data/wvs_group_priors.csv")
|
| 57 |
+
```
|
| 58 |
+
|
| 59 |
+
## Citation
|
| 60 |
+
|
| 61 |
+
```bibtex
|
| 62 |
+
@article{borah2026belief,
|
| 63 |
+
title={Belief-Sim: Towards Belief-Driven Simulation of Demographic Misinformation Susceptibility},
|
| 64 |
+
author={Borah, Angana and Khan, Zohaib and Mihalcea, Rada and P{\'e}rez-Rosas, Ver{\'o}nica},
|
| 65 |
+
journal={arXiv preprint arXiv:2603.03585},
|
| 66 |
+
year={2026}
|
| 67 |
+
}
|
| 68 |
+
```
|
| 69 |
+
|
| 70 |
+
Questions or collaboration inquiries about misinformation research can be directed to anganab@umich.edu.
|
UPLOAD_STEPS.md
ADDED
|
@@ -0,0 +1,40 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Uploading BeliefSim to Hugging Face
|
| 2 |
+
|
| 3 |
+
Run these commands from `/home/anganab/misinfo` after reviewing the generated files and confirming upstream redistribution permissions.
|
| 4 |
+
|
| 5 |
+
```bash
|
| 6 |
+
cd /home/anganab/misinfo
|
| 7 |
+
python3 beliefsim_hf_dataset/scripts/prepare_release.py
|
| 8 |
+
```
|
| 9 |
+
|
| 10 |
+
Install the Hugging Face CLI if needed:
|
| 11 |
+
|
| 12 |
+
```bash
|
| 13 |
+
python3 -m pip install --user -U huggingface_hub
|
| 14 |
+
```
|
| 15 |
+
|
| 16 |
+
Log in with a Hugging Face token that has write access:
|
| 17 |
+
|
| 18 |
+
```bash
|
| 19 |
+
huggingface-cli login
|
| 20 |
+
```
|
| 21 |
+
|
| 22 |
+
Create the dataset repository. Use the org name if you want it under MichiganNLP:
|
| 23 |
+
|
| 24 |
+
```bash
|
| 25 |
+
huggingface-cli repo create MichiganNLP/beliefsim --type dataset --private
|
| 26 |
+
```
|
| 27 |
+
|
| 28 |
+
Upload the prepared folder:
|
| 29 |
+
|
| 30 |
+
```bash
|
| 31 |
+
huggingface-cli upload MichiganNLP/beliefsim beliefsim_hf_dataset . --repo-type dataset
|
| 32 |
+
```
|
| 33 |
+
|
| 34 |
+
Open the dataset page, inspect the preview, then switch visibility to public only after verifying that PANDORA, MIST-1, and WVS redistribution terms permit the included fields. If permissions are uncertain, keep the repo private or upload only `README.md` and `scripts/prepare_release.py`.
|
| 35 |
+
|
| 36 |
+
Suggested public URL after upload:
|
| 37 |
+
|
| 38 |
+
```text
|
| 39 |
+
https://huggingface.co/datasets/MichiganNLP/beliefsim
|
| 40 |
+
```
|
data/claims.csv
ADDED
|
@@ -0,0 +1,157 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
source,claim_id,claim_text,gold_label,content_warning
|
| 2 |
+
PANDORA,Q256,Police confirm that #sydneysiege is finally over. Two people reportedly injured after suffering gunshot wounds http://t.co/nsprnSYTDT,,True
|
| 3 |
+
PANDORA,Q259,"Police have clarified that there were two shootings in Ottawa today, not three: at the War Memorial and Parliament Hill.",,True
|
| 4 |
+
PANDORA,Q262,Police have surrounded this building where the suspected #CharlieHebdo attackers are holed-up http://t.co/B0TRvE2iYs http://t.co/becxNG0Kxi,,True
|
| 5 |
+
PANDORA,Q266,"Police say shots fired at 3 #Ottawa sites - National War Memorial, Parliament Hill, and now Rideau shopping centre http://t.co/rOnqpUbuqc",,True
|
| 6 |
+
PANDORA,Q269,Police taking people out of #Paris grocery where hostages were being held. http://t.co/7Bxdhozq4H,,True
|
| 7 |
+
PANDORA,Q272,"Prince not playing Massey Hall tonight, promoter says http://t.co/clVHvM07kx http://t.co/IADirsFOOC",,True
|
| 8 |
+
PANDORA,Q275,"Ray Hadley says he spoke with hostage, and could hear the gunman in the background barking orders and demanding to go live on air",,True
|
| 9 |
+
PANDORA,Q278,Reports on @channeltennews #sydneysiege gunman wants #ISIL flag delivered to cafe and he also wants to speak to PM or people will be killed.,,True
|
| 10 |
+
PANDORA,Q281,SYDNEY SIEGE: Gunman forces hostages to hold up ISIS flag in window http://t.co/9K3XXEiSFa http://t.co/cATxCjYXpy,,True
|
| 11 |
+
PANDORA,Q284,Secret Service tells Infowars: Hillary seriously ill; needs special accommodations Tune in 4pm-6pm CST https://t.co/OQtch0Lewb #trump #tcot,,True
|
| 12 |
+
PANDORA,Q287,Secret Service tells Infowars: Hillary seriously ill; needs special accommodations Tune in 4pm-6pm CST https://t.co/OQtch0Lewb #trump #tcot,,True
|
| 13 |
+
PANDORA,Q290,Senior U.S. official: Canadian government has informed U.S. that one shooter is dead in Ottawa. Live blog: http://t.co/q98AMohu7T,,True
|
| 14 |
+
PANDORA,Q293,Several hostages freed at Jewish supermarket in Paris. Photo Thomas Samson #AFP http://t.co/C9ltgMT0Wl,,True
|
| 15 |
+
PANDORA,Q296,Soldier killed in Canada shooting was a young reservist with a six-year-old son http://t.co/83PReIl9XV http://t.co/LVprXOCCF7,,True
|
| 16 |
+
PANDORA,Q299,Sydney airspace wasn't closed. A second terror suspect wasn't arrested. Myths around #sydneysiege debunked. http://t.co/yTLKLUKnFd,,True
|
| 17 |
+
PANDORA,Q302,The Sydney cafe siege may be part of a larger plot. @Y7News #MartinPlaceSiege http://t.co/f2aTNEpjmh http://t.co/DE4IBxv73K,,True
|
| 18 |
+
PANDORA,Q305,The gunman in Ottawa has been shot and killed. I'm at a loss for words this morning. That isn't my Canada.,,True
|
| 19 |
+
PANDORA,Q308,"The latest @CBCNews on #Ottawa shootings. Gunman killed inside Parliament, soldier shot at War Memorial. http://t.co/kngapKTSCe #cdnpoli",,True
|
| 20 |
+
PANDORA,Q311,These are not timid colours; soldiers back guarding Tomb of Unknown Soldier after today's shooting #StandforCanada http://t.co/7KoW2xATKG,,True
|
| 21 |
+
PANDORA,Q314,This afternoon we've lowered our flags to half mast in honour of the Canadian Reservist who lost his life in Ottawa. http://t.co/3oTF5sd2Lf,,True
|
| 22 |
+
PANDORA,Q317,This is crazy! #CapeTown #capestorm #weatherforecast https://t.co/3bcKOKrCJB,,True
|
| 23 |
+
PANDORA,Q320,"UPDATE: 12 now confirmed dead in #CharlieHebdo attack in Paris, @AP is reporting. Story: http://t.co/Jfqmha1GdV (AP) http://t.co/vDCIFHIa9U",,True
|
| 24 |
+
PANDORA,Q323,"UPDATE: 13 people being held hostage in #Sydney shop, Opera House evacuated after suspicious package found: reports http://t.co/n4D3yGjso9",,True
|
| 25 |
+
PANDORA,Q326,Uber Sydney trips from CBD will be free for riders. Higher rates are still in place to encourage drivers to get into the CBD.,,True
|
| 26 |
+
PANDORA,Q329,Uber intros surge pricing in downtown Sydney during hostage siege http://t.co/XWGe9MpUzU http://t.co/cwhIiozFNr,,True
|
| 27 |
+
PANDORA,Q332,"Uber says it has hiked prices in Sydney to ""encourage more drivers to come online & pick up passengers."" http://t.co/MCJ0rMSXPc #SydneySiege",,True
|
| 28 |
+
PANDORA,Q335,Unconfirmed reports claim that Michael Essien has contracted Ebola. http://t.co/VASQrZdLhH,,True
|
| 29 |
+
PANDORA,Q338,Unformed Russian Embassy staff in London have left for Russia Rumours Putin HAS DIED! http://t.co/zSIV8w6FJ2 via @ShaunyNews #PutinDead?,,True
|
| 30 |
+
PANDORA,Q341,"WTF RT @Jeggit: Believe it or not, this is a shark on the freeway in Houston, Texas. #HurricaneHarvy https://t.co/Vpikg0zguV",,True
|
| 31 |
+
PANDORA,Q344,Watch video showing gunfire inside Canada's parliament in Ottawa http://t.co/CJpXNAk8nS http://t.co/hxwr2NEr2K,,True
|
| 32 |
+
PANDORA,Q347,“@LePoint: #CharlieHebdo : “The cartoonists Charb & cabu are dead.” http://t.co/7USD83cQd2 http://t.co/WGHbLiLFoX”,,True
|
| 33 |
+
PANDORA,Q350,“@LePoint: #CharlieHebdo : “The cartoonists Charb & cabu are dead.” http://t.co/7USD83cQd2 http://t.co/WGHbLiLFoX”,,True
|
| 34 |
+
PANDORA,Q353,R_A Desperate Scramble as Covid-19 Families vie for Access to Plasma Therapy,,True
|
| 35 |
+
PANDORA,Q356,R_Adults with Covid-19 Twice as Likely to Have Eaten at Restaurants,,True
|
| 36 |
+
PANDORA,Q359,R_Amazon Plans to Prosecute Sellers for Coronavirus Outbreak.jpg,,True
|
| 37 |
+
PANDORA,Q362,"R_American Incomes Were Raising, Until the Pandemic Hit",,True
|
| 38 |
+
PANDORA,Q365,"R_Amid Coronavirus Outbreak, Carnival Cruise Line Offers on-Ship Credits to Passengers Who Don't Reschedule.jpeg",,True
|
| 39 |
+
PANDORA,Q368,R_Anti-Inflammatory Drug may Shorten Covid-19 Recovery Time,,True
|
| 40 |
+
PANDORA,Q371,R_AstraZeneca Resumes Its COVID-19 Vaccine Trials in the U.K.,,True
|
| 41 |
+
PANDORA,Q374,"R_Coronavirus can Hijack Brain Cells to Replicate Itself, Yale Researchers Discover",,True
|
| 42 |
+
PANDORA,Q377,R_Coronavirus Poses Tough Challenge for Economic Policymakers.jpeg,,True
|
| 43 |
+
PANDORA,Q380,R_Coronavirus Vaccine Showing Promise in Early Human Trials,,True
|
| 44 |
+
PANDORA,Q383,R_Covid-19 Cases Among Florida Children Jumped 26 Percent in a Month.,,True
|
| 45 |
+
PANDORA,Q386,"R_CDC Coronavirus Spread may Last into 2021, but Impact can be Blunted.jpeg",,True
|
| 46 |
+
PANDORA,Q389,R_DOJ Seeks New Emergency Powers Amid Coronavirus Pandemic,,True
|
| 47 |
+
PANDORA,Q392,R_Experimental Drug Holds Promise for Treating the Coronavirus,,True
|
| 48 |
+
PANDORA,Q395,R_Fauci Says It's Doable to have Millions of Doses of Covid-19 Vaccine by January,,True
|
| 49 |
+
PANDORA,Q398,R_Germany Boosts Investment in Covid-19 Vaccine Research,,True
|
| 50 |
+
PANDORA,Q401,R_Israel Declares 14 Day Quarantine for all Arrivals.jpeg,,True
|
| 51 |
+
PANDORA,Q404,R_It's Irresponsible and It's Dangerous-Experts Rip Trump's Idea of Injecting Disinfectant to Treat COVID-19,,True
|
| 52 |
+
PANDORA,Q407,R_N.I.H. Director has Cautious Optimism for Covid-19 Vaccine by End of 2020,,True
|
| 53 |
+
PANDORA,Q410,R_Ohio Man Dies from COVID-19 After Criticizing Governor's Coronavirus Lockdown as Madness.jpg,,True
|
| 54 |
+
PANDORA,Q413,"R_Pennsylvania Coronavirus Restrictions Deemed Unconstitutional, Federal Judge Rules",,True
|
| 55 |
+
PANDORA,Q416,R_Police in the US Spread a False Claim that Meth is Contaminated with Coronavirus.jpeg,,True
|
| 56 |
+
PANDORA,Q419,R_Some Urban Hospitals Face Closure or Cutback as the Pandemic Adds to Fiscal Woes,,True
|
| 57 |
+
PANDORA,News_1_share,No,,True
|
| 58 |
+
MIST-1,MIST_1,A Small Group of People Control the World Economy by Manipulating the Price of Gold and Oil,misinformation,True
|
| 59 |
+
MIST-1,MIST_2,A Study Found That the Mainstream Media Is Lying about the Cause of Lyme Disease,misinformation,True
|
| 60 |
+
MIST-1,MIST_3,African Nations Are Expected to Hand Over Control of Their Resources to Western Investors Within a Decade,misinformation,True
|
| 61 |
+
MIST-1,MIST_4,Black People Are More Likely to Be Criminals,misinformation,True
|
| 62 |
+
MIST-1,MIST_5,Breaking News: Australia Is the Only Country That Lets Pedophiles Off the Hook,misinformation,True
|
| 63 |
+
MIST-1,MIST_6,Breaking News: Scientists Found a Link Between Climate Change and Tooth Decay,misinformation,True
|
| 64 |
+
MIST-1,MIST_7,Certain Vaccines Are Loaded with Dangerous Chemicals and Toxins,misinformation,True
|
| 65 |
+
MIST-1,MIST_8,"Climate Scientists' Work Is 'Unreliable', a 'Deceptive Method of Communication'",misinformation,True
|
| 66 |
+
MIST-1,MIST_9,"Doctors Are Paid to Promote All Kinds of Ridiculous, Harmful, and Dangerous Treatments",misinformation,True
|
| 67 |
+
MIST-1,MIST_10,"Ebola Virus 'Caused by US Nuclear Weapons Testing', New Study Says",misinformation,True
|
| 68 |
+
MIST-1,MIST_11,Fact: Left-Wing/Left-Wing Media Exaggerates the 'White Flight' of West Coast Whites Towards Minority Enclaves,misinformation,True
|
| 69 |
+
MIST-1,MIST_12,Google Has Made It Illegal to Film Police Officers in the US,misinformation,True
|
| 70 |
+
MIST-1,MIST_13,Government Officials Have Illegally Manipulated the Weather to Cause Devastating Storms,misinformation,True
|
| 71 |
+
MIST-1,MIST_14,Government Officials Have Manipulated Stock Prices to Hide Scandals,misinformation,True
|
| 72 |
+
MIST-1,MIST_15,"Left-Wing Extremism Causes 'More Damage' to World Than Terrorism, Says UN Report",misinformation,True
|
| 73 |
+
MIST-1,MIST_16,Left-Wingers Are More Likely to Lie to Get a Good Grade,misinformation,True
|
| 74 |
+
MIST-1,MIST_17,New Data Show Shark Fins Are the 'Most Important Source of Protein' for the World's Poor,misinformation,True
|
| 75 |
+
MIST-1,MIST_18,New Study: Americans Are the Most Religious People on Earth,misinformation,True
|
| 76 |
+
MIST-1,MIST_19,New Study: Clear Relationship Between Eye Color and Intelligence,misinformation,True
|
| 77 |
+
MIST-1,MIST_20,New Study: Left-Wingers Are More Likely to Lie to Get a Higher Salary,misinformation,True
|
| 78 |
+
MIST-1,MIST_21,New Study: Liberals Are More Likely to Be Overweight,misinformation,True
|
| 79 |
+
MIST-1,MIST_22,"Right-Wing Extremists: 5% of Population, 20% of Voting Power, 30% of the Wealth, 70% of the Police and Army",misinformation,True
|
| 80 |
+
MIST-1,MIST_23,Science Proves That Conservatives Are More Violent than Liberals,misinformation,True
|
| 81 |
+
MIST-1,MIST_24,Scientists Are Working to Genetically Engineer Food to Produce a Toxin That Will Give It Aphrodisiac Qualities,misinformation,True
|
| 82 |
+
MIST-1,MIST_25,Scientists at Harvard Are Now Talking about the Possibility of the Moon Landing Being Faked,misinformation,True
|
| 83 |
+
MIST-1,MIST_26,Scientists Find 'Genetic Basis' for Right-Wing Extremist Views,misinformation,True
|
| 84 |
+
MIST-1,MIST_27,"Sudden Infant Death Syndrome (SIDS) Is Now a ""Scientific"" Epidemic, and the Media and Medical Community Has Been Covering It up for Decades",misinformation,True
|
| 85 |
+
MIST-1,MIST_28,The Corporate Media Is Controlled by the Military-industrial Complex: The Major Oil Companies Own the Media and Control Their Agenda,misinformation,True
|
| 86 |
+
MIST-1,MIST_29,The Drug Companies Have Been Controlling the Political Arena for Over a Hundred Years,misinformation,True
|
| 87 |
+
MIST-1,MIST_30,"The Government Has Secret Information on Every Citizen, Including Their Financial and Medical Information",misinformation,True
|
| 88 |
+
MIST-1,MIST_31,The Government Is Actively Destroying Evidence Related to the JFK Assassination,misinformation,True
|
| 89 |
+
MIST-1,MIST_32,The Government Is Conducting a Massive Cover-Up of Their Involvement in 9/11,misinformation,True
|
| 90 |
+
MIST-1,MIST_33,The Government Is Knowingly Spreading Disease Through the Airwaves and Food Supply,misinformation,True
|
| 91 |
+
MIST-1,MIST_34,The Government Is Manipulating the Public's Perception of Genetic Engineering in Order to Make People More Accepting of Such Techniques,misinformation,True
|
| 92 |
+
MIST-1,MIST_35,"The Government Is Secretly Stockpiling Food and Other Goods in Case of a ""Hard-Currency Collapse""",misinformation,True
|
| 93 |
+
MIST-1,MIST_36,"The Mainstream Media Is Misinforming about Vaccinations: Vaccines Cause Autism, Vaccines Are Unsafe and Dangerous",misinformation,True
|
| 94 |
+
MIST-1,MIST_37,"The More You Learn About the Moon Landing, the More You Realize That It Was Faked",misinformation,True
|
| 95 |
+
MIST-1,MIST_38,"The So-Called ""Overdose"" Epidemic Is a Myth, and Those Who Believe It Are ""Nutritional Extremists""",misinformation,True
|
| 96 |
+
MIST-1,MIST_39,UFO Sightings Are Actually the Result of Secret Military Experiments,misinformation,True
|
| 97 |
+
MIST-1,MIST_40,UK Will Have to Spend up to £23bn on Military in Response to Right-Wing Extremism,misinformation,True
|
| 98 |
+
MIST-1,MIST_41,UN Report: Worldwide Rise of Infant Mortality Due to Modern Medicine,misinformation,True
|
| 99 |
+
MIST-1,MIST_42,UN: More than 50% of the World's Population Will Face Famine by 2070,misinformation,True
|
| 100 |
+
MIST-1,MIST_43,UN: New Report Shows Shark Fin Soup as 'the Most Important Source of Protein' for World's Poor,misinformation,True
|
| 101 |
+
MIST-1,MIST_44,US Is the Most Dangerous Place on Earth for Women,misinformation,True
|
| 102 |
+
MIST-1,MIST_45,64% of Americans Want Stricter Laws on Gun Sales,true_information,True
|
| 103 |
+
MIST-1,MIST_46,83% Say Measles Vaccine Is Safe for Healthy Children - No Partisan Differences in Views of Vaccine Safety,true_information,True
|
| 104 |
+
MIST-1,MIST_47,About a Quarter of Large US Newspapers Laid off Staff in 2018,true_information,True
|
| 105 |
+
MIST-1,MIST_48,Americans Feel Generally Positive about Their Own Finances,true_information,True
|
| 106 |
+
MIST-1,MIST_49,"Americans Have Positive Views about Religion’s Role in Society, But Want It out of Politics",true_information,True
|
| 107 |
+
MIST-1,MIST_50,"Attitudes Toward EU Are Largely Positive, Both Within Europe and Outside It",true_information,True
|
| 108 |
+
MIST-1,MIST_51,Blue Light Isn’t the Main Source of Eye Fatigue and Sleep Loss - It’s Your Computer,true_information,True
|
| 109 |
+
MIST-1,MIST_52,Data Show Upswing in Child Exploitation Cases,true_information,True
|
| 110 |
+
MIST-1,MIST_53,Democrats More Supportive than Republicans of Federal Spending for Scientific Research,true_information,True
|
| 111 |
+
MIST-1,MIST_54,"East Germany Has Narrowed Economic Gap with West Germany Since Fall of Communism, But Still Lags",true_information,True
|
| 112 |
+
MIST-1,MIST_55,Experts Optimistic About the Next 50 Years of Digital Life,true_information,True
|
| 113 |
+
MIST-1,MIST_56,Four in 10 Teachers Say Their School Is Not Well Protected,true_information,True
|
| 114 |
+
MIST-1,MIST_57,Germany Welcomes Tesla's Berlin Move as Boost to E-Car Shift,true_information,True
|
| 115 |
+
MIST-1,MIST_58,Global Warming Age Gap: Younger Americans Most Worried,true_information,True
|
| 116 |
+
MIST-1,MIST_59,Hawaii May Subpoena Airbnb for Tax Records of Rental Hosts,true_information,True
|
| 117 |
+
MIST-1,MIST_60,Hyatt Will Remove Small Bottles from Hotel Bathrooms by 2021,true_information,True
|
| 118 |
+
MIST-1,MIST_61,"In Emerging Economies, Smartphone and Social Media Users Have Broader Social Networks",true_information,True
|
| 119 |
+
MIST-1,MIST_62,"In US, 54% Say Teachers Unprepared to Handle Discipline",true_information,True
|
| 120 |
+
MIST-1,MIST_63,"In US, 71% Support Transgender People Serving in Military",true_information,True
|
| 121 |
+
MIST-1,MIST_64,"In Western European Countries with Church Taxes, Support for the Tradition Remains Strong",true_information,True
|
| 122 |
+
MIST-1,MIST_65,International Relations Experts and US Public Agree: America Is Less Respected Globally,true_information,True
|
| 123 |
+
MIST-1,MIST_66,Is US Fertility at An All-time Low? Two of Three Measures Point to Yes,true_information,True
|
| 124 |
+
MIST-1,MIST_67,Japan's Ageing 'Hidden Christians' Fear They May Be Their Religion's Last Generation,true_information,True
|
| 125 |
+
MIST-1,MIST_68,"Latinos Are More Likely to Believe in the American Dream, But Most Say It Is Hard to Achieve",true_information,True
|
| 126 |
+
MIST-1,MIST_69,Leaked Russian Interference Report Raises UK Vote Questions,true_information,True
|
| 127 |
+
MIST-1,MIST_70,"Majority in US Still Want Abortion Legal, with Limits",true_information,True
|
| 128 |
+
MIST-1,MIST_71,Minnesota School District May Monitor Students’ Online Posts,true_information,True
|
| 129 |
+
MIST-1,MIST_72,More People Around the World See US Power and Influence as a ‘Major Threat’ to Their Country,true_information,True
|
| 130 |
+
MIST-1,MIST_73,Morocco’s King Appoints Committee Chief to Fight Poverty and Inequality,true_information,True
|
| 131 |
+
MIST-1,MIST_74,Most Americans Say It’s OK for Professional Athletes to Speak out Publicly about Politics,true_information,True
|
| 132 |
+
MIST-1,MIST_75,Most Americans Say Science Has Brought Benefits to Society and Expect More to Come,true_information,True
|
| 133 |
+
MIST-1,MIST_76,Most Distant World Ever Explored Gets New Name: Arrokoth,true_information,True
|
| 134 |
+
MIST-1,MIST_77,National Politics on Twitter: Small Share of US Adults Produce Majority of Tweets,true_information,True
|
| 135 |
+
MIST-1,MIST_78,Nearly Half in US Fear Being the Victim of a Mass Shooting,true_information,True
|
| 136 |
+
MIST-1,MIST_79,Nearly Six-in-Ten Americans Say Abortion Should Be Legal in All or Most Cases,true_information,True
|
| 137 |
+
MIST-1,MIST_80,Norway's Oil Decline Accelerates,true_information,True
|
| 138 |
+
MIST-1,MIST_81,"Obama Tops Public’s List of Best President in Their Lifetime, Followed by Clinton, Reagan",true_information,True
|
| 139 |
+
MIST-1,MIST_82,One-in-Three Worldwide Lack Confidence in NGOs,true_information,True
|
| 140 |
+
MIST-1,MIST_83,One-in-Five Americans Now Listen to Audiobooks,true_information,True
|
| 141 |
+
MIST-1,MIST_84,"One-in-Five US Newsroom Employees Live in New York, Los Angeles or DC",true_information,True
|
| 142 |
+
MIST-1,MIST_85,Online Grocery Shopping Still Rare in US,true_information,True
|
| 143 |
+
MIST-1,MIST_86,Political Typology Reveals Deep Fissures on the Right and Left,true_information,True
|
| 144 |
+
MIST-1,MIST_87,"Reflecting a Demographic Shift, 109 US Counties Have Become Majority Nonwhite Since 2000",true_information,True
|
| 145 |
+
MIST-1,MIST_88,"Republicans Divided in Views of Trump’s Conduct, Democrats Are Broadly Critical",true_information,True
|
| 146 |
+
MIST-1,MIST_89,"Republicans, Democrats See Opposing Party as More Ideological Than Their Own",true_information,True
|
| 147 |
+
MIST-1,MIST_90,"Since Trump’s Election, Increased Attention to Politics – Especially Among Women",true_information,True
|
| 148 |
+
MIST-1,MIST_91,Students at Smaller Colleges More Likely to Say Faculty Care,true_information,True
|
| 149 |
+
MIST-1,MIST_92,Taiwan Seeks to Join Fight Against Global Warming,true_information,True
|
| 150 |
+
MIST-1,MIST_93,Two in Three Americans Now Support Legalizing Marijuana,true_information,True
|
| 151 |
+
MIST-1,MIST_94,United Nations Gets Mostly Positive Marks from People Around the World,true_information,True
|
| 152 |
+
MIST-1,MIST_95,"Universal Basic Income Favored in Canada, UK But Not in US",true_information,True
|
| 153 |
+
MIST-1,MIST_96,"US Hispanic Population Reached New High in 2018, But Growth Has Slowed",true_information,True
|
| 154 |
+
MIST-1,MIST_97,US Panel Backs Wider Use of Fish Oil to Prevent Heart Attack,true_information,True
|
| 155 |
+
MIST-1,MIST_98,US Safety Board Wants Boeing to Redesign 737 NG Part after Fatal Southwest Accident,true_information,True
|
| 156 |
+
MIST-1,MIST_99,US Support for Legal Marijuana Steady in Past Year,true_information,True
|
| 157 |
+
MIST-1,MIST_100,"Volkswagen to Invest 60 Billion Euros in E-mobility, Digital Tech by 2024",true_information,True
|
data/dataset_summary.json
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"claims": 156,
|
| 3 |
+
"judgments": 40964,
|
| 4 |
+
"evaluation_instances": 40135,
|
| 5 |
+
"wvs_group_prior_rows": 976,
|
| 6 |
+
"sources": {
|
| 7 |
+
"PANDORA": {
|
| 8 |
+
"claims": 56,
|
| 9 |
+
"judgments": 64,
|
| 10 |
+
"evaluation_instances": 53
|
| 11 |
+
},
|
| 12 |
+
"MIST-1": {
|
| 13 |
+
"claims": 100,
|
| 14 |
+
"judgments": 40900,
|
| 15 |
+
"evaluation_instances": 40082
|
| 16 |
+
}
|
| 17 |
+
},
|
| 18 |
+
"privacy": {
|
| 19 |
+
"dropped": [
|
| 20 |
+
"ResponseId",
|
| 21 |
+
"PROLIFIC_ID",
|
| 22 |
+
"IPAddress",
|
| 23 |
+
"LocationLatitude",
|
| 24 |
+
"LocationLongitude",
|
| 25 |
+
"open-text notes/comments",
|
| 26 |
+
"raw timestamps"
|
| 27 |
+
],
|
| 28 |
+
"participant_ids": "deterministic salted SHA-256 hashes, truncated to 16 hex characters",
|
| 29 |
+
"demographics": "broad gender, age bucket, education bucket, and living-area fields only"
|
| 30 |
+
}
|
| 31 |
+
}
|
data/evaluation_instances.csv
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
data/judgments.csv
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
data/wvs_group_priors.csv
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
scripts/prepare_release.py
ADDED
|
@@ -0,0 +1,437 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#!/usr/bin/env python3
|
| 2 |
+
"""Prepare an anonymized BeliefSim dataset package for Hugging Face.
|
| 3 |
+
|
| 4 |
+
The script keeps claims, participant judgments, evaluation triplets, and WVS
|
| 5 |
+
group priors. It drops direct identifiers, IP/location metadata, and open-text
|
| 6 |
+
free-response notes.
|
| 7 |
+
"""
|
| 8 |
+
|
| 9 |
+
import hashlib
|
| 10 |
+
import json
|
| 11 |
+
import re
|
| 12 |
+
import zipfile
|
| 13 |
+
from pathlib import Path
|
| 14 |
+
from xml.etree import ElementTree as ET
|
| 15 |
+
|
| 16 |
+
import pandas as pd
|
| 17 |
+
|
| 18 |
+
|
| 19 |
+
ROOT = Path(__file__).resolve().parents[2]
|
| 20 |
+
OUT = Path(__file__).resolve().parents[1] / "data"
|
| 21 |
+
SALT = "beliefsim-release-v1"
|
| 22 |
+
|
| 23 |
+
|
| 24 |
+
PANDORA_PATH = ROOT / "misinfo_combined_latest_with_acc_new.csv"
|
| 25 |
+
MIST_PATH = ROOT / "wvs_misinfo" / "MIST - Sample 1 - Raw Dataset.csv"
|
| 26 |
+
MIST_ITEM_DB = ROOT / "wvs_misinfo" / "MIST - Phase 4 - Item Database (January 2020).xlsx"
|
| 27 |
+
|
| 28 |
+
WVS_FILES = {
|
| 29 |
+
"gender": ROOT / "wvs_misinfo" / "gender_alldimensions_wvs.csv",
|
| 30 |
+
"living_area": ROOT / "wvs_misinfo" / "urbrur_alldimensions_wvs.csv",
|
| 31 |
+
"age": ROOT / "wvs_misinfo" / "age_alldimensions.csv",
|
| 32 |
+
"education": ROOT / "wvs_misinfo" / "education_alldimensions.csv",
|
| 33 |
+
}
|
| 34 |
+
|
| 35 |
+
|
| 36 |
+
def anonymize(prefix: str, *parts: object) -> str:
|
| 37 |
+
raw = "|".join("" if p is None else str(p) for p in parts)
|
| 38 |
+
digest = hashlib.sha256(f"{SALT}|{prefix}|{raw}".encode("utf-8")).hexdigest()[:16]
|
| 39 |
+
return f"{prefix}_{digest}"
|
| 40 |
+
|
| 41 |
+
|
| 42 |
+
def clean_text(value: object) -> str:
|
| 43 |
+
if pd.isna(value):
|
| 44 |
+
return ""
|
| 45 |
+
return re.sub(r"\s+", " ", str(value)).strip()
|
| 46 |
+
|
| 47 |
+
|
| 48 |
+
def norm(value: object) -> str:
|
| 49 |
+
return re.sub(r"[^a-z0-9]+", " ", clean_text(value).lower()).strip()
|
| 50 |
+
|
| 51 |
+
|
| 52 |
+
def first_nonempty(row: pd.Series, candidates: list) -> str:
|
| 53 |
+
for col in candidates:
|
| 54 |
+
if col in row.index:
|
| 55 |
+
val = clean_text(row[col])
|
| 56 |
+
if val and val.lower() != "nan":
|
| 57 |
+
return val
|
| 58 |
+
return ""
|
| 59 |
+
|
| 60 |
+
|
| 61 |
+
def extract_claim(prompt_text: str) -> str:
|
| 62 |
+
text = re.sub(r"^\s*News:\s*", "", clean_text(prompt_text), flags=re.I)
|
| 63 |
+
for marker in ["Supporting Stance:", "Refuting Stance:", "Your responses:", "Your response:"]:
|
| 64 |
+
if marker in text:
|
| 65 |
+
text = text.split(marker, 1)[0]
|
| 66 |
+
return clean_text(text)
|
| 67 |
+
|
| 68 |
+
|
| 69 |
+
def standardize_pandora_judgment(value: object) -> str:
|
| 70 |
+
v = norm(value)
|
| 71 |
+
if not v:
|
| 72 |
+
return ""
|
| 73 |
+
if "importid" in v or v in {"true information", "misinformation", "have you heard of the information before", "comments notes"}:
|
| 74 |
+
return ""
|
| 75 |
+
if "true information" in v or v in {"true", "real"}:
|
| 76 |
+
return "true_information"
|
| 77 |
+
if "misinformation" in v or v in {"false", "fake"}:
|
| 78 |
+
return "misinformation"
|
| 79 |
+
if "not sure" in v or "unsure" in v:
|
| 80 |
+
return "not_sure"
|
| 81 |
+
return clean_text(value)
|
| 82 |
+
|
| 83 |
+
|
| 84 |
+
def standardize_mist_judgment(value: object) -> str:
|
| 85 |
+
v = norm(value)
|
| 86 |
+
if not v:
|
| 87 |
+
return ""
|
| 88 |
+
if v in {"real", "true", "1"} or "real" in v:
|
| 89 |
+
return "true_information"
|
| 90 |
+
if v in {"fake", "false", "0"} or "fake" in v:
|
| 91 |
+
return "misinformation"
|
| 92 |
+
return clean_text(value)
|
| 93 |
+
|
| 94 |
+
|
| 95 |
+
def age_bucket(value: object) -> str:
|
| 96 |
+
s = clean_text(value)
|
| 97 |
+
if not s:
|
| 98 |
+
return ""
|
| 99 |
+
m = re.search(r"\d+", s)
|
| 100 |
+
if not m:
|
| 101 |
+
return s
|
| 102 |
+
age = int(m.group())
|
| 103 |
+
if age < 30:
|
| 104 |
+
return "18-29"
|
| 105 |
+
if age < 45:
|
| 106 |
+
return "30-44"
|
| 107 |
+
if age < 60:
|
| 108 |
+
return "45-59"
|
| 109 |
+
return "60+"
|
| 110 |
+
|
| 111 |
+
|
| 112 |
+
def education_bucket(value: object) -> str:
|
| 113 |
+
v = norm(value)
|
| 114 |
+
if not v:
|
| 115 |
+
return ""
|
| 116 |
+
completed = [
|
| 117 |
+
"bachelor",
|
| 118 |
+
"master",
|
| 119 |
+
"doctor",
|
| 120 |
+
"professional",
|
| 121 |
+
"college degree",
|
| 122 |
+
"university",
|
| 123 |
+
"graduate",
|
| 124 |
+
]
|
| 125 |
+
if any(token in v for token in completed):
|
| 126 |
+
return "completed"
|
| 127 |
+
return "not_completed"
|
| 128 |
+
|
| 129 |
+
|
| 130 |
+
def load_pandora() -> tuple:
|
| 131 |
+
if not PANDORA_PATH.exists():
|
| 132 |
+
return [], [], []
|
| 133 |
+
|
| 134 |
+
raw = pd.read_csv(PANDORA_PATH, header=None, dtype=str, low_memory=False)
|
| 135 |
+
qids = [clean_text(x) for x in raw.iloc[0].tolist()]
|
| 136 |
+
labels = [clean_text(x) for x in raw.iloc[1].tolist()]
|
| 137 |
+
columns = []
|
| 138 |
+
seen: dict = {}
|
| 139 |
+
qid_map: dict = {}
|
| 140 |
+
for qid, label in zip(qids, labels):
|
| 141 |
+
base = label or qid or "unnamed"
|
| 142 |
+
seen[base] = seen.get(base, 0) + 1
|
| 143 |
+
col = base if seen[base] == 1 else f"{base}__{seen[base]}"
|
| 144 |
+
columns.append(col)
|
| 145 |
+
if qid:
|
| 146 |
+
qid_map[col] = qid
|
| 147 |
+
|
| 148 |
+
# Qualtrics export rows: machine ids, question text, choice/import rows, then responses.
|
| 149 |
+
df = raw.iloc[4:].copy()
|
| 150 |
+
df.columns = columns
|
| 151 |
+
news_cols = [c for c in df.columns if norm(c).startswith("news")]
|
| 152 |
+
|
| 153 |
+
claims: dict[str, dict] = {}
|
| 154 |
+
judgments: list = []
|
| 155 |
+
instances: list = []
|
| 156 |
+
|
| 157 |
+
# In this Qualtrics export the answer to "Your responses" is stored in the
|
| 158 |
+
# same column as the long claim prompt; the next two columns are heard-before
|
| 159 |
+
# and free-text notes, which are intentionally not released.
|
| 160 |
+
response_cols = {c: c for c in news_cols}
|
| 161 |
+
demo_cols = {
|
| 162 |
+
"gender": ["What is your gender?", "gender"],
|
| 163 |
+
"age_group": ["How old are you?", "age"],
|
| 164 |
+
"living_area": ["How would you describe the area you live in?", "area", "living_area"],
|
| 165 |
+
"education_bucket": [
|
| 166 |
+
"What is the highest level of education you have completed?",
|
| 167 |
+
"degree",
|
| 168 |
+
"education",
|
| 169 |
+
],
|
| 170 |
+
}
|
| 171 |
+
id_candidates = ["ResponseId", "Response ID", "PROLIFIC_ID"]
|
| 172 |
+
|
| 173 |
+
for row_idx, row in df.iterrows():
|
| 174 |
+
row_judgments = []
|
| 175 |
+
participant_id = anonymize("pandora", row_idx, first_nonempty(row, id_candidates))
|
| 176 |
+
demographics = {}
|
| 177 |
+
for key, candidates in demo_cols.items():
|
| 178 |
+
val = first_nonempty(row, candidates)
|
| 179 |
+
demographics[key] = education_bucket(val) if key == "education_bucket" else clean_text(val)
|
| 180 |
+
|
| 181 |
+
if demographics.get("age_group"):
|
| 182 |
+
demographics["age_group"] = age_bucket(demographics["age_group"])
|
| 183 |
+
|
| 184 |
+
for news_col in news_cols:
|
| 185 |
+
prompt_text = clean_text(row.get(news_col, ""))
|
| 186 |
+
resp_col = response_cols.get(news_col, "")
|
| 187 |
+
judgment = standardize_pandora_judgment(row.get(resp_col, "")) if resp_col else ""
|
| 188 |
+
claim_text = extract_claim(prompt_text)
|
| 189 |
+
if not claim_text or not judgment:
|
| 190 |
+
continue
|
| 191 |
+
claim_id = qid_map.get(news_col, "") or anonymize("pandora_claim", news_col)
|
| 192 |
+
claims[claim_id] = {
|
| 193 |
+
"source": "PANDORA",
|
| 194 |
+
"claim_id": claim_id,
|
| 195 |
+
"claim_text": claim_text,
|
| 196 |
+
"gold_label": "",
|
| 197 |
+
"content_warning": True,
|
| 198 |
+
}
|
| 199 |
+
record = {
|
| 200 |
+
"source": "PANDORA",
|
| 201 |
+
"participant_id": participant_id,
|
| 202 |
+
"claim_id": claim_id,
|
| 203 |
+
"judgment": judgment,
|
| 204 |
+
**demographics,
|
| 205 |
+
}
|
| 206 |
+
judgments.append(record)
|
| 207 |
+
row_judgments.append(record)
|
| 208 |
+
|
| 209 |
+
for i in range(2, len(row_judgments)):
|
| 210 |
+
b1, b2, target = row_judgments[i - 2], row_judgments[i - 1], row_judgments[i]
|
| 211 |
+
instances.append(
|
| 212 |
+
{
|
| 213 |
+
"source": "PANDORA",
|
| 214 |
+
"instance_id": anonymize("pandora_instance", participant_id, target["claim_id"], i),
|
| 215 |
+
"participant_id": participant_id,
|
| 216 |
+
"target_claim_id": target["claim_id"],
|
| 217 |
+
"target_judgment": target["judgment"],
|
| 218 |
+
"observed_claim_1_id": b1["claim_id"],
|
| 219 |
+
"observed_judgment_1": b1["judgment"],
|
| 220 |
+
"observed_claim_2_id": b2["claim_id"],
|
| 221 |
+
"observed_judgment_2": b2["judgment"],
|
| 222 |
+
**demographics,
|
| 223 |
+
}
|
| 224 |
+
)
|
| 225 |
+
|
| 226 |
+
return list(claims.values()), judgments, instances
|
| 227 |
+
|
| 228 |
+
|
| 229 |
+
def read_xlsx_first_sheet(path):
|
| 230 |
+
"""Read a simple XLSX first sheet using only the Python standard library."""
|
| 231 |
+
ns = {"a": "http://schemas.openxmlformats.org/spreadsheetml/2006/main"}
|
| 232 |
+
with zipfile.ZipFile(str(path)) as zf:
|
| 233 |
+
shared = []
|
| 234 |
+
if "xl/sharedStrings.xml" in zf.namelist():
|
| 235 |
+
root = ET.fromstring(zf.read("xl/sharedStrings.xml"))
|
| 236 |
+
for item in root.findall(".//a:si", ns):
|
| 237 |
+
shared.append("".join(t.text or "" for t in item.findall(".//a:t", ns)))
|
| 238 |
+
|
| 239 |
+
sheet_name = "xl/worksheets/sheet1.xml"
|
| 240 |
+
root = ET.fromstring(zf.read(sheet_name))
|
| 241 |
+
rows = []
|
| 242 |
+
for row in root.findall(".//a:sheetData/a:row", ns):
|
| 243 |
+
values = []
|
| 244 |
+
for cell in row.findall("a:c", ns):
|
| 245 |
+
cell_type = cell.attrib.get("t", "")
|
| 246 |
+
value_node = cell.find("a:v", ns)
|
| 247 |
+
inline_node = cell.find("a:is/a:t", ns)
|
| 248 |
+
value = ""
|
| 249 |
+
if inline_node is not None:
|
| 250 |
+
value = inline_node.text or ""
|
| 251 |
+
elif value_node is not None:
|
| 252 |
+
raw = value_node.text or ""
|
| 253 |
+
value = shared[int(raw)] if cell_type == "s" and raw.isdigit() and int(raw) < len(shared) else raw
|
| 254 |
+
values.append(value)
|
| 255 |
+
rows.append(values)
|
| 256 |
+
|
| 257 |
+
if not rows:
|
| 258 |
+
return pd.DataFrame()
|
| 259 |
+
width = max(len(r) for r in rows)
|
| 260 |
+
rows = [r + [""] * (width - len(r)) for r in rows]
|
| 261 |
+
header = [clean_text(x) or "column_{}".format(i) for i, x in enumerate(rows[0])]
|
| 262 |
+
return pd.DataFrame(rows[1:], columns=header)
|
| 263 |
+
|
| 264 |
+
|
| 265 |
+
def load_mist_item_db() -> pd.DataFrame:
|
| 266 |
+
try:
|
| 267 |
+
db = pd.read_excel(MIST_ITEM_DB, dtype=str)
|
| 268 |
+
except ImportError:
|
| 269 |
+
db = read_xlsx_first_sheet(MIST_ITEM_DB)
|
| 270 |
+
cols = {norm(c): c for c in db.columns}
|
| 271 |
+
id_col = cols.get("id") or next((c for c in db.columns if norm(c) == "id"), "")
|
| 272 |
+
headline_col = (
|
| 273 |
+
cols.get("headline")
|
| 274 |
+
or cols.get("item")
|
| 275 |
+
or next((c for c in db.columns if "headline" in norm(c) or "item" == norm(c)), "")
|
| 276 |
+
)
|
| 277 |
+
out = db[[id_col, headline_col]].copy()
|
| 278 |
+
out.columns = ["item_id", "claim_text"]
|
| 279 |
+
out["gold_label"] = out["item_id"].map(lambda x: "true_information" if clean_text(x).upper().startswith("R") else "misinformation")
|
| 280 |
+
out["claim_id"] = [f"MIST_{i + 1}" for i in range(len(out))]
|
| 281 |
+
return out
|
| 282 |
+
|
| 283 |
+
|
| 284 |
+
def load_mist() -> tuple:
|
| 285 |
+
if not MIST_PATH.exists() or not MIST_ITEM_DB.exists():
|
| 286 |
+
return [], [], []
|
| 287 |
+
|
| 288 |
+
df = pd.read_csv(MIST_PATH, dtype=str, low_memory=False)
|
| 289 |
+
item_db = load_mist_item_db()
|
| 290 |
+
claims = [
|
| 291 |
+
{
|
| 292 |
+
"source": "MIST-1",
|
| 293 |
+
"claim_id": row.claim_id,
|
| 294 |
+
"claim_text": clean_text(row.claim_text),
|
| 295 |
+
"gold_label": row.gold_label,
|
| 296 |
+
"content_warning": True,
|
| 297 |
+
}
|
| 298 |
+
for row in item_db.itertuples(index=False)
|
| 299 |
+
]
|
| 300 |
+
claim_ids = item_db["claim_id"].tolist()
|
| 301 |
+
mist_cols = [c for c in df.columns if re.fullmatch(r"MIST_\d+", clean_text(c))]
|
| 302 |
+
if not mist_cols:
|
| 303 |
+
mist_cols = [c for c in df.columns if clean_text(c) in claim_ids]
|
| 304 |
+
|
| 305 |
+
judgments: list = []
|
| 306 |
+
instances: list = []
|
| 307 |
+
gender_cols = [c for c in df.columns if norm(c) in {"gender", "sex"} or "gender" in norm(c)]
|
| 308 |
+
age_cols = [c for c in df.columns if norm(c) == "age" or "age" in norm(c)]
|
| 309 |
+
edu_cols = [c for c in df.columns if "education" in norm(c) or "degree" in norm(c)]
|
| 310 |
+
|
| 311 |
+
for row_idx, row in df.iterrows():
|
| 312 |
+
demographics = {
|
| 313 |
+
"gender": first_nonempty(row, gender_cols),
|
| 314 |
+
"age_group": age_bucket(first_nonempty(row, age_cols)),
|
| 315 |
+
"living_area": "",
|
| 316 |
+
"education_bucket": education_bucket(first_nonempty(row, edu_cols)),
|
| 317 |
+
}
|
| 318 |
+
participant_id = anonymize("mist", row_idx)
|
| 319 |
+
row_judgments = []
|
| 320 |
+
for col in mist_cols:
|
| 321 |
+
judgment = standardize_mist_judgment(row.get(col, ""))
|
| 322 |
+
if not judgment:
|
| 323 |
+
continue
|
| 324 |
+
rec = {
|
| 325 |
+
"source": "MIST-1",
|
| 326 |
+
"participant_id": participant_id,
|
| 327 |
+
"claim_id": clean_text(col),
|
| 328 |
+
"judgment": judgment,
|
| 329 |
+
**demographics,
|
| 330 |
+
}
|
| 331 |
+
judgments.append(rec)
|
| 332 |
+
row_judgments.append(rec)
|
| 333 |
+
|
| 334 |
+
for i in range(2, len(row_judgments)):
|
| 335 |
+
b1, b2, target = row_judgments[i - 2], row_judgments[i - 1], row_judgments[i]
|
| 336 |
+
instances.append(
|
| 337 |
+
{
|
| 338 |
+
"source": "MIST-1",
|
| 339 |
+
"instance_id": anonymize("mist_instance", participant_id, target["claim_id"], i),
|
| 340 |
+
"participant_id": participant_id,
|
| 341 |
+
"target_claim_id": target["claim_id"],
|
| 342 |
+
"target_judgment": target["judgment"],
|
| 343 |
+
"observed_claim_1_id": b1["claim_id"],
|
| 344 |
+
"observed_judgment_1": b1["judgment"],
|
| 345 |
+
"observed_claim_2_id": b2["claim_id"],
|
| 346 |
+
"observed_judgment_2": b2["judgment"],
|
| 347 |
+
**demographics,
|
| 348 |
+
}
|
| 349 |
+
)
|
| 350 |
+
|
| 351 |
+
return claims, judgments, instances
|
| 352 |
+
|
| 353 |
+
|
| 354 |
+
def load_wvs_priors() -> list:
|
| 355 |
+
records: list = []
|
| 356 |
+
for axis, path in WVS_FILES.items():
|
| 357 |
+
if not path.exists():
|
| 358 |
+
continue
|
| 359 |
+
df = pd.read_csv(path, dtype=str)
|
| 360 |
+
q_col = next((c for c in df.columns if norm(c) in {"question", "question text"}), "")
|
| 361 |
+
id_col = next((c for c in df.columns if norm(c) in {"question no", "question_no", "qid"}), "")
|
| 362 |
+
for _, row in df.iterrows():
|
| 363 |
+
for col in df.columns:
|
| 364 |
+
n = norm(col)
|
| 365 |
+
if not n.endswith("distribution") or n == "overall distribution":
|
| 366 |
+
continue
|
| 367 |
+
group = re.sub(r"_?distribution$", "", col).strip("_")
|
| 368 |
+
most_col = f"{group}_most"
|
| 369 |
+
least_col = f"{group}_least"
|
| 370 |
+
records.append(
|
| 371 |
+
{
|
| 372 |
+
"demographic_axis": axis,
|
| 373 |
+
"group": group,
|
| 374 |
+
"question_id": clean_text(row.get(id_col, "")) if id_col else "",
|
| 375 |
+
"question_text": clean_text(row.get(q_col, "")) if q_col else "",
|
| 376 |
+
"distribution": clean_text(row.get(col, "")),
|
| 377 |
+
"most_common": clean_text(row.get(most_col, "")),
|
| 378 |
+
"least_common": clean_text(row.get(least_col, "")),
|
| 379 |
+
"source_file": path.name,
|
| 380 |
+
}
|
| 381 |
+
)
|
| 382 |
+
return records
|
| 383 |
+
|
| 384 |
+
|
| 385 |
+
def main() -> None:
|
| 386 |
+
OUT.mkdir(parents=True, exist_ok=True)
|
| 387 |
+
p_claims, p_judgments, p_instances = load_pandora()
|
| 388 |
+
m_claims, m_judgments, m_instances = load_mist()
|
| 389 |
+
wvs = load_wvs_priors()
|
| 390 |
+
|
| 391 |
+
claims = pd.DataFrame(p_claims + m_claims).drop_duplicates(["source", "claim_id"])
|
| 392 |
+
judgments = pd.DataFrame(p_judgments + m_judgments)
|
| 393 |
+
instances = pd.DataFrame(p_instances + m_instances)
|
| 394 |
+
priors = pd.DataFrame(wvs)
|
| 395 |
+
|
| 396 |
+
claims.to_csv(OUT / "claims.csv", index=False)
|
| 397 |
+
judgments.to_csv(OUT / "judgments.csv", index=False)
|
| 398 |
+
instances.to_csv(OUT / "evaluation_instances.csv", index=False)
|
| 399 |
+
priors.to_csv(OUT / "wvs_group_priors.csv", index=False)
|
| 400 |
+
|
| 401 |
+
summary = {
|
| 402 |
+
"claims": len(claims),
|
| 403 |
+
"judgments": len(judgments),
|
| 404 |
+
"evaluation_instances": len(instances),
|
| 405 |
+
"wvs_group_prior_rows": len(priors),
|
| 406 |
+
"sources": {
|
| 407 |
+
"PANDORA": {
|
| 408 |
+
"claims": int((claims["source"] == "PANDORA").sum()) if not claims.empty else 0,
|
| 409 |
+
"judgments": int((judgments["source"] == "PANDORA").sum()) if not judgments.empty else 0,
|
| 410 |
+
"evaluation_instances": int((instances["source"] == "PANDORA").sum()) if not instances.empty else 0,
|
| 411 |
+
},
|
| 412 |
+
"MIST-1": {
|
| 413 |
+
"claims": int((claims["source"] == "MIST-1").sum()) if not claims.empty else 0,
|
| 414 |
+
"judgments": int((judgments["source"] == "MIST-1").sum()) if not judgments.empty else 0,
|
| 415 |
+
"evaluation_instances": int((instances["source"] == "MIST-1").sum()) if not instances.empty else 0,
|
| 416 |
+
},
|
| 417 |
+
},
|
| 418 |
+
"privacy": {
|
| 419 |
+
"dropped": [
|
| 420 |
+
"ResponseId",
|
| 421 |
+
"PROLIFIC_ID",
|
| 422 |
+
"IPAddress",
|
| 423 |
+
"LocationLatitude",
|
| 424 |
+
"LocationLongitude",
|
| 425 |
+
"open-text notes/comments",
|
| 426 |
+
"raw timestamps",
|
| 427 |
+
],
|
| 428 |
+
"participant_ids": "deterministic salted SHA-256 hashes, truncated to 16 hex characters",
|
| 429 |
+
"demographics": "broad gender, age bucket, education bucket, and living-area fields only",
|
| 430 |
+
},
|
| 431 |
+
}
|
| 432 |
+
(OUT / "dataset_summary.json").write_text(json.dumps(summary, indent=2))
|
| 433 |
+
print(json.dumps(summary, indent=2))
|
| 434 |
+
|
| 435 |
+
|
| 436 |
+
if __name__ == "__main__":
|
| 437 |
+
main()
|