Spaces:
Running
Running
INIFanalitica
commited on
Commit
•
ef6f36a
1
Parent(s):
4409e62
Update app.py
Browse files
app.py
CHANGED
@@ -2,7 +2,7 @@ import os
|
|
2 |
import streamlit as st
|
3 |
import google.generativeai as genai
|
4 |
|
5 |
-
#
|
6 |
|
7 |
error_flag = False # Global variable to track error display
|
8 |
|
@@ -73,8 +73,11 @@ def principal():
|
|
73 |
model
|
74 |
)
|
75 |
|
76 |
-
#
|
77 |
-
|
|
|
|
|
|
|
78 |
|
79 |
# Actualiza la barra de progreso
|
80 |
barra_progreso_chunks.progress((i + 1) / len(chunks))
|
|
|
2 |
import streamlit as st
|
3 |
import google.generativeai as genai
|
4 |
|
5 |
+
# TERMINATOR
|
6 |
|
7 |
error_flag = False # Global variable to track error display
|
8 |
|
|
|
73 |
model
|
74 |
)
|
75 |
|
76 |
+
# Decodifica el texto de ASCII a lenguaje legible por humano
|
77 |
+
respuesta_decodificada = respuesta_bot.encode('utf-8').decode('unicode_escape')
|
78 |
+
|
79 |
+
# Agrega la respuesta formateada decodificada a la salida
|
80 |
+
salida_formateada += respuesta_decodificada + "\n"
|
81 |
|
82 |
# Actualiza la barra de progreso
|
83 |
barra_progreso_chunks.progress((i + 1) / len(chunks))
|