v1

package
v0.4.23 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 24, 2024 License: MIT Imports: 8 Imported by: 3

Documentation

Index

Constants

View Source
const (
	LibrarianMinerService_RecognizeImageBinary_FullMethodName = "/librarian.miner.v1.LibrarianMinerService/RecognizeImageBinary"
	LibrarianMinerService_RecognizeImageURL_FullMethodName    = "/librarian.miner.v1.LibrarianMinerService/RecognizeImageURL"
)

Variables

View Source
var File_librarian_miner_v1_miner_proto protoreflect.FileDescriptor
View Source
var LibrarianMinerService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "librarian.miner.v1.LibrarianMinerService",
	HandlerType: (*LibrarianMinerServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "RecognizeImageURL",
			Handler:    _LibrarianMinerService_RecognizeImageURL_Handler,
		},
	},
	Streams: []grpc.StreamDesc{
		{
			StreamName:    "RecognizeImageBinary",
			Handler:       _LibrarianMinerService_RecognizeImageBinary_Handler,
			ClientStreams: true,
		},
	},
	Metadata: "librarian/miner/v1/miner.proto",
}

LibrarianMinerService_ServiceDesc is the grpc.ServiceDesc for LibrarianMinerService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterLibrarianMinerServiceServer

func RegisterLibrarianMinerServiceServer(s grpc.ServiceRegistrar, srv LibrarianMinerServiceServer)

Types

type LibrarianMinerServiceClient

type LibrarianMinerServiceClient interface {
	RecognizeImageBinary(ctx context.Context, opts ...grpc.CallOption) (grpc.ClientStreamingClient[RecognizeImageBinaryRequest, RecognizeImageBinaryResponse], error)
	RecognizeImageURL(ctx context.Context, in *RecognizeImageURLRequest, opts ...grpc.CallOption) (*RecognizeImageURLResponse, error)
}

LibrarianMinerServiceClient is the client API for LibrarianMinerService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

The main role of Miner is to encapsulate compute-intensive tasks

type LibrarianMinerServiceServer

type LibrarianMinerServiceServer interface {
	RecognizeImageBinary(grpc.ClientStreamingServer[RecognizeImageBinaryRequest, RecognizeImageBinaryResponse]) error
	RecognizeImageURL(context.Context, *RecognizeImageURLRequest) (*RecognizeImageURLResponse, error)
	// contains filtered or unexported methods
}

LibrarianMinerServiceServer is the server API for LibrarianMinerService service. All implementations must embed UnimplementedLibrarianMinerServiceServer for forward compatibility.

The main role of Miner is to encapsulate compute-intensive tasks

type LibrarianMinerService_RecognizeImageBinaryClient

type LibrarianMinerService_RecognizeImageBinaryClient = grpc.ClientStreamingClient[RecognizeImageBinaryRequest, RecognizeImageBinaryResponse]

This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name.

type LibrarianMinerService_RecognizeImageBinaryServer

type LibrarianMinerService_RecognizeImageBinaryServer = grpc.ClientStreamingServer[RecognizeImageBinaryRequest, RecognizeImageBinaryResponse]

This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name.

type RecognizeImageBinaryRequest

type RecognizeImageBinaryRequest struct {
	Data []byte `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"`
	// contains filtered or unexported fields
}

func (*RecognizeImageBinaryRequest) Descriptor deprecated

func (*RecognizeImageBinaryRequest) Descriptor() ([]byte, []int)

Deprecated: Use RecognizeImageBinaryRequest.ProtoReflect.Descriptor instead.

func (*RecognizeImageBinaryRequest) GetData

func (x *RecognizeImageBinaryRequest) GetData() []byte

func (*RecognizeImageBinaryRequest) ProtoMessage

func (*RecognizeImageBinaryRequest) ProtoMessage()

func (*RecognizeImageBinaryRequest) ProtoReflect

func (*RecognizeImageBinaryRequest) Reset

func (x *RecognizeImageBinaryRequest) Reset()

func (*RecognizeImageBinaryRequest) String

func (x *RecognizeImageBinaryRequest) String() string

type RecognizeImageBinaryResponse

type RecognizeImageBinaryResponse struct {
	Results []*RecognizeImageResult `protobuf:"bytes,1,rep,name=results,proto3" json:"results,omitempty"`
	// contains filtered or unexported fields
}

