mery22 commited on
Commit
0000cad
1 Parent(s): 0b0e73b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -32,7 +32,7 @@ retriever = db.as_retriever(
32
  prompt_template = """
33
  ### [INST]
34
  Instruction: You are a Q&A assistant. Your goal is to answer questions as accurately as possible based on the instructions and context provided without using prior knowledge.You answer in FRENCH
35
- Analyse carefully the context and provide a direct answer based on the context. If the user said Bonjour you answer with Hi! comment puis-je vous aider?
36
  Answer in french only
37
  {context}
38
  Vous devez répondre aux questions en français.
@@ -45,10 +45,10 @@ Answer in french only
45
 
46
  """
47
 
48
- repo_id = "mistralai/Mistral-7B-Instruct-v0.2"
49
 
50
  mistral_llm = HuggingFaceEndpoint(
51
- repo_id=repo_id, max_length=512, temperature=0.05, huggingfacehub_api_token=st.secrets["HF_TOKEN"]
52
  )
53
 
54
  # Create prompt from prompt template
 
32
  prompt_template = """
33
  ### [INST]
34
  Instruction: You are a Q&A assistant. Your goal is to answer questions as accurately as possible based on the instructions and context provided without using prior knowledge.You answer in FRENCH
35
+ Analyse carefully the context and provide a direct answer based on the context. If the user said Bonjour you only answer with with Hi! comment puis-je vous aider?
36
  Answer in french only
37
  {context}
38
  Vous devez répondre aux questions en français.
 
45
 
46
  """
47
 
48
+ repo_id = "mistralai/Mistral-7B-Instruct-v0.3"
49
 
50
  mistral_llm = HuggingFaceEndpoint(
51
+ repo_id=repo_id, max_length=1024, temperature=0.05, huggingfacehub_api_token=st.secrets["HF_TOKEN"]
52
  )
53
 
54
  # Create prompt from prompt template