bupa1018 commited on
Commit
72d6cbc
·
verified ·
1 Parent(s): 9f6f379

Update kadiApy_ragchain.py

Browse files
Files changed (1) hide show
  1. kadiApy_ragchain.py +1 -11
kadiApy_ragchain.py CHANGED
@@ -27,9 +27,7 @@ class KadiApyRagchain:
27
 
28
  code_contexts = self.retrieve_contexts(rewritten_query, k=3, filter={"usage": code_library_usage_prediction})
29
  doc_contexts = self.retrieve_contexts(query, k=2, filter={"dataset_category": "kadi_apy_docs"})
30
-
31
-
32
-
33
  # Format contexts
34
  print("Formatting docs:")
35
  formatted_doc_contexts = self.format_documents(doc_contexts)
@@ -41,14 +39,6 @@ class KadiApyRagchain:
41
  #response = self.generate_response(query, chat_history, formatted_contexts)
42
  return response
43
 
44
-
45
-
46
- def get_history(self):
47
- """
48
- Retrieve the entire conversation history.
49
- """
50
- return self.conversation
51
-
52
  def rewrite_query(self, query):
53
  """
54
  Rewrite the user's query to align with the language and structure of the library's methods and documentation.
 
27
 
28
  code_contexts = self.retrieve_contexts(rewritten_query, k=3, filter={"usage": code_library_usage_prediction})
29
  doc_contexts = self.retrieve_contexts(query, k=2, filter={"dataset_category": "kadi_apy_docs"})
30
+
 
 
31
  # Format contexts
32
  print("Formatting docs:")
33
  formatted_doc_contexts = self.format_documents(doc_contexts)
 
39
  #response = self.generate_response(query, chat_history, formatted_contexts)
40
  return response
41
 
 
 
 
 
 
 
 
 
42
  def rewrite_query(self, query):
43
  """
44
  Rewrite the user's query to align with the language and structure of the library's methods and documentation.