pb

package
v0.0.0-...-7af1aca Latest Latest
Warning

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

Go to latest
Published: Feb 27, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	CorpusEntry_InTak_name = map[int32]string{
		0: "UNSET",
		1: "NOT_IN_TAK",
		2: "IN_TAK",
	}
	CorpusEntry_InTak_value = map[string]int32{
		"UNSET":      0,
		"NOT_IN_TAK": 1,
		"IN_TAK":     2,
	}
)

Enum value maps for CorpusEntry_InTak.

View Source
var Analysis_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "tak.proto.Analysis",
	HandlerType: (*AnalysisServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Evaluate",
			Handler:    _Analysis_Evaluate_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "tak/proto/analysis.proto",
}

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

View Source
var File_tak_proto_analysis_proto protoreflect.FileDescriptor
View Source
var File_tak_proto_corpus_entry_proto protoreflect.FileDescriptor
View Source
var File_tak_proto_taktician_proto protoreflect.FileDescriptor
View Source
var Taktician_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "tak.proto.Taktician",
	HandlerType: (*TakticianServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Analyze",
			Handler:    _Taktician_Analyze_Handler,
		},
		{
			MethodName: "Canonicalize",
			Handler:    _Taktician_Canonicalize_Handler,
		},
		{
			MethodName: "IsPositionInTak",
			Handler:    _Taktician_IsPositionInTak_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "tak/proto/taktician.proto",
}

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

Functions

func RegisterAnalysisServer

func RegisterAnalysisServer(s grpc.ServiceRegistrar, srv AnalysisServer)

func RegisterTakticianServer

func RegisterTakticianServer(s grpc.ServiceRegistrar, srv TakticianServer)

Types

type AnalysisClient

type AnalysisClient interface {
	Evaluate(ctx context.Context, in *EvaluateRequest, opts ...grpc.CallOption) (*EvaluateResponse, error)
}

AnalysisClient is the client API for Analysis 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.

func NewAnalysisClient

func NewAnalysisClient(cc grpc.ClientConnInterface) AnalysisClient

type AnalysisServer

type AnalysisServer interface {
	Evaluate(context.Context, *EvaluateRequest) (*EvaluateResponse, error)
	// contains filtered or unexported methods
}

AnalysisServer is the server API for Analysis service. All implementations must embed UnimplementedAnalysisServer for forward compatibility

type AnalyzeRequest

type AnalyzeRequest struct {
	Position string `protobuf:"bytes,1,opt,name=position,proto3" json:"position,omitempty"`
	Depth    int32  `protobuf:"varint,2,opt,name=depth,proto3" json:"depth,omitempty"`
	Precise  bool   `protobuf:"varint,3,opt,name=precise,proto3" json:"precise,omitempty"`
	// contains filtered or unexported fields
}

func (*AnalyzeRequest) Descriptor deprecated

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

Deprecated: Use AnalyzeRequest.ProtoReflect.Descriptor instead.

func (*AnalyzeRequest) GetDepth

func (x *AnalyzeRequest) GetDepth() int32

func (*AnalyzeRequest) GetPosition

func (x *AnalyzeRequest) GetPosition() string

func (*AnalyzeRequest) GetPrecise

func (x *AnalyzeRequest) GetPrecise() bool

func (*AnalyzeRequest) ProtoMessage

func (*AnalyzeRequest) ProtoMessage()

func (*AnalyzeRequest) ProtoReflect

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

func (*AnalyzeRequest) Reset

func (x *AnalyzeRequest) Reset()

func (*AnalyzeRequest) String

func (x *AnalyzeRequest) String() string

type AnalyzeResponse

type AnalyzeResponse struct {
	Pv    []string `protobuf:"bytes,1,rep,name=pv,proto3" json:"pv,omitempty"`
	Value int64    `protobuf:"varint,2,opt,name=value,proto3" json:"value,omitempty"`
	Depth int32    `protobuf:"varint,3,opt,name=depth,proto3" json:"depth,omitempty"`
	// contains filtered or unexported fields
}

func (*AnalyzeResponse) Descriptor deprecated

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

Deprecated: Use AnalyzeResponse.ProtoReflect.Descriptor instead.

func (*AnalyzeResponse) GetDepth

func (x *AnalyzeResponse) GetDepth() int32

func (*AnalyzeResponse) GetPv

func (x *AnalyzeResponse) GetPv() []string

func (*AnalyzeResponse) GetValue

func (x *AnalyzeResponse) GetValue() int64

func (*AnalyzeResponse) ProtoMessage

func (*AnalyzeResponse) ProtoMessage()

func (*AnalyzeResponse) ProtoReflect

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

func (*AnalyzeResponse) Reset

func (x *AnalyzeResponse) Reset()

func (*AnalyzeResponse) String

func (x *AnalyzeResponse) String() string

type CanonicalizeRequest

type CanonicalizeRequest struct {
	Size  int32    `protobuf:"varint,1,opt,name=size,proto3" json:"size,omitempty"`
	Moves []string `protobuf:"bytes,2,rep,name=moves,proto3" json:"moves,omitempty"`
	// contains filtered or unexported fields
}

func (*CanonicalizeRequest) Descriptor deprecated

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

Deprecated: Use CanonicalizeRequest.ProtoReflect.Descriptor instead.

func (*CanonicalizeRequest) GetMoves

func (x *CanonicalizeRequest) GetMoves() []string

func (*CanonicalizeRequest) GetSize

func (x *CanonicalizeRequest) GetSize() int32

func (*CanonicalizeRequest) ProtoMessage

func (*CanonicalizeRequest) ProtoMessage()

func (*CanonicalizeRequest) ProtoReflect

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

func (*CanonicalizeRequest) Reset

func (x *CanonicalizeRequest) Reset()

func (*CanonicalizeRequest) String

func (x *CanonicalizeRequest) String() string

type CanonicalizeResponse

type CanonicalizeResponse struct {
	Moves []string `protobuf:"bytes,1,rep,name=moves,proto3" json:"moves,omitempty"`
	// contains filtered or unexported fields
}

func (*CanonicalizeResponse) Descriptor deprecated

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

Deprecated: Use CanonicalizeResponse.ProtoReflect.Descriptor instead.

func (*CanonicalizeResponse) GetMoves

func (x *CanonicalizeResponse) GetMoves() []string

func (*CanonicalizeResponse) ProtoMessage

func (*CanonicalizeResponse) ProtoMessage()

func (*CanonicalizeResponse) ProtoReflect

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

func (*CanonicalizeResponse) Reset

func (x *CanonicalizeResponse) Reset()

func (*CanonicalizeResponse) String

func (x *CanonicalizeResponse) String() string

type CorpusEntry

type CorpusEntry struct {
	Day      string            `protobuf:"bytes,1,opt,name=day,proto3" json:"day,omitempty"`
	Id       int32             `protobuf:"varint,2,opt,name=id,proto3" json:"id,omitempty"`
	Ply      int32             `protobuf:"varint,3,opt,name=ply,proto3" json:"ply,omitempty"`
	Tps      string            `protobuf:"bytes,4,opt,name=tps,proto3" json:"tps,omitempty"`
	Move     string            `protobuf:"bytes,5,opt,name=move,proto3" json:"move,omitempty"`
	Value    float32           `protobuf:"fixed32,6,opt,name=value,proto3" json:"value,omitempty"`
	Plies    int32             `protobuf:"varint,7,opt,name=plies,proto3" json:"plies,omitempty"`
	Features []int64           `protobuf:"varint,8,rep,packed,name=features,proto3" json:"features,omitempty"`
	InTak    CorpusEntry_InTak `protobuf:"varint,9,opt,name=in_tak,json=inTak,proto3,enum=tak.proto.CorpusEntry_InTak" json:"in_tak,omitempty"`
	// contains filtered or unexported fields
}

func (*CorpusEntry) Descriptor deprecated

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

Deprecated: Use CorpusEntry.ProtoReflect.Descriptor instead.

func (*CorpusEntry) GetDay

func (x *CorpusEntry) GetDay() string

func (*CorpusEntry) GetFeatures

func (x *CorpusEntry) GetFeatures() []int64

func (*CorpusEntry) GetId

func (x *CorpusEntry) GetId() int32

func (*CorpusEntry) GetInTak

func (x *CorpusEntry) GetInTak() CorpusEntry_InTak

func (*CorpusEntry) GetMove

func (x *CorpusEntry) GetMove() string

func (*CorpusEntry) GetPlies

func (x *CorpusEntry) GetPlies() int32

func (*CorpusEntry) GetPly

func (x *CorpusEntry) GetPly() int32

func (*CorpusEntry) GetTps

func (x *CorpusEntry) GetTps() string

func (*CorpusEntry) GetValue

func (x *CorpusEntry) GetValue() float32

func (*CorpusEntry) ProtoMessage

func (*CorpusEntry) ProtoMessage()

func (*CorpusEntry) ProtoReflect

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

func (*CorpusEntry) Reset

func (x *CorpusEntry) Reset()

func (*CorpusEntry) String

func (x *CorpusEntry) String() string

type CorpusEntry_InTak

type CorpusEntry_InTak int32
const (
	CorpusEntry_UNSET      CorpusEntry_InTak = 0
	CorpusEntry_NOT_IN_TAK CorpusEntry_InTak = 1
	CorpusEntry_IN_TAK     CorpusEntry_InTak = 2
)

func (CorpusEntry_InTak) Descriptor

func (CorpusEntry_InTak) Enum

func (CorpusEntry_InTak) EnumDescriptor deprecated

func (CorpusEntry_InTak) EnumDescriptor() ([]byte, []int)

Deprecated: Use CorpusEntry_InTak.Descriptor instead.

func (CorpusEntry_InTak) Number

func (CorpusEntry_InTak) String

func (x CorpusEntry_InTak) String() string

func (CorpusEntry_InTak) Type

type EvaluateRequest

type EvaluateRequest struct {
	Position []int32 `protobuf:"varint,1,rep,packed,name=position,proto3" json:"position,omitempty"`
	// contains filtered or unexported fields
}

func (*EvaluateRequest) Descriptor deprecated

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

Deprecated: Use EvaluateRequest.ProtoReflect.Descriptor instead.

func (*EvaluateRequest) GetPosition

func (x *EvaluateRequest) GetPosition() []int32

func (*EvaluateRequest) ProtoMessage

func (*EvaluateRequest) ProtoMessage()

func (*EvaluateRequest) ProtoReflect

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

func (*EvaluateRequest) Reset

func (x *EvaluateRequest) Reset()

func (*EvaluateRequest) String

func (x *EvaluateRequest) String() string

type EvaluateResponse

type EvaluateResponse struct {
	MoveProbs      []float32 `protobuf:"fixed32,1,rep,packed,name=move_probs,json=moveProbs,proto3" json:"move_probs,omitempty"`
	Value          float32   `protobuf:"fixed32,2,opt,name=value,proto3" json:"value,omitempty"`
	MoveProbsBytes []byte    `protobuf:"bytes,3,opt,name=move_probs_bytes,json=moveProbsBytes,proto3" json:"move_probs_bytes,omitempty"`
	// contains filtered or unexported fields
}

func (*EvaluateResponse) Descriptor deprecated

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

Deprecated: Use EvaluateResponse.ProtoReflect.Descriptor instead.

func (*EvaluateResponse) GetMoveProbs

func (x *EvaluateResponse) GetMoveProbs() []float32

func (*EvaluateResponse) GetMoveProbsBytes

func (x *EvaluateResponse) GetMoveProbsBytes() []byte

func (*EvaluateResponse) GetValue

func (x *EvaluateResponse) GetValue() float32

