Skier8402 commited on
Commit
57176b4
·
verified ·
1 Parent(s): 46b4cad

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -4
app.py CHANGED
@@ -17,7 +17,6 @@ from langchain.memory import ConversationBufferMemory
17
  from langchain.chains import ConversationalRetrievalChain
18
  from htmlTemplates import css, bot_template, user_template
19
  from langchain.llms import HuggingFaceHub
20
- from huggingface_hub import InferenceApi
21
 
22
 
23
  def get_pdf_text(pdf_docs):
@@ -106,8 +105,8 @@ def get_conversation_chain(vectorstore):
106
  A conversational retrieval chain for generating responses.
107
 
108
  """
109
- llm = InferenceApi(
110
- repo_id="mistralai/Mixtral-8x22B-Instruct-v0.1",
111
  model_kwargs={"temperature": 0.5, "max_length": 1048},
112
  )
113
  # llm = ChatOpenAI(temperature=0, model="gpt-3.5-turbo-0613")
@@ -192,4 +191,4 @@ def main():
192
 
193
 
194
  if __name__ == "__main__":
195
- main()
 
17
  from langchain.chains import ConversationalRetrievalChain
18
  from htmlTemplates import css, bot_template, user_template
19
  from langchain.llms import HuggingFaceHub
 
20
 
21
 
22
  def get_pdf_text(pdf_docs):
 
105
  A conversational retrieval chain for generating responses.
106
 
107
  """
108
+ llm = HuggingFaceHub(
109
+ repo_id="mistralai/Mixtral-8x7B-Instruct-v0.1",
110
  model_kwargs={"temperature": 0.5, "max_length": 1048},
111
  )
112
  # llm = ChatOpenAI(temperature=0, model="gpt-3.5-turbo-0613")
 
191
 
192
 
193
  if __name__ == "__main__":
194
+ main()