CosmoAI commited on
Commit
ae690b5
·
verified ·
1 Parent(s): 95a65b5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -113,7 +113,9 @@ for question in ["What is karma?", "Who is Arjuna?"]:
113
  # ]
114
  from transformers import BertTokenizer, TFBertForQuestionAnswering
115
  from transformers import AdamW # Optimizer (optional)
116
- from transformers import SquadLoss # Loss function (optional)
 
 
117
 
118
  # Load pre-trained model and tokenizer
119
  tokenizer = BertTokenizer.from_pretrained('bert-base-uncased')
 
113
  # ]
114
  from transformers import BertTokenizer, TFBertForQuestionAnswering
115
  from transformers import AdamW # Optimizer (optional)
116
+ # from transformers import SquadLoss # Loss function (optional)
117
+ from transformers.models.squad import SquadLoss
118
+
119
 
120
  # Load pre-trained model and tokenizer
121
  tokenizer = BertTokenizer.from_pretrained('bert-base-uncased')