Cloud Speech V1 Client - Class SpeakerDiarizationConfig (1.7.0)

Reference documentation and code samples for the Cloud Speech V1 Client class SpeakerDiarizationConfig.

Config to enable speaker diarization.

Generated from protobuf message google.cloud.speech.v1.SpeakerDiarizationConfig

Methods

__construct

Constructor.

Parameters
Name Description
data array

Optional. Data for populating the Message object.

↳ enable_speaker_diarization bool

If 'true', enables speaker detection for each recognized word in the top alternative of the recognition result using a speaker_tag provided in the WordInfo.

↳ min_speaker_count int

Minimum number of speakers in the conversation. This range gives you more flexibility by allowing the system to automatically determine the correct number of speakers. If not set, the default value is 2.

↳ max_speaker_count int

Maximum number of speakers in the conversation. This range gives you more flexibility by allowing the system to automatically determine the correct number of speakers. If not set, the default value is 6.

↳ speaker_tag int

Output only. Unused.

getEnableSpeakerDiarization

If 'true', enables speaker detection for each recognized word in the top alternative of the recognition result using a speaker_tag provided in the WordInfo.

Generated from protobuf field bool enable_speaker_diarization = 1;

Returns
Type Description
bool

setEnableSpeakerDiarization

If 'true', enables speaker detection for each recognized word in the top alternative of the recognition result using a speaker_tag provided in the WordInfo.

Generated from protobuf field bool enable_speaker_diarization = 1;

Parameter
Name Description
var bool
Returns
Type Description
$this

getMinSpeakerCount

Minimum number of speakers in the conversation. This range gives you more flexibility by allowing the system to automatically determine the correct number of speakers. If not set, the default value is 2.

Generated from protobuf field int32 min_speaker_count = 2;

Returns
Type Description
int

setMinSpeakerCount

Minimum number of speakers in the conversation. This range gives you more flexibility by allowing the system to automatically determine the correct number of speakers. If not set, the default value is 2.

Generated from protobuf field int32 min_speaker_count = 2;

Parameter
Name Description
var int
Returns
Type Description
$this

getMaxSpeakerCount

Maximum number of speakers in the conversation. This range gives you more flexibility by allowing the system to automatically determine the correct number of speakers. If not set, the default value is 6.

Generated from protobuf field int32 max_speaker_count = 3;

Returns
Type Description
int

setMaxSpeakerCount

Maximum number of speakers in the conversation. This range gives you more flexibility by allowing the system to automatically determine the correct number of speakers. If not set, the default value is 6.

Generated from protobuf field int32 max_speaker_count = 3;

Parameter
Name Description
var int
Returns
Type Description
$this

getSpeakerTag

Output only. Unused.

Generated from protobuf field int32 speaker_tag = 5 [deprecated = true, (.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
int

setSpeakerTag

Output only. Unused.

Generated from protobuf field int32 speaker_tag = 5 [deprecated = true, (.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
var int
Returns
Type Description
$this