Spaces:
Sleeping
Sleeping
xavierbarbier
commited on
Update app.py
Browse files
app.py
CHANGED
@@ -17,7 +17,7 @@ model = model = GPT4All(model_name, model_path, allow_download = False, device="
|
|
17 |
|
18 |
|
19 |
model.config["promptTemplate"] = "[INST] {0} [/INST]"
|
20 |
-
model.config["systemPrompt"] = "Tu es un assitant et
|
21 |
model._is_chat_session_activated = False
|
22 |
|
23 |
max_new_tokens = 2048
|
@@ -40,7 +40,7 @@ def extract_text(file):
|
|
40 |
|
41 |
def summarise(text):
|
42 |
|
43 |
-
prompt =
|
44 |
|
45 |
|
46 |
outputs = model.generate(prompt=prompt, temp=0.5, top_k = 40, top_p = 1, max_tokens = max_new_tokens)
|
|
|
17 |
|
18 |
|
19 |
model.config["promptTemplate"] = "[INST] {0} [/INST]"
|
20 |
+
model.config["systemPrompt"] = "Tu es un assitant et ta tâche est de résumer des texte en français"
|
21 |
model._is_chat_session_activated = False
|
22 |
|
23 |
max_new_tokens = 2048
|
|
|
40 |
|
41 |
def summarise(text):
|
42 |
|
43 |
+
prompt = text
|
44 |
|
45 |
|
46 |
outputs = model.generate(prompt=prompt, temp=0.5, top_k = 40, top_p = 1, max_tokens = max_new_tokens)
|