From 03c824c29c1311b69de5bca1bd444c72c96afa74 Mon Sep 17 00:00:00 2001 From: Daniel Han Date: Tue, 29 Apr 2025 23:57:46 -0700 Subject: [PATCH] Update synthetic.py --- unsloth/dataprep/synthetic.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/unsloth/dataprep/synthetic.py b/unsloth/dataprep/synthetic.py index f76e170c59..5eadacf448 100644 --- a/unsloth/dataprep/synthetic.py +++ b/unsloth/dataprep/synthetic.py @@ -238,6 +238,7 @@ prompts: def configure_synthetic_data_kit( model_name = "unsloth/Llama-3.1-8B-Instruct-unsloth-bnb-4bit", + output_folder = "synthetic_data_output", temperature = 0.7, top_p = 0.95, chunk_size = 4000, @@ -248,6 +249,12 @@ def configure_synthetic_data_kit( cleanup_batch_size = 4, cleanup_temperature = 0.3, ): + locations = "pdf,html,youtube,docx,ppt,txt,output,generated,cleaned,final" + locations = locations.split(",") + for path in locations: + os.makedirs(os.path.join(output_folder, path), exist_ok = True) + pass + config = synthetic_config_string\ .replace("{model_name}", str(model_name))\ .replace("{temperature}", str(temperature))\