Spaces:
Running
Running
Upload 2 files
Browse files- downloads/index.html +88 -19
- downloads/interactive.py +5 -0
downloads/index.html
CHANGED
|
@@ -1,28 +1,26 @@
|
|
| 1 |
<!DOCTYPE html>
|
| 2 |
<html lang="en">
|
|
|
|
| 3 |
<head>
|
| 4 |
<meta charset="UTF-8">
|
| 5 |
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
| 6 |
<title>Download | CompactAI Studio</title>
|
| 7 |
<link rel="preconnect" href="https://fonts.googleapis.com">
|
| 8 |
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
| 9 |
-
<link href="https://fonts.googleapis.com/css2?family=Geist:wght@400;500;600;700&family=Geist+Mono&display=swap"
|
|
|
|
| 10 |
<style>
|
| 11 |
:root {
|
| 12 |
--black: #000000;
|
| 13 |
--black-soft: #0a0a0a;
|
| 14 |
-
--black-muted: #111111;
|
| 15 |
--gray-1: #171717;
|
| 16 |
--gray-2: #262626;
|
| 17 |
--gray-3: #363636;
|
| 18 |
-
--gray-4: #525252;
|
| 19 |
--gray-5: #737373;
|
| 20 |
--gray-6: #a3a3a3;
|
| 21 |
--gray-7: #d4d4d4;
|
| 22 |
-
--gray-8: #e5e5e5;
|
| 23 |
--white: #ffffff;
|
| 24 |
--accent: #ff4d00;
|
| 25 |
-
--accent-muted: #ff6a2a;
|
| 26 |
--font-sans: 'Geist', -apple-system, BlinkMacSystemFont, sans-serif;
|
| 27 |
--font-mono: 'Geist Mono', 'SF Mono', 'Fira Code', monospace;
|
| 28 |
--container-max: 900px;
|
|
@@ -70,7 +68,7 @@
|
|
| 70 |
left: 0;
|
| 71 |
right: 0;
|
| 72 |
z-index: 100;
|
| 73 |
-
background: rgba(0, 0, 0, 0.
|
| 74 |
backdrop-filter: blur(12px);
|
| 75 |
border-bottom: 1px solid var(--gray-2);
|
| 76 |
padding: 16px 0;
|
|
@@ -211,6 +209,41 @@
|
|
| 211 |
align-items: center;
|
| 212 |
}
|
| 213 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 214 |
.note {
|
| 215 |
margin-top: 32px;
|
| 216 |
padding: 16px;
|
|
@@ -226,6 +259,7 @@
|
|
| 226 |
}
|
| 227 |
</style>
|
| 228 |
</head>
|
|
|
|
| 229 |
<body>
|
| 230 |
<nav>
|
| 231 |
<div class="container">
|
|
@@ -251,8 +285,8 @@
|
|
| 251 |
<div class="download-card-left">
|
| 252 |
<div class="platform-icon">
|
| 253 |
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
| 254 |
-
<rect x="3" y="3" width="18" height="18" rx="2"/>
|
| 255 |
-
<path d="M9 9h6v6H9z"/>
|
| 256 |
</svg>
|
| 257 |
</div>
|
| 258 |
<div class="download-info">
|
|
@@ -261,9 +295,10 @@
|
|
| 261 |
</div>
|
| 262 |
</div>
|
| 263 |
<a href="CompactAI Studio Setup 1.0.0.exe" download class="download-btn">
|
| 264 |
-
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor"
|
| 265 |
-
|
| 266 |
-
<path d="
|
|
|
|
| 267 |
</svg>
|
| 268 |
Download
|
| 269 |
</a>
|
|
@@ -273,8 +308,8 @@
|
|
| 273 |
<div class="download-card-left">
|
| 274 |
<div class="platform-icon">
|
| 275 |
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
| 276 |
-
<path d="M20 18l-8-5-8 5"/>
|
| 277 |
-
<path d="M4 18l8-5 8 5"/>
|
| 278 |
</svg>
|
| 279 |
</div>
|
| 280 |
<div class="download-info">
|
|
@@ -283,19 +318,53 @@
|
|
| 283 |
</div>
|
| 284 |
</div>
|
| 285 |
<a href="CompactAI Studio-1.0.0.AppImage" class="download-btn">
|
| 286 |
-
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor"
|
| 287 |
-
|
| 288 |
-
<path d="
|
|
|
|
| 289 |
</svg>
|
| 290 |
Download
|
| 291 |
</a>
|
| 292 |
</div>
|
| 293 |
|
| 294 |
-
|
| 295 |
-
|
| 296 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 297 |
</div>
|
| 298 |
</div>
|
| 299 |
</main>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 300 |
</body>
|
|
|
|
| 301 |
</html>
|
|
|
|
| 1 |
<!DOCTYPE html>
|
| 2 |
<html lang="en">
|
| 3 |
+
|
| 4 |
<head>
|
| 5 |
<meta charset="UTF-8">
|
| 6 |
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
| 7 |
<title>Download | CompactAI Studio</title>
|
| 8 |
<link rel="preconnect" href="https://fonts.googleapis.com">
|
| 9 |
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
| 10 |
+
<link href="https://fonts.googleapis.com/css2?family=Geist:wght@400;500;600;700&family=Geist+Mono&display=swap"
|
| 11 |
+
rel="stylesheet">
|
| 12 |
<style>
|
| 13 |
:root {
|
| 14 |
--black: #000000;
|
| 15 |
--black-soft: #0a0a0a;
|
|
|
|
| 16 |
--gray-1: #171717;
|
| 17 |
--gray-2: #262626;
|
| 18 |
--gray-3: #363636;
|
|
|
|
| 19 |
--gray-5: #737373;
|
| 20 |
--gray-6: #a3a3a3;
|
| 21 |
--gray-7: #d4d4d4;
|
|
|
|
| 22 |
--white: #ffffff;
|
| 23 |
--accent: #ff4d00;
|
|
|
|
| 24 |
--font-sans: 'Geist', -apple-system, BlinkMacSystemFont, sans-serif;
|
| 25 |
--font-mono: 'Geist Mono', 'SF Mono', 'Fira Code', monospace;
|
| 26 |
--container-max: 900px;
|
|
|
|
| 68 |
left: 0;
|
| 69 |
right: 0;
|
| 70 |
z-index: 100;
|
| 71 |
+
background: rgba(0, 0, 0, 0.85);
|
| 72 |
backdrop-filter: blur(12px);
|
| 73 |
border-bottom: 1px solid var(--gray-2);
|
| 74 |
padding: 16px 0;
|
|
|
|
| 209 |
align-items: center;
|
| 210 |
}
|
| 211 |
|
| 212 |
+
.browser-alt {
|
| 213 |
+
margin-top: 40px;
|
| 214 |
+
padding: 28px 32px;
|
| 215 |
+
background: var(--gray-1);
|
| 216 |
+
border: 1px solid var(--gray-2);
|
| 217 |
+
border-radius: 12px;
|
| 218 |
+
}
|
| 219 |
+
|
| 220 |
+
.browser-alt h2 {
|
| 221 |
+
font-size: 22px;
|
| 222 |
+
font-weight: 600;
|
| 223 |
+
color: var(--white);
|
| 224 |
+
margin-bottom: 12px;
|
| 225 |
+
}
|
| 226 |
+
|
| 227 |
+
.browser-alt > p {
|
| 228 |
+
color: var(--gray-5);
|
| 229 |
+
font-size: 15px;
|
| 230 |
+
margin-bottom: 16px;
|
| 231 |
+
max-width: 52ch;
|
| 232 |
+
}
|
| 233 |
+
|
| 234 |
+
.code-block {
|
| 235 |
+
font-family: var(--font-mono);
|
| 236 |
+
font-size: 13px;
|
| 237 |
+
line-height: 1.5;
|
| 238 |
+
background: var(--black-soft);
|
| 239 |
+
border: 1px solid var(--gray-2);
|
| 240 |
+
border-radius: 8px;
|
| 241 |
+
padding: 16px 20px;
|
| 242 |
+
color: var(--gray-7);
|
| 243 |
+
overflow-x: auto;
|
| 244 |
+
white-space: pre;
|
| 245 |
+
}
|
| 246 |
+
|
| 247 |
.note {
|
| 248 |
margin-top: 32px;
|
| 249 |
padding: 16px;
|
|
|
|
| 259 |
}
|
| 260 |
</style>
|
| 261 |
</head>
|
| 262 |
+
|
| 263 |
<body>
|
| 264 |
<nav>
|
| 265 |
<div class="container">
|
|
|
|
| 285 |
<div class="download-card-left">
|
| 286 |
<div class="platform-icon">
|
| 287 |
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
| 288 |
+
<rect x="3" y="3" width="18" height="18" rx="2" />
|
| 289 |
+
<path d="M9 9h6v6H9z" />
|
| 290 |
</svg>
|
| 291 |
</div>
|
| 292 |
<div class="download-info">
|
|
|
|
| 295 |
</div>
|
| 296 |
</div>
|
| 297 |
<a href="CompactAI Studio Setup 1.0.0.exe" download class="download-btn">
|
| 298 |
+
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor"
|
| 299 |
+
stroke-width="2">
|
| 300 |
+
<path d="M6 9l6 6 6-6" />
|
| 301 |
+
<path d="M12 15V3" />
|
| 302 |
</svg>
|
| 303 |
Download
|
| 304 |
</a>
|
|
|
|
| 308 |
<div class="download-card-left">
|
| 309 |
<div class="platform-icon">
|
| 310 |
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
| 311 |
+
<path d="M20 18l-8-5-8 5" />
|
| 312 |
+
<path d="M4 18l8-5 8 5" />
|
| 313 |
</svg>
|
| 314 |
</div>
|
| 315 |
<div class="download-info">
|
|
|
|
| 318 |
</div>
|
| 319 |
</div>
|
| 320 |
<a href="CompactAI Studio-1.0.0.AppImage" class="download-btn">
|
| 321 |
+
<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor"
|
| 322 |
+
stroke-width="2">
|
| 323 |
+
<path d="M6 9l6 6 6-6" />
|
| 324 |
+
<path d="M12 15V3" />
|
| 325 |
</svg>
|
| 326 |
Download
|
| 327 |
</a>
|
| 328 |
</div>
|
| 329 |
|
| 330 |
+
<section class="browser-alt">
|
| 331 |
+
<h2>Don't feel like downloading an app? No worries!</h2>
|
| 332 |
+
<p>Run the browser version, pull checkpoints from <a href="https://huggingface.co/CompactAI">huggingface.co/CompactAI</a>, and chat locally without installing the desktop app. Dependencies install automatically the first time you launch it.</p>
|
| 333 |
+
<div style="display:flex; gap:12px; flex-wrap:wrap; margin-bottom:16px;">
|
| 334 |
+
<button id="browser-launcher-download" type="button" class="download-btn">Download browser launcher</button>
|
| 335 |
+
</div>
|
| 336 |
+
<pre class="code-block">python3 interactive.py</pre>
|
| 337 |
+
</section>
|
| 338 |
+
|
| 339 |
+
<div class="note">
|
| 340 |
+
<strong>Note:</strong> The web launcher downloads model files from Hugging Face and caches them
|
| 341 |
+
locally. The desktop app still ships for offline use if you prefer a packaged installer.
|
| 342 |
+
</div>
|
| 343 |
</div>
|
| 344 |
</div>
|
| 345 |
</main>
|
| 346 |
+
<script>
|
| 347 |
+
const browserLauncherButton = document.getElementById('browser-launcher-download');
|
| 348 |
+
if (browserLauncherButton) {
|
| 349 |
+
browserLauncherButton.addEventListener('click', async () => {
|
| 350 |
+
try {
|
| 351 |
+
const response = await fetch('interactive.py');
|
| 352 |
+
if (!response.ok) throw new Error('Download failed.');
|
| 353 |
+
const blob = await response.blob();
|
| 354 |
+
const url = URL.createObjectURL(blob);
|
| 355 |
+
const link = document.createElement('a');
|
| 356 |
+
link.href = url;
|
| 357 |
+
link.download = 'interactive.py';
|
| 358 |
+
document.body.appendChild(link);
|
| 359 |
+
link.click();
|
| 360 |
+
link.remove();
|
| 361 |
+
URL.revokeObjectURL(url);
|
| 362 |
+
} catch {
|
| 363 |
+
alert('Could not download interactive.py from this page.');
|
| 364 |
+
}
|
| 365 |
+
});
|
| 366 |
+
}
|
| 367 |
+
</script>
|
| 368 |
</body>
|
| 369 |
+
|
| 370 |
</html>
|
downloads/interactive.py
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
from interactive import main
|
| 2 |
+
|
| 3 |
+
|
| 4 |
+
if __name__ == "__main__":
|
| 5 |
+
main()
|