loubnabnl HF staff commited on
Commit
ccabd7d
·
1 Parent(s): 23e778d

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -199,9 +199,9 @@ if st.button("Generate code!", key=4):
199
  )
200
  for i in range(len(generations)):
201
  st.markdown(f"**{selected_models[i]}**")
202
- for i in range(len(generations)):
203
- if selected_models in generations[i].keys():
204
- st.code(generations[i][selected_models])
205
  if len(generations) < len(selected_models):
206
  st.markdown("<span style='color:red'>Warning: Some models run into timeout, you can try generating code using the original subspaces: [InCoder](https://huggingface.co/spaces/loubnabnl/incoder-subspace), [CodeGen](https://huggingface.co/spaces/loubnabnl/codegen-subspace), [CodeParrot](https://huggingface.co/spaces/loubnabnl/codeparrot-subspace)</span>", unsafe_allow_html=True)
207
 
 
199
  )
200
  for i in range(len(generations)):
201
  st.markdown(f"**{selected_models[i]}**")
202
+ for j in range(len(generations)):
203
+ if selected_models[i] in generations[j].keys():
204
+ st.code(generations[j][selected_models[i]])
205
  if len(generations) < len(selected_models):
206
  st.markdown("<span style='color:red'>Warning: Some models run into timeout, you can try generating code using the original subspaces: [InCoder](https://huggingface.co/spaces/loubnabnl/incoder-subspace), [CodeGen](https://huggingface.co/spaces/loubnabnl/codegen-subspace), [CodeParrot](https://huggingface.co/spaces/loubnabnl/codeparrot-subspace)</span>", unsafe_allow_html=True)
207