UNPKG

@namastexlabs/speak

Version:

Open source voice dictation for everyone

279 lines (270 loc) โ€ข 8.95 kB
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Speak - Open Source Voice Dictation</title> <style> body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; margin: 0; padding: 20px; background: #f5f5f5; color: #333; } .container { max-width: 800px; margin: 0 auto; background: white; padding: 40px; border-radius: 8px; box-shadow: 0 2px 10px rgba(0,0,0,0.1); } .header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 30px; } h1 { color: #0066CC; margin: 0; } .settings-btn { background: #0066CC; color: white; border: none; padding: 8px 16px; border-radius: 4px; cursor: pointer; font-size: 14px; } .settings-btn:hover { background: #0052a3; } .status-card { background: #f8f9fa; padding: 20px; border-radius: 8px; margin: 20px 0; border-left: 4px solid #0066CC; } .status-ready { border-left-color: #28a745; background: #d4edda; } .status-recording { border-left-color: #dc3545; background: #f8d7da; animation: pulse 1s infinite; } .status-error { border-left-color: #ffc107; background: #fff3cd; } @keyframes pulse { 0% { opacity: 1; } 50% { opacity: 0.7; } 100% { opacity: 1; } } .hotkey-display { background: #e9ecef; padding: 10px 15px; border-radius: 4px; font-family: monospace; font-weight: bold; display: inline-block; margin: 10px 0; } .recording-indicator { display: none; position: fixed; top: 20px; right: 20px; background: #dc3545; color: white; padding: 10px 20px; border-radius: 20px; font-weight: bold; z-index: 1000; box-shadow: 0 2px 10px rgba(0,0,0,0.3); } .features { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 20px; margin: 30px 0; } .feature { padding: 20px; border: 1px solid #ddd; border-radius: 4px; text-align: center; } .feature h3 { color: #0066CC; margin-top: 0; } .feature-icon { font-size: 32px; margin-bottom: 10px; } .instructions { background: #e7f3ff; padding: 20px; border-radius: 8px; margin: 20px 0; } .instructions ol { margin: 0; padding-left: 20px; } .instructions li { margin-bottom: 8px; } .test-controls { background: #f8f9fa; padding: 20px; border-radius: 8px; margin: 20px 0; } .test-controls h3 { margin-top: 0; color: #495057; } .btn { background: #0066CC; color: white; border: none; padding: 10px 20px; border-radius: 4px; cursor: pointer; font-size: 14px; margin: 5px; } .btn:hover { background: #0052a3; } .btn-secondary { background: #6c757d; } .btn-secondary:hover { background: #545b62; } .btn-danger { background: #dc3545; } .btn-danger:hover { background: #c82333; } .status-text { font-size: 18px; font-weight: bold; margin: 10px 0; } .last-transcription { background: #f8f9fa; padding: 15px; border-radius: 4px; margin: 10px 0; font-style: italic; border-left: 3px solid #0066CC; } .footer { text-align: center; margin-top: 40px; padding-top: 20px; border-top: 1px solid #ddd; color: #666; font-size: 14px; } .footer a { color: #0066CC; text-decoration: none; } .footer a:hover { text-decoration: underline; } </style> </head> <body> <div class="container"> <div class="header"> <h1>๐ŸŽ™๏ธ Speak</h1> <button class="settings-btn" onclick="openSettings()">โš™๏ธ Settings</button> </div> <p style="text-align: center; font-size: 18px; color: #666; margin-bottom: 30px;"> Your voice, your data, your control - Open source voice dictation for everyone </p> <div id="status-card" class="status-card status-ready"> <div class="status-text" id="status-text">๐ŸŽฏ Ready to Dictate</div> <p id="status-description">Hold <span id="hotkey-display" class="hotkey-display">Ctrl + Hold</span> to start recording</p> </div> <div class="instructions"> <h3>๐Ÿš€ How to Use Speak</h3> <ol> <li>Make sure your microphone is connected and permissions are granted</li> <li>Hold the hotkey (<span id="hotkey-instruction">Ctrl</span>) to start recording</li> <li>Speak clearly and naturally</li> <li>Release the hotkey to stop recording and insert text</li> <li>Text appears instantly at your cursor position</li> </ol> </div> <div class="test-controls"> <h3>๐Ÿงช Test Controls</h3> <p>Use these buttons to test the dictation system:</p> <button class="btn" onclick="startRecording()" id="start-btn">๐ŸŽ™๏ธ Start Recording</button> <button class="btn btn-danger" onclick="stopRecording()" id="stop-btn" disabled>โน๏ธ Stop Recording</button> <div id="test-status"></div> </div> <div id="last-transcription" class="last-transcription" style="display: none;"> <strong>Last transcription:</strong> <span id="transcription-text"></span> </div> <h2>โœจ Key Features</h2> <div class="features"> <div class="feature"> <div class="feature-icon">๐ŸŽฏ</div> <h3>Universal Dictation</h3> <p>Works in any application via global hotkey. No app switching required.</p> </div> <div class="feature"> <div class="feature-icon">๐Ÿ›ก๏ธ</div> <h3>Privacy First</h3> <p>Your voice is processed by OpenAI Whisper with end-to-end encryption.</p> </div> <div class="feature"> <div class="feature-icon">๐Ÿง</div> <h3>Cross-Platform</h3> <p>Native support for Windows, macOS, and Linux distributions.</p> </div> <div class="feature"> <div class="feature-icon">โšก</div> <h3>High Performance</h3> <p>OpenAI Whisper models deliver excellent accuracy with low latency.</p> </div> <div class="feature"> <div class="feature-icon">๐Ÿ”“</div> <h3>Open Source</h3> <p>Full transparency, community-driven, and self-hostable.</p> </div> <div class="feature"> <div class="feature-icon">๐ŸŒ</div> <h3>Multi-Language</h3> <p>Support for multiple languages with automatic detection.</p> </div> </div> <div class="footer"> <p> <a href="#" onclick="openExternal('https://github.com/yourusername/speak')">View on GitHub</a> | <a href="#" onclick="openExternal('./docs/')">Documentation</a> | <a href="#" onclick="openExternal('./docs/why-speak.md')">Why Speak?</a> </p> <p>Speak is free, open source, and built for the future of voice interaction.</p> </div> </div> <div class="recording-indicator" id="recording-indicator"> ๐ŸŽ™๏ธ Recording... </div> <script src="main.js"></script> </body> </html>