Update app.py
Browse files
app.py
CHANGED
|
@@ -34,45 +34,44 @@ def responder(mensagem):
|
|
| 34 |
app = gr.Interface(
|
| 35 |
fn=responder,
|
| 36 |
inputs=gr.Textbox(placeholder="Digite sua pergunta aqui", label="Mensagem", lines=2),
|
| 37 |
-
outputs=gr.Textbox(label="Resposta do
|
| 38 |
-
title="
|
| 39 |
description="Teste do modelo DeepSeek via OpenRouter com retorno direto.",
|
| 40 |
-
theme="
|
| 41 |
css="""
|
| 42 |
-
/*
|
| 43 |
.gradio-container {
|
| 44 |
-
background-color: #
|
| 45 |
color: #333;
|
| 46 |
font-family: 'Arial', sans-serif;
|
| 47 |
}
|
| 48 |
|
| 49 |
-
|
| 50 |
-
|
| 51 |
-
|
| 52 |
-
|
| 53 |
-
padding: 10px;
|
| 54 |
-
font-size: 14px;
|
| 55 |
}
|
| 56 |
|
| 57 |
-
|
| 58 |
-
|
| 59 |
-
|
| 60 |
}
|
| 61 |
|
| 62 |
-
|
| 63 |
-
|
| 64 |
-
|
|
|
|
| 65 |
border-radius: 5px;
|
| 66 |
-
padding:
|
| 67 |
font-size: 14px;
|
| 68 |
-
color: #333;
|
| 69 |
}
|
| 70 |
|
|
|
|
| 71 |
.gradio-button {
|
| 72 |
-
background-color: #
|
| 73 |
-
color:
|
| 74 |
font-size: 14px;
|
| 75 |
-
padding: 10px;
|
| 76 |
border-radius: 5px;
|
| 77 |
}
|
| 78 |
|
|
@@ -80,12 +79,19 @@ app = gr.Interface(
|
|
| 80 |
background-color: #005bb5;
|
| 81 |
}
|
| 82 |
|
| 83 |
-
|
| 84 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 85 |
}
|
| 86 |
|
| 87 |
-
|
| 88 |
-
|
|
|
|
| 89 |
}
|
| 90 |
"""
|
| 91 |
)
|
|
|
|
| 34 |
app = gr.Interface(
|
| 35 |
fn=responder,
|
| 36 |
inputs=gr.Textbox(placeholder="Digite sua pergunta aqui", label="Mensagem", lines=2),
|
| 37 |
+
outputs=gr.Textbox(label="Resposta do Chatbot", lines=4),
|
| 38 |
+
title="Meu Primeiro Chatbot com IA Generativa",
|
| 39 |
description="Teste do modelo DeepSeek via OpenRouter com retorno direto.",
|
| 40 |
+
theme="huggingface", # Usando o tema padrão do Hugging Face
|
| 41 |
css="""
|
| 42 |
+
/* Estilo de fundo */
|
| 43 |
.gradio-container {
|
| 44 |
+
background-color: #F7F8FB;
|
| 45 |
color: #333;
|
| 46 |
font-family: 'Arial', sans-serif;
|
| 47 |
}
|
| 48 |
|
| 49 |
+
/* Estilo do título */
|
| 50 |
+
.gradio-title {
|
| 51 |
+
color: #0066CC;
|
| 52 |
+
font-weight: bold;
|
|
|
|
|
|
|
| 53 |
}
|
| 54 |
|
| 55 |
+
/* Estilo da descrição */
|
| 56 |
+
.gradio-description {
|
| 57 |
+
color: #666;
|
| 58 |
}
|
| 59 |
|
| 60 |
+
/* Estilo dos campos de entrada */
|
| 61 |
+
.gradio-input {
|
| 62 |
+
background-color: #FFFFFF;
|
| 63 |
+
border: 2px solid #B3B3B3;
|
| 64 |
border-radius: 5px;
|
| 65 |
+
padding: 12px;
|
| 66 |
font-size: 14px;
|
|
|
|
| 67 |
}
|
| 68 |
|
| 69 |
+
/* Estilo do botão */
|
| 70 |
.gradio-button {
|
| 71 |
+
background-color: #0066CC;
|
| 72 |
+
color: #FFFFFF;
|
| 73 |
font-size: 14px;
|
| 74 |
+
padding: 10px 20px;
|
| 75 |
border-radius: 5px;
|
| 76 |
}
|
| 77 |
|
|
|
|
| 79 |
background-color: #005bb5;
|
| 80 |
}
|
| 81 |
|
| 82 |
+
/* Estilo das saídas */
|
| 83 |
+
.gradio-output {
|
| 84 |
+
background-color: #FFFFFF;
|
| 85 |
+
border: 2px solid #B3B3B3;
|
| 86 |
+
border-radius: 5px;
|
| 87 |
+
padding: 12px;
|
| 88 |
+
font-size: 14px;
|
| 89 |
+
color: #333;
|
| 90 |
}
|
| 91 |
|
| 92 |
+
/* Definição do estilo para foco */
|
| 93 |
+
.gradio-input:focus {
|
| 94 |
+
border-color: #0066CC;
|
| 95 |
}
|
| 96 |
"""
|
| 97 |
)
|