A tiny JavaScript library for adding speech recognition and voice commands to websites.
annyang is a lightweight JavaScript library that adds speech recognition capabilities to websites, enabling users to control web applications with voice commands. It provides a simple API to define custom voice commands and integrates seamlessly with the browser's native SpeechRecognition API. The library solves the problem of making web interfaces more accessible and interactive through hands-free voice control.
Frontend developers and web designers looking to enhance user experience with voice interaction, particularly for accessibility features, hands-free navigation, or innovative UI controls.
Developers choose annyang for its minimal size (2 KB), zero dependencies, and straightforward API that simplifies adding speech recognition without complex setups. Its compatibility with the browser's built-in API ensures broad support and ease of integration.
💬 Speech recognition for your site
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Leverages the browser's native SpeechRecognition API, resulting in a minimal 2 KB library with zero external dependencies, as highlighted in the README.
Uses a straightforward object-based syntax to define voice commands, including wildcards for dynamic inputs, making it easy to set up basic interactions as shown in the Hello World example.
Supports ESM, CommonJS, and script tag inclusion, allowing seamless adoption in various JavaScript project setups without configuration hurdles.
Easily pairs with Speech KITT for a customizable graphical interface, providing visual feedback and user controls to enhance the speech recognition experience, as documented in the README.
Relies on the SpeechRecognition API, which has inconsistent support across browsers—particularly poor on iOS Safari—leading to unreliable user experiences in some environments.
Only supports simple keyword and wildcard matching, lacking advanced features like continuous listening, context awareness, or natural language processing without custom extensions.
Requires integrating Speech KITT as an additional library for a graphical interface, adding complexity and potential compatibility issues for projects needing visual controls out-of-the-box.