| | |
| | | bool Initialize(AudioCodec* codec, srmodel_list_t* models_list); |
| | | void Feed(const std::vector<int16_t>& data); |
| | | void OnWakeWordDetected(std::function<void(const std::string& wake_word)> callback); |
| | | void OnOfflineCommandDetected(std::function<void(const std::string& command)> callback); |
| | | void Start(); |
| | | void Stop(); |
| | | size_t GetFeedSize(); |
| | |
| | | std::deque<Command> commands_; |
| | | |
| | | std::function<void(const std::string& wake_word)> wake_word_detected_callback_; |
| | | std::function<void(const std::string& command)> offline_command_detected_callback_; |
| | | AudioCodec* codec_ = nullptr; |
| | | std::string last_detected_wake_word_; |
| | | std::atomic<bool> running_ = false; |