Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -1,10 +1,12 @@
|
|
1 |
import gradio as gr
|
2 |
-
from transformers import
|
|
|
|
|
3 |
|
4 |
-
# Load the
|
5 |
model_name = "deepseek-ai/DeepSeek-V3"
|
6 |
tokenizer = AutoTokenizer.from_pretrained(model_name)
|
7 |
-
model =
|
8 |
|
9 |
def classify_text(text):
|
10 |
inputs = tokenizer(text, return_tensors="pt")
|
|
|
1 |
import gradio as gr
|
2 |
+
from transformers import AutoTokenizer, PreTrainedTokenizer
|
3 |
+
import torch
|
4 |
+
from custom_model import CustomModel
|
5 |
|
6 |
+
# Load the tokenizer and custom model
|
7 |
model_name = "deepseek-ai/DeepSeek-V3"
|
8 |
tokenizer = AutoTokenizer.from_pretrained(model_name)
|
9 |
+
model = CustomModel.from_pretrained(model_name)
|
10 |
|
11 |
def classify_text(text):
|
12 |
inputs = tokenizer(text, return_tensors="pt")
|