Heiko Hotz commited on
Commit
661c2a9
1 Parent(s): 79c52cc

initial commit

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -138,7 +138,7 @@ if st.button('Analyze'):
138
  else:
139
  if number_results == '1':
140
  answer = predictions['0']
141
- st.text_area(label="Answer", value=f"{answer}")
142
  else:
143
  answer = ""
144
  with open("nbest.json") as jf:
@@ -146,7 +146,7 @@ if st.button('Analyze'):
146
  for i in range(int(number_results)):
147
  answer += f"Answer {i+1}: {data['0'][i]['text']} -- \n"
148
  answer += f"Probability: {round(data['0'][i]['probability']*100,1)}%\n\n"
149
- st.success(answer)
150
- st.success("Successfully processed contract!")
151
  else:
152
  st.write("Unable to call model, please select question and contract")
 
138
  else:
139
  if number_results == '1':
140
  answer = predictions['0']
141
+ # st.text_area(label="Answer", value=f"{answer}")
142
  else:
143
  answer = ""
144
  with open("nbest.json") as jf:
 
146
  for i in range(int(number_results)):
147
  answer += f"Answer {i+1}: {data['0'][i]['text']} -- \n"
148
  answer += f"Probability: {round(data['0'][i]['probability']*100,1)}%\n\n"
149
+ st.success(answer)
150
+ # st.success("Successfully processed contract!")
151
  else:
152
  st.write("Unable to call model, please select question and contract")