Commit
·
afd47cf
1
Parent(s):
9874d12
Update app.py
Browse files
app.py
CHANGED
@@ -2,7 +2,7 @@ import time
|
|
2 |
import streamlit as st
|
3 |
import torch
|
4 |
import string
|
5 |
-
|
6 |
|
7 |
from transformers import BertTokenizer, BertForMaskedLM
|
8 |
|
@@ -91,8 +91,8 @@ try:
|
|
91 |
start = time.time()
|
92 |
try:
|
93 |
res = get_bert_prediction(input_text,top_k)
|
94 |
-
st.
|
95 |
-
st.json(
|
96 |
|
97 |
except Exception as e:
|
98 |
st.error("Some error occurred during prediction" + str(e))
|
|
|
2 |
import streamlit as st
|
3 |
import torch
|
4 |
import string
|
5 |
+
|
6 |
|
7 |
from transformers import BertTokenizer, BertForMaskedLM
|
8 |
|
|
|
91 |
start = time.time()
|
92 |
try:
|
93 |
res = get_bert_prediction(input_text,top_k)
|
94 |
+
st.caption("Results in JSON")
|
95 |
+
st.json(res)
|
96 |
|
97 |
except Exception as e:
|
98 |
st.error("Some error occurred during prediction" + str(e))
|