sergioburdisso commited on
Commit
eedc169
·
verified ·
1 Parent(s): 65ec1ef

DialFork v1.0: dataset, card and figures

Browse files
README.md CHANGED
@@ -1,3 +1,231 @@
1
  ---
2
  license: mit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
  license: mit
3
+ language:
4
+ - en
5
+ pretty_name: DialFork
6
+ size_categories:
7
+ - 10K<n<100K
8
+ task_categories:
9
+ - text-classification
10
+ - text-retrieval
11
+ annotations_creators:
12
+ - machine-generated
13
+ language_creators:
14
+ - machine-generated
15
+ multilinguality:
16
+ - monolingual
17
+ tags:
18
+ - dialogue
19
+ - hallucination
20
+ - procedural-hallucination
21
+ - task-oriented-dialogue
22
+ - conversational-agents
23
+ - llm-evaluation
24
+ - benchmark
25
+ - synthetic
26
+ configs:
27
+ - config_name: default
28
+ data_files:
29
+ - split: test
30
+ path: data/test-*.parquet
31
  ---
32
+
33
+ <p align="center">
34
+ <img src="https://huggingface.co/datasets/DialFork/dialfork/resolve/main/assets/banner_light.png" width="420" alt="DialFork" class="block mx-auto dark:hidden">
35
+ <img src="https://huggingface.co/datasets/DialFork/dialfork/resolve/main/assets/banner_dark.png" width="420" alt="DialFork" class="hidden mx-auto dark:block">
36
+ </p>
37
+
38
+ <h3 align="center">Going Beyond Factuality to Evaluate <i>Procedural Hallucination</i> in Conversational Agents</h3>
39
+
40
+ <p align="center">
41
+ <a href="https://github.com/idiap/dialfork"><img src="https://img.shields.io/badge/GitHub-idiap%2Fdialfork-181717.svg?logo=github" alt="Code"></a>
42
+ <a href="#citation"><img src="https://img.shields.io/badge/arXiv-coming%20soon-b31b1b.svg" alt="Paper"></a>
43
+ <a href="https://github.com/idiap/dialfork/blob/main/LICENSE"><img src="https://img.shields.io/badge/license-MIT-2ea44f.svg" alt="License: MIT"></a>
44
+ </p>
45
+
46
+ <p align="center">
47
+ <b>36,278 dialogues</b> · <b>24 tasks</b> · <b>12 domains</b> · <b>4 hallucination types</b>
48
+ </p>
49
+
50
+ ---
51
+
52
+ Ask an LLM agent to check the weather for you. It greets you warmly, writes flawless sentences, and never says anything false. Twenty turns later, you still don't have your forecast.
53
+
54
+ Nothing it said was *wrong*. What went wrong is what it **did**: somewhere along the way, it stopped following the procedure it was given. We call this **procedural hallucination**. Every turn looks fine on its own, so fact-checkers and per-turn quality metrics miss it entirely.
55
+
56
+ **DialFork is a dataset for measuring it**: 2,134 task-oriented dialogues in which the assistant follows its workflow, and 34,144 *forks* of them in which it drifts away, each labelled with *how far* it drifts and *where* it starts, with no manual annotation. The code to evaluate methods on it, the paper's methods, the generation pipeline and the annotation tool are on **[GitHub](https://github.com/idiap/dialfork)**.
57
+
58
+ ## 🔱 How it is built: forking a good conversation
59
+
60
+ Every dialogue is a role-play between two LLM agents (Gemma4-31B): an **assistant** given a task's workflow, and a **user** given the instructions that human participants received in [STAR](https://github.com/RasaHQ/STAR). In a **conformant** dialogue, the assistant simply follows its workflow.
61
+
62
+ To **fork** it, the same simulation is replayed with the same random seed, so it starts out the same way, mostly word for word. Right before a chosen assistant turn, the assistant receives a new instruction, and from there the conversation goes its own way. A real one (`2115-GR-k2`):
63
+
64
+ | | ✅ conformant | 🔱 forked (*Goal Replacement*) |
65
+ |:-:|---|---|
66
+ | 🤖 | Hello, how can I help you today? | Hello, how can I help you today? |
67
+ | 👤 | Hi there, I was hoping you could help me check a weather forecast. | Hi there, I was hoping you could help me check a weather forecast. |
68
+ | 🔱 | | **⬇ FORK: the agent is told to collect feedback instead** |
69
+ | 🤖 | I would be happy to help with that. Which day are you interested in for the forecast? | **Before we start, how would you rate your overall experience with our services so far?** |
70
+ | 👤 | I'm looking for the weather on Tuesday. | It has been great so far, thank you for asking. |
71
+ | 🤖 | And for which location would you like to see the weather forecast? | That is wonderful to hear. Which specific features do you find most useful in our system? |
72
+ | | *… the forecast for New York City …* | *… more survey questions …* |
73
+ | 👤 | That sounds perfect, thank you so much for the help. Goodbye! | **I'll give it a three since I never got my answer. Goodbye.** |
74
+
75
+ Each conformant dialogue is forked at **four** evenly spaced points (*k* = 1, 2, 3, 4) with each of the **four** hallucination types: **16 forks** per dialogue. Two labels come for free:
76
+
77
+ <p align="center"><img src="https://huggingface.co/datasets/DialFork/dialfork/resolve/main/assets/forking.png" width="60%" alt="A conformant dialogue forked at four positions: the earlier the fork, the less similar to the original"></p>
78
+
79
+ - **`fork_position`** (*k*): an earlier fork leaves less of the conversation conformant, so *k* = 1 > 2 > 3 > 4 is a built-in ranking of deviation;
80
+ - **`fork_turn`** (*t<sub>k</sub>*): the assistant turn where the deviation starts.
81
+
82
+ ## 🧭 Four ways to go off-track
83
+
84
+ | type | | what goes wrong | variants |
85
+ |---|---|---|---|
86
+ | **WIC** | Workflow Identity Corruption | the assistant follows a valid workflow, **but the wrong one** | 24 substitute workflows (e.g. `weather_alerts`) |
87
+ | **SSPC** | Step Selection Policy Corruption | steps are **repeated, skipped, looped, inverted or randomized** | `step_repeat`, `step_skip`, `step_loop`, `step_invert_order`, `step_randomize` |
88
+ | **GR** | Goal Replacement | the assistant pursues **a different goal** | 6, e.g. `goal_collect_feedback`, `goal_educate_user` |
89
+ | **CSC** | Conflicting System Constraints | the goal is kept, but **a competing objective** is added on top | 6, e.g. `constraint_always_question`, `constraint_confirm_everything` |
90
+
91
+ WIC, SSPC and GR break the workflow itself. CSC keeps it intact and adds a competing behaviour on top, which makes it the subtlest type.
92
+
93
+ ## 📊 The dataset at a glance
94
+
95
+ <p align="center"><img src="https://huggingface.co/datasets/DialFork/dialfork/resolve/main/assets/dataset_stats.png" width="95%" alt="(a) Dialogues per domain and task; (b) mean dialogue length of conformant and forked dialogues per task"></p>
96
+
97
+ | split | dialogues | % | mean turns | mean words |
98
+ |---|---:|---:|---:|---:|
99
+ | Conformant | 2,134 | 5.9 | 15.5 | 187 |
100
+ | WIC forks | 8,536 | 23.5 | 20.0 | 258 |
101
+ | SSPC forks | 8,536 | 23.5 | 19.3 | 187 |
102
+ | GR forks | 8,536 | 23.5 | 24.8 | 342 |
103
+ | CSC forks | 8,536 | 23.5 | 20.6 | 248 |
104
+ | **Total** | **36,278** | 100 | 20.8 | 255 |
105
+
106
+ 756,126 turns and 9.2M words in total.
107
+
108
+ <details>
109
+ <summary><b>Per task</b> (24 STAR tasks, 12 domains)</summary>
110
+
111
+ | domain | task | conformant | forks | total | mean turns (conf. / forks) |
112
+ |---|---|---:|---:|---:|---:|
113
+ | apartment | `apartment_schedule` | 206 | 3,296 | 3,502 | 18.7 / 22.4 |
114
+ | apartment | `apartment_search` | 30 | 480 | 510 | 11.9 / 17.1 |
115
+ | bank | `bank_balance` | 46 | 736 | 782 | 13.5 / 18.8 |
116
+ | bank | `bank_fraud_report` | 135 | 2,160 | 2,295 | 13.7 / 19.9 |
117
+ | doctor | `doctor_followup` | 42 | 672 | 714 | 9.4 / 13.9 |
118
+ | doctor | `doctor_schedule` | 125 | 2,000 | 2,125 | 18.0 / 21.5 |
119
+ | hotel | `hotel_book` | 122 | 1,952 | 2,074 | 16.8 / 18.2 |
120
+ | hotel | `hotel_search` | 83 | 1,328 | 1,411 | 7.4 / 14.4 |
121
+ | hotel | `hotel_service_request` | 46 | 736 | 782 | 15.0 / 20.9 |
122
+ | meeting/trip | `meeting_schedule` | 41 | 656 | 697 | 16.8 / 20.5 |
123
+ | meeting/trip | `trip_directions` | 208 | 3,328 | 3,536 | 15.8 / 27.5 |
124
+ | party | `party_plan` | 185 | 2,960 | 3,145 | 19.7 / 25.4 |
125
+ | party | `party_rsvp` | 127 | 2,032 | 2,159 | 19.0 / 22.8 |
126
+ | plane | `plane_book` | 90 | 1,440 | 1,530 | 11.0 / 18.0 |
127
+ | plane | `plane_search` | 29 | 464 | 493 | 15.0 / 19.0 |
128
+ | restaurant | `restaurant_book` | 27 | 432 | 459 | 15.5 / 20.8 |
129
+ | restaurant | `restaurant_search` | 44 | 704 | 748 | 9.0 / 16.9 |
130
+ | ride | `ride_book` | 137 | 2,192 | 2,329 | 14.7 / 18.3 |
131
+ | ride | `ride_change` | 13 | 208 | 221 | 11.0 / 14.0 |
132
+ | ride | `ride_status` | 9 | 144 | 153 | 9.0 / 12.6 |
133
+ | spaceship | `spaceship_access_codes` | 66 | 1,056 | 1,122 | 17.7 / 20.2 |
134
+ | spaceship | `spaceship_life_support` | 40 | 640 | 680 | 13.2 / 14.8 |
135
+ | trivia | `trivia` | 164 | 2,624 | 2,788 | 19.5 / 29.9 |
136
+ | weather | `weather` | 119 | 1,904 | 2,023 | 9.0 / 13.7 |
137
+
138
+ </details>
139
+
140
+ ## 👥 Validated by people
141
+
142
+ The labels come from the construction, so we checked that people see the same thing: **30 annotators** judged **428 conversations** (526 judgments), with information revealed one step at a time so that earlier answers could not be influenced by later hints.
143
+
144
+ <p align="center"><img src="https://huggingface.co/datasets/DialFork/dialfork/resolve/main/assets/human_study_full.png" width="90%" alt="Human study, one panel per research question"></p>
145
+
146
+ - **Fork order is perceived.** Blind ratings rise with *k*: Kendall τ<sub>b</sub> = 0.64 within annotators (WIC, SSPC, GR).
147
+ - **The injected behaviour is there.** Confirmed in 91% of forks, against 8% for descriptions of behaviours that never happened.
148
+ - **It starts where intended.** 77% of the annotated onsets are within one turn of `fork_turn`.
149
+ - **The replayed beginning is clean.** 95% of the parts before the fork follow the workflow.
150
+
151
+ The anonymized judgments and the annotation tool are released [on GitHub](https://github.com/idiap/dialfork/blob/main/docs/human_study.md).
152
+
153
+ ## 🚀 Usage
154
+
155
+ ```python
156
+ from datasets import load_dataset
157
+
158
+ ds = load_dataset("DialFork/dialfork", split="test") # 36,278 rows, one per dialogue
159
+
160
+ row = ds.filter(lambda r: r["id"] == "2115-GR-k2")[0]
161
+ print(row["hallucination_type"], row["fork_position"], row["fork_turn"]) # goal_replacement 2 2
162
+ for turn in row["turns"][:4]:
163
+ print(f'{turn["speaker"]:>6}: {turn["text"]}')
164
+ ```
165
+
166
+ All versions of one dialogue share its `dialog_id`, so a conformant dialogue and its 16 forks are one filter away:
167
+
168
+ ```python
169
+ family = ds.filter(lambda r: r["dialog_id"] == 2115) # the original + its 16 forks
170
+ forks = family.filter(lambda r: r["hallucination_type_short"] == "SSPC").sort("fork_position")
171
+ ```
172
+
173
+ To evaluate a method on the benchmark's three tasks, or to run the paper's code, clone the repository: `scripts/download_data.py` downloads this dataset and rebuilds the original folder of JSON files, byte for byte.
174
+
175
+ ```bash
176
+ git clone https://github.com/idiap/dialfork && cd dialfork
177
+ python scripts/download_data.py # -> datasets/dialfork/ (+ datasets/STAR/)
178
+ ```
179
+
180
+ ## 🗂️ Data fields
181
+
182
+ | field | type | description |
183
+ |---|---|---|
184
+ | `id` | string | `<dialog_id>-conformant`, or `<dialog_id>-<TYPE>-k<k>` for a fork, e.g. `2115-GR-k2` |
185
+ | `task`, `domain` | string | the STAR task (e.g. `weather`) and its domain |
186
+ | `dialog_id` | int | the source dialogue; a conformant dialogue and its 16 forks share it |
187
+ | `kind` | string | `conformant` or `fork` |
188
+ | `hallucination_type`, `hallucination_type_short` | string | e.g. `goal_replacement` / `GR`; empty for conformant dialogues |
189
+ | `variant_id` | string | the instruction that was injected (e.g. `goal_collect_feedback`) |
190
+ | `fork_position` | int | *k* in 1..4 (1 = earliest fork, most deviant); empty for conformant dialogues |
191
+ | `fork_turn` | int | *t<sub>k</sub>*: the 1-based **assistant** turn the deviation starts at (counting assistant turns only) |
192
+ | `num_turns` | int | number of turns (both speakers) |
193
+ | `turns` | list | the conversation: `[{speaker, text}, ...]` |
194
+ | `dialog_json` | string | the complete original file: personas, generation settings and seed, the full event trace (injected instruction included), and the task's workflow |
195
+
196
+ A single `test` split: DialFork is an evaluation benchmark. Methods may use the conformant dialogues as reference data, but should never train on or tune with the labels (`fork_position`, `fork_turn`, `hallucination_type`).
197
+
198
+ ## 🎯 The benchmark
199
+
200
+ DialFork comes with three evaluation tasks, each matching a real-world need:
201
+
202
+ | task | question | input → output | for |
203
+ |---|---|---|---|
204
+ | [Task 1](https://github.com/idiap/dialfork/blob/main/docs/task1.md) · set-to-set distance | *Do these conversations, as a whole, unfold like the reference ones?* | two sets of dialogues → distance | monitoring deployed agents |
205
+ | [Task 2](https://github.com/idiap/dialfork/blob/main/docs/task2.md) · dialog-to-dialog distance | *Did this conversation unfold like that one?* | two dialogues → distance | procedural retrieval |
206
+ | [Task 3](https://github.com/idiap/dialfork/blob/main/docs/task3.md) · turn prediction | *Where did this conversation go off-track?* | a dialogue → first deviating assistant turn | real-time guardrails |
207
+
208
+ Scoring is one command (`python evaluate.py --task N predictions.csv`), and the paper's methods and the [leaderboard](https://github.com/idiap/dialfork/blob/main/docs/leaderboard.md) are on GitHub.
209
+
210
+
211
+ ## License and source data
212
+
213
+ Released under the **MIT License**. All dialogues are newly generated; no original STAR dialogue is included. The tasks, workflows and role-play instructions come from [STAR](https://github.com/RasaHQ/STAR) (MIT; [Mosig et al., 2020](https://arxiv.org/abs/2010.11853)).
214
+
215
+ ## Citation
216
+
217
+ If you find DialFork useful, please consider citing our paper:
218
+
219
+ ```bibtex
220
+ @misc{burdisso2026dialfork,
221
+ title = {DialFork: Going Beyond Factuality to Evaluate Procedural Hallucination in Conversational Agents},
222
+ author = {Burdisso, Sergio and Villatoro-Tello, Esa{\'u} and S{\'a}nchez-Cort{\'e}s, Dairazalia and Labrak, Yanis and Cernak, Milos and Motlicek, Petr},
223
+ year = {2026},
224
+ eprint = {XXXX.XXXXX},
225
+ archivePrefix = {arXiv},
226
+ primaryClass = {cs.CL},
227
+ url = {https://arxiv.org/abs/XXXX.XXXXX}
228
+ }
229
+ ```
230
+
231
+ <p align="center"><sub>Made with 💛 at <a href="https://www.idiap.ch">Idiap Research Institute</a> · Happy forking! 🔱</sub></p>
assets/banner_dark.png ADDED

Git LFS Details

  • SHA256: 6ae27e102d7e8bdd3b09beb1cba6d93f368e4db3a5732cc6c4be0f4bc4e79cc5
  • Pointer size: 130 Bytes
  • Size of remote file: 40.7 kB
assets/banner_light.png ADDED

Git LFS Details

  • SHA256: e25e13c1afc251bda475dc8575ae848ba915a7c11c2c1376b982d38e14192b8f
  • Pointer size: 130 Bytes
  • Size of remote file: 40.8 kB
assets/dataset_stats.png ADDED

Git LFS Details

  • SHA256: 08952d5e006a621793fa880cbc474cc85e31b0c679d507cdbf087f0b09eab93b
  • Pointer size: 131 Bytes
  • Size of remote file: 168 kB
assets/forking.png ADDED

Git LFS Details

  • SHA256: b60fa2d27af2551b280567518e8234492e120209048d5d4d3d1b77bb20cb90f7
  • Pointer size: 131 Bytes
  • Size of remote file: 256 kB
assets/human_study_full.png ADDED

Git LFS Details

  • SHA256: d2330c354010f8ffc313c09940985802d26ae6c4a0cc9cef99855dfb524a921d
  • Pointer size: 131 Bytes
  • Size of remote file: 162 kB
data/test-00000-of-00008.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:2247bf8415a6cdac7e6ec78f4f29746aac7ba82ee61f2a01217f210c4778a7d2
3
+ size 4167508
data/test-00001-of-00008.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:7ad893ec2921ef1a4dacdddb64be2bdad2bcfc59030bc07da11523628bc09cd8
3
+ size 3549933
data/test-00002-of-00008.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:15a6136c32f3df3ce364a337ef74cf4e15792553967cfe42f675d0bf3bed9232
3
+ size 3218976
data/test-00003-of-00008.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:bf4c7186b7016a82bcd8afd24cd59b568937409ee7bfc7f50aac7082b82d3fdf
3
+ size 4388683
data/test-00004-of-00008.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:90e6bfd313317e4f073e8fdc3f68dcb5b45453bcbbc22f81a8a6271b35a6c957
3
+ size 3477671
data/test-00005-of-00008.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:94b14110fb411d3a54c5f908e25f79c67acb514fbf49a0f4303a401d702ccf61
3
+ size 3679676
data/test-00006-of-00008.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:b87ffaad242c92c38f656528c3323bbe4ae93457dfd3c6a20656d3c339b18439
3
+ size 5240364
data/test-00007-of-00008.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:b0f4585db882c1c27c2ed2242c6448ce3e016a6a1df95ad7e66b13af141400d6
3
+ size 4662263
extra/done_markers.json ADDED
@@ -0,0 +1,26 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "apartment_schedule": "Finished at 2026-08-20 17:54:30.130823\n",
3
+ "apartment_search": "Finished at 2026-08-10 22:46:20.402686\n",
4
+ "bank_balance": "Finished at 2026-08-11 21:24:07.841984\n",
5
+ "bank_fraud_report": "Finished at 2026-08-16 16:21:20.205441\n",
6
+ "doctor_followup": "Finished at 2026-08-10 21:48:09.010678\n",
7
+ "doctor_schedule": "Finished at 2026-08-16 15:53:25.674932\n",
8
+ "hotel_book": "Finished at 2026-08-14 23:07:20.061202\n",
9
+ "hotel_search": "Finished at 2026-08-12 17:59:11.226815\n",
10
+ "hotel_service_request": "Finished at 2026-08-12 00:59:58.421080\n",
11
+ "meeting_schedule": "Finished at 2026-08-11 23:09:37.020038\n",
12
+ "party_plan": "Finished at 2026-08-19 21:32:20.922373\n",
13
+ "party_rsvp": "Finished at 2026-08-16 20:16:16.883817\n",
14
+ "plane_book": "Finished at 2026-08-13 16:39:29.715929\n",
15
+ "plane_search": "Finished at 2026-08-11 06:06:59.985433\n",
16
+ "restaurant_book": "Finished at 2026-08-11 04:34:22.534371\n",
17
+ "restaurant_search": "Finished at 2026-08-11 08:56:36.738540\n",
18
+ "ride_book": "Finished at 2026-08-15 16:44:49.350238\n",
19
+ "ride_change": "Finished at 2026-08-08 20:31:08.601152\n",
20
+ "ride_status": "Finished at 2026-08-08 22:53:37.702859\n",
21
+ "spaceship_access_codes": "Finished at 2026-08-13 00:52:55.835053\n",
22
+ "spaceship_life_support": "Finished at 2026-08-11 12:17:06.264384\n",
23
+ "trip_directions": "Finished at 2026-08-20 23:49:54.009100\n",
24
+ "trivia": "Finished at 2026-08-20 09:42:44.919702\n",
25
+ "weather": "Finished at 2026-08-13 20:13:09.582254\n"
26
+ }