Spaces:
Runtime error
Runtime error
fix collection clear
Browse files- app/rag.py +5 -6
app/rag.py
CHANGED
@@ -107,9 +107,8 @@ class ChatPDF:
|
|
107 |
return streaming_response
|
108 |
|
109 |
def clear(self):
|
110 |
-
|
111 |
-
|
112 |
-
|
113 |
-
|
114 |
-
|
115 |
-
self.nodes = []
|
|
|
107 |
return streaming_response
|
108 |
|
109 |
def clear(self):
|
110 |
+
self.client.delete_collection(collection_name="rag_documents")
|
111 |
+
self.pdf_count = 0
|
112 |
+
self.text_chunks = []
|
113 |
+
self.doc_ids = []
|
114 |
+
self.nodes = []
|
|