sharsh02 commited on
Commit
5696f45
1 Parent(s): a461cd7

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -5
app.py CHANGED
@@ -363,10 +363,10 @@ def generate_final_response(prompt, history):
363
  yield output
364
  except StopAsyncIteration:
365
  yield "Sorry, could you provide more details to clarify your query"
366
- except:
367
- yield "Sorry, your query couldn't be processed. Retry with correct name of stock"
368
- except:
369
- yield "Connection couldn't be established with LLM, Model might be overloaded!"
370
 
371
  def generate_function_call(prompt):
372
  # temperature = float(temperature)
@@ -443,7 +443,7 @@ demo = gr.ChatInterface(
443
  fn=generate_final_response,
444
  examples=["Any updates on Polycab"],
445
  chatbot=my_chatbot,
446
- title='<span style="font-family: Helvetica; font-size: 40px; color: green;">💲tockX</span>',
447
  theme=theme,
448
  js= js_func,
449
  css = """.gradio-container {
 
363
  yield output
364
  except StopAsyncIteration:
365
  yield "Sorry, could you provide more details to clarify your query"
366
+ except Exception as e:
367
+ yield f"Sorry, your query couldn't be processed. Retry with correct name of stock - An error occurred: {e}"
368
+ except Exception as e:
369
+ yield f"Connection couldn't be established with LLM, Model might be overloaded! - - An error occurred: {e}"
370
 
371
  def generate_function_call(prompt):
372
  # temperature = float(temperature)
 
443
  fn=generate_final_response,
444
  examples=["Any updates on Polycab"],
445
  chatbot=my_chatbot,
446
+ title='<span style="font-family: Helvetica; font-size: 40px; color: green;">StockX</span>',
447
  theme=theme,
448
  js= js_func,
449
  css = """.gradio-container {