twimbit-ai commited on
Commit
d45a892
·
verified ·
1 Parent(s): becfb2f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -3
app.py CHANGED
@@ -41,8 +41,7 @@ def get_web_search_you(query):
41
  def predict(message, history, _n_web_search, _strategy):
42
  # docs = get_web_search_you(message)
43
 
44
- with open('history.json', mode='a', encoding='utf-8') as f:
45
- json.dump(history, f)
46
  docs = get_docs_from_web(message, history[-1:], _n_web_search, _strategy)
47
  partial_message = ''
48
  information = ''
@@ -106,4 +105,4 @@ strategy = gr.Radio(["Deep", "Normal"], label="Strategy", value="Normal",
106
 
107
  app = gr.ChatInterface(predict, additional_inputs=[n_web_search, strategy])
108
  app.queue(default_concurrency_limit=5)
109
- app.launch(debug=True, share=False)
 
41
  def predict(message, history, _n_web_search, _strategy):
42
  # docs = get_web_search_you(message)
43
 
44
+ print(history)
 
45
  docs = get_docs_from_web(message, history[-1:], _n_web_search, _strategy)
46
  partial_message = ''
47
  information = ''
 
105
 
106
  app = gr.ChatInterface(predict, additional_inputs=[n_web_search, strategy])
107
  app.queue(default_concurrency_limit=5)
108
+ app.launch(debug=True, share=True)