Commit
·
489b632
1
Parent(s):
c7eeb02
fix: Index error multi-turn
Browse files
src/distilabel_dataset_generator/apps/sft.py
CHANGED
@@ -128,10 +128,10 @@ def generate_dataset(
|
|
128 |
result["system_prompt"] = system_prompt
|
129 |
else:
|
130 |
for result in magpie_results:
|
131 |
-
result[
|
132 |
0, {"role": "system", "content": system_prompt}
|
133 |
)
|
134 |
-
result[
|
135 |
while n_processed < num_rows:
|
136 |
progress(
|
137 |
0.5 + 0.5 * n_processed / num_rows,
|
|
|
128 |
result["system_prompt"] = system_prompt
|
129 |
else:
|
130 |
for result in magpie_results:
|
131 |
+
result["conversation"].insert(
|
132 |
0, {"role": "system", "content": system_prompt}
|
133 |
)
|
134 |
+
result["messages"] = result["conversation"]
|
135 |
while n_processed < num_rows:
|
136 |
progress(
|
137 |
0.5 + 0.5 * n_processed / num_rows,
|