g8a9 commited on
Commit
a67a49a
1 Parent(s): 7d78d64

change model and req

Browse files
Files changed (2) hide show
  1. requirements.txt +2 -1
  2. single.py +2 -2
requirements.txt CHANGED
@@ -1,2 +1,3 @@
1
  transformers==4.20.1
2
- ferret-xai>=0.2.0
 
 
1
  transformers==4.20.1
2
+ ferret-xai>=0.2.0
3
+ sentencepiece
single.py CHANGED
@@ -4,7 +4,7 @@ from transformers import AutoModelForSequenceClassification, AutoTokenizer, Auto
4
  from ferret import Benchmark
5
  from torch.nn.functional import softmax
6
 
7
- DEFAULT_MODEL = "distilbert-base-uncased-finetuned-sst-2-english"
8
 
9
 
10
  @st.cache()
@@ -60,7 +60,7 @@ def body():
60
  help="Positional index of your target class.",
61
  )
62
 
63
- text = st.text_input("Text")
64
 
65
  compute = st.button("Compute")
66
 
 
4
  from ferret import Benchmark
5
  from torch.nn.functional import softmax
6
 
7
+ DEFAULT_MODEL = "cardiffnlp/twitter-xlm-roberta-base-sentiment"
8
 
9
 
10
  @st.cache()
 
60
  help="Positional index of your target class.",
61
  )
62
 
63
+ text = st.text_input("Text", "I love your style!")
64
 
65
  compute = st.button("Compute")
66