Update app.py
Browse files
app.py
CHANGED
|
@@ -2,7 +2,7 @@ import gradio as gr
|
|
| 2 |
from transformers import AutoTokenizer, AutoModelForCausalLM
|
| 3 |
import torch
|
| 4 |
|
| 5 |
-
print("
|
| 6 |
|
| 7 |
model_name = "samzito12/lora_model2"
|
| 8 |
|
|
@@ -66,9 +66,9 @@ demo = gr.ChatInterface(
|
|
| 66 |
it's a custom fine-tuned model for ID2223 Lab 2.
|
| 67 |
""",
|
| 68 |
examples=[
|
| 69 |
-
["What model are you?"
|
| 70 |
-
["Explain machine learning in simple terms"
|
| 71 |
-
["Write a Python function to reverse a string"
|
| 72 |
],
|
| 73 |
additional_inputs=[
|
| 74 |
gr.Slider(minimum=0, maximum=2, value=0.7, step=0.1, label="Temperature"),
|
|
|
|
| 2 |
from transformers import AutoTokenizer, AutoModelForCausalLM
|
| 3 |
import torch
|
| 4 |
|
| 5 |
+
print("Loading the model...")
|
| 6 |
|
| 7 |
model_name = "samzito12/lora_model2"
|
| 8 |
|
|
|
|
| 66 |
it's a custom fine-tuned model for ID2223 Lab 2.
|
| 67 |
""",
|
| 68 |
examples=[
|
| 69 |
+
["What model are you?"],
|
| 70 |
+
["Explain machine learning in simple terms"],
|
| 71 |
+
["Write a Python function to reverse a string"]
|
| 72 |
],
|
| 73 |
additional_inputs=[
|
| 74 |
gr.Slider(minimum=0, maximum=2, value=0.7, step=0.1, label="Temperature"),
|