// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// 	protoc-gen-go v1.36.6
// 	protoc        v3.21.12
// source: yandex/cloud/ai/ocr/v1/ocr_service.proto

package ocr

import (
	_ "github.com/yandex-cloud/go-genproto/yandex/cloud"
	_ "github.com/yandex-cloud/go-genproto/yandex/cloud/api"
	operation "github.com/yandex-cloud/go-genproto/yandex/cloud/operation"
	_ "google.golang.org/genproto/googleapis/api/annotations"
	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)
)

type RecognizeTextRequest struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// Types that are valid to be assigned to Source:
	//
	//	*RecognizeTextRequest_Content
	Source isRecognizeTextRequest_Source `protobuf_oneof:"source"`
	// Specifications of the ([MIME type](https://en.wikipedia.org/wiki/Media_type)). Each specification contains the file to analyze and features to use for analysis. Restrictions:
	// * Supported file formats: `JPEG`, `PNG`, `PDF`.
	// * Maximum file size: see [documentation](/docs/vision/concepts/limits).
	// * Image size should not exceed 20M pixels (length x width).
	// * The number of pages in a PDF file should not exceed 1.
	MimeType string `protobuf:"bytes,2,opt,name=mime_type,json=mimeType,proto3" json:"mime_type,omitempty"`
	// [List of the languages](/docs/vision/concepts/ocr/supported-languages) to recognize text.
	// Specified in [ISO 639-1](https://en.wikipedia.org/wiki/ISO_639-1) format (for example, `ru`).
	LanguageCodes []string `protobuf:"bytes,3,rep,name=language_codes,json=languageCodes,proto3" json:"language_codes,omitempty"`
	// [Model](/docs/vision/concepts/ocr/template-recognition#models) to use for text detection.
	Model         string `protobuf:"bytes,4,opt,name=model,proto3" json:"model,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *RecognizeTextRequest) Reset() {
	*x = RecognizeTextRequest{}
	mi := &file_yandex_cloud_ai_ocr_v1_ocr_service_proto_msgTypes[0]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *RecognizeTextRequest) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*RecognizeTextRequest) ProtoMessage() {}

func (x *RecognizeTextRequest) ProtoReflect() protoreflect.Message {
	mi := &file_yandex_cloud_ai_ocr_v1_ocr_service_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 RecognizeTextRequest.ProtoReflect.Descriptor instead.
func (*RecognizeTextRequest) Descriptor() ([]byte, []int) {
	return file_yandex_cloud_ai_ocr_v1_ocr_service_proto_rawDescGZIP(), []int{0}
}

func (x *RecognizeTextRequest) GetSource() isRecognizeTextRequest_Source {
	if x != nil {
		return x.Source
	}
	return nil
}

func (x *RecognizeTextRequest) GetContent() []byte {
	if x != nil {
		if x, ok := x.Source.(*RecognizeTextRequest_Content); ok {
			return x.Content
		}
	}
	return nil
}

func (x *RecognizeTextRequest) GetMimeType() string {
	if x != nil {
		return x.MimeType
	}
	return ""
}

func (x *RecognizeTextRequest) GetLanguageCodes() []string {
	if x != nil {
		return x.LanguageCodes
	}
	return nil
}

func (x *RecognizeTextRequest) GetModel() string {
	if x != nil {
		return x.Model
	}
	return ""
}

type isRecognizeTextRequest_Source interface {
	isRecognizeTextRequest_Source()
}

type RecognizeTextRequest_Content struct {
	// Bytes with data
	Content []byte `protobuf:"bytes,1,opt,name=content,proto3,oneof"`
}

func (*RecognizeTextRequest_Content) isRecognizeTextRequest_Source() {}

type RecognizeTextResponse struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// Recognized text blocks in page or text from entities.
	TextAnnotation *TextAnnotation `protobuf:"bytes,1,opt,name=text_annotation,json=textAnnotation,proto3" json:"text_annotation,omitempty"`
	// Page number in PDF file.
	Page          int64 `protobuf:"varint,2,opt,name=page,proto3" json:"page,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *RecognizeTextResponse) Reset() {
	*x = RecognizeTextResponse{}
	mi := &file_yandex_cloud_ai_ocr_v1_ocr_service_proto_msgTypes[1]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *RecognizeTextResponse) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*RecognizeTextResponse) ProtoMessage() {}

func (x *RecognizeTextResponse) ProtoReflect() protoreflect.Message {
	mi := &file_yandex_cloud_ai_ocr_v1_ocr_service_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 RecognizeTextResponse.ProtoReflect.Descriptor instead.
func (*RecognizeTextResponse) Descriptor() ([]byte, []int) {
	return file_yandex_cloud_ai_ocr_v1_ocr_service_proto_rawDescGZIP(), []int{1}
}

func (x *RecognizeTextResponse) GetTextAnnotation() *TextAnnotation {
	if x != nil {
		return x.TextAnnotation
	}
	return nil
}

func (x *RecognizeTextResponse) GetPage() int64 {
	if x != nil {
		return x.Page
	}
	return 0
}

type GetRecognitionRequest struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// Operation ID of async recognition request.
	OperationId   string `protobuf:"bytes,1,opt,name=operation_id,json=operationId,proto3" json:"operation_id,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *GetRecognitionRequest) Reset() {
	*x = GetRecognitionRequest{}
	mi := &file_yandex_cloud_ai_ocr_v1_ocr_service_proto_msgTypes[2]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *GetRecognitionRequest) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*GetRecognitionRequest) ProtoMessage() {}

func (x *GetRecognitionRequest) ProtoReflect() protoreflect.Message {
	mi := &file_yandex_cloud_ai_ocr_v1_ocr_service_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 GetRecognitionRequest.ProtoReflect.Descriptor instead.
func (*GetRecognitionRequest) Descriptor() ([]byte, []int) {
	return file_yandex_cloud_ai_ocr_v1_ocr_service_proto_rawDescGZIP(), []int{2}
}

func (x *GetRecognitionRequest) GetOperationId() string {
	if x != nil {
		return x.OperationId
	}
	return ""
}

var File_yandex_cloud_ai_ocr_v1_ocr_service_proto protoreflect.FileDescriptor

const file_yandex_cloud_ai_ocr_v1_ocr_service_proto_rawDesc = "" +
	"\n" +
	"(yandex/cloud/ai/ocr/v1/ocr_service.proto\x12\x16yandex.cloud.ai.ocr.v1\x1a yandex/cloud/ai/ocr/v1/ocr.proto\x1a\x1cgoogle/api/annotations.proto\x1a\x1dyandex/cloud/validation.proto\x1a yandex/cloud/api/operation.proto\x1a&yandex/cloud/operation/operation.proto\"\xa0\x01\n" +
	"\x14RecognizeTextRequest\x12\x1a\n" +
	"\acontent\x18\x01 \x01(\fH\x00R\acontent\x12\x1b\n" +
	"\tmime_type\x18\x02 \x01(\tR\bmimeType\x12%\n" +
	"\x0elanguage_codes\x18\x03 \x03(\tR\rlanguageCodes\x12\x1e\n" +
	"\x05model\x18\x04 \x01(\tB\b\x8a\xc81\x04<=50R\x05modelB\b\n" +
	"\x06source\"|\n" +
	"\x15RecognizeTextResponse\x12O\n" +
	"\x0ftext_annotation\x18\x01 \x01(\v2&.yandex.cloud.ai.ocr.v1.TextAnnotationR\x0etextAnnotation\x12\x12\n" +
	"\x04page\x18\x02 \x01(\x03R\x04page\"H\n" +
	"\x15GetRecognitionRequest\x12/\n" +
	"\foperation_id\x18\x01 \x01(\tB\f\xe8\xc71\x01\x8a\xc81\x04<=50R\voperationId2\xa7\x01\n" +
	"\x16TextRecognitionService\x12\x8c\x01\n" +
	"\tRecognize\x12,.yandex.cloud.ai.ocr.v1.RecognizeTextRequest\x1a-.yandex.cloud.ai.ocr.v1.RecognizeTextResponse\" \x82\xd3\xe4\x93\x02\x1a:\x01*\"\x15/ocr/v1/recognizeText0\x012\xd1\x02\n" +
	"\x1bTextRecognitionAsyncService\x12\x9e\x01\n" +
	"\tRecognize\x12,.yandex.cloud.ai.ocr.v1.RecognizeTextRequest\x1a!.yandex.cloud.operation.Operation\"@\xb2\xd2*\x17\x12\x15google.protobuf.Empty\x82\xd3\xe4\x93\x02\x1f:\x01*\"\x1a/ocr/v1/recognizeTextAsync\x12\x90\x01\n" +
	"\x0eGetRecognition\x12-.yandex.cloud.ai.ocr.v1.GetRecognitionRequest\x1a-.yandex.cloud.ai.ocr.v1.RecognizeTextResponse\"\x1e\x82\xd3\xe4\x93\x02\x18\x12\x16/ocr/v1/getRecognition0\x01B\\\n" +
	"\x1ayandex.cloud.api.ai.ocr.v1Z>github.com/yandex-cloud/go-genproto/yandex/cloud/ai/ocr/v1;ocrb\x06proto3"

var (
	file_yandex_cloud_ai_ocr_v1_ocr_service_proto_rawDescOnce sync.Once
	file_yandex_cloud_ai_ocr_v1_ocr_service_proto_rawDescData []byte
)

func file_yandex_cloud_ai_ocr_v1_ocr_service_proto_rawDescGZIP() []byte {
	file_yandex_cloud_ai_ocr_v1_ocr_service_proto_rawDescOnce.Do(func() {
		file_yandex_cloud_ai_ocr_v1_ocr_service_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_yandex_cloud_ai_ocr_v1_ocr_service_proto_rawDesc), len(file_yandex_cloud_ai_ocr_v1_ocr_service_proto_rawDesc)))
	})
	return file_yandex_cloud_ai_ocr_v1_ocr_service_proto_rawDescData
}

var file_yandex_cloud_ai_ocr_v1_ocr_service_proto_msgTypes = make([]protoimpl.MessageInfo, 3)
var file_yandex_cloud_ai_ocr_v1_ocr_service_proto_goTypes = []any{
	(*RecognizeTextRequest)(nil),  // 0: yandex.cloud.ai.ocr.v1.RecognizeTextRequest
	(*RecognizeTextResponse)(nil), // 1: yandex.cloud.ai.ocr.v1.RecognizeTextResponse
	(*GetRecognitionRequest)(nil), // 2: yandex.cloud.ai.ocr.v1.GetRecognitionRequest
	(*TextAnnotation)(nil),        // 3: yandex.cloud.ai.ocr.v1.TextAnnotation
	(*operation.Operation)(nil),   // 4: yandex.cloud.operation.Operation
}
var file_yandex_cloud_ai_ocr_v1_ocr_service_proto_depIdxs = []int32{
	3, // 0: yandex.cloud.ai.ocr.v1.RecognizeTextResponse.text_annotation:type_name -> yandex.cloud.ai.ocr.v1.TextAnnotation
	0, // 1: yandex.cloud.ai.ocr.v1.TextRecognitionService.Recognize:input_type -> yandex.cloud.ai.ocr.v1.RecognizeTextRequest
	0, // 2: yandex.cloud.ai.ocr.v1.TextRecognitionAsyncService.Recognize:input_type -> yandex.cloud.ai.ocr.v1.RecognizeTextRequest
	2, // 3: yandex.cloud.ai.ocr.v1.TextRecognitionAsyncService.GetRecognition:input_type -> yandex.cloud.ai.ocr.v1.GetRecognitionRequest
	1, // 4: yandex.cloud.ai.ocr.v1.TextRecognitionService.Recognize:output_type -> yandex.cloud.ai.ocr.v1.RecognizeTextResponse
	4, // 5: yandex.cloud.ai.ocr.v1.TextRecognitionAsyncService.Recognize:output_type -> yandex.cloud.operation.Operation
	1, // 6: yandex.cloud.ai.ocr.v1.TextRecognitionAsyncService.GetRecognition:output_type -> yandex.cloud.ai.ocr.v1.RecognizeTextResponse
	4, // [4:7] is the sub-list for method output_type
	1, // [1:4] is the sub-list for method input_type
	1, // [1:1] is the sub-list for extension type_name
	1, // [1:1] is the sub-list for extension extendee
	0, // [0:1] is the sub-list for field type_name
}

func init() { file_yandex_cloud_ai_ocr_v1_ocr_service_proto_init() }
func file_yandex_cloud_ai_ocr_v1_ocr_service_proto_init() {
	if File_yandex_cloud_ai_ocr_v1_ocr_service_proto != nil {
		return
	}
	file_yandex_cloud_ai_ocr_v1_ocr_proto_init()
	file_yandex_cloud_ai_ocr_v1_ocr_service_proto_msgTypes[0].OneofWrappers = []any{
		(*RecognizeTextRequest_Content)(nil),
	}
	type x struct{}
	out := protoimpl.TypeBuilder{
		File: protoimpl.DescBuilder{
			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
			RawDescriptor: unsafe.Slice(unsafe.StringData(file_yandex_cloud_ai_ocr_v1_ocr_service_proto_rawDesc), len(file_yandex_cloud_ai_ocr_v1_ocr_service_proto_rawDesc)),
			NumEnums:      0,
			NumMessages:   3,
			NumExtensions: 0,
			NumServices:   2,
		},
		GoTypes:           file_yandex_cloud_ai_ocr_v1_ocr_service_proto_goTypes,
		DependencyIndexes: file_yandex_cloud_ai_ocr_v1_ocr_service_proto_depIdxs,
		MessageInfos:      file_yandex_cloud_ai_ocr_v1_ocr_service_proto_msgTypes,
	}.Build()
	File_yandex_cloud_ai_ocr_v1_ocr_service_proto = out.File
	file_yandex_cloud_ai_ocr_v1_ocr_service_proto_goTypes = nil
	file_yandex_cloud_ai_ocr_v1_ocr_service_proto_depIdxs = nil
}
