Documentation ¶
Index ¶
- Constants
- Variables
- func RegisterLibrarianMinerServiceServer(s grpc.ServiceRegistrar, srv LibrarianMinerServiceServer)
- type LibrarianMinerServiceClient
- type LibrarianMinerServiceServer
- type LibrarianMinerService_RecognizeImageBinaryClient
- type LibrarianMinerService_RecognizeImageBinaryServer
- type RecognizeImageBinaryRequest
- func (*RecognizeImageBinaryRequest) Descriptor() ([]byte, []int)deprecated
- func (x *RecognizeImageBinaryRequest) GetData() []byte
- func (*RecognizeImageBinaryRequest) ProtoMessage()
- func (x *RecognizeImageBinaryRequest) ProtoReflect() protoreflect.Message
- func (x *RecognizeImageBinaryRequest) Reset()
- func (x *RecognizeImageBinaryRequest) String() string
- type RecognizeImageBinaryResponse
- func (*RecognizeImageBinaryResponse) Descriptor() ([]byte, []int)deprecated
- func (x *RecognizeImageBinaryResponse) GetResults() []*RecognizeImageResult
- func (*RecognizeImageBinaryResponse) ProtoMessage()
- func (x *RecognizeImageBinaryResponse) ProtoReflect() protoreflect.Message
- func (x *RecognizeImageBinaryResponse) Reset()
- func (x *RecognizeImageBinaryResponse) String() string
- type RecognizeImageResult
- func (*RecognizeImageResult) Descriptor() ([]byte, []int)deprecated
- func (x *RecognizeImageResult) GetConfidence() float64
- func (x *RecognizeImageResult) GetText() string
- func (*RecognizeImageResult) ProtoMessage()
- func (x *RecognizeImageResult) ProtoReflect() protoreflect.Message
- func (x *RecognizeImageResult) Reset()
- func (x *RecognizeImageResult) String() string
- type RecognizeImageURLRequest
- func (*RecognizeImageURLRequest) Descriptor() ([]byte, []int)deprecated
- func (x *RecognizeImageURLRequest) GetUrl() string
- func (*RecognizeImageURLRequest) ProtoMessage()
- func (x *RecognizeImageURLRequest) ProtoReflect() protoreflect.Message
- func (x *RecognizeImageURLRequest) Reset()
- func (x *RecognizeImageURLRequest) String() string
- type RecognizeImageURLResponse
- func (*RecognizeImageURLResponse) Descriptor() ([]byte, []int)deprecated
- func (x *RecognizeImageURLResponse) GetResults() []*RecognizeImageResult
- func (*RecognizeImageURLResponse) ProtoMessage()
- func (x *RecognizeImageURLResponse) ProtoReflect() protoreflect.Message
- func (x *RecognizeImageURLResponse) Reset()
- func (x *RecognizeImageURLResponse) String() string
- type UnimplementedLibrarianMinerServiceServer
- type UnsafeLibrarianMinerServiceServer
Constants ¶
const ( LibrarianMinerService_RecognizeImageBinary_FullMethodName = "/librarian.miner.v1.LibrarianMinerService/RecognizeImageBinary" LibrarianMinerService_RecognizeImageURL_FullMethodName = "/librarian.miner.v1.LibrarianMinerService/RecognizeImageURL" )
Variables ¶
var File_librarian_miner_v1_miner_proto protoreflect.FileDescriptor
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
func NewLibrarianMinerServiceClient ¶
func NewLibrarianMinerServiceClient(cc grpc.ClientConnInterface) LibrarianMinerServiceClient
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 (x *RecognizeImageBinaryRequest) ProtoReflect() protoreflect.Message
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 (x *RecognizeImageBinaryResponse) GetResults() []*RecognizeImageResult
func (*RecognizeImageBinaryResponse) ProtoMessage ¶
func (*RecognizeImageBinaryResponse) ProtoMessage()
func (*RecognizeImageBinaryResponse) ProtoReflect ¶
func (x *RecognizeImageBinaryResponse) ProtoReflect() protoreflect.Message
func (*RecognizeImageBinaryResponse) Reset ¶
func (x *RecognizeImageBinaryResponse) Reset()
func (*RecognizeImageBinaryResponse) String ¶
func (x *RecognizeImageBinaryResponse) String() 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 (x *RecognizeImageURLResponse) GetResults() []*RecognizeImageResult
func (*RecognizeImageURLResponse) ProtoMessage ¶
func (*RecognizeImageURLResponse) ProtoMessage()
func (*RecognizeImageURLResponse) ProtoReflect ¶
func (x *RecognizeImageURLResponse) ProtoReflect() protoreflect.Message
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) RecognizeImageBinary ¶
func (UnimplementedLibrarianMinerServiceServer) RecognizeImageBinary(grpc.ClientStreamingServer[RecognizeImageBinaryRequest, RecognizeImageBinaryResponse]) error
func (UnimplementedLibrarianMinerServiceServer) RecognizeImageURL ¶
func (UnimplementedLibrarianMinerServiceServer) RecognizeImageURL(context.Context, *RecognizeImageURLRequest) (*RecognizeImageURLResponse, error)
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.