---
title: SFSpeechAudioBufferRecognitionRequest
framework: speech
role: symbol
role_heading: Class
path: speech/sfspeechaudiobufferrecognitionrequest
---

# SFSpeechAudioBufferRecognitionRequest

A request to recognize speech from captured audio content, such as audio from the device’s microphone.

## Declaration

```swift
class SFSpeechAudioBufferRecognitionRequest
```

## Overview

Overview Use an SFSpeechAudioBufferRecognitionRequest object to perform speech recognition on live audio, or on a set of existing audio buffers. For example, use this request object to route audio from a device’s microphone to the speech recognizer. The request object contains no audio initially. As you capture audio, call append(_:) or appendAudioSampleBuffer(_:) to add audio samples to the request object. The speech recognizer continuously analyzes the audio you appended, stopping only when you call the endAudio() method. You must call endAudio() explicitly to stop the speech recognition process. For a complete example of how to use audio buffers with speech recognition, see SpeakToMe: Using Speech Recognition with AVAudioEngine.

## Topics

### Appending Audio Buffers

- [append(_:)](speech/sfspeechaudiobufferrecognitionrequest/append(_:).md)
- [appendAudioSampleBuffer(_:)](speech/sfspeechaudiobufferrecognitionrequest/appendaudiosamplebuffer(_:).md)
- [endAudio()](speech/sfspeechaudiobufferrecognitionrequest/endaudio().md)

### Getting the Audio Format

- [nativeAudioFormat](speech/sfspeechaudiobufferrecognitionrequest/nativeaudioformat.md)

## Relationships

### Inherits From

- [SFSpeechRecognitionRequest](speech/sfspeechrecognitionrequest.md)

### Conforms To

- [CVarArg](swift/cvararg.md)
- [CustomDebugStringConvertible](swift/customdebugstringconvertible.md)
- [CustomStringConvertible](swift/customstringconvertible.md)
- [Equatable](swift/equatable.md)
- [Hashable](swift/hashable.md)
- [NSObjectProtocol](objectivec/nsobjectprotocol.md)

## See Also

### Audio sources

- [SFSpeechURLRecognitionRequest](speech/sfspeechurlrecognitionrequest.md)
- [SFSpeechRecognitionRequest](speech/sfspeechrecognitionrequest.md)
