ranamhamoud commited on
Commit
2d42a30
·
verified ·
1 Parent(s): bc37c1b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -5
app.py CHANGED
@@ -99,7 +99,7 @@ def generate(
99
  final_story = "".join(outputs)
100
  try:
101
  saved_story = Story(message=message, content=final_story).save()
102
- yield f"Story saved with ID: {saved_story.story_id}"
103
  except Exception as e:
104
  yield f"Failed to save story: {str(e)}"
105
 
@@ -108,8 +108,8 @@ chat_interface = gr.ChatInterface(
108
  stop_btn=None,
109
  examples=[
110
  ["Can you explain briefly to me what is the Python programming language?"],
111
- ["I'm curious about Merge Sort."],
112
- ["Teach me about conditionals."]
113
  ],
114
  )
115
 
@@ -119,7 +119,7 @@ with gr.Blocks(css="style.css") as demo:
119
  gr.Markdown(LICENSE)
120
 
121
  if __name__ == "__main__":
122
- demo.queue(max_size=20).launch()
123
- demo.launch(share=True)
124
 
125
 
 
99
  final_story = "".join(outputs)
100
  try:
101
  saved_story = Story(message=message, content=final_story).save()
102
+ yield f"Story saved with ID: {saved_story.story_id}\n\n{final_story}"
103
  except Exception as e:
104
  yield f"Failed to save story: {str(e)}"
105
 
 
108
  stop_btn=None,
109
  examples=[
110
  ["Can you explain briefly to me what is the Python programming language?"],
111
+ ["Could you please provide an explanation about the concept of recursion?"],
112
+ ["Tell me more about Stacks."]
113
  ],
114
  )
115
 
 
119
  gr.Markdown(LICENSE)
120
 
121
  if __name__ == "__main__":
122
+ demo.launch(share=True, enable_queue=True, max_size=20)
123
+
124
 
125