Spaces:
Sleeping
Sleeping
commit
#1
by Rahul-8853 - opened
app.py
CHANGED
|
@@ -3,7 +3,7 @@ from transformers import AutoModelForSequenceClassification, AutoTokenizer
|
|
| 3 |
import torch
|
| 4 |
|
| 5 |
# Load the model and tokenizer from Hugging Face
|
| 6 |
-
model_name = "
|
| 7 |
model = AutoModelForSequenceClassification.from_pretrained(model_name)
|
| 8 |
tokenizer = AutoTokenizer.from_pretrained(model_name)
|
| 9 |
|
|
@@ -33,3 +33,4 @@ if st.button("Predict"):
|
|
| 33 |
st.write(f"{label}: {score:.4f}")
|
| 34 |
else:
|
| 35 |
st.write("Please enter some text to get predictions.")
|
|
|
|
|
|
| 3 |
import torch
|
| 4 |
|
| 5 |
# Load the model and tokenizer from Hugging Face
|
| 6 |
+
model_name = "KevSun/Personality_LM"
|
| 7 |
model = AutoModelForSequenceClassification.from_pretrained(model_name)
|
| 8 |
tokenizer = AutoTokenizer.from_pretrained(model_name)
|
| 9 |
|
|
|
|
| 33 |
st.write(f"{label}: {score:.4f}")
|
| 34 |
else:
|
| 35 |
st.write("Please enter some text to get predictions.")
|
| 36 |
+
|