Update app.py
Browse files
app.py
CHANGED
@@ -381,7 +381,7 @@ def create_interface() -> gr.Blocks:
|
|
381 |
pdf_input = gr.File(
|
382 |
label="Carregar PDF",
|
383 |
file_types=[".pdf"],
|
384 |
-
type="
|
385 |
)
|
386 |
question_input = gr.Textbox(
|
387 |
label="Sua Pergunta",
|
@@ -473,7 +473,15 @@ def create_interface() -> gr.Blocks:
|
|
473 |
def main():
|
474 |
"""Função principal"""
|
475 |
try:
|
476 |
-
# Configurar logging
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
477 |
logging.basicConfig(
|
478 |
level=logging.INFO,
|
479 |
format='%(asctime)s - %(name)s - %(levelname)s - %(message)s',
|
|
|
381 |
pdf_input = gr.File(
|
382 |
label="Carregar PDF",
|
383 |
file_types=[".pdf"],
|
384 |
+
type="filepath"
|
385 |
)
|
386 |
question_input = gr.Textbox(
|
387 |
label="Sua Pergunta",
|
|
|
473 |
def main():
|
474 |
"""Função principal"""
|
475 |
try:
|
476 |
+
# Configurar logging detalhado
|
477 |
+
logging.basicConfig(
|
478 |
+
level=logging.DEBUG, # Aumentado para DEBUG
|
479 |
+
format='%(asctime)s - %(name)s - %(levelname)s - %(pathname)s:%(lineno)d - %(message)s',
|
480 |
+
handlers=[
|
481 |
+
logging.StreamHandler(),
|
482 |
+
logging.FileHandler('qa_system_detailed.log')
|
483 |
+
]
|
484 |
+
)
|
485 |
logging.basicConfig(
|
486 |
level=logging.INFO,
|
487 |
format='%(asctime)s - %(name)s - %(levelname)s - %(message)s',
|