karwanjiru commited on
Commit
b96f71d
1 Parent(s): 33c9c73
Files changed (1) hide show
  1. app.py +7 -2
app.py CHANGED
@@ -24,6 +24,7 @@ def respond(message, history):
24
  )
25
 
26
  return response.choices[0].message['content']
 
27
  # Define the function to generate posts
28
  def generate_post(prompt):
29
  response = client.chat_completion(
@@ -79,7 +80,11 @@ with demo:
79
  )
80
  advanced_button = gr.Button("Show Advanced Settings")
81
  advanced_settings = gr.Column(visible=False)
82
-
 
 
 
 
83
 
84
  def toggle_advanced_settings():
85
  advanced_settings.visible = not advanced_settings.visible
@@ -111,4 +116,4 @@ with demo:
111
  moderate_image_button.click(moderate_image, uploaded_image, image_moderation_result)
112
 
113
  if __name__ == "__main__":
114
- demo.launch()
 
24
  )
25
 
26
  return response.choices[0].message['content']
27
+
28
  # Define the function to generate posts
29
  def generate_post(prompt):
30
  response = client.chat_completion(
 
80
  )
81
  advanced_button = gr.Button("Show Advanced Settings")
82
  advanced_settings = gr.Column(visible=False)
83
+ with advanced_settings:
84
+ chat_interface.additional_inputs[0].visible = True
85
+ chat_interface.additional_inputs[1].visible = True
86
+ chat_interface.additional_inputs[2].visible = True
87
+ chat_interface.additional_inputs[3].visible = True
88
 
89
  def toggle_advanced_settings():
90
  advanced_settings.visible = not advanced_settings.visible
 
116
  moderate_image_button.click(moderate_image, uploaded_image, image_moderation_result)
117
 
118
  if __name__ == "__main__":
119
+ demo.launch(debug=True)