Vihang28 commited on
Commit
b7b6034
·
verified ·
1 Parent(s): 58cc64e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -5
app.py CHANGED
@@ -70,11 +70,10 @@ def message_and_history(img, input, history, api_key):
70
  s.append(input)
71
  inp = ' '.join(s)
72
  output = api_calling(img,inp, api_key)
73
- # if len(input) == 0:
74
- # input = "How many tiles need replacement?"
75
- # history.append((input, output))
76
- # else:
77
- # history.append((input, output))
78
  return history, history
79
 
80
  block = gr.Blocks(theme=gr.themes.Glass(primary_hue="slate"))
 
70
  s.append(input)
71
  inp = ' '.join(s)
72
  output = api_calling(img,inp, api_key)
73
+ if len(input) == 0:
74
+ history.append(output)
75
+ else:
76
+ history.append((input, output))
 
77
  return history, history
78
 
79
  block = gr.Blocks(theme=gr.themes.Glass(primary_hue="slate"))