Spaces:
Runtime error
Runtime error
artificialguybr
commited on
Commit
•
329db81
1
Parent(s):
9fcf5b1
Update app.py
Browse files
app.py
CHANGED
@@ -3,11 +3,8 @@ import re
|
|
3 |
from transformers import AutoModelForCausalLM, AutoTokenizer
|
4 |
|
5 |
model_name_or_path = "teknium/OpenHermes-2-Mistral-7B"
|
6 |
-
model = AutoModelForCausalLM.from_pretrained(model_name_or_path,device_map="auto",
|
7 |
-
|
8 |
-
load_in_8bit=True,
|
9 |
-
revision="main")
|
10 |
-
tokenizer = AutoTokenizer.from_pretrained(model_name_or_path, use_fast=True)
|
11 |
|
12 |
BASE_SYSTEM_MESSAGE = "I carefully provide accurate, factual, thoughtful, nuanced answers and am brilliant at reasoning."
|
13 |
|
|
|
3 |
from transformers import AutoModelForCausalLM, AutoTokenizer
|
4 |
|
5 |
model_name_or_path = "teknium/OpenHermes-2-Mistral-7B"
|
6 |
+
model = AutoModelForCausalLM.from_pretrained(model_name_or_path,device_map="auto", trust_remote_code=False, load_in_8bit=True, revision="main")
|
7 |
+
tokenizer = AutoTokenizer.from_pretrained(model_name_or_path)
|
|
|
|
|
|
|
8 |
|
9 |
BASE_SYSTEM_MESSAGE = "I carefully provide accurate, factual, thoughtful, nuanced answers and am brilliant at reasoning."
|
10 |
|