dafeadfe
Browse files
app.py
CHANGED
@@ -64,17 +64,17 @@ def train_ui_tars(file):
|
|
64 |
trainer.train()
|
65 |
|
66 |
# Step 5: Save the model
|
67 |
-
model.save_pretrained("
|
68 |
-
tokenizer.save_pretrained("./
|
69 |
|
70 |
-
return "Training completed successfully! Model saved to ./
|
71 |
|
72 |
except Exception as e:
|
73 |
return f"Error: {str(e)}"
|
74 |
|
75 |
# Gradio UI
|
76 |
with gr.Blocks(title="Model Fine-Tuning Interface") as demo:
|
77 |
-
gr.Markdown("
|
78 |
gr.Markdown("Upload a JSON file with 'input' and 'output' pairs to fine-tune the model on your fraud dataset.")
|
79 |
|
80 |
file_input = gr.File(label="Upload Fraud Dataset (JSON)")
|
|
|
64 |
trainer.train()
|
65 |
|
66 |
# Step 5: Save the model
|
67 |
+
model.save_pretrained("train_llama.py")
|
68 |
+
tokenizer.save_pretrained("./train_llama.py")
|
69 |
|
70 |
+
return "Training completed successfully! Model saved to ./train_llama.py"
|
71 |
|
72 |
except Exception as e:
|
73 |
return f"Error: {str(e)}"
|
74 |
|
75 |
# Gradio UI
|
76 |
with gr.Blocks(title="Model Fine-Tuning Interface") as demo:
|
77 |
+
gr.Markdown("train_llama.py")
|
78 |
gr.Markdown("Upload a JSON file with 'input' and 'output' pairs to fine-tune the model on your fraud dataset.")
|
79 |
|
80 |
file_input = gr.File(label="Upload Fraud Dataset (JSON)")
|
final_combined_fraud_data (2).json → final_combined_fraud_data.json
RENAMED
File without changes
|
requirements.txt
CHANGED
@@ -1,4 +1,7 @@
|
|
1 |
torch
|
2 |
transformers
|
3 |
datasets
|
4 |
-
gradio
|
|
|
|
|
|
|
|
1 |
torch
|
2 |
transformers
|
3 |
datasets
|
4 |
+
gradio
|
5 |
+
peft
|
6 |
+
accelerate
|
7 |
+
bitsandbytes
|
train_llama.py → train.py
RENAMED
File without changes
|