Spaces:
Sleeping
Sleeping
Commit
•
df9ca2e
1
Parent(s):
e2ee2f6
Update app.py
Browse files
app.py
CHANGED
@@ -12,9 +12,18 @@ from langchain.chains import ConversationalRetrievalChain
|
|
12 |
from langchain.chat_models import ChatOpenAI
|
13 |
from htmlTemplates import bot_template, user_template, css
|
14 |
from transformers import pipeline
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
15 |
import sys
|
16 |
import os
|
17 |
from dotenv import load_dotenv
|
|
|
18 |
|
19 |
HUGGINGFACEHUB_API_TOKEN = os.getenv("HUGGINGFACEHUB_API_TOKEN")
|
20 |
repo_id=os.getenv("repo_id")
|
|
|
12 |
from langchain.chat_models import ChatOpenAI
|
13 |
from htmlTemplates import bot_template, user_template, css
|
14 |
from transformers import pipeline
|
15 |
+
|
16 |
+
import pinecone
|
17 |
+
from langchain.embeddings.openai import OpenAIEmbeddings
|
18 |
+
from langchain.vectorstores import Pinecone
|
19 |
+
from langchain import PromptTemplate
|
20 |
+
from langchain.chains.question_answering import load_qa_chain
|
21 |
+
#from langchain.chains.summarize import load_summarize_chain
|
22 |
+
import nltk
|
23 |
import sys
|
24 |
import os
|
25 |
from dotenv import load_dotenv
|
26 |
+
load_dotenv()
|
27 |
|
28 |
HUGGINGFACEHUB_API_TOKEN = os.getenv("HUGGINGFACEHUB_API_TOKEN")
|
29 |
repo_id=os.getenv("repo_id")
|