Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -2,12 +2,12 @@ import gradio as gr
|
|
2 |
import torch
|
3 |
from transformers import AutoTokenizer, AutoModelForSequenceClassification
|
4 |
|
5 |
-
# Load the
|
6 |
-
model_path = 'viv/AIKIA
|
7 |
-
tokenizer = AutoTokenizer.from_pretrained(
|
8 |
|
9 |
-
#
|
10 |
-
model = AutoModelForSequenceClassification.from_pretrained(model_path
|
11 |
|
12 |
# Preprocessing function for Greek text
|
13 |
def preprocessing_greek(text):
|
|
|
2 |
import torch
|
3 |
from transformers import AutoTokenizer, AutoModelForSequenceClassification
|
4 |
|
5 |
+
# Load the model and tokenizer from Hugging Face Hub
|
6 |
+
model_path = 'viv/AIKIA' # Hugging Face model ID
|
7 |
+
tokenizer = AutoTokenizer.from_pretrained(model_path) # Tokenizer from Hugging Face
|
8 |
|
9 |
+
# Load the model from Hugging Face repository
|
10 |
+
model = AutoModelForSequenceClassification.from_pretrained(model_path)
|
11 |
|
12 |
# Preprocessing function for Greek text
|
13 |
def preprocessing_greek(text):
|