Spaces:
Runtime error
Runtime error
acecalisto3
commited on
Update app.py
Browse files
app.py
CHANGED
@@ -6,6 +6,7 @@ import datetime
|
|
6 |
import csv
|
7 |
import threading
|
8 |
import re
|
|
|
9 |
from urllib.parse import urlparse
|
10 |
|
11 |
import pandas as pd
|
@@ -1168,7 +1169,9 @@ def load_model():
|
|
1168 |
"""
|
1169 |
model_name = "mistralai/Mixtral-8x7B-Instruct-v0.1"
|
1170 |
try:
|
1171 |
-
tokenizer
|
|
|
|
|
1172 |
model = AutoModelForSeq2SeqLM.from_pretrained(model_name)
|
1173 |
pipe = pipeline(
|
1174 |
"text-generation",
|
|
|
6 |
import csv
|
7 |
import threading
|
8 |
import re
|
9 |
+
import unittest
|
10 |
from urllib.parse import urlparse
|
11 |
|
12 |
import pandas as pd
|
|
|
1169 |
"""
|
1170 |
model_name = "mistralai/Mixtral-8x7B-Instruct-v0.1"
|
1171 |
try:
|
1172 |
+
# Load tokenizer with warning suppression
|
1173 |
+
tokenizer = AutoTokenizer.from_pretrained("mistralai/Mixtral-8x7B-Instruct-v0.1", clean_up_tokenization_spaces=True)
|
1174 |
+
|
1175 |
model = AutoModelForSeq2SeqLM.from_pretrained(model_name)
|
1176 |
pipe = pipeline(
|
1177 |
"text-generation",
|