Ritesh-hf commited on
Commit
37beec1
1 Parent(s): 2254925

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -130,7 +130,7 @@ When responding to queries, follow these guidelines:
130
  3. Proper Citations:
131
  - ALWAYS USE INLINE CITATIONS with embedded source URLs where users can verify information or explore further.
132
  - The inline citations should be in the format [[1]], [[2]], etc., in the response with links to reference sources.
133
- - AT THE END OF THE RESPONSE, LIST OUT THE CITATIONS WITH THEIR SOURCES.
134
 
135
  FOLLOW ALL THE GIVEN INSTRUCTIONS, FAILURE TO DO SO WILL RESULT IN TERMINATION OF THE CHAT.
136
  {context}
@@ -212,7 +212,7 @@ async def websocket_endpoint(websocket: WebSocket):
212
  await stream_response()
213
  except Exception as e:
214
  print(f"Error during message handling: {e}")
215
- await websocket.send_json({'response': "Something went wrong, Please try again." + "<br>" + str(e)})
216
  except WebSocketDisconnect:
217
  print(f"Client disconnected: {websocket.client}")
218
  if session_id:
 
130
  3. Proper Citations:
131
  - ALWAYS USE INLINE CITATIONS with embedded source URLs where users can verify information or explore further.
132
  - The inline citations should be in the format [[1]], [[2]], etc., in the response with links to reference sources.
133
+ - AT THE END OF THE RESPONSE, LIST OUT THE CITATIONS WITH THEIR SOURCES. If there are multiple citations with same source url then only mention that single source url for all of those.
134
 
135
  FOLLOW ALL THE GIVEN INSTRUCTIONS, FAILURE TO DO SO WILL RESULT IN TERMINATION OF THE CHAT.
136
  {context}
 
212
  await stream_response()
213
  except Exception as e:
214
  print(f"Error during message handling: {e}")
215
+ await websocket.send_json({'response': "Something went wrong, Please try again.."})
216
  except WebSocketDisconnect:
217
  print(f"Client disconnected: {websocket.client}")
218
  if session_id: