blob: 9a9084e6655cd955800a8ac625b001d57ec3889e [file] [log] [blame]
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: google/cloud/automl/v1beta1/prediction_service.proto
package automl // import "google.golang.org/genproto/googleapis/cloud/automl/v1beta1"
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import _ "google.golang.org/genproto/googleapis/api/annotations"
import (
context "golang.org/x/net/context"
grpc "google.golang.org/grpc"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
// Request message for [PredictionService.Predict][google.cloud.automl.v1beta1.PredictionService.Predict].
type PredictRequest struct {
// Name of the model requested to serve the prediction.
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
// Required.
// Payload to perform a prediction on. The payload must match the
// problem type that the model was trained to solve.
Payload *ExamplePayload `protobuf:"bytes,2,opt,name=payload,proto3" json:"payload,omitempty"`
// Additional domain-specific parameters, any string must be up to 25000
// characters long.
//
// * For Image Classification:
//
// `score_threshold` - (float) A value from 0.0 to 1.0. When the model
// makes predictions for an
// image, it will only produce results that have at least this confidence
// score threshold. The default is 0.5.
Params map[string]string `protobuf:"bytes,3,rep,name=params,proto3" json:"params,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *PredictRequest) Reset() { *m = PredictRequest{} }
func (m *PredictRequest) String() string { return proto.CompactTextString(m) }
func (*PredictRequest) ProtoMessage() {}
func (*PredictRequest) Descriptor() ([]byte, []int) {
return fileDescriptor_prediction_service_1b71b7f556fd7159, []int{0}
}
func (m *PredictRequest) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_PredictRequest.Unmarshal(m, b)
}
func (m *PredictRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_PredictRequest.Marshal(b, m, deterministic)
}
func (dst *PredictRequest) XXX_Merge(src proto.Message) {
xxx_messageInfo_PredictRequest.Merge(dst, src)
}
func (m *PredictRequest) XXX_Size() int {
return xxx_messageInfo_PredictRequest.Size(m)
}
func (m *PredictRequest) XXX_DiscardUnknown() {
xxx_messageInfo_PredictRequest.DiscardUnknown(m)
}
var xxx_messageInfo_PredictRequest proto.InternalMessageInfo
func (m *PredictRequest) GetName() string {
if m != nil {
return m.Name
}
return ""
}
func (m *PredictRequest) GetPayload() *ExamplePayload {
if m != nil {
return m.Payload
}
return nil
}
func (m *PredictRequest) GetParams() map[string]string {
if m != nil {
return m.Params
}
return nil
}
// Response message for [PredictionService.Predict][google.cloud.automl.v1beta1.PredictionService.Predict].
//
// Currently, this is only
// used to return an image recognition prediction result. More prediction
// output metadata might be introduced in the future.
type PredictResponse struct {
// Prediction result.
Payload []*AnnotationPayload `protobuf:"bytes,1,rep,name=payload,proto3" json:"payload,omitempty"`
// Additional domain-specific prediction response metadata.
Metadata map[string]string `protobuf:"bytes,2,rep,name=metadata,proto3" json:"metadata,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *PredictResponse) Reset() { *m = PredictResponse{} }
func (m *PredictResponse) String() string { return proto.CompactTextString(m) }
func (*PredictResponse) ProtoMessage() {}
func (*PredictResponse) Descriptor() ([]byte, []int) {
return fileDescriptor_prediction_service_1b71b7f556fd7159, []int{1}
}
func (m *PredictResponse) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_PredictResponse.Unmarshal(m, b)
}
func (m *PredictResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_PredictResponse.Marshal(b, m, deterministic)
}
func (dst *PredictResponse) XXX_Merge(src proto.Message) {
xxx_messageInfo_PredictResponse.Merge(dst, src)
}
func (m *PredictResponse) XXX_Size() int {
return xxx_messageInfo_PredictResponse.Size(m)
}
func (m *PredictResponse) XXX_DiscardUnknown() {
xxx_messageInfo_PredictResponse.DiscardUnknown(m)
}
var xxx_messageInfo_PredictResponse proto.InternalMessageInfo
func (m *PredictResponse) GetPayload() []*AnnotationPayload {
if m != nil {
return m.Payload
}
return nil
}
func (m *PredictResponse) GetMetadata() map[string]string {
if m != nil {
return m.Metadata
}
return nil
}
func init() {
proto.RegisterType((*PredictRequest)(nil), "google.cloud.automl.v1beta1.PredictRequest")
proto.RegisterMapType((map[string]string)(nil), "google.cloud.automl.v1beta1.PredictRequest.ParamsEntry")
proto.RegisterType((*PredictResponse)(nil), "google.cloud.automl.v1beta1.PredictResponse")
proto.RegisterMapType((map[string]string)(nil), "google.cloud.automl.v1beta1.PredictResponse.MetadataEntry")
}
// Reference imports to suppress errors if they are not otherwise used.
var _ context.Context
var _ grpc.ClientConn
// This is a compile-time assertion to ensure that this generated file
// is compatible with the grpc package it is being compiled against.
const _ = grpc.SupportPackageIsVersion4
// PredictionServiceClient is the client API for PredictionService service.
//
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
type PredictionServiceClient interface {
// Perform a prediction.
Predict(ctx context.Context, in *PredictRequest, opts ...grpc.CallOption) (*PredictResponse, error)
}
type predictionServiceClient struct {
cc *grpc.ClientConn
}
func NewPredictionServiceClient(cc *grpc.ClientConn) PredictionServiceClient {
return &predictionServiceClient{cc}
}
func (c *predictionServiceClient) Predict(ctx context.Context, in *PredictRequest, opts ...grpc.CallOption) (*PredictResponse, error) {
out := new(PredictResponse)
err := c.cc.Invoke(ctx, "/google.cloud.automl.v1beta1.PredictionService/Predict", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
// PredictionServiceServer is the server API for PredictionService service.
type PredictionServiceServer interface {
// Perform a prediction.
Predict(context.Context, *PredictRequest) (*PredictResponse, error)
}
func RegisterPredictionServiceServer(s *grpc.Server, srv PredictionServiceServer) {
s.RegisterService(&_PredictionService_serviceDesc, srv)
}
func _PredictionService_Predict_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(PredictRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(PredictionServiceServer).Predict(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/google.cloud.automl.v1beta1.PredictionService/Predict",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(PredictionServiceServer).Predict(ctx, req.(*PredictRequest))
}
return interceptor(ctx, in, info, handler)
}
var _PredictionService_serviceDesc = grpc.ServiceDesc{
ServiceName: "google.cloud.automl.v1beta1.PredictionService",
HandlerType: (*PredictionServiceServer)(nil),
Methods: []grpc.MethodDesc{
{
MethodName: "Predict",
Handler: _PredictionService_Predict_Handler,
},
},
Streams: []grpc.StreamDesc{},
Metadata: "google/cloud/automl/v1beta1/prediction_service.proto",
}
func init() {
proto.RegisterFile("google/cloud/automl/v1beta1/prediction_service.proto", fileDescriptor_prediction_service_1b71b7f556fd7159)
}
var fileDescriptor_prediction_service_1b71b7f556fd7159 = []byte{
// 462 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x93, 0xdf, 0x8a, 0xd3, 0x40,
0x14, 0xc6, 0x99, 0x56, 0x77, 0xdd, 0x29, 0xfe, 0x1b, 0x44, 0x4a, 0x14, 0x2c, 0xbd, 0x2a, 0xdd,
0x65, 0x86, 0xad, 0xc2, 0x6a, 0x57, 0x2f, 0xb6, 0x50, 0xf0, 0x46, 0x0c, 0x11, 0xbc, 0xf0, 0xa6,
0x9c, 0x4d, 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