Spaces:
Sleeping
Sleeping
Pclanglais
commited on
Commit
•
a0503fe
1
Parent(s):
1995166
Update app.py
Browse files
app.py
CHANGED
@@ -137,7 +137,12 @@ class MistralChatBot:
|
|
137 |
batch_prompts = [editorial_text]
|
138 |
|
139 |
out = token_classifier(batch_prompts)
|
140 |
-
|
|
|
|
|
|
|
|
|
|
|
141 |
generated_text = f'{css}<h2 style="text-align:center">Réponse</h2>\n<div class="generation">{out}</div>'
|
142 |
return generated_text
|
143 |
|
|
|
137 |
batch_prompts = [editorial_text]
|
138 |
|
139 |
out = token_classifier(batch_prompts)
|
140 |
+
classified_list = []
|
141 |
+
for classification in out:
|
142 |
+
df = pd.DataFrame(classification)
|
143 |
+
|
144 |
+
classified_list = pd.concat(classified_list)
|
145 |
+
out = transform_chunks(pd.concat(classified_list))
|
146 |
generated_text = f'{css}<h2 style="text-align:center">Réponse</h2>\n<div class="generation">{out}</div>'
|
147 |
return generated_text
|
148 |
|