Spaces:
Running
Running
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
| <title>AI Chat Assistant</title> | |
| <link rel="stylesheet" href="style.css"> | |
| </head> | |
| <body> | |
| <div class="container"> | |
| <header> | |
| <div class="header-content"> | |
| <div class="logo"> | |
| <svg width="32" height="32" viewBox="0 0 32 32" fill="none"> | |
| <circle cx="16" cy="16" r="14" stroke="currentColor" stroke-width="2" /> | |
| <path d="M16 10v12M10 16h12" stroke="currentColor" stroke-width="2" stroke-linecap="round" /> | |
| </svg> | |
| <h1>AI Assistant</h1> | |
| </div> | |
| <a href="https://huggingface.co/spaces/akhaliq/anycoder" target="_blank" class="built-with"> | |
| Built with anycoder | |
| </a> | |
| </div> | |
| </header> | |
| <div class="chat-container"> | |
| <div id="loadingScreen" class="loading-screen"> | |
| <div class="loading-content"> | |
| <div class="spinner"></div> | |
| <h2>Loading AI Model</h2> | |
| <p id="loadingStatus">Initializing...</p> | |
| <div class="progress-bar"> | |
| <div id="progressFill" class="progress-fill"></div> | |
| </div> | |
| <p class="progress-text" id="progressText">0%</p> | |
| </div> | |
| </div> | |
| <div id="chatInterface" class="chat-interface" style="display: none;"> | |
| <div class="messages-container" id="messagesContainer"> | |
| <div class="welcome-message"> | |
| <h2>π Hello!</h2> | |
| <p>I'm your AI assistant powered by Gemma 3. How can I help you today?</p> | |
| <div class="suggestions"> | |
| <button class="suggestion-btn" data-prompt="Write a poem about machine learning"> | |
| β¨ Write a poem | |
| </button> | |
| <button class="suggestion-btn" data-prompt="Explain quantum computing in simple terms"> | |
| π¬ Explain quantum computing | |
| </button> | |
| <button class="suggestion-btn" data-prompt="Give me tips for better productivity"> | |
| π‘ Productivity tips | |
| </button> | |
| </div> | |
| </div> | |
| </div> | |
| <div class="input-container"> | |
| <div class="input-wrapper"> | |
| <textarea | |
| id="userInput" | |
| placeholder="Message AI Assistant..." | |
| rows="1" | |
| ></textarea> | |
| <button id="sendButton" class="send-button" disabled> | |
| <svg width="24" height="24" viewBox="0 0 24 24" fill="none"> | |
| <path d="M22 2L11 13M22 2l-7 20-4-9-9-4 20-7z" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/> | |
| </svg> | |
| </button> | |
| </div> | |
| </div> | |
| </div> | |
| </div> | |
| </div> | |
| <script type="module" src="index.js"></script> | |
| </body> | |
| </html> |