func (*RecognizeImageBinaryResponse) Descriptor deprecated

func (*RecognizeImageBinaryResponse) Descriptor() ([]byte, []int)

Deprecated: Use RecognizeImageBinaryResponse.ProtoReflect.Descriptor instead.

func (*RecognizeImageBinaryResponse) GetResults

func (*RecognizeImageBinaryResponse) ProtoMessage

func (*RecognizeImageBinaryResponse) ProtoMessage()

func (*RecognizeImageBinaryResponse) ProtoReflect

func (*RecognizeImageBinaryResponse) Reset

func (x *RecognizeImageBinaryResponse) Reset()

func (*RecognizeImageBinaryResponse) String

type RecognizeImageResult

type RecognizeImageResult struct {
	Confidence float64 `protobuf:"fixed64,1,opt,name=confidence,proto3" json:"confidence,omitempty"`
	Text       string  `protobuf:"bytes,2,opt,name=text,proto3" json:"text,omitempty"`
	// contains filtered or unexported fields
}

func (*RecognizeImageResult) Descriptor deprecated

func (*RecognizeImageResult) Descriptor() ([]byte, []int)

Deprecated: Use RecognizeImageResult.ProtoReflect.Descriptor instead.

func (*RecognizeImageResult) GetConfidence

func (x *RecognizeImageResult) GetConfidence() float64

func (*RecognizeImageResult) GetText

func (x *RecognizeImageResult) GetText() string

func (*RecognizeImageResult) ProtoMessage

func (*RecognizeImageResult) ProtoMessage()

func (*RecognizeImageResult) ProtoReflect

func (x *RecognizeImageResult) ProtoReflect() protoreflect.Message

func (*RecognizeImageResult) Reset

func (x *RecognizeImageResult) Reset()

func (*RecognizeImageResult) String

func (x *RecognizeImageResult) String() string

type RecognizeImageURLRequest

type RecognizeImageURLRequest struct {
	Url string `protobuf:"bytes,1,opt,name=url,proto3" json:"url,omitempty"`
	// contains filtered or unexported fields
}

func (*RecognizeImageURLRequest) Descriptor deprecated

func (*RecognizeImageURLRequest) Descriptor() ([]byte, []int)

Deprecated: Use RecognizeImageURLRequest.ProtoReflect.Descriptor instead.

func (*RecognizeImageURLRequest) GetUrl

func (x *RecognizeImageURLRequest) GetUrl() string

func (*RecognizeImageURLRequest) ProtoMessage

func (*RecognizeImageURLRequest) ProtoMessage()

func (*RecognizeImageURLRequest) ProtoReflect

func (x *RecognizeImageURLRequest) ProtoReflect() protoreflect.Message

func (*RecognizeImageURLRequest) Reset

func (x *RecognizeImageURLRequest) Reset()

func (*RecognizeImageURLRequest) String

func (x *RecognizeImageURLRequest) String() string

type RecognizeImageURLResponse

type RecognizeImageURLResponse struct {
	Results []*RecognizeImageResult `protobuf:"bytes,1,rep,name=results,proto3" json:"results,omitempty"`
	// contains filtered or unexported fields
}

func (*RecognizeImageURLResponse) Descriptor deprecated

func (*RecognizeImageURLResponse) Descriptor() ([]byte, []int)

Deprecated: Use RecognizeImageURLResponse.ProtoReflect.Descriptor instead.

func (*RecognizeImageURLResponse) GetResults

func (*RecognizeImageURLResponse) ProtoMessage

func (*RecognizeImageURLResponse) ProtoMessage()

func (*RecognizeImageURLResponse) ProtoReflect

func (*RecognizeImageURLResponse) Reset

func (x *RecognizeImageURLResponse) Reset()

func (*RecognizeImageURLResponse) String

func (x *RecognizeImageURLResponse) String() string

type UnimplementedLibrarianMinerServiceServer

type UnimplementedLibrarianMinerServiceServer struct{}

UnimplementedLibrarianMinerServiceServer must be embedded to have forward compatible implementations.

NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.

func (UnimplementedLibrarianMinerServiceServer) RecognizeImageURL

type UnsafeLibrarianMinerServiceServer

type UnsafeLibrarianMinerServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeLibrarianMinerServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to LibrarianMinerServiceServer will result in compilation errors.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL