AI 스피커를 만들때 가장 필수적인 기능은 wake up voice trigger 이다.
라즈베리파이 환경에서 직접 구현하기 위해 여러 아이디어를 고민했었는데
마침 apple 의 siri에 대한 paper가 제공됐다.
machinelearning.apple.com/research/hey-siri
Hey Siri: An On-device DNN-powered Voice Trigger for Apple’s Personal Assistant
The "Hey Siri" feature allows users to invoke Siri hands-free. A very small speech recognizer runs all the time and listens for just those…
machinelearning.apple.com
애플에서 머신러닝 관련된 여러 문서를 제공하니 참고하면 좋을것 같다.
전체적 개요는
1. pyaudio 를 통해 마이크에 접근해 오디오 스트림을 받는다.
2. 저장 데이터 타입을 queue로 구현하여 3~4초 정도의 음성파일을 연속적으로 받는다.
(마치 컴퓨터 네트워크의 receive window처럼 훑는 방식)
3. 큐를 numpy로 복제한다.
4. 학습된 DNN 모델에 numpy 배열을 넣고 wake up voice 인지 아닌지를 분류한다.
잘 작동할지는 모르겠지만 아마 잘 될 것 같다(?)