DRDELATV commited on
Commit
9abcd12
·
verified ·
1 Parent(s): 22ca508

Upload interface_demo.html with huggingface_hub

Browse files
Files changed (1) hide show
  1. interface_demo.html +294 -0
interface_demo.html ADDED
@@ -0,0 +1,294 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html lang="es">
3
+ <head>
4
+ <meta charset="UTF-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>GPT Local - Interfaces Disponibles</title>
7
+ <style>
8
+ body {
9
+ font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
10
+ line-height: 1.6;
11
+ max-width: 1200px;
12
+ margin: 0 auto;
13
+ padding: 20px;
14
+ background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
15
+ color: #333;
16
+ min-height: 100vh;
17
+ }
18
+ .container {
19
+ background: white;
20
+ border-radius: 15px;
21
+ padding: 30px;
22
+ box-shadow: 0 20px 40px rgba(0,0,0,0.1);
23
+ }
24
+ h1 {
25
+ color: #2c3e50;
26
+ text-align: center;
27
+ font-size: 2.5em;
28
+ margin-bottom: 10px;
29
+ }
30
+ .subtitle {
31
+ text-align: center;
32
+ color: #7f8c8d;
33
+ font-size: 1.2em;
34
+ margin-bottom: 40px;
35
+ }
36
+ .interface-grid {
37
+ display: grid;
38
+ grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
39
+ gap: 30px;
40
+ margin: 40px 0;
41
+ }
42
+ .interface-card {
43
+ border: 2px solid #e3e9ee;
44
+ border-radius: 12px;
45
+ padding: 25px;
46
+ background: #fafbfc;
47
+ transition: all 0.3s ease;
48
+ }
49
+ .interface-card:hover {
50
+ border-color: #667eea;
51
+ transform: translateY(-5px);
52
+ box-shadow: 0 15px 30px rgba(0,0,0,0.1);
53
+ }
54
+ .interface-title {
55
+ font-size: 1.4em;
56
+ font-weight: bold;
57
+ color: #2c3e50;
58
+ margin-bottom: 15px;
59
+ display: flex;
60
+ align-items: center;
61
+ }
62
+ .icon {
63
+ font-size: 1.5em;
64
+ margin-right: 10px;
65
+ }
66
+ .interface-description {
67
+ color: #5a6c7d;
68
+ margin-bottom: 20px;
69
+ line-height: 1.5;
70
+ }
71
+ .features {
72
+ list-style: none;
73
+ padding: 0;
74
+ margin: 15px 0;
75
+ }
76
+ .features li {
77
+ padding: 5px 0;
78
+ color: #34495e;
79
+ }
80
+ .features li:before {
81
+ content: "✅ ";
82
+ margin-right: 8px;
83
+ }
84
+ .command {
85
+ background: #2c3e50;
86
+ color: #ecf0f1;
87
+ padding: 12px 15px;
88
+ border-radius: 8px;
89
+ font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
90
+ font-size: 0.9em;
91
+ margin: 15px 0;
92
+ word-break: break-all;
93
+ }
94
+ .status {
95
+ padding: 8px 15px;
96
+ border-radius: 6px;
97
+ font-weight: bold;
98
+ text-align: center;
99
+ margin: 10px 0;
100
+ }
101
+ .status.working {
102
+ background: #d4edda;
103
+ color: #155724;
104
+ border: 1px solid #c3e6cb;
105
+ }
106
+ .status.issue {
107
+ background: #f8d7da;
108
+ color: #721c24;
109
+ border: 1px solid #f5c6cb;
110
+ }
111
+ .links {
112
+ margin-top: 40px;
113
+ padding: 25px;
114
+ background: #f8f9fa;
115
+ border-radius: 10px;
116
+ }
117
+ .links h3 {
118
+ color: #2c3e50;
119
+ margin-bottom: 15px;
120
+ }
121
+ .link-grid {
122
+ display: grid;
123
+ grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
124
+ gap: 15px;
125
+ }
126
+ .link-item {
127
+ display: flex;
128
+ align-items: center;
129
+ padding: 10px;
130
+ background: white;
131
+ border-radius: 8px;
132
+ text-decoration: none;
133
+ color: #2c3e50;
134
+ border: 1px solid #dee2e6;
135
+ transition: all 0.3s ease;
136
+ }
137
+ .link-item:hover {
138
+ border-color: #667eea;
139
+ transform: translateX(5px);
140
+ }
141
+ .link-icon {
142
+ margin-right: 10px;
143
+ font-size: 1.2em;
144
+ }
145
+ .architecture {
146
+ margin-top: 40px;
147
+ padding: 25px;
148
+ background: #f8f9fa;
149
+ border-radius: 10px;
150
+ }
151
+ .component {
152
+ background: white;
153
+ padding: 15px;
154
+ margin: 10px 0;
155
+ border-radius: 8px;
156
+ border-left: 4px solid #667eea;
157
+ }
158
+ </style>
159
+ </head>
160
+ <body>
161
+ <div class="container">
162
+ <h1>🤖 GPT Local</h1>
163
+ <p class="subtitle">Sistema de chat GPT local con HuggingFace y múltiples interfaces</p>
164
+
165
+ <div class="interface-grid">
166
+ <!-- Chat Terminal -->
167
+ <div class="interface-card">
168
+ <div class="interface-title">
169
+ <span class="icon">💻</span>
170
+ Chat Terminal
171
+ </div>
172
+ <div class="interface-description">
173
+ Interfaz de línea de comandos optimizada para Apple Silicon (MPS).
174
+ Es la interfaz principal y más estable del sistema.
175
+ </div>
176
+ <div class="status working">✅ Funcionando Perfectamente</div>
177
+ <ul class="features">
178
+ <li>Optimizado para macOS MPS</li>
179
+ <li>Modelo DialoGPT-small</li>
180
+ <li>Chat conversacional</li>
181
+ <li>Reset de historial</li>
182
+ <li>Logging detallado</li>
183
+ </ul>
184
+ <div class="command">python3 chat_terminal.py</div>
185
+ </div>
186
+
187
+ <!-- Interfaz Web Gradio -->
188
+ <div class="interface-card">
189
+ <div class="interface-title">
190
+ <span class="icon">🌐</span>
191
+ Interfaz Web (Gradio)
192
+ </div>
193
+ <div class="interface-description">
194
+ Interfaz web moderna con pestañas para chat y configuración.
195
+ Actualmente tiene problemas de compatibilidad.
196
+ </div>
197
+ <div class="status issue">⚠️ Error de Compatibilidad</div>
198
+ <ul class="features">
199
+ <li>Interfaz gráfica web</li>
200
+ <li>Control de parámetros</li>
201
+ <li>Múltiples modelos</li>
202
+ <li>Chat persistente</li>
203
+ <li>Puerto 7860</li>
204
+ </ul>
205
+ <div class="command">python3 main.py</div>
206
+ </div>
207
+
208
+ <!-- Docker Container -->
209
+ <div class="interface-card">
210
+ <div class="interface-title">
211
+ <span class="icon">🐳</span>
212
+ Contenedor Docker
213
+ </div>
214
+ <div class="interface-description">
215
+ Imagen Alpine Linux securizada, lista para despliegue en producción.
216
+ Sin vulnerabilidades de seguridad.
217
+ </div>
218
+ <div class="status working">✅ Imagen Segura Lista</div>
219
+ <ul class="features">
220
+ <li>Base Alpine Linux</li>
221
+ <li>Usuario no privilegiado</li>
222
+ <li>Sin vulnerabilidades</li>
223
+ <li>2.2GB optimizado</li>
224
+ <li>Python 3.12</li>
225
+ </ul>
226
+ <div class="command">docker run -p 7860:7860 drtv/gpt-local</div>
227
+ </div>
228
+
229
+ <!-- Pruebas y Tests -->
230
+ <div class="interface-card">
231
+ <div class="interface-title">
232
+ <span class="icon">🧪</span>
233
+ Sistema de Pruebas
234
+ </div>
235
+ <div class="interface-description">
236
+ Script de pruebas automáticas para verificar el funcionamiento
237
+ del modelo y los componentes del sistema.
238
+ </div>
239
+ <div class="status working">✅ Pruebas Funcionales</div>
240
+ <ul class="features">
241
+ <li>Test de modelo</li>
242
+ <li>Verificación MPS</li>
243
+ <li>Test de generación</li>
244
+ <li>Logging de errores</li>
245
+ <li>Validación completa</li>
246
+ </ul>
247
+ <div class="command">python3 test_gpt.py</div>
248
+ </div>
249
+ </div>
250
+
251
+ <div class="architecture">
252
+ <h3>🏗️ Arquitectura del Sistema</h3>
253
+ <div class="component">
254
+ <strong>models/</strong> - Gestión de modelos HuggingFace
255
+ <br><small>model_loader.py, text_generator.py</small>
256
+ </div>
257
+ <div class="component">
258
+ <strong>ui/</strong> - Interfaces de usuario
259
+ <br><small>gradio_interface.py (web), chat_terminal.py (terminal)</small>
260
+ </div>
261
+ <div class="component">
262
+ <strong>config/</strong> - Configuración del sistema
263
+ <br><small>settings.py con parámetros por defecto</small>
264
+ </div>
265
+ <div class="component">
266
+ <strong>Docker</strong> - Contenedor securizado
267
+ <br><small>Alpine Linux, usuario no privilegiado, sin vulnerabilidades</small>
268
+ </div>
269
+ </div>
270
+
271
+ <div class="links">
272
+ <h3>🔗 Enlaces del Proyecto</h3>
273
+ <div class="link-grid">
274
+ <a href="https://github.com/panacea-icono/gpt-local" class="link-item">
275
+ <span class="link-icon">📁</span>
276
+ Repositorio GitHub
277
+ </a>
278
+ <a href="https://huggingface.co/DRDELATV/gpt-local" class="link-item">
279
+ <span class="link-icon">🤗</span>
280
+ HuggingFace Hub
281
+ </a>
282
+ <a href="https://hub.docker.com/r/drtv/gpt-local" class="link-item">
283
+ <span class="link-icon">🐳</span>
284
+ Docker Hub
285
+ </a>
286
+ <a href="http://localhost:7860" class="link-item">
287
+ <span class="link-icon">🌐</span>
288
+ Interfaz Local (cuando funcione)
289
+ </a>
290
+ </div>
291
+ </div>
292
+ </div>
293
+ </body>
294
+ </html>