Porcupine wake word engine.
Actively maintained. Last release 5 months ago, commits in 16 of the last 26 weeks. A safe choice.
pip install pvporcupinePorcupine Wake Word Engine
Made in Vancouver, Canada by Picovoice
Porcupine is a highly-accurate and lightweight wake word engine. It enables building always-listening voice-enabled applications. It is
- using deep neural networks trained in real-world environments.
- compact and computationally-efficient. It is perfect for IoT.
- cross-platform:
- Arm Cortex-M, STM32, and Arduino
- Raspberry Pi (Zero, 3, 4, 5)
- Android and iOS
- Chrome, Safari, Firefox, and Edge
- Linux (x86_64), macOS (x86_64, arm64), and Windows (x86_64, arm64)
- scalable. It can detect multiple always-listening voice commands with no added runtime footprint.
- self-service. Developers can train custom wake word models using Picovoice Console.
Compatibility
- Python 3.9+
- Runs on Linux (x86_64), macOS (x86_64 and arm64), Windows (x86_64, arm64), and Raspberry Pi (Zero, 3, 4, 5).
Installation
pip3 install pvporcupine
AccessKey
Porcupine requires a valid Picovoice AccessKey at initialization. AccessKey acts as your credentials when using Porcupine SDKs.
You can get your AccessKey for free. Make sure to keep your AccessKey secret.
Signup or Login to Picovoice Console to get your AccessKey.
Usage
Create an instance of the engine
import pvporcupine
access_key = "${ACCESS_KEY}" # AccessKey obtained from Picovoice Console (https://console.picovoice.ai/)
handle = pvporcupine.create(access_key=access_key, keywords=['picovoice'])
handle is an instance of Porcupine that detects utterances of "Picovoice". keywords input argument is a shorthand
for accessing default keyword model files shipped with the package. The list of default keywords can be retrieved by
import pvporcupine
print(pvporcupine.KEYWORDS)
Porcupine can detect multiple keywords concurrently
import pvporcupine
access_key = "${ACCESS_KEY}" # AccessKey obtained from Picovoice Console (https://console.picovoice.ai/)
handle = pvporcupine.create(access_key=access_key, keywords=['bumblebee', 'picovoice'])