Spaces:
Sleeping
Sleeping
Commit
·
e014d40
1
Parent(s):
618bce1
added comments
Browse files- chatbot.py +2 -2
chatbot.py
CHANGED
@@ -16,7 +16,7 @@ class ChatBot():
|
|
16 |
'https://noqs.in/internships/'
|
17 |
]
|
18 |
|
19 |
-
url_loader = UnstructuredURLLoader(urls=urls)
|
20 |
url_data = url_loader.load()
|
21 |
|
22 |
text_loader = TextLoader('data.txt', encoding = 'UTF-8')
|
@@ -29,7 +29,7 @@ class ChatBot():
|
|
29 |
self.docs = url_docs + text_docs
|
30 |
|
31 |
def start_embeddings(self):
|
32 |
-
embeddings = HuggingFaceEmbeddings()
|
33 |
load_dotenv()
|
34 |
# Initialize Pinecone client
|
35 |
pc = Pinecone(
|
|
|
16 |
'https://noqs.in/internships/'
|
17 |
]
|
18 |
|
19 |
+
url_loader = UnstructuredURLLoader(urls=urls) #' can also use Web Base Loader
|
20 |
url_data = url_loader.load()
|
21 |
|
22 |
text_loader = TextLoader('data.txt', encoding = 'UTF-8')
|
|
|
29 |
self.docs = url_docs + text_docs
|
30 |
|
31 |
def start_embeddings(self):
|
32 |
+
embeddings = HuggingFaceEmbeddings() # uses sentence based embddings for ingestion and retrieval
|
33 |
load_dotenv()
|
34 |
# Initialize Pinecone client
|
35 |
pc = Pinecone(
|