---
title: "init(detectionOptions:reportResults:)"
framework: speech
role: symbol
role_heading: Initializer
path: "speech/speechdetector/init(detectionoptions:reportresults:)"
---

# init(detectionOptions:reportResults:)

Creates a speech detector.

## Declaration

```swift
init(detectionOptions: SpeechDetector.DetectionOptions, reportResults: Bool)
```

## Parameters

- `detectionOptions`: Instance of doc://com.apple.speech/documentation/Speech/SpeechDetector/DetectionOptions that allows clients to customize the behavior of doc://com.apple.speech/documentation/Speech/SpeechDetector beyond its default settings.
- `reportResults`: Enables the doc://com.apple.speech/documentation/Speech/SpeechDetector/results sequence to report the VAD model’s results (and any relevant errors) back to clients. The default behavior is that doc://com.apple.speech/documentation/Speech/SpeechDetector does not report results or errors back to the client and merely enables VAD as a power optimization.

## See Also

### Creating a detector

- [init()](speech/speechdetector/init().md)
- [SpeechDetector.DetectionOptions](speech/speechdetector/detectionoptions.md)
- [SpeechDetector.SensitivityLevel](speech/speechdetector/sensitivitylevel.md)
