Class: Google::Cloud::Speech::V2::RecognitionConfig

Inherits:
Object
  • Object
show all
Extended by:
Protobuf::MessageExts::ClassMethods
Includes:
Protobuf::MessageExts
Defined in:
proto_docs/google/cloud/speech/v2/cloud_speech.rb

Overview

Provides information to the Recognizer that specifies how to process the recognition request.

Instance Attribute Summary collapse

Instance Attribute Details

#adaptation::Google::Cloud::Speech::V2::SpeechAdaptation

Returns Speech adaptation context that weights recognizer predictions for specific words and phrases.

Returns:



645
646
647
648
# File 'proto_docs/google/cloud/speech/v2/cloud_speech.rb', line 645

class RecognitionConfig
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods
end

#auto_decoding_config::Google::Cloud::Speech::V2::AutoDetectDecodingConfig

Returns Automatically detect decoding parameters. Preferred for supported formats.

Returns:



645
646
647
648
# File 'proto_docs/google/cloud/speech/v2/cloud_speech.rb', line 645

class RecognitionConfig
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods
end

#explicit_decoding_config::Google::Cloud::Speech::V2::ExplicitDecodingConfig

Returns Explicitly specified decoding parameters. Required if using headerless PCM audio (linear16, mulaw, alaw).

Returns:



645
646
647
648
# File 'proto_docs/google/cloud/speech/v2/cloud_speech.rb', line 645

class RecognitionConfig
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods
end

#features::Google::Cloud::Speech::V2::RecognitionFeatures

Returns Speech recognition features to enable.

Returns:



645
646
647
648
# File 'proto_docs/google/cloud/speech/v2/cloud_speech.rb', line 645

class RecognitionConfig
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods
end

#language_codes::Array<::String>

Returns Optional. The language of the supplied audio as a BCP-47 language tag. Language tags are normalized to BCP-47 before they are used eg "en-us" becomes "en-US".

Supported languages for each model are listed in the Table of Supported Models.

If additional languages are provided, recognition result will contain recognition in the most likely language detected. The recognition result will include the language tag of the language detected in the audio.

Returns:

  • (::Array<::String>)

    Optional. The language of the supplied audio as a BCP-47 language tag. Language tags are normalized to BCP-47 before they are used eg "en-us" becomes "en-US".

    Supported languages for each model are listed in the Table of Supported Models.

    If additional languages are provided, recognition result will contain recognition in the most likely language detected. The recognition result will include the language tag of the language detected in the audio.



645
646
647
648
# File 'proto_docs/google/cloud/speech/v2/cloud_speech.rb', line 645

class RecognitionConfig
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods
end

#model::String

Returns Optional. Which model to use for recognition requests. Select the model best suited to your domain to get best results.

Guidance for choosing which model to use can be found in the Transcription Models Documentation and the models supported in each region can be found in the Table Of Supported Models.

Returns:

  • (::String)

    Optional. Which model to use for recognition requests. Select the model best suited to your domain to get best results.

    Guidance for choosing which model to use can be found in the Transcription Models Documentation and the models supported in each region can be found in the Table Of Supported Models.



645
646
647
648
# File 'proto_docs/google/cloud/speech/v2/cloud_speech.rb', line 645

class RecognitionConfig
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods
end

#transcript_normalization::Google::Cloud::Speech::V2::TranscriptNormalization

Returns Optional. Use transcription normalization to automatically replace parts of the transcript with phrases of your choosing. For StreamingRecognize, this normalization only applies to stable partial transcripts (stability > 0.8) and final transcripts.

Returns:

  • (::Google::Cloud::Speech::V2::TranscriptNormalization)

    Optional. Use transcription normalization to automatically replace parts of the transcript with phrases of your choosing. For StreamingRecognize, this normalization only applies to stable partial transcripts (stability > 0.8) and final transcripts.



645
646
647
648
# File 'proto_docs/google/cloud/speech/v2/cloud_speech.rb', line 645

class RecognitionConfig
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods
end