Browse Source

Update main.py

donzito 2 năm trước cách đây
mục cha
commit
6d617d6748
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      chatbot/main.py

+ 1 - 1
chatbot/main.py

@@ -31,7 +31,7 @@ class Chatbot():
         # load index
         self.ai_storage_context = None
         self.ai_index = None
-        base_dir = settings.BASE_DIR + '/storage'
+        base_dir = os.path.join(settings.BASE_DIR, 'storage')
         try:
             self.ai_storage_context = StorageContext.from_defaults(persist_dir=base_dir)
             self.ai_index = load_index_from_storage(self.ai_storage_context)