Ufoptg commited on
Commit
b79ffd9
1 Parent(s): 2a67f81

Update main.py

Browse files
Files changed (1) hide show
  1. main.py +5 -1
main.py CHANGED
@@ -330,7 +330,11 @@ def gemini_oracle(item: GeminiPro):
330
  oracle_base=oracle_base
331
  )
332
  cybersecuritydb(item.user_id, item.mongo_url)
333
- answer, oracle_chat = geni._GeminiLatest__get_response_oracle(item.query)
 
 
 
 
334
  return SuccessResponse(
335
  status="True",
336
  randydev={
 
330
  oracle_base=oracle_base
331
  )
332
  cybersecuritydb(item.user_id, item.mongo_url)
333
+ if item.oracle_base == "Delete":
334
+ clearedhistory = geni._clear_oracle_history_in_db()
335
+ return SuccessResponse(status="True", randydev={"message": f"Oracle Status: {clearedhistory}")
336
+ else:
337
+ answer, oracle_chat = geni._GeminiLatest__get_response_oracle(item.query)
338
  return SuccessResponse(
339
  status="True",
340
  randydev={