Dua Rajper commited on
Update app.py
Browse files
app.py
CHANGED
|
@@ -48,7 +48,8 @@ def get_vectorstore(text_chunks):
|
|
| 48 |
# Function to set up the conversational retrieval chain
|
| 49 |
def get_conversation_chain(vectorstore):
|
| 50 |
try:
|
| 51 |
-
|
|
|
|
| 52 |
memory = ConversationBufferMemory(memory_key='chat_history', return_messages=True)
|
| 53 |
|
| 54 |
conversation_chain = ConversationalRetrievalChain.from_llm(
|
|
|
|
| 48 |
# Function to set up the conversational retrieval chain
|
| 49 |
def get_conversation_chain(vectorstore):
|
| 50 |
try:
|
| 51 |
+
groq_api_key = os.getenv("GROQ_API_KEY")
|
| 52 |
+
llm = ChatGroq(model="llama-3.3-70b-versatile", temperature=0.5, api_key=groq_api_key)
|
| 53 |
memory = ConversationBufferMemory(memory_key='chat_history', return_messages=True)
|
| 54 |
|
| 55 |
conversation_chain = ConversationalRetrievalChain.from_llm(
|