Spaces:
Running
on
Zero
Running
on
Zero
alfredplpl
commited on
Commit
•
0ee3851
1
Parent(s):
31b9227
Update app.py
Browse files
app.py
CHANGED
@@ -47,8 +47,12 @@ h1 {
|
|
47 |
"""
|
48 |
|
49 |
# Load the tokenizer and model
|
50 |
-
tokenizer = AutoTokenizer.from_pretrained("google/gemma-2-2b-jpn-it"
|
51 |
-
model = AutoModelForCausalLM.from_pretrained(
|
|
|
|
|
|
|
|
|
52 |
|
53 |
@spaces.GPU()
|
54 |
def chat_llama3_8b(message: str,
|
|
|
47 |
"""
|
48 |
|
49 |
# Load the tokenizer and model
|
50 |
+
tokenizer = AutoTokenizer.from_pretrained("google/gemma-2-2b-jpn-it")
|
51 |
+
model = AutoModelForCausalLM.from_pretrained(
|
52 |
+
"google/gemma-2-2b-jpn-it",
|
53 |
+
device_map="auto",
|
54 |
+
torch_dtype=torch.bfloat16,
|
55 |
+
)
|
56 |
|
57 |
@spaces.GPU()
|
58 |
def chat_llama3_8b(message: str,
|