speech
Installation
SKILL.md
Speech (iOS)
Speech is an experimental on-device recognition capability. Enable it for the app in Wearables Developer Center and obtain microphone permission before starting it.
Request permission deliberately
Check permission silently first with checkPermissionStatus(.microphone). If it is not granted, call requestPermission(.microphone) only after a user action that explains the transition to the Meta AI app, and continue only when the result is .granted.
Attach and start
Add Speech after the DeviceSession reaches .started. Register listeners before start() so initial state, locale, errors, and transcription events are not missed.
guard let speech = try session.addSpeech() else { return }