derek-thomas HF staff commited on
Commit
9f9e321
1 Parent(s): f6070bd

Adding more logging

Browse files
Files changed (1) hide show
  1. app.py +2 -0
app.py CHANGED
@@ -31,10 +31,12 @@ def bot(history, system_prompt=""):
31
  top_k = 5
32
  query = history[-1][0]
33
 
 
34
  # Retrieve documents relevant to query
35
  document_start = perf_counter()
36
  documents = qd_retriever.retrieve(query, top_k=top_k)
37
  document_time = document_start - perf_counter()
 
38
 
39
  # Create Prompt
40
  prompt = template.render(documents=documents, query=query)
 
31
  top_k = 5
32
  query = history[-1][0]
33
 
34
+ logger.warning('Retrieving documents...')
35
  # Retrieve documents relevant to query
36
  document_start = perf_counter()
37
  documents = qd_retriever.retrieve(query, top_k=top_k)
38
  document_time = document_start - perf_counter()
39
+ logger.warning('Finished Retrieving documents...')
40
 
41
  # Create Prompt
42
  prompt = template.render(documents=documents, query=query)