Update templates/docs.html
Browse files- templates/docs.html +124 -135
templates/docs.html
CHANGED
@@ -6,155 +6,144 @@
|
|
6 |
<title>Documentation - MoA Chat</title>
|
7 |
<link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/tailwind.min.css" rel="stylesheet">
|
8 |
<link rel="stylesheet" href="/static/style.css" />
|
9 |
-
<style>
|
10 |
-
.sticky-buttons {
|
11 |
-
position: fixed;
|
12 |
-
top: 1rem;
|
13 |
-
right: 1rem;
|
14 |
-
display: flex;
|
15 |
-
gap: 0.5rem;
|
16 |
-
z-index: 1000;
|
17 |
-
}
|
18 |
-
.sticky-buttons button {
|
19 |
-
padding: 0.5rem 0.75rem;
|
20 |
-
background-color: var(--blue);
|
21 |
-
color: var(--fg1);
|
22 |
-
border: none;
|
23 |
-
border-radius: 0.375rem;
|
24 |
-
font-weight: bold;
|
25 |
-
cursor: pointer;
|
26 |
-
transition: background-color 0.3s;
|
27 |
-
}
|
28 |
-
.sticky-buttons button:hover {
|
29 |
-
background-color: var(--purple);
|
30 |
-
color: var(--fg0);
|
31 |
-
}
|
32 |
-
</style>
|
33 |
</head>
|
|
|
34 |
|
35 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
36 |
|
37 |
-
|
38 |
-
|
39 |
-
<a href="/" class="px-3 py-2 bg-blue text-fg0 rounded hover:bg-purple transition text-center">← Chat</a>
|
40 |
-
<button id="langToggle">🇬🇧/🇪🇸</button>
|
41 |
-
</div>
|
42 |
-
|
43 |
-
<main class="flex flex-col items-center p-6 space-y-6 max-w-4xl mx-auto">
|
44 |
|
45 |
<!-- English Section -->
|
46 |
-
<section id="en"
|
47 |
-
|
48 |
-
<
|
49 |
-
|
50 |
-
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
|
55 |
-
|
56 |
-
<
|
57 |
-
|
58 |
-
<
|
59 |
-
<
|
60 |
-
|
61 |
-
|
62 |
-
|
63 |
-
|
64 |
-
|
65 |
-
|
66 |
-
<
|
67 |
-
<
|
68 |
-
<
|
69 |
-
|
70 |
-
|
71 |
-
|
72 |
-
|
73 |
-
|
74 |
-
|
75 |
-
|
76 |
-
|
77 |
-
|
78 |
-
|
79 |
-
|
80 |
-
|
81 |
-
|
82 |
-
|
83 |
-
|
84 |
-
|
85 |
-
|
86 |
-
|
87 |
-
|
88 |
-
|
89 |
-
|
90 |
-
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
-
|
95 |
-
|
96 |
-
</
|
|
|
|
|
|
|
|
|
|
|
97 |
|
98 |
</section>
|
99 |
|
100 |
<!-- Spanish Section -->
|
101 |
-
<section id="es"
|
102 |
-
|
103 |
-
<
|
104 |
-
|
105 |
-
|
106 |
-
|
107 |
-
|
108 |
-
|
109 |
-
|
110 |
-
|
111 |
-
<
|
112 |
-
|
113 |
-
<
|
114 |
-
<
|
115 |
-
|
116 |
-
|
117 |
-
|
118 |
-
|
119 |
-
|
120 |
-
|
121 |
-
<
|
122 |
-
<
|
123 |
-
<
|
124 |
-
|
125 |
-
|
126 |
-
|
127 |
-
|
128 |
-
|
129 |
-
|
130 |
-
|
131 |
-
|
132 |
-
|
133 |
-
|
134 |
-
|
135 |
-
|
136 |
-
|
137 |
-
|
138 |
-
|
139 |
-
|
140 |
-
|
141 |
-
|
142 |
-
|
143 |
-
|
144 |
-
|
145 |
-
|
146 |
-
|
147 |
-
|
148 |
-
|
149 |
-
|
150 |
-
|
151 |
-
|
|
|
|
|
|
|
|
|
152 |
|
153 |
</section>
|
154 |
|
155 |
</main>
|
156 |
|
157 |
-
<script src="/static/docs.js"></script>
|
158 |
|
159 |
</body>
|
160 |
</html>
|
|
|
6 |
<title>Documentation - MoA Chat</title>
|
7 |
<link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/tailwind.min.css" rel="stylesheet">
|
8 |
<link rel="stylesheet" href="/static/style.css" />
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
9 |
</head>
|
10 |
+
<body class="bg0 text-fg0 transition-colors duration-300 flex flex-col min-h-screen">
|
11 |
|
12 |
+
<!-- Top Fixed Bar -->
|
13 |
+
<header class="flex items-center justify-between p-4 bg1 shadow-md sticky top-0 z-50">
|
14 |
+
<h1 class="text-2xl font-bold">Documentation</h1>
|
15 |
+
<div class="space-x-2 flex items-center">
|
16 |
+
<a href="/" id="chatButton" class="px-3 py-1 rounded bg-blue hover:bg-purple text-fg0 transition">← Chat</a>
|
17 |
+
<button id="langToggle" class="px-3 py-1 rounded bg-blue hover:bg-purple text-fg0 transition">🌐</button>
|
18 |
+
<button id="themeToggle" class="px-3 py-1 rounded bg-blue hover:bg-purple text-fg0 transition">🌙</button>
|
19 |
+
</div>
|
20 |
+
</header>
|
21 |
|
22 |
+
<!-- Scrollable Main Content -->
|
23 |
+
<main class="flex-1 overflow-y-auto p-6 space-y-8">
|
|
|
|
|
|
|
|
|
|
|
24 |
|
25 |
<!-- English Section -->
|
26 |
+
<section id="en" class="space-y-8">
|
27 |
+
|
28 |
+
<div class="space-y-4">
|
29 |
+
<h2 class="text-xl font-semibold">What is MoA Chat?</h2>
|
30 |
+
<p>
|
31 |
+
MoA Chat is a minimalistic and modern multi-model AI chat platform based on the "Mixture of Agents" (MoA) architecture.
|
32 |
+
It allows you to query multiple language models (LLMs) simultaneously, and combine their responses into a final answer.
|
33 |
+
</p>
|
34 |
+
</div>
|
35 |
+
|
36 |
+
<div class="space-y-4">
|
37 |
+
<h2 class="text-xl font-semibold">How It Works</h2>
|
38 |
+
<img src="https://github.com/togethercomputer/MoA/raw/main/assets/moa-explained.png" alt="MoA System Architecture" class="rounded shadow-lg">
|
39 |
+
<p>
|
40 |
+
Each conversation consists of three AI models (LLM-A, LLM-B, LLM-C) answering separately based on a structured system prompt,
|
41 |
+
and one aggregator model (LLM-D) combining their outputs into a high-quality final response.
|
42 |
+
</p>
|
43 |
+
</div>
|
44 |
+
|
45 |
+
<div class="space-y-4">
|
46 |
+
<h2 class="text-xl font-semibold">Features</h2>
|
47 |
+
<ul class="list-disc list-inside space-y-2">
|
48 |
+
<li>🔹 Minimal, fast, fully responsive UI.</li>
|
49 |
+
<li>🔹 Supports any OpenRouter, Groq, Together AI, or Grok model easily.</li>
|
50 |
+
<li>🔹 Auto-theme (light/dark) detection based on your device.</li>
|
51 |
+
<li>🔹 Smooth animations and Gruvbox Material palette.</li>
|
52 |
+
<li>🔹 Self-hostable without any hidden costs.</li>
|
53 |
+
</ul>
|
54 |
+
</div>
|
55 |
+
|
56 |
+
<div class="space-y-4">
|
57 |
+
<h2 class="text-xl font-semibold">How to Self-Host</h2>
|
58 |
+
<p>1. Deploy to Hugging Face Spaces (Docker).</p>
|
59 |
+
<p>2. Add your API keys under "Secrets" (OPENROUTER_API_KEY, GROK_API_KEY, etc).</p>
|
60 |
+
<p>3. Configure `llm/model_config.json` to add new providers or models.</p>
|
61 |
+
<p>4. That's it! No database required.</p>
|
62 |
+
</div>
|
63 |
+
|
64 |
+
<div class="space-y-4">
|
65 |
+
<h2 class="text-xl font-semibold">Adding Models</h2>
|
66 |
+
<p>
|
67 |
+
To add new models, simply update the <code>llm/model_config.json</code> file by mapping model names to providers.
|
68 |
+
No backend changes are needed — the app automatically pulls from the updated list.
|
69 |
+
</p>
|
70 |
+
</div>
|
71 |
+
|
72 |
+
<div class="space-y-4">
|
73 |
+
<h2 class="text-xl font-semibold">License</h2>
|
74 |
+
<p>This project is licensed under the <strong>AGPLv3</strong>.
|
75 |
+
Fully free, fully open-source, no restrictions.</p>
|
76 |
+
</div>
|
77 |
+
|
78 |
+
<div class="space-y-4">
|
79 |
+
<h2 class="text-xl font-semibold">Credits</h2>
|
80 |
+
<p>Inspired by <a href="https://github.com/togethercomputer/MoA" class="text-blue underline hover:text-purple" target="_blank">Together MoA</a> and built with ❤️ in Panamá.</p>
|
81 |
+
</div>
|
82 |
|
83 |
</section>
|
84 |
|
85 |
<!-- Spanish Section -->
|
86 |
+
<section id="es" class="space-y-8 hidden">
|
87 |
+
|
88 |
+
<div class="space-y-4">
|
89 |
+
<h2 class="text-xl font-semibold">¿Qué es MoA Chat?</h2>
|
90 |
+
<p>
|
91 |
+
MoA Chat es una plataforma de chat de IA moderna y minimalista basada en la arquitectura "Mixture of Agents" (MoA).
|
92 |
+
Permite consultar múltiples modelos de lenguaje (LLMs) al mismo tiempo y combinar sus respuestas en una sola.
|
93 |
+
</p>
|
94 |
+
</div>
|
95 |
+
|
96 |
+
<div class="space-y-4">
|
97 |
+
<h2 class="text-xl font-semibold">¿Cómo Funciona?</h2>
|
98 |
+
<img src="https://github.com/togethercomputer/MoA/raw/main/assets/moa-explained.png" alt="Arquitectura MoA" class="rounded shadow-lg">
|
99 |
+
<p>
|
100 |
+
Cada conversación involucra tres modelos de IA (LLM-A, LLM-B, LLM-C) respondiendo por separado con un prompt estructurado,
|
101 |
+
y un modelo agregador (LLM-D) que combina las respuestas en una final de alta calidad.
|
102 |
+
</p>
|
103 |
+
</div>
|
104 |
+
|
105 |
+
<div class="space-y-4">
|
106 |
+
<h2 class="text-xl font-semibold">Características</h2>
|
107 |
+
<ul class="list-disc list-inside space-y-2">
|
108 |
+
<li>🔹 UI rápida, minimalista y adaptable.</li>
|
109 |
+
<li>🔹 Soporte para OpenRouter, Groq, Together AI, Grok.</li>
|
110 |
+
<li>🔹 Cambio automático de tema claro/oscuro.</li>
|
111 |
+
<li>🔹 Animaciones suaves y paleta Gruvbox Material.</li>
|
112 |
+
<li>🔹 100% autohospedable.</li>
|
113 |
+
</ul>
|
114 |
+
</div>
|
115 |
+
|
116 |
+
<div class="space-y-4">
|
117 |
+
<h2 class="text-xl font-semibold">Cómo Autohospedarlo</h2>
|
118 |
+
<p>1. Despliega en Hugging Face Spaces (Docker).</p>
|
119 |
+
<p>2. Agrega tus llaves API en "Secrets" (OPENROUTER_API_KEY, GROK_API_KEY, etc).</p>
|
120 |
+
<p>3. Configura <code>llm/model_config.json</code> para agregar modelos o proveedores.</p>
|
121 |
+
<p>4. ¡Listo! No requiere base de datos.</p>
|
122 |
+
</div>
|
123 |
+
|
124 |
+
<div class="space-y-4">
|
125 |
+
<h2 class="text-xl font-semibold">Agregar Modelos</h2>
|
126 |
+
<p>
|
127 |
+
Para agregar nuevos modelos, solo edita <code>llm/model_config.json</code>.
|
128 |
+
La app actualizará las opciones automáticamente.
|
129 |
+
</p>
|
130 |
+
</div>
|
131 |
+
|
132 |
+
<div class="space-y-4">
|
133 |
+
<h2 class="text-xl font-semibold">Licencia</h2>
|
134 |
+
<p>Este proyecto usa la licencia <strong>AGPLv3</strong>.</p>
|
135 |
+
</div>
|
136 |
+
|
137 |
+
<div class="space-y-4">
|
138 |
+
<h2 class="text-xl font-semibold">Créditos</h2>
|
139 |
+
<p>Inspirado en <a href="https://github.com/togethercomputer/MoA" class="text-blue underline hover:text-purple" target="_blank">Together MoA</a> y construido con ❤️ en Panamá.</p>
|
140 |
+
</div>
|
141 |
|
142 |
</section>
|
143 |
|
144 |
</main>
|
145 |
|
146 |
+
<script src="/static/docs.js"></script>
|
147 |
|
148 |
</body>
|
149 |
</html>
|