// Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.36.11 // protoc v5.29.0 // source: rime/speech_to_text.proto package rimeapi import ( protoreflect "google.golang.org/protobuf/reflect/protoreflect" protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" unsafe "unsafe" ) const ( // Verify that this generated code is sufficiently up-to-date. _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) // Verify that runtime/protoimpl is sufficiently up-to-date. _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) ) // Output formatting intent. The packaged model prompt describes the intent; // it steers the model rather than hard-guaranteeing token-level behavior. type TranscriptionMode int32 const ( // Defaults to TRANSCRIPTION_MODE_WRITTEN. TranscriptionMode_TRANSCRIPTION_MODE_UNSPECIFIED TranscriptionMode = 0 // Standard written formatting: numerals as digits, codes compact. // "flight two four seven" is intended to come back as "flight 247". TranscriptionMode_TRANSCRIPTION_MODE_WRITTEN TranscriptionMode = 1 // Verbatim rendering: keep every filler, repetition, and false start; // numbers as spoken words. "uh flight two four seven" is intended to come // back as "uh flight two four seven". TranscriptionMode_TRANSCRIPTION_MODE_VERBATIM TranscriptionMode = 2 ) // Enum value maps for TranscriptionMode. var ( TranscriptionMode_name = map[int32]string{ 0: "TRANSCRIPTION_MODE_UNSPECIFIED", 1: "TRANSCRIPTION_MODE_WRITTEN", 2: "TRANSCRIPTION_MODE_VERBATIM", } TranscriptionMode_value = map[string]int32{ "TRANSCRIPTION_MODE_UNSPECIFIED": 0, "TRANSCRIPTION_MODE_WRITTEN": 1, "TRANSCRIPTION_MODE_VERBATIM": 2, } ) func (x TranscriptionMode) Enum() *TranscriptionMode { p := new(TranscriptionMode) *p = x return p } func (x TranscriptionMode) String() string { return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) } func (TranscriptionMode) Descriptor() protoreflect.EnumDescriptor { return file_rime_speech_to_text_proto_enumTypes[0].Descriptor() } func (TranscriptionMode) Type() protoreflect.EnumType { return &file_rime_speech_to_text_proto_enumTypes[0] } func (x TranscriptionMode) Number() protoreflect.EnumNumber { return protoreflect.EnumNumber(x) } // Deprecated: Use TranscriptionMode.Descriptor instead. func (TranscriptionMode) EnumDescriptor() ([]byte, []int) { return file_rime_speech_to_text_proto_rawDescGZIP(), []int{0} } // How the resolved language was chosen. type LanguageSource int32 const ( // The service could not resolve a catalog language for this result. Never // a silent substitute for LANGUAGE_SOURCE_SELECTED or // LANGUAGE_SOURCE_DETECTED. LanguageSource_LANGUAGE_SOURCE_UNSPECIFIED LanguageSource = 0 // The caller supplied the language and the service confirmed it against // the packaged model catalog. LanguageSource_LANGUAGE_SOURCE_SELECTED LanguageSource = 1 // The model detected the served catalog language. Not produced while every // request must select its language. LanguageSource_LANGUAGE_SOURCE_DETECTED LanguageSource = 2 ) // Enum value maps for LanguageSource. var ( LanguageSource_name = map[int32]string{ 0: "LANGUAGE_SOURCE_UNSPECIFIED", 1: "LANGUAGE_SOURCE_SELECTED", 2: "LANGUAGE_SOURCE_DETECTED", } LanguageSource_value = map[string]int32{ "LANGUAGE_SOURCE_UNSPECIFIED": 0, "LANGUAGE_SOURCE_SELECTED": 1, "LANGUAGE_SOURCE_DETECTED": 2, } ) func (x LanguageSource) Enum() *LanguageSource { p := new(LanguageSource) *p = x return p } func (x LanguageSource) String() string { return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) } func (LanguageSource) Descriptor() protoreflect.EnumDescriptor { return file_rime_speech_to_text_proto_enumTypes[1].Descriptor() } func (LanguageSource) Type() protoreflect.EnumType { return &file_rime_speech_to_text_proto_enumTypes[1] } func (x LanguageSource) Number() protoreflect.EnumNumber { return protoreflect.EnumNumber(x) } // Deprecated: Use LanguageSource.Descriptor instead. func (LanguageSource) EnumDescriptor() ([]byte, []int) { return file_rime_speech_to_text_proto_rawDescGZIP(), []int{1} } // Which streaming output contract the session uses. type StreamingOutputContract int32 const ( // Invalid for a request: callers must explicitly select an output contract. StreamingOutputContract_STREAMING_OUTPUT_CONTRACT_UNSPECIFIED StreamingOutputContract = 0 // Responses are append-only `delta` fragments: each five-second window of // audio is transcribed once, on its own, so a fragment is never revised. // Concatenate them in arrival order (including newline separators between // transcription windows) to form the transcript. The final `done` text // equals that concatenation. StreamingOutputContract_STREAMING_OUTPUT_CONTRACT_APPEND_FRAGMENTS StreamingOutputContract = 1 // Responses are full replacing `hypothesis` transcripts: each hypothesis // carries the complete current transcript and a monotonically increasing // revision, and entirely replaces the previous one. The final `done` text // equals the last hypothesis and carries its revision; an utterance with // no recognized speech may emit no hypothesis and finishes with an empty // final at revision zero. StreamingOutputContract_STREAMING_OUTPUT_CONTRACT_REVISED_HYPOTHESES StreamingOutputContract = 2 ) // Enum value maps for StreamingOutputContract. var ( StreamingOutputContract_name = map[int32]string{ 0: "STREAMING_OUTPUT_CONTRACT_UNSPECIFIED", 1: "STREAMING_OUTPUT_CONTRACT_APPEND_FRAGMENTS", 2: "STREAMING_OUTPUT_CONTRACT_REVISED_HYPOTHESES", } StreamingOutputContract_value = map[string]int32{ "STREAMING_OUTPUT_CONTRACT_UNSPECIFIED": 0, "STREAMING_OUTPUT_CONTRACT_APPEND_FRAGMENTS": 1, "STREAMING_OUTPUT_CONTRACT_REVISED_HYPOTHESES": 2, } ) func (x StreamingOutputContract) Enum() *StreamingOutputContract { p := new(StreamingOutputContract) *p = x return p } func (x StreamingOutputContract) String() string { return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) } func (StreamingOutputContract) Descriptor() protoreflect.EnumDescriptor { return file_rime_speech_to_text_proto_enumTypes[2].Descriptor() } func (StreamingOutputContract) Type() protoreflect.EnumType { return &file_rime_speech_to_text_proto_enumTypes[2] } func (x StreamingOutputContract) Number() protoreflect.EnumNumber { return protoreflect.EnumNumber(x) } // Deprecated: Use StreamingOutputContract.Descriptor instead. func (StreamingOutputContract) EnumDescriptor() ([]byte, []int) { return file_rime_speech_to_text_proto_rawDescGZIP(), []int{2} } type TranscriptionOptions struct { state protoimpl.MessageState `protogen:"open.v1"` // Required BCP-47 tag of the spoken language, resolved against the packaged // catalog (`en` or `es`). An omitted tag or `und` is rejected with // INVALID_ARGUMENT. Language *string `protobuf:"bytes,1,opt,name=language,proto3,oneof" json:"language,omitempty"` Mode TranscriptionMode `protobuf:"varint,2,opt,name=mode,proto3,enum=rime.TranscriptionMode" json:"mode,omitempty"` // Recognition terms, for example ["Mitchell Gourley", "Super-G", "USOC"]. // An empty list adds no bias; the service rejects empty or whitespace-only // terms. Order and term text are preserved, with ", " inserted between // terms before composition into the packaged mode prompt. The packaged // model's caller-context budget counts UTF-8 bytes including separators; // the composed prompt keeps the mode prompt intact. // Terms softly bias recognition without forcing a match; per-word weights // are not supported. ContextTerms []string `protobuf:"bytes,3,rep,name=context_terms,json=contextTerms,proto3" json:"context_terms,omitempty"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *TranscriptionOptions) Reset() { *x = TranscriptionOptions{} mi := &file_rime_speech_to_text_proto_msgTypes[0] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *TranscriptionOptions) String() string { return protoimpl.X.MessageStringOf(x) } func (*TranscriptionOptions) ProtoMessage() {} func (x *TranscriptionOptions) ProtoReflect() protoreflect.Message { mi := &file_rime_speech_to_text_proto_msgTypes[0] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use TranscriptionOptions.ProtoReflect.Descriptor instead. func (*TranscriptionOptions) Descriptor() ([]byte, []int) { return file_rime_speech_to_text_proto_rawDescGZIP(), []int{0} } func (x *TranscriptionOptions) GetLanguage() string { if x != nil && x.Language != nil { return *x.Language } return "" } func (x *TranscriptionOptions) GetMode() TranscriptionMode { if x != nil { return x.Mode } return TranscriptionMode_TRANSCRIPTION_MODE_UNSPECIFIED } func (x *TranscriptionOptions) GetContextTerms() []string { if x != nil { return x.ContextTerms } return nil } type ResolvedLanguage struct { state protoimpl.MessageState `protogen:"open.v1"` // Canonical BCP-47 tag drawn from the packaged model catalog. Tag string `protobuf:"bytes,1,opt,name=tag,proto3" json:"tag,omitempty"` Source LanguageSource `protobuf:"varint,2,opt,name=source,proto3,enum=rime.LanguageSource" json:"source,omitempty"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *ResolvedLanguage) Reset() { *x = ResolvedLanguage{} mi := &file_rime_speech_to_text_proto_msgTypes[1] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *ResolvedLanguage) String() string { return protoimpl.X.MessageStringOf(x) } func (*ResolvedLanguage) ProtoMessage() {} func (x *ResolvedLanguage) ProtoReflect() protoreflect.Message { mi := &file_rime_speech_to_text_proto_msgTypes[1] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use ResolvedLanguage.ProtoReflect.Descriptor instead. func (*ResolvedLanguage) Descriptor() ([]byte, []int) { return file_rime_speech_to_text_proto_rawDescGZIP(), []int{1} } func (x *ResolvedLanguage) GetTag() string { if x != nil { return x.Tag } return "" } func (x *ResolvedLanguage) GetSource() LanguageSource { if x != nil { return x.Source } return LanguageSource_LANGUAGE_SOURCE_UNSPECIFIED } type TranscriptionRequest struct { state protoimpl.MessageState `protogen:"open.v1"` // A complete WAV file, including its RIFF/WAVE header, bounded to 16 MiB. // PCM16 little-endian mono 16 kHz is the qualified input format. The // packaged decoder may accept other WAV encodings/rates; those extensions // are not a portable interface guarantee. Headerless PCM is not WAV. Audio []byte `protobuf:"bytes,1,opt,name=audio,proto3" json:"audio,omitempty"` // Required: `language` must select the spoken language. Options *TranscriptionOptions `protobuf:"bytes,2,opt,name=options,proto3,oneof" json:"options,omitempty"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *TranscriptionRequest) Reset() { *x = TranscriptionRequest{} mi := &file_rime_speech_to_text_proto_msgTypes[2] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *TranscriptionRequest) String() string { return protoimpl.X.MessageStringOf(x) } func (*TranscriptionRequest) ProtoMessage() {} func (x *TranscriptionRequest) ProtoReflect() protoreflect.Message { mi := &file_rime_speech_to_text_proto_msgTypes[2] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use TranscriptionRequest.ProtoReflect.Descriptor instead. func (*TranscriptionRequest) Descriptor() ([]byte, []int) { return file_rime_speech_to_text_proto_rawDescGZIP(), []int{2} } func (x *TranscriptionRequest) GetAudio() []byte { if x != nil { return x.Audio } return nil } func (x *TranscriptionRequest) GetOptions() *TranscriptionOptions { if x != nil { return x.Options } return nil } type TranscriptionResponse struct { state protoimpl.MessageState `protogen:"open.v1"` Text string `protobuf:"bytes,1,opt,name=text,proto3" json:"text,omitempty"` // The canonical catalog language the caller selected. Language *ResolvedLanguage `protobuf:"bytes,2,opt,name=language,proto3,oneof" json:"language,omitempty"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *TranscriptionResponse) Reset() { *x = TranscriptionResponse{} mi := &file_rime_speech_to_text_proto_msgTypes[3] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *TranscriptionResponse) String() string { return protoimpl.X.MessageStringOf(x) } func (*TranscriptionResponse) ProtoMessage() {} func (x *TranscriptionResponse) ProtoReflect() protoreflect.Message { mi := &file_rime_speech_to_text_proto_msgTypes[3] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use TranscriptionResponse.ProtoReflect.Descriptor instead. func (*TranscriptionResponse) Descriptor() ([]byte, []int) { return file_rime_speech_to_text_proto_rawDescGZIP(), []int{3} } func (x *TranscriptionResponse) GetText() string { if x != nil { return x.Text } return "" } func (x *TranscriptionResponse) GetLanguage() *ResolvedLanguage { if x != nil { return x.Language } return nil } // Streaming input is always headerless signed PCM16 little-endian mono // 16 kHz; the format is not configurable. type StreamingConfig struct { state protoimpl.MessageState `protogen:"open.v1"` // Under either output contract, `language` is a required BCP-47 tag (an // omitted tag or `und` is rejected) and `mode` selects the written or // verbatim prompt. Language *string `protobuf:"bytes,3,opt,name=language,proto3,oneof" json:"language,omitempty"` Mode TranscriptionMode `protobuf:"varint,4,opt,name=mode,proto3,enum=rime.TranscriptionMode" json:"mode,omitempty"` // Explicitly selects the output contract. The service confirms the // selection before accepting audio; an unrecognized value is rejected // rather than silently downgraded. OutputContract StreamingOutputContract `protobuf:"varint,5,opt,name=output_contract,json=outputContract,proto3,enum=rime.StreamingOutputContract" json:"output_contract,omitempty"` // Recognition terms under either output contract. Same validation, budgets // and composition as TranscriptionOptions.context_terms; an empty list adds // no bias. ContextTerms []string `protobuf:"bytes,6,rep,name=context_terms,json=contextTerms,proto3" json:"context_terms,omitempty"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *StreamingConfig) Reset() { *x = StreamingConfig{} mi := &file_rime_speech_to_text_proto_msgTypes[4] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *StreamingConfig) String() string { return protoimpl.X.MessageStringOf(x) } func (*StreamingConfig) ProtoMessage() {} func (x *StreamingConfig) ProtoReflect() protoreflect.Message { mi := &file_rime_speech_to_text_proto_msgTypes[4] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use StreamingConfig.ProtoReflect.Descriptor instead. func (*StreamingConfig) Descriptor() ([]byte, []int) { return file_rime_speech_to_text_proto_rawDescGZIP(), []int{4} } func (x *StreamingConfig) GetLanguage() string { if x != nil && x.Language != nil { return *x.Language } return "" } func (x *StreamingConfig) GetMode() TranscriptionMode { if x != nil { return x.Mode } return TranscriptionMode_TRANSCRIPTION_MODE_UNSPECIFIED } func (x *StreamingConfig) GetOutputContract() StreamingOutputContract { if x != nil { return x.OutputContract } return StreamingOutputContract_STREAMING_OUTPUT_CONTRACT_UNSPECIFIED } func (x *StreamingConfig) GetContextTerms() []string { if x != nil { return x.ContextTerms } return nil } type StreamingTranscriptionRequest struct { state protoimpl.MessageState `protogen:"open.v1"` // Types that are valid to be assigned to Payload: // // *StreamingTranscriptionRequest_Config // *StreamingTranscriptionRequest_Audio Payload isStreamingTranscriptionRequest_Payload `protobuf_oneof:"payload"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *StreamingTranscriptionRequest) Reset() { *x = StreamingTranscriptionRequest{} mi := &file_rime_speech_to_text_proto_msgTypes[5] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *StreamingTranscriptionRequest) String() string { return protoimpl.X.MessageStringOf(x) } func (*StreamingTranscriptionRequest) ProtoMessage() {} func (x *StreamingTranscriptionRequest) ProtoReflect() protoreflect.Message { mi := &file_rime_speech_to_text_proto_msgTypes[5] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use StreamingTranscriptionRequest.ProtoReflect.Descriptor instead. func (*StreamingTranscriptionRequest) Descriptor() ([]byte, []int) { return file_rime_speech_to_text_proto_rawDescGZIP(), []int{5} } func (x *StreamingTranscriptionRequest) GetPayload() isStreamingTranscriptionRequest_Payload { if x != nil { return x.Payload } return nil } func (x *StreamingTranscriptionRequest) GetConfig() *StreamingConfig { if x != nil { if x, ok := x.Payload.(*StreamingTranscriptionRequest_Config); ok { return x.Config } } return nil } func (x *StreamingTranscriptionRequest) GetAudio() []byte { if x != nil { if x, ok := x.Payload.(*StreamingTranscriptionRequest_Audio); ok { return x.Audio } } return nil } type isStreamingTranscriptionRequest_Payload interface { isStreamingTranscriptionRequest_Payload() } type StreamingTranscriptionRequest_Config struct { // Required exactly once as the first request. Config *StreamingConfig `protobuf:"bytes,1,opt,name=config,proto3,oneof"` } type StreamingTranscriptionRequest_Audio struct { // PCM16 bytes. Each message is bounded to 64 KiB and the utterance to // 16 MiB. An odd byte count is invalid. Audio []byte `protobuf:"bytes,2,opt,name=audio,proto3,oneof"` } func (*StreamingTranscriptionRequest_Config) isStreamingTranscriptionRequest_Payload() {} func (*StreamingTranscriptionRequest_Audio) isStreamingTranscriptionRequest_Payload() {} type StreamingTranscriptionResponse struct { state protoimpl.MessageState `protogen:"open.v1"` // Types that are valid to be assigned to Payload: // // *StreamingTranscriptionResponse_Delta // *StreamingTranscriptionResponse_Done // *StreamingTranscriptionResponse_Accepted // *StreamingTranscriptionResponse_Hypothesis Payload isStreamingTranscriptionResponse_Payload `protobuf_oneof:"payload"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *StreamingTranscriptionResponse) Reset() { *x = StreamingTranscriptionResponse{} mi := &file_rime_speech_to_text_proto_msgTypes[6] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *StreamingTranscriptionResponse) String() string { return protoimpl.X.MessageStringOf(x) } func (*StreamingTranscriptionResponse) ProtoMessage() {} func (x *StreamingTranscriptionResponse) ProtoReflect() protoreflect.Message { mi := &file_rime_speech_to_text_proto_msgTypes[6] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use StreamingTranscriptionResponse.ProtoReflect.Descriptor instead. func (*StreamingTranscriptionResponse) Descriptor() ([]byte, []int) { return file_rime_speech_to_text_proto_rawDescGZIP(), []int{6} } func (x *StreamingTranscriptionResponse) GetPayload() isStreamingTranscriptionResponse_Payload { if x != nil { return x.Payload } return nil } func (x *StreamingTranscriptionResponse) GetDelta() *TranscriptionDelta { if x != nil { if x, ok := x.Payload.(*StreamingTranscriptionResponse_Delta); ok { return x.Delta } } return nil } func (x *StreamingTranscriptionResponse) GetDone() *TranscriptionDone { if x != nil { if x, ok := x.Payload.(*StreamingTranscriptionResponse_Done); ok { return x.Done } } return nil } func (x *StreamingTranscriptionResponse) GetAccepted() *StreamingAccepted { if x != nil { if x, ok := x.Payload.(*StreamingTranscriptionResponse_Accepted); ok { return x.Accepted } } return nil } func (x *StreamingTranscriptionResponse) GetHypothesis() *TranscriptionHypothesis { if x != nil { if x, ok := x.Payload.(*StreamingTranscriptionResponse_Hypothesis); ok { return x.Hypothesis } } return nil } type isStreamingTranscriptionResponse_Payload interface { isStreamingTranscriptionResponse_Payload() } type StreamingTranscriptionResponse_Delta struct { // An append-only transcript fragment under the append-fragment contract. // Concatenate deltas in arrival order, including newline separators // between transcription windows; they are not replacement hypotheses. Delta *TranscriptionDelta `protobuf:"bytes,1,opt,name=delta,proto3,oneof"` } type StreamingTranscriptionResponse_Done struct { // Exactly one final transcript for a successfully completed utterance. // Under the append-fragment contract its text equals the concatenation of // all preceding delta fragments; under // STREAMING_OUTPUT_CONTRACT_REVISED_HYPOTHESES it equals the last // hypothesis. It may be empty when the input contains no recognized // speech. Done *TranscriptionDone `protobuf:"bytes,2,opt,name=done,proto3,oneof"` } type StreamingTranscriptionResponse_Accepted struct { // Confirms the selected output contract before any audio-derived // response. Every accepted configuration selects // STREAMING_OUTPUT_CONTRACT_APPEND_FRAGMENTS or // STREAMING_OUTPUT_CONTRACT_REVISED_HYPOTHESES; // STREAMING_OUTPUT_CONTRACT_UNSPECIFIED is rejected as invalid input. Accepted *StreamingAccepted `protobuf:"bytes,3,opt,name=accepted,proto3,oneof"` } type StreamingTranscriptionResponse_Hypothesis struct { // The latest full transcript hypothesis under // STREAMING_OUTPUT_CONTRACT_REVISED_HYPOTHESES. Each hypothesis replaces // the previous one entirely. Hypothesis *TranscriptionHypothesis `protobuf:"bytes,4,opt,name=hypothesis,proto3,oneof"` } func (*StreamingTranscriptionResponse_Delta) isStreamingTranscriptionResponse_Payload() {} func (*StreamingTranscriptionResponse_Done) isStreamingTranscriptionResponse_Payload() {} func (*StreamingTranscriptionResponse_Accepted) isStreamingTranscriptionResponse_Payload() {} func (*StreamingTranscriptionResponse_Hypothesis) isStreamingTranscriptionResponse_Payload() {} type StreamingAccepted struct { state protoimpl.MessageState `protogen:"open.v1"` OutputContract StreamingOutputContract `protobuf:"varint,1,opt,name=output_contract,json=outputContract,proto3,enum=rime.StreamingOutputContract" json:"output_contract,omitempty"` // Confirms the selected language. Language *ResolvedLanguage `protobuf:"bytes,2,opt,name=language,proto3,oneof" json:"language,omitempty"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *StreamingAccepted) Reset() { *x = StreamingAccepted{} mi := &file_rime_speech_to_text_proto_msgTypes[7] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *StreamingAccepted) String() string { return protoimpl.X.MessageStringOf(x) } func (*StreamingAccepted) ProtoMessage() {} func (x *StreamingAccepted) ProtoReflect() protoreflect.Message { mi := &file_rime_speech_to_text_proto_msgTypes[7] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use StreamingAccepted.ProtoReflect.Descriptor instead. func (*StreamingAccepted) Descriptor() ([]byte, []int) { return file_rime_speech_to_text_proto_rawDescGZIP(), []int{7} } func (x *StreamingAccepted) GetOutputContract() StreamingOutputContract { if x != nil { return x.OutputContract } return StreamingOutputContract_STREAMING_OUTPUT_CONTRACT_UNSPECIFIED } func (x *StreamingAccepted) GetLanguage() *ResolvedLanguage { if x != nil { return x.Language } return nil } type TranscriptionDelta struct { state protoimpl.MessageState `protogen:"open.v1"` Text string `protobuf:"bytes,1,opt,name=text,proto3" json:"text,omitempty"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *TranscriptionDelta) Reset() { *x = TranscriptionDelta{} mi := &file_rime_speech_to_text_proto_msgTypes[8] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *TranscriptionDelta) String() string { return protoimpl.X.MessageStringOf(x) } func (*TranscriptionDelta) ProtoMessage() {} func (x *TranscriptionDelta) ProtoReflect() protoreflect.Message { mi := &file_rime_speech_to_text_proto_msgTypes[8] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use TranscriptionDelta.ProtoReflect.Descriptor instead. func (*TranscriptionDelta) Descriptor() ([]byte, []int) { return file_rime_speech_to_text_proto_rawDescGZIP(), []int{8} } func (x *TranscriptionDelta) GetText() string { if x != nil { return x.Text } return "" } // A full-hypothesis partial. `text` is the complete current transcript, not a // delta; a later hypothesis with a higher revision replaces it. type TranscriptionHypothesis struct { state protoimpl.MessageState `protogen:"open.v1"` Text string `protobuf:"bytes,1,opt,name=text,proto3" json:"text,omitempty"` // Monotonically increasing within a session, starting at 1. Revision uint64 `protobuf:"varint,2,opt,name=revision,proto3" json:"revision,omitempty"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *TranscriptionHypothesis) Reset() { *x = TranscriptionHypothesis{} mi := &file_rime_speech_to_text_proto_msgTypes[9] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *TranscriptionHypothesis) String() string { return protoimpl.X.MessageStringOf(x) } func (*TranscriptionHypothesis) ProtoMessage() {} func (x *TranscriptionHypothesis) ProtoReflect() protoreflect.Message { mi := &file_rime_speech_to_text_proto_msgTypes[9] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use TranscriptionHypothesis.ProtoReflect.Descriptor instead. func (*TranscriptionHypothesis) Descriptor() ([]byte, []int) { return file_rime_speech_to_text_proto_rawDescGZIP(), []int{9} } func (x *TranscriptionHypothesis) GetText() string { if x != nil { return x.Text } return "" } func (x *TranscriptionHypothesis) GetRevision() uint64 { if x != nil { return x.Revision } return 0 } type TranscriptionDone struct { state protoimpl.MessageState `protogen:"open.v1"` Text string `protobuf:"bytes,1,opt,name=text,proto3" json:"text,omitempty"` // See TranscriptionResponse.language. Reported under either output // contract. Language *ResolvedLanguage `protobuf:"bytes,2,opt,name=language,proto3,oneof" json:"language,omitempty"` // The revision of the final hypothesis under // STREAMING_OUTPUT_CONTRACT_REVISED_HYPOTHESES; zero under the // append-fragment contract. Revision uint64 `protobuf:"varint,3,opt,name=revision,proto3" json:"revision,omitempty"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *TranscriptionDone) Reset() { *x = TranscriptionDone{} mi := &file_rime_speech_to_text_proto_msgTypes[10] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *TranscriptionDone) String() string { return protoimpl.X.MessageStringOf(x) } func (*TranscriptionDone) ProtoMessage() {} func (x *TranscriptionDone) ProtoReflect() protoreflect.Message { mi := &file_rime_speech_to_text_proto_msgTypes[10] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use TranscriptionDone.ProtoReflect.Descriptor instead. func (*TranscriptionDone) Descriptor() ([]byte, []int) { return file_rime_speech_to_text_proto_rawDescGZIP(), []int{10} } func (x *TranscriptionDone) GetText() string { if x != nil { return x.Text } return "" } func (x *TranscriptionDone) GetLanguage() *ResolvedLanguage { if x != nil { return x.Language } return nil } func (x *TranscriptionDone) GetRevision() uint64 { if x != nil { return x.Revision } return 0 } type SpeechWebSocketRequest struct { state protoimpl.MessageState `protogen:"open.v1"` // Types that are valid to be assigned to Payload: // // *SpeechWebSocketRequest_Start // *SpeechWebSocketRequest_Audio // *SpeechWebSocketRequest_End // *SpeechWebSocketRequest_Cancel Payload isSpeechWebSocketRequest_Payload `protobuf_oneof:"payload"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *SpeechWebSocketRequest) Reset() { *x = SpeechWebSocketRequest{} mi := &file_rime_speech_to_text_proto_msgTypes[11] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *SpeechWebSocketRequest) String() string { return protoimpl.X.MessageStringOf(x) } func (*SpeechWebSocketRequest) ProtoMessage() {} func (x *SpeechWebSocketRequest) ProtoReflect() protoreflect.Message { mi := &file_rime_speech_to_text_proto_msgTypes[11] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use SpeechWebSocketRequest.ProtoReflect.Descriptor instead. func (*SpeechWebSocketRequest) Descriptor() ([]byte, []int) { return file_rime_speech_to_text_proto_rawDescGZIP(), []int{11} } func (x *SpeechWebSocketRequest) GetPayload() isSpeechWebSocketRequest_Payload { if x != nil { return x.Payload } return nil } func (x *SpeechWebSocketRequest) GetStart() *StreamingConfig { if x != nil { if x, ok := x.Payload.(*SpeechWebSocketRequest_Start); ok { return x.Start } } return nil } func (x *SpeechWebSocketRequest) GetAudio() []byte { if x != nil { if x, ok := x.Payload.(*SpeechWebSocketRequest_Audio); ok { return x.Audio } } return nil } func (x *SpeechWebSocketRequest) GetEnd() *SpeechWebSocketEnd { if x != nil { if x, ok := x.Payload.(*SpeechWebSocketRequest_End); ok { return x.End } } return nil } func (x *SpeechWebSocketRequest) GetCancel() *SpeechWebSocketCancel { if x != nil { if x, ok := x.Payload.(*SpeechWebSocketRequest_Cancel); ok { return x.Cancel } } return nil } type isSpeechWebSocketRequest_Payload interface { isSpeechWebSocketRequest_Payload() } type SpeechWebSocketRequest_Start struct { Start *StreamingConfig `protobuf:"bytes,1,opt,name=start,proto3,oneof"` } type SpeechWebSocketRequest_Audio struct { Audio []byte `protobuf:"bytes,2,opt,name=audio,proto3,oneof"` } type SpeechWebSocketRequest_End struct { End *SpeechWebSocketEnd `protobuf:"bytes,3,opt,name=end,proto3,oneof"` } type SpeechWebSocketRequest_Cancel struct { Cancel *SpeechWebSocketCancel `protobuf:"bytes,4,opt,name=cancel,proto3,oneof"` } func (*SpeechWebSocketRequest_Start) isSpeechWebSocketRequest_Payload() {} func (*SpeechWebSocketRequest_Audio) isSpeechWebSocketRequest_Payload() {} func (*SpeechWebSocketRequest_End) isSpeechWebSocketRequest_Payload() {} func (*SpeechWebSocketRequest_Cancel) isSpeechWebSocketRequest_Payload() {} type SpeechWebSocketEnd struct { state protoimpl.MessageState `protogen:"open.v1"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *SpeechWebSocketEnd) Reset() { *x = SpeechWebSocketEnd{} mi := &file_rime_speech_to_text_proto_msgTypes[12] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *SpeechWebSocketEnd) String() string { return protoimpl.X.MessageStringOf(x) } func (*SpeechWebSocketEnd) ProtoMessage() {} func (x *SpeechWebSocketEnd) ProtoReflect() protoreflect.Message { mi := &file_rime_speech_to_text_proto_msgTypes[12] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use SpeechWebSocketEnd.ProtoReflect.Descriptor instead. func (*SpeechWebSocketEnd) Descriptor() ([]byte, []int) { return file_rime_speech_to_text_proto_rawDescGZIP(), []int{12} } type SpeechWebSocketCancel struct { state protoimpl.MessageState `protogen:"open.v1"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *SpeechWebSocketCancel) Reset() { *x = SpeechWebSocketCancel{} mi := &file_rime_speech_to_text_proto_msgTypes[13] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *SpeechWebSocketCancel) String() string { return protoimpl.X.MessageStringOf(x) } func (*SpeechWebSocketCancel) ProtoMessage() {} func (x *SpeechWebSocketCancel) ProtoReflect() protoreflect.Message { mi := &file_rime_speech_to_text_proto_msgTypes[13] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use SpeechWebSocketCancel.ProtoReflect.Descriptor instead. func (*SpeechWebSocketCancel) Descriptor() ([]byte, []int) { return file_rime_speech_to_text_proto_rawDescGZIP(), []int{13} } type SpeechWebSocketResponse struct { state protoimpl.MessageState `protogen:"open.v1"` // Types that are valid to be assigned to Payload: // // *SpeechWebSocketResponse_Started // *SpeechWebSocketResponse_Delta // *SpeechWebSocketResponse_Done // *SpeechWebSocketResponse_Error // *SpeechWebSocketResponse_Cancelled // *SpeechWebSocketResponse_Hypothesis Payload isSpeechWebSocketResponse_Payload `protobuf_oneof:"payload"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *SpeechWebSocketResponse) Reset() { *x = SpeechWebSocketResponse{} mi := &file_rime_speech_to_text_proto_msgTypes[14] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *SpeechWebSocketResponse) String() string { return protoimpl.X.MessageStringOf(x) } func (*SpeechWebSocketResponse) ProtoMessage() {} func (x *SpeechWebSocketResponse) ProtoReflect() protoreflect.Message { mi := &file_rime_speech_to_text_proto_msgTypes[14] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use SpeechWebSocketResponse.ProtoReflect.Descriptor instead. func (*SpeechWebSocketResponse) Descriptor() ([]byte, []int) { return file_rime_speech_to_text_proto_rawDescGZIP(), []int{14} } func (x *SpeechWebSocketResponse) GetPayload() isSpeechWebSocketResponse_Payload { if x != nil { return x.Payload } return nil } func (x *SpeechWebSocketResponse) GetStarted() *SpeechWebSocketStarted { if x != nil { if x, ok := x.Payload.(*SpeechWebSocketResponse_Started); ok { return x.Started } } return nil } func (x *SpeechWebSocketResponse) GetDelta() *TranscriptionDelta { if x != nil { if x, ok := x.Payload.(*SpeechWebSocketResponse_Delta); ok { return x.Delta } } return nil } func (x *SpeechWebSocketResponse) GetDone() *TranscriptionDone { if x != nil { if x, ok := x.Payload.(*SpeechWebSocketResponse_Done); ok { return x.Done } } return nil } func (x *SpeechWebSocketResponse) GetError() *SpeechWebSocketError { if x != nil { if x, ok := x.Payload.(*SpeechWebSocketResponse_Error); ok { return x.Error } } return nil } func (x *SpeechWebSocketResponse) GetCancelled() *SpeechWebSocketCancelled { if x != nil { if x, ok := x.Payload.(*SpeechWebSocketResponse_Cancelled); ok { return x.Cancelled } } return nil } func (x *SpeechWebSocketResponse) GetHypothesis() *TranscriptionHypothesis { if x != nil { if x, ok := x.Payload.(*SpeechWebSocketResponse_Hypothesis); ok { return x.Hypothesis } } return nil } type isSpeechWebSocketResponse_Payload interface { isSpeechWebSocketResponse_Payload() } type SpeechWebSocketResponse_Started struct { Started *SpeechWebSocketStarted `protobuf:"bytes,1,opt,name=started,proto3,oneof"` } type SpeechWebSocketResponse_Delta struct { Delta *TranscriptionDelta `protobuf:"bytes,2,opt,name=delta,proto3,oneof"` } type SpeechWebSocketResponse_Done struct { Done *TranscriptionDone `protobuf:"bytes,3,opt,name=done,proto3,oneof"` } type SpeechWebSocketResponse_Error struct { Error *SpeechWebSocketError `protobuf:"bytes,4,opt,name=error,proto3,oneof"` } type SpeechWebSocketResponse_Cancelled struct { Cancelled *SpeechWebSocketCancelled `protobuf:"bytes,5,opt,name=cancelled,proto3,oneof"` } type SpeechWebSocketResponse_Hypothesis struct { // Full-hypothesis partial under // STREAMING_OUTPUT_CONTRACT_REVISED_HYPOTHESES; see // TranscriptionHypothesis. Hypothesis *TranscriptionHypothesis `protobuf:"bytes,6,opt,name=hypothesis,proto3,oneof"` } func (*SpeechWebSocketResponse_Started) isSpeechWebSocketResponse_Payload() {} func (*SpeechWebSocketResponse_Delta) isSpeechWebSocketResponse_Payload() {} func (*SpeechWebSocketResponse_Done) isSpeechWebSocketResponse_Payload() {} func (*SpeechWebSocketResponse_Error) isSpeechWebSocketResponse_Payload() {} func (*SpeechWebSocketResponse_Cancelled) isSpeechWebSocketResponse_Payload() {} func (*SpeechWebSocketResponse_Hypothesis) isSpeechWebSocketResponse_Payload() {} type SpeechWebSocketStarted struct { state protoimpl.MessageState `protogen:"open.v1"` RequestId string `protobuf:"bytes,1,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"` // Confirms STREAMING_OUTPUT_CONTRACT_APPEND_FRAGMENTS or // STREAMING_OUTPUT_CONTRACT_REVISED_HYPOTHESES before any audio-derived // response. Present for every accepted configuration. Accepted *StreamingAccepted `protobuf:"bytes,2,opt,name=accepted,proto3,oneof" json:"accepted,omitempty"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *SpeechWebSocketStarted) Reset() { *x = SpeechWebSocketStarted{} mi := &file_rime_speech_to_text_proto_msgTypes[15] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *SpeechWebSocketStarted) String() string { return protoimpl.X.MessageStringOf(x) } func (*SpeechWebSocketStarted) ProtoMessage() {} func (x *SpeechWebSocketStarted) ProtoReflect() protoreflect.Message { mi := &file_rime_speech_to_text_proto_msgTypes[15] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use SpeechWebSocketStarted.ProtoReflect.Descriptor instead. func (*SpeechWebSocketStarted) Descriptor() ([]byte, []int) { return file_rime_speech_to_text_proto_rawDescGZIP(), []int{15} } func (x *SpeechWebSocketStarted) GetRequestId() string { if x != nil { return x.RequestId } return "" } func (x *SpeechWebSocketStarted) GetAccepted() *StreamingAccepted { if x != nil { return x.Accepted } return nil } type SpeechWebSocketError struct { state protoimpl.MessageState `protogen:"open.v1"` // Stable public category such as invalid_input, resource_exhausted, // unavailable, timeout, cancelled, or internal. Kind string `protobuf:"bytes,1,opt,name=kind,proto3" json:"kind,omitempty"` // Human-readable diagnostic; clients branch on `kind`, not this text. Message string `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"` RequestId *string `protobuf:"bytes,3,opt,name=request_id,json=requestId,proto3,oneof" json:"request_id,omitempty"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *SpeechWebSocketError) Reset() { *x = SpeechWebSocketError{} mi := &file_rime_speech_to_text_proto_msgTypes[16] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *SpeechWebSocketError) String() string { return protoimpl.X.MessageStringOf(x) } func (*SpeechWebSocketError) ProtoMessage() {} func (x *SpeechWebSocketError) ProtoReflect() protoreflect.Message { mi := &file_rime_speech_to_text_proto_msgTypes[16] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use SpeechWebSocketError.ProtoReflect.Descriptor instead. func (*SpeechWebSocketError) Descriptor() ([]byte, []int) { return file_rime_speech_to_text_proto_rawDescGZIP(), []int{16} } func (x *SpeechWebSocketError) GetKind() string { if x != nil { return x.Kind } return "" } func (x *SpeechWebSocketError) GetMessage() string { if x != nil { return x.Message } return "" } func (x *SpeechWebSocketError) GetRequestId() string { if x != nil && x.RequestId != nil { return *x.RequestId } return "" } // Acknowledges an explicit `cancel`. Closing the connection instead also // cancels its associated backend work, but cannot carry this acknowledgement. type SpeechWebSocketCancelled struct { state protoimpl.MessageState `protogen:"open.v1"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *SpeechWebSocketCancelled) Reset() { *x = SpeechWebSocketCancelled{} mi := &file_rime_speech_to_text_proto_msgTypes[17] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *SpeechWebSocketCancelled) String() string { return protoimpl.X.MessageStringOf(x) } func (*SpeechWebSocketCancelled) ProtoMessage() {} func (x *SpeechWebSocketCancelled) ProtoReflect() protoreflect.Message { mi := &file_rime_speech_to_text_proto_msgTypes[17] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use SpeechWebSocketCancelled.ProtoReflect.Descriptor instead. func (*SpeechWebSocketCancelled) Descriptor() ([]byte, []int) { return file_rime_speech_to_text_proto_rawDescGZIP(), []int{17} } var File_rime_speech_to_text_proto protoreflect.FileDescriptor const file_rime_speech_to_text_proto_rawDesc = "" + "\n" + "\x19rime/speech_to_text.proto\x12\x04rime\"\x96\x01\n" + "\x14TranscriptionOptions\x12\x1f\n" + "\blanguage\x18\x01 \x01(\tH\x00R\blanguage\x88\x01\x01\x12+\n" + "\x04mode\x18\x02 \x01(\x0e2\x17.rime.TranscriptionModeR\x04mode\x12#\n" + "\rcontext_terms\x18\x03 \x03(\tR\fcontextTermsB\v\n" + "\t_language\"R\n" + "\x10ResolvedLanguage\x12\x10\n" + "\x03tag\x18\x01 \x01(\tR\x03tag\x12,\n" + "\x06source\x18\x02 \x01(\x0e2\x14.rime.LanguageSourceR\x06source\"s\n" + "\x14TranscriptionRequest\x12\x14\n" + "\x05audio\x18\x01 \x01(\fR\x05audio\x129\n" + "\aoptions\x18\x02 \x01(\v2\x1a.rime.TranscriptionOptionsH\x00R\aoptions\x88\x01\x01B\n" + "\n" + "\b_options\"q\n" + "\x15TranscriptionResponse\x12\x12\n" + "\x04text\x18\x01 \x01(\tR\x04text\x127\n" + "\blanguage\x18\x02 \x01(\v2\x16.rime.ResolvedLanguageH\x00R\blanguage\x88\x01\x01B\v\n" + "\t_language\"\x82\x02\n" + "\x0fStreamingConfig\x12\x1f\n" + "\blanguage\x18\x03 \x01(\tH\x00R\blanguage\x88\x01\x01\x12+\n" + "\x04mode\x18\x04 \x01(\x0e2\x17.rime.TranscriptionModeR\x04mode\x12F\n" + "\x0foutput_contract\x18\x05 \x01(\x0e2\x1d.rime.StreamingOutputContractR\x0eoutputContract\x12#\n" + "\rcontext_terms\x18\x06 \x03(\tR\fcontextTermsB\v\n" + "\t_languageJ\x04\b\x01\x10\x02J\x04\b\x02\x10\x03R\x11sample_rate_hertzR\bchannels\"s\n" + "\x1dStreamingTranscriptionRequest\x12/\n" + "\x06config\x18\x01 \x01(\v2\x15.rime.StreamingConfigH\x00R\x06config\x12\x16\n" + "\x05audio\x18\x02 \x01(\fH\x00R\x05audioB\t\n" + "\apayload\"\x84\x02\n" + "\x1eStreamingTranscriptionResponse\x120\n" + "\x05delta\x18\x01 \x01(\v2\x18.rime.TranscriptionDeltaH\x00R\x05delta\x12-\n" + "\x04done\x18\x02 \x01(\v2\x17.rime.TranscriptionDoneH\x00R\x04done\x125\n" + "\baccepted\x18\x03 \x01(\v2\x17.rime.StreamingAcceptedH\x00R\baccepted\x12?\n" + "\n" + "hypothesis\x18\x04 \x01(\v2\x1d.rime.TranscriptionHypothesisH\x00R\n" + "hypothesisB\t\n" + "\apayload\"\xa1\x01\n" + "\x11StreamingAccepted\x12F\n" + "\x0foutput_contract\x18\x01 \x01(\x0e2\x1d.rime.StreamingOutputContractR\x0eoutputContract\x127\n" + "\blanguage\x18\x02 \x01(\v2\x16.rime.ResolvedLanguageH\x00R\blanguage\x88\x01\x01B\v\n" + "\t_language\"(\n" + "\x12TranscriptionDelta\x12\x12\n" + "\x04text\x18\x01 \x01(\tR\x04text\"I\n" + "\x17TranscriptionHypothesis\x12\x12\n" + "\x04text\x18\x01 \x01(\tR\x04text\x12\x1a\n" + "\brevision\x18\x02 \x01(\x04R\brevision\"\x89\x01\n" + "\x11TranscriptionDone\x12\x12\n" + "\x04text\x18\x01 \x01(\tR\x04text\x127\n" + "\blanguage\x18\x02 \x01(\v2\x16.rime.ResolvedLanguageH\x00R\blanguage\x88\x01\x01\x12\x1a\n" + "\brevision\x18\x03 \x01(\x04R\brevisionB\v\n" + "\t_language\"\xcf\x01\n" + "\x16SpeechWebSocketRequest\x12-\n" + "\x05start\x18\x01 \x01(\v2\x15.rime.StreamingConfigH\x00R\x05start\x12\x16\n" + "\x05audio\x18\x02 \x01(\fH\x00R\x05audio\x12,\n" + "\x03end\x18\x03 \x01(\v2\x18.rime.SpeechWebSocketEndH\x00R\x03end\x125\n" + "\x06cancel\x18\x04 \x01(\v2\x1b.rime.SpeechWebSocketCancelH\x00R\x06cancelB\t\n" + "\apayload\"\x14\n" + "\x12SpeechWebSocketEnd\"\x17\n" + "\x15SpeechWebSocketCancel\"\xf4\x02\n" + "\x17SpeechWebSocketResponse\x128\n" + "\astarted\x18\x01 \x01(\v2\x1c.rime.SpeechWebSocketStartedH\x00R\astarted\x120\n" + "\x05delta\x18\x02 \x01(\v2\x18.rime.TranscriptionDeltaH\x00R\x05delta\x12-\n" + "\x04done\x18\x03 \x01(\v2\x17.rime.TranscriptionDoneH\x00R\x04done\x122\n" + "\x05error\x18\x04 \x01(\v2\x1a.rime.SpeechWebSocketErrorH\x00R\x05error\x12>\n" + "\tcancelled\x18\x05 \x01(\v2\x1e.rime.SpeechWebSocketCancelledH\x00R\tcancelled\x12?\n" + "\n" + "hypothesis\x18\x06 \x01(\v2\x1d.rime.TranscriptionHypothesisH\x00R\n" + "hypothesisB\t\n" + "\apayload\"~\n" + "\x16SpeechWebSocketStarted\x12\x1d\n" + "\n" + "request_id\x18\x01 \x01(\tR\trequestId\x128\n" + "\baccepted\x18\x02 \x01(\v2\x17.rime.StreamingAcceptedH\x00R\baccepted\x88\x01\x01B\v\n" + "\t_accepted\"w\n" + "\x14SpeechWebSocketError\x12\x12\n" + "\x04kind\x18\x01 \x01(\tR\x04kind\x12\x18\n" + "\amessage\x18\x02 \x01(\tR\amessage\x12\"\n" + "\n" + "request_id\x18\x03 \x01(\tH\x00R\trequestId\x88\x01\x01B\r\n" + "\v_request_id\"\x1a\n" + "\x18SpeechWebSocketCancelled*x\n" + "\x11TranscriptionMode\x12\"\n" + "\x1eTRANSCRIPTION_MODE_UNSPECIFIED\x10\x00\x12\x1e\n" + "\x1aTRANSCRIPTION_MODE_WRITTEN\x10\x01\x12\x1f\n" + "\x1bTRANSCRIPTION_MODE_VERBATIM\x10\x02*m\n" + "\x0eLanguageSource\x12\x1f\n" + "\x1bLANGUAGE_SOURCE_UNSPECIFIED\x10\x00\x12\x1c\n" + "\x18LANGUAGE_SOURCE_SELECTED\x10\x01\x12\x1c\n" + "\x18LANGUAGE_SOURCE_DETECTED\x10\x02*\xa6\x01\n" + "\x17StreamingOutputContract\x12)\n" + "%STREAMING_OUTPUT_CONTRACT_UNSPECIFIED\x10\x00\x12.\n" + "*STREAMING_OUTPUT_CONTRACT_APPEND_FRAGMENTS\x10\x01\x120\n" + ",STREAMING_OUTPUT_CONTRACT_REVISED_HYPOTHESES\x10\x022\xbf\x01\n" + "\fSpeechToText\x12G\n" + "\n" + "Transcribe\x12\x1a.rime.TranscriptionRequest\x1a\x1b.rime.TranscriptionResponse\"\x00\x12f\n" + "\x13TranscribeStreaming\x12#.rime.StreamingTranscriptionRequest\x1a$.rime.StreamingTranscriptionResponse\"\x00(\x010\x01b\x06proto3" var ( file_rime_speech_to_text_proto_rawDescOnce sync.Once file_rime_speech_to_text_proto_rawDescData []byte ) func file_rime_speech_to_text_proto_rawDescGZIP() []byte { file_rime_speech_to_text_proto_rawDescOnce.Do(func() { file_rime_speech_to_text_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_rime_speech_to_text_proto_rawDesc), len(file_rime_speech_to_text_proto_rawDesc))) }) return file_rime_speech_to_text_proto_rawDescData } var file_rime_speech_to_text_proto_enumTypes = make([]protoimpl.EnumInfo, 3) var file_rime_speech_to_text_proto_msgTypes = make([]protoimpl.MessageInfo, 18) var file_rime_speech_to_text_proto_goTypes = []any{ (TranscriptionMode)(0), // 0: rime.TranscriptionMode (LanguageSource)(0), // 1: rime.LanguageSource (StreamingOutputContract)(0), // 2: rime.StreamingOutputContract (*TranscriptionOptions)(nil), // 3: rime.TranscriptionOptions (*ResolvedLanguage)(nil), // 4: rime.ResolvedLanguage (*TranscriptionRequest)(nil), // 5: rime.TranscriptionRequest (*TranscriptionResponse)(nil), // 6: rime.TranscriptionResponse (*StreamingConfig)(nil), // 7: rime.StreamingConfig (*StreamingTranscriptionRequest)(nil), // 8: rime.StreamingTranscriptionRequest (*StreamingTranscriptionResponse)(nil), // 9: rime.StreamingTranscriptionResponse (*StreamingAccepted)(nil), // 10: rime.StreamingAccepted (*TranscriptionDelta)(nil), // 11: rime.TranscriptionDelta (*TranscriptionHypothesis)(nil), // 12: rime.TranscriptionHypothesis (*TranscriptionDone)(nil), // 13: rime.TranscriptionDone (*SpeechWebSocketRequest)(nil), // 14: rime.SpeechWebSocketRequest (*SpeechWebSocketEnd)(nil), // 15: rime.SpeechWebSocketEnd (*SpeechWebSocketCancel)(nil), // 16: rime.SpeechWebSocketCancel (*SpeechWebSocketResponse)(nil), // 17: rime.SpeechWebSocketResponse (*SpeechWebSocketStarted)(nil), // 18: rime.SpeechWebSocketStarted (*SpeechWebSocketError)(nil), // 19: rime.SpeechWebSocketError (*SpeechWebSocketCancelled)(nil), // 20: rime.SpeechWebSocketCancelled } var file_rime_speech_to_text_proto_depIdxs = []int32{ 0, // 0: rime.TranscriptionOptions.mode:type_name -> rime.TranscriptionMode 1, // 1: rime.ResolvedLanguage.source:type_name -> rime.LanguageSource 3, // 2: rime.TranscriptionRequest.options:type_name -> rime.TranscriptionOptions 4, // 3: rime.TranscriptionResponse.language:type_name -> rime.ResolvedLanguage 0, // 4: rime.StreamingConfig.mode:type_name -> rime.TranscriptionMode 2, // 5: rime.StreamingConfig.output_contract:type_name -> rime.StreamingOutputContract 7, // 6: rime.StreamingTranscriptionRequest.config:type_name -> rime.StreamingConfig 11, // 7: rime.StreamingTranscriptionResponse.delta:type_name -> rime.TranscriptionDelta 13, // 8: rime.StreamingTranscriptionResponse.done:type_name -> rime.TranscriptionDone 10, // 9: rime.StreamingTranscriptionResponse.accepted:type_name -> rime.StreamingAccepted 12, // 10: rime.StreamingTranscriptionResponse.hypothesis:type_name -> rime.TranscriptionHypothesis 2, // 11: rime.StreamingAccepted.output_contract:type_name -> rime.StreamingOutputContract 4, // 12: rime.StreamingAccepted.language:type_name -> rime.ResolvedLanguage 4, // 13: rime.TranscriptionDone.language:type_name -> rime.ResolvedLanguage 7, // 14: rime.SpeechWebSocketRequest.start:type_name -> rime.StreamingConfig 15, // 15: rime.SpeechWebSocketRequest.end:type_name -> rime.SpeechWebSocketEnd 16, // 16: rime.SpeechWebSocketRequest.cancel:type_name -> rime.SpeechWebSocketCancel 18, // 17: rime.SpeechWebSocketResponse.started:type_name -> rime.SpeechWebSocketStarted 11, // 18: rime.SpeechWebSocketResponse.delta:type_name -> rime.TranscriptionDelta 13, // 19: rime.SpeechWebSocketResponse.done:type_name -> rime.TranscriptionDone 19, // 20: rime.SpeechWebSocketResponse.error:type_name -> rime.SpeechWebSocketError 20, // 21: rime.SpeechWebSocketResponse.cancelled:type_name -> rime.SpeechWebSocketCancelled 12, // 22: rime.SpeechWebSocketResponse.hypothesis:type_name -> rime.TranscriptionHypothesis 10, // 23: rime.SpeechWebSocketStarted.accepted:type_name -> rime.StreamingAccepted 5, // 24: rime.SpeechToText.Transcribe:input_type -> rime.TranscriptionRequest 8, // 25: rime.SpeechToText.TranscribeStreaming:input_type -> rime.StreamingTranscriptionRequest 6, // 26: rime.SpeechToText.Transcribe:output_type -> rime.TranscriptionResponse 9, // 27: rime.SpeechToText.TranscribeStreaming:output_type -> rime.StreamingTranscriptionResponse 26, // [26:28] is the sub-list for method output_type 24, // [24:26] is the sub-list for method input_type 24, // [24:24] is the sub-list for extension type_name 24, // [24:24] is the sub-list for extension extendee 0, // [0:24] is the sub-list for field type_name } func init() { file_rime_speech_to_text_proto_init() } func file_rime_speech_to_text_proto_init() { if File_rime_speech_to_text_proto != nil { return } file_rime_speech_to_text_proto_msgTypes[0].OneofWrappers = []any{} file_rime_speech_to_text_proto_msgTypes[2].OneofWrappers = []any{} file_rime_speech_to_text_proto_msgTypes[3].OneofWrappers = []any{} file_rime_speech_to_text_proto_msgTypes[4].OneofWrappers = []any{} file_rime_speech_to_text_proto_msgTypes[5].OneofWrappers = []any{ (*StreamingTranscriptionRequest_Config)(nil), (*StreamingTranscriptionRequest_Audio)(nil), } file_rime_speech_to_text_proto_msgTypes[6].OneofWrappers = []any{ (*StreamingTranscriptionResponse_Delta)(nil), (*StreamingTranscriptionResponse_Done)(nil), (*StreamingTranscriptionResponse_Accepted)(nil), (*StreamingTranscriptionResponse_Hypothesis)(nil), } file_rime_speech_to_text_proto_msgTypes[7].OneofWrappers = []any{} file_rime_speech_to_text_proto_msgTypes[10].OneofWrappers = []any{} file_rime_speech_to_text_proto_msgTypes[11].OneofWrappers = []any{ (*SpeechWebSocketRequest_Start)(nil), (*SpeechWebSocketRequest_Audio)(nil), (*SpeechWebSocketRequest_End)(nil), (*SpeechWebSocketRequest_Cancel)(nil), } file_rime_speech_to_text_proto_msgTypes[14].OneofWrappers = []any{ (*SpeechWebSocketResponse_Started)(nil), (*SpeechWebSocketResponse_Delta)(nil), (*SpeechWebSocketResponse_Done)(nil), (*SpeechWebSocketResponse_Error)(nil), (*SpeechWebSocketResponse_Cancelled)(nil), (*SpeechWebSocketResponse_Hypothesis)(nil), } file_rime_speech_to_text_proto_msgTypes[15].OneofWrappers = []any{} file_rime_speech_to_text_proto_msgTypes[16].OneofWrappers = []any{} type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: unsafe.Slice(unsafe.StringData(file_rime_speech_to_text_proto_rawDesc), len(file_rime_speech_to_text_proto_rawDesc)), NumEnums: 3, NumMessages: 18, NumExtensions: 0, NumServices: 1, }, GoTypes: file_rime_speech_to_text_proto_goTypes, DependencyIndexes: file_rime_speech_to_text_proto_depIdxs, EnumInfos: file_rime_speech_to_text_proto_enumTypes, MessageInfos: file_rime_speech_to_text_proto_msgTypes, }.Build() File_rime_speech_to_text_proto = out.File file_rime_speech_to_text_proto_goTypes = nil file_rime_speech_to_text_proto_depIdxs = nil }