Spaces:
Sleeping
Sleeping
Update initialize.py
Browse files- initialize.py +5 -1
initialize.py
CHANGED
@@ -35,7 +35,11 @@ def define_components(document_store, api_key):
|
|
35 |
|
36 |
generator = HuggingFaceTGIGenerator(
|
37 |
model="mistralai/Mistral-7B-Instruct-v0.1",
|
38 |
-
token=Secret.from_token(api_key)
|
|
|
|
|
|
|
|
|
39 |
)
|
40 |
generator.warm_up()
|
41 |
return retriever, prompt_builder, generator
|
|
|
35 |
|
36 |
generator = HuggingFaceTGIGenerator(
|
37 |
model="mistralai/Mistral-7B-Instruct-v0.1",
|
38 |
+
token=Secret.from_token(api_key),
|
39 |
+
generation_kwargs = {
|
40 |
+
'max_new_tokens':100,
|
41 |
+
'temperature':0.7
|
42 |
+
}
|
43 |
)
|
44 |
generator.warm_up()
|
45 |
return retriever, prompt_builder, generator
|