Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -47,7 +47,7 @@ def get_conversational_chain():
|
|
47 |
"""
|
48 |
# model = ChatGoogleGenerativeAI(model="gemini-pro", temperature=0.1)
|
49 |
model = HuggingFaceHub(repo_id="google/gemma-1.1-7b-it",
|
50 |
-
model_kwargs={"temperature": 0.2,"max_new_tokens":512
|
51 |
prompt = PromptTemplate(template=prompt_template, input_variables=["context", "question"])
|
52 |
chain = LLMChain(llm=model, chain_type="stuff", prompt=prompt)
|
53 |
return chain
|
|
|
47 |
"""
|
48 |
# model = ChatGoogleGenerativeAI(model="gemini-pro", temperature=0.1)
|
49 |
model = HuggingFaceHub(repo_id="google/gemma-1.1-7b-it",
|
50 |
+
model_kwargs={"temperature": 0.2,"max_new_tokens":512, "return_only_answer":True})
|
51 |
prompt = PromptTemplate(template=prompt_template, input_variables=["context", "question"])
|
52 |
chain = LLMChain(llm=model, chain_type="stuff", prompt=prompt)
|
53 |
return chain
|