func (*EvaluateResponse) ProtoMessage

func (*EvaluateResponse) ProtoMessage()

func (*EvaluateResponse) ProtoReflect

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

func (*EvaluateResponse) Reset

func (x *EvaluateResponse) Reset()

func (*EvaluateResponse) String

func (x *EvaluateResponse) String() string

type IsPositionInTakRequest

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

func (*IsPositionInTakRequest) Descriptor deprecated

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

Deprecated: Use IsPositionInTakRequest.ProtoReflect.Descriptor instead.

func (*IsPositionInTakRequest) GetPosition

func (x *IsPositionInTakRequest) GetPosition() string

func (*IsPositionInTakRequest) ProtoMessage

func (*IsPositionInTakRequest) ProtoMessage()

func (*IsPositionInTakRequest) ProtoReflect

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

func (*IsPositionInTakRequest) Reset

func (x *IsPositionInTakRequest) Reset()

func (*IsPositionInTakRequest) String

func (x *IsPositionInTakRequest) String() string

type IsPositionInTakResponse

type IsPositionInTakResponse struct {
	InTak   bool   `protobuf:"varint,1,opt,name=inTak,proto3" json:"inTak,omitempty"`
	TakMove string `protobuf:"bytes,2,opt,name=takMove,proto3" json:"takMove,omitempty"`
	// contains filtered or unexported fields
}

func (*IsPositionInTakResponse) Descriptor deprecated

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

Deprecated: Use IsPositionInTakResponse.ProtoReflect.Descriptor instead.

func (*IsPositionInTakResponse) GetInTak

func (x *IsPositionInTakResponse) GetInTak() bool

func (*IsPositionInTakResponse) GetTakMove

func (x *IsPositionInTakResponse) GetTakMove() string

func (*IsPositionInTakResponse) ProtoMessage

func (*IsPositionInTakResponse) ProtoMessage()

func (*IsPositionInTakResponse) ProtoReflect

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

func (*IsPositionInTakResponse) Reset

func (x *IsPositionInTakResponse) Reset()

func (*IsPositionInTakResponse) String

func (x *IsPositionInTakResponse) String() string

type TakticianClient

type TakticianClient interface {
	Analyze(ctx context.Context, in *AnalyzeRequest, opts ...grpc.CallOption) (*AnalyzeResponse, error)
	Canonicalize(ctx context.Context, in *CanonicalizeRequest, opts ...grpc.CallOption) (*CanonicalizeResponse, error)
	IsPositionInTak(ctx context.Context, in *IsPositionInTakRequest, opts ...grpc.CallOption) (*IsPositionInTakResponse, error)
}

TakticianClient is the client API for Taktician 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.

func NewTakticianClient

func NewTakticianClient(cc grpc.ClientConnInterface) TakticianClient

type TakticianServer

type TakticianServer interface {
	Analyze(context.Context, *AnalyzeRequest) (*AnalyzeResponse, error)
	Canonicalize(context.Context, *CanonicalizeRequest) (*CanonicalizeResponse, error)
	IsPositionInTak(context.Context, *IsPositionInTakRequest) (*IsPositionInTakResponse, error)
	// contains filtered or unexported methods
}

TakticianServer is the server API for Taktician service. All implementations must embed UnimplementedTakticianServer for forward compatibility

type UnimplementedAnalysisServer

type UnimplementedAnalysisServer struct {
}

UnimplementedAnalysisServer must be embedded to have forward compatible implementations.

func (UnimplementedAnalysisServer) Evaluate

type UnimplementedTakticianServer

type UnimplementedTakticianServer struct {
}

UnimplementedTakticianServer must be embedded to have forward compatible implementations.

func (UnimplementedTakticianServer) Analyze

func (UnimplementedTakticianServer) Canonicalize

func (UnimplementedTakticianServer) IsPositionInTak

type UnsafeAnalysisServer

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

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

type UnsafeTakticianServer

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

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

Jump to

Keyboard shortcuts

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