v1alpha1

package
v0.0.0-...-e2da53a Latest Latest
Warning

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

Go to latest
Published: May 31, 2024 License: Apache-2.0 Imports: 21 Imported by: 3

Documentation

Overview

Package v1alpha1 is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

This section is empty.

Variables

View Source
var (
	BlockKind_name = map[int32]string{
		0: "UNKNOWN_BLOCK_KIND",
		1: "MARKUP",
		2: "CODE",
	}
	BlockKind_value = map[string]int32{
		"UNKNOWN_BLOCK_KIND": 0,
		"MARKUP":             1,
		"CODE":               2,
	}
)

Enum value maps for BlockKind.

View Source
var (
	EvalResultStatus_name = map[int32]string{
		0: "UNKNOWN_EVAL_RESULT_STATUS",
		1: "DONE",
		2: "ERROR",
	}
	EvalResultStatus_value = map[string]int32{
		"UNKNOWN_EVAL_RESULT_STATUS": 0,
		"DONE":                       1,
		"ERROR":                      2,
	}
)

Enum value maps for EvalResultStatus.

View Source
var EvalService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "EvalService",
	HandlerType: (*EvalServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "List",
			Handler:    _EvalService_List_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "foyle/v1alpha1/eval.proto",
}

EvalService_ServiceDesc is the grpc.ServiceDesc for EvalService 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 ExecuteService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "ExecuteService",
	HandlerType: (*ExecuteServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Execute",
			Handler:    _ExecuteService_Execute_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "foyle/v1alpha1/agent.proto",
}

ExecuteService_ServiceDesc is the grpc.ServiceDesc for ExecuteService 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_foyle_v1alpha1_agent_proto protoreflect.FileDescriptor
View Source
var File_foyle_v1alpha1_doc_proto protoreflect.FileDescriptor
View Source
var File_foyle_v1alpha1_eval_proto protoreflect.FileDescriptor
View Source
var File_foyle_v1alpha1_trainer_proto protoreflect.FileDescriptor
View Source
var GenerateService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "GenerateService",
	HandlerType: (*GenerateServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Generate",
			Handler:    _GenerateService_Generate_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "foyle/v1alpha1/agent.proto",
}

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

Functions

func RegisterEvalServiceServer

func RegisterEvalServiceServer(s grpc.ServiceRegistrar, srv EvalServiceServer)

func RegisterExecuteServiceHandler

func RegisterExecuteServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterExecuteServiceHandler registers the http handlers for service ExecuteService to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterExecuteServiceHandlerClient

func RegisterExecuteServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client ExecuteServiceClient) error

RegisterExecuteServiceHandlerClient registers the http handlers for service ExecuteService to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "ExecuteServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "ExecuteServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "ExecuteServiceClient" to call the correct interceptors.

func RegisterExecuteServiceHandlerFromEndpoint

func RegisterExecuteServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterExecuteServiceHandlerFromEndpoint is same as RegisterExecuteServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterExecuteServiceHandlerServer

func RegisterExecuteServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server ExecuteServiceServer) error

RegisterExecuteServiceHandlerServer registers the http handlers for service ExecuteService to "mux". UnaryRPC :call ExecuteServiceServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterExecuteServiceHandlerFromEndpoint instead.

func RegisterExecuteServiceServer

func RegisterExecuteServiceServer(s grpc.ServiceRegistrar, srv ExecuteServiceServer)

func RegisterGenerateServiceHandler

func RegisterGenerateServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterGenerateServiceHandler registers the http handlers for service GenerateService to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterGenerateServiceHandlerClient

func RegisterGenerateServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client GenerateServiceClient) error

RegisterGenerateServiceHandlerClient registers the http handlers for service GenerateService to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "GenerateServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "GenerateServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "GenerateServiceClient" to call the correct interceptors.

func RegisterGenerateServiceHandlerFromEndpoint

func RegisterGenerateServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterGenerateServiceHandlerFromEndpoint is same as RegisterGenerateServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterGenerateServiceHandlerServer

func RegisterGenerateServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server GenerateServiceServer) error

RegisterGenerateServiceHandlerServer registers the http handlers for service GenerateService to "mux". UnaryRPC :call GenerateServiceServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterGenerateServiceHandlerFromEndpoint instead.

func RegisterGenerateServiceServer

func RegisterGenerateServiceServer(s grpc.ServiceRegistrar, srv GenerateServiceServer)

Types

type Block

type Block struct {

	// BlockKind is an enum indicating what type of block it is e.g text or output
	// It maps to VSCode's NotebookCellKind
	// https://github.com/microsoft/vscode/blob/98332892fd2cb3c948ced33f542698e20c6279b9/src/vs/workbench/api/common/extHostTypes.ts#L3766
	Kind BlockKind `protobuf:"varint,1,opt,name=kind,proto3,enum=BlockKind" json:"kind,omitempty"`
	// language is a string identifying the language.
	// It maps to languageId
	// https://github.com/microsoft/vscode/blob/98332892fd2cb3c948ced33f542698e20c6279b9/src/vs/workbench/api/common/extHostTypes.ts#L3623
	Language string `protobuf:"bytes,2,opt,name=language,proto3" json:"language,omitempty"`
	// contents is the actual contents of the block.
	// Not the outputs of the block.
	// It corresponds to the value in NotebookCellData
	Contents string `protobuf:"bytes,3,opt,name=contents,proto3" json:"contents,omitempty"`
	// outputs are the output of a block if any.
	Outputs []*BlockOutput `protobuf:"bytes,4,rep,name=outputs,proto3" json:"outputs,omitempty"`
	// IDs of any traces associated with this block.
	// TODO(jeremy): Can we deprecate this field? The trace is a property of the request not the individual block.
	TraceIds []string `protobuf:"bytes,6,rep,name=trace_ids,json=traceIds,proto3" json:"trace_ids,omitempty"`
	// ID of the block.
	Id string `protobuf:"bytes,7,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

Block represents a block in a document. It is inspired by the VSCode NotebookCellData type https://github.com/microsoft/vscode/blob/98332892fd2cb3c948ced33f542698e20c6279b9/src/vs/workbench/api/common/extHostTypes.ts#L3598

func (*Block) Descriptor deprecated

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

Deprecated: Use Block.ProtoReflect.Descriptor instead.

func (*Block) GetContents

func (x *Block) GetContents() string

func (*Block) GetId

func (x *Block) GetId() string

func (*Block) GetKind

func (x *Block) GetKind() BlockKind

func (*Block) GetLanguage

func (x *Block) GetLanguage() string

func (*Block) GetOutputs

func (x *Block) GetOutputs() []*BlockOutput

func (*Block) GetTraceIds

func (x *Block) GetTraceIds() []string

func (*Block) MarshalLogObject

func (m *Block) MarshalLogObject(enc go_uber_org_zap_zapcore.ObjectEncoder) error

func (*Block) ProtoMessage

func (*Block) ProtoMessage()

func (*Block) ProtoReflect

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

func (*Block) Reset

func (x *Block) Reset()

func (*Block) String

func (x *Block) String() string

type BlockKind

type BlockKind int32
const (
	BlockKind_UNKNOWN_BLOCK_KIND BlockKind = 0
	BlockKind_MARKUP             BlockKind = 1
	BlockKind_CODE               BlockKind = 2
)

func (BlockKind) Descriptor

func (BlockKind) Descriptor() protoreflect.EnumDescriptor

func (BlockKind) Enum

func (x BlockKind) Enum() *BlockKind

func (BlockKind) EnumDescriptor deprecated

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

Deprecated: Use BlockKind.Descriptor instead.

func (BlockKind) Number

func (x BlockKind) Number() protoreflect.EnumNumber

func (BlockKind) String

func (x BlockKind) String() string

func (BlockKind) Type

type BlockOutput

type BlockOutput struct {

	// items is the output items. Each item is the different representation of the same output data
	Items []*BlockOutputItem `protobuf:"bytes,1,rep,name=items,proto3" json:"items,omitempty"`
	// contains filtered or unexported fields
}

BlockOutput represents the output of a block. It corresponds to a VSCode NotebookCellOutput https://github.com/microsoft/vscode/blob/98332892fd2cb3c948ced33f542698e20c6279b9/src/vscode-dts/vscode.d.ts#L14835

func (*BlockOutput) Descriptor deprecated

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

Deprecated: Use BlockOutput.ProtoReflect.Descriptor instead.

func (*BlockOutput) GetItems

func (x *BlockOutput) GetItems() []*BlockOutputItem

func (*BlockOutput) MarshalLogObject

func (m *BlockOutput) MarshalLogObject(enc go_uber_org_zap_zapcore.ObjectEncoder) error

func (*BlockOutput) ProtoMessage

func (*BlockOutput) ProtoMessage()

func (*BlockOutput) ProtoReflect

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

func (*BlockOutput) Reset

func (x *BlockOutput) Reset()

func (*BlockOutput) String

func (x *BlockOutput) String() string

type BlockOutputItem

type BlockOutputItem struct {

	// mime is the mime type of the output item.
	Mime string `protobuf:"bytes,1,opt,name=mime,proto3" json:"mime,omitempty"`
	// value of the output item.
	// We use string data type and not bytes because the JSON representation of bytes is a base64 string.
	// vscode data uses a byte. We may need to add support for bytes to support non text data data in the future.
	TextData string `protobuf:"bytes,2,opt,name=text_data,json=textData,proto3" json:"text_data,omitempty"`
	// contains filtered or unexported fields
}

BlockOutputItem represents an item in a block output. It corresponds to a VSCode NotebookCellOutputItem https://github.com/microsoft/vscode/blob/98332892fd2cb3c948ced33f542698e20c6279b9/src/vscode-dts/vscode.d.ts#L14753

func (*BlockOutputItem) Descriptor deprecated

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

Deprecated: Use BlockOutputItem.ProtoReflect.Descriptor instead.

func (*BlockOutputItem) GetMime

func (x *BlockOutputItem) GetMime() string

func (*BlockOutputItem) GetTextData

func (x *BlockOutputItem) GetTextData() string

func (*BlockOutputItem) MarshalLogObject

func (*BlockOutputItem) ProtoMessage

func (*BlockOutputItem) ProtoMessage()

func (*BlockOutputItem) ProtoReflect

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

func (*BlockOutputItem) Reset

func (x *BlockOutputItem) Reset()

func (*BlockOutputItem) String

func (x *BlockOutputItem) String() string

type Doc

type Doc struct {
	Blocks []*Block `protobuf:"bytes,1,rep,name=blocks,proto3" json:"blocks,omitempty"`
	// contains filtered or unexported fields
}

Doc represents a document in the editor.

func (*Doc) Descriptor deprecated

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

Deprecated: Use Doc.ProtoReflect.Descriptor instead.

func (*Doc) GetBlocks

func (x *Doc) GetBlocks() []*Block

func (*Doc) MarshalLogObject

func (m *Doc) MarshalLogObject(enc go_uber_org_zap_zapcore.ObjectEncoder) error

func (*Doc) ProtoMessage

func (*Doc) ProtoMessage()

func (*Doc) ProtoReflect

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

func (*Doc) Reset

func (x *Doc) Reset()

func (*Doc) String

func (x *Doc) String() string

type EvalResult

type EvalResult struct {

	// Example is the answer and expected result
	Example *Example `protobuf:"bytes,1,opt,name=example,proto3" json:"example,omitempty"`
	// example_file is the file containing the example
	ExampleFile string `protobuf:"bytes,2,opt,name=example_file,json=exampleFile,proto3" json:"example_file,omitempty"`
	// Actual response
	Actual []*Block `protobuf:"bytes,3,rep,name=actual,proto3" json:"actual,omitempty"`
	// The distance between the actual and expected response
	Distance           int32   `protobuf:"varint,4,opt,name=distance,proto3" json:"distance,omitempty"`
	NormalizedDistance float32 `protobuf:"fixed32,7,opt,name=normalized_distance,json=normalizedDistance,proto3" json:"normalized_distance,omitempty"`
	Error              string  `protobuf:"bytes,5,opt,name=error,proto3" json:"error,omitempty"`
	// Status of the evaluation
	Status EvalResultStatus `protobuf:"varint,6,opt,name=status,proto3,enum=EvalResultStatus" json:"status,omitempty"`
	// The ID of the generate trace
	GenTraceId string `protobuf:"bytes,8,opt,name=gen_trace_id,json=genTraceId,proto3" json:"gen_trace_id,omitempty"`
	// Best matching RAG result
	BestRagResult *RAGResult `protobuf:"bytes,9,opt,name=best_rag_result,json=bestRagResult,proto3" json:"best_rag_result,omitempty"`
	// contains filtered or unexported fields
}

EvalResult represents an evaluation result

func (*EvalResult) Descriptor deprecated

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

Deprecated: Use EvalResult.ProtoReflect.Descriptor instead.

func (*EvalResult) GetActual

func (x *EvalResult) GetActual() []*Block

func (*EvalResult) GetBestRagResult

func (x *EvalResult) GetBestRagResult() *RAGResult

func (*EvalResult) GetDistance

func (x *EvalResult) GetDistance() int32

func (*EvalResult) GetError

func (x *EvalResult) GetError() string

func (*EvalResult) GetExample

func (x *EvalResult) GetExample() *Example

func (*EvalResult) GetExampleFile

func (x *EvalResult) GetExampleFile() string

func (*EvalResult) GetGenTraceId

func (x *EvalResult) GetGenTraceId() string

func (*EvalResult) GetNormalizedDistance

func (x *EvalResult) GetNormalizedDistance() float32

func (*EvalResult) GetStatus

func (x *EvalResult) GetStatus() EvalResultStatus

func (*EvalResult) MarshalLogObject

func (m *EvalResult) MarshalLogObject(enc go_uber_org_zap_zapcore.ObjectEncoder) error

func (*EvalResult) ProtoMessage

func (*EvalResult) ProtoMessage()

func (*EvalResult) ProtoReflect

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

func (*EvalResult) Reset

func (x *EvalResult) Reset()

func (*EvalResult) String

func (x *EvalResult) String() string

type EvalResultListRequest

type EvalResultListRequest struct {

	// The path of the database to fetch results for
	Database string `protobuf:"bytes,1,opt,name=database,proto3" json:"database,omitempty"`
	// contains filtered or unexported fields
}

func (*EvalResultListRequest) Descriptor deprecated

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

Deprecated: Use EvalResultListRequest.ProtoReflect.Descriptor instead.

func (*EvalResultListRequest) GetDatabase

func (x *EvalResultListRequest) GetDatabase() string

func (*EvalResultListRequest) MarshalLogObject

func (*EvalResultListRequest) ProtoMessage

func (*EvalResultListRequest) ProtoMessage()

func (*EvalResultListRequest) ProtoReflect

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

func (*EvalResultListRequest) Reset

func (x *EvalResultListRequest) Reset()

func (*EvalResultListRequest) String

func (x *EvalResultListRequest) String() string

type EvalResultListResponse

type EvalResultListResponse struct {
	Items []*EvalResult `protobuf:"bytes,1,rep,name=items,proto3" json:"items,omitempty"`
	// contains filtered or unexported fields
}

func (*EvalResultListResponse) Descriptor deprecated

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

Deprecated: Use EvalResultListResponse.ProtoReflect.Descriptor instead.

func (*EvalResultListResponse) GetItems

func (x *EvalResultListResponse) GetItems() []*EvalResult

func (*EvalResultListResponse) MarshalLogObject

func (*EvalResultListResponse) ProtoMessage

func (*EvalResultListResponse) ProtoMessage()

func (*EvalResultListResponse) ProtoReflect

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

func (*EvalResultListResponse) Reset

func (x *EvalResultListResponse) Reset()

func (*EvalResultListResponse) String

func (x *EvalResultListResponse) String() string

type EvalResultStatus

type EvalResultStatus int32
const (
	EvalResultStatus_UNKNOWN_EVAL_RESULT_STATUS EvalResultStatus = 0
	EvalResultStatus_DONE                       EvalResultStatus = 1
	EvalResultStatus_ERROR                      EvalResultStatus = 2
)

func (EvalResultStatus) Descriptor

func (EvalResultStatus) Enum

func (EvalResultStatus) EnumDescriptor deprecated

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

Deprecated: Use EvalResultStatus.Descriptor instead.

func (EvalResultStatus) Number

func (EvalResultStatus) String

func (x EvalResultStatus) String() string

func (EvalResultStatus) Type

type EvalServiceClient

type EvalServiceClient interface {
	List(ctx context.Context, in *EvalResultListRequest, opts ...grpc.CallOption) (*EvalResultListResponse, error)
}

EvalServiceClient is the client API for EvalService 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.

type EvalServiceServer

type EvalServiceServer interface {
	List(context.Context, *EvalResultListRequest) (*EvalResultListResponse, error)
	// contains filtered or unexported methods
}

EvalServiceServer is the server API for EvalService service. All implementations must embed UnimplementedEvalServiceServer for forward compatibility

type Example

type Example struct {
	Id        string    `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Embedding []float32 `protobuf:"fixed32,2,rep,packed,name=embedding,proto3" json:"embedding,omitempty"`
	Query     *Doc      `protobuf:"bytes,3,opt,name=query,proto3" json:"query,omitempty"`
	Answer    []*Block  `protobuf:"bytes,4,rep,name=answer,proto3" json:"answer,omitempty"`
	// contains filtered or unexported fields
}

Example represents an example to be used in few shot learning

func (*Example) Descriptor deprecated

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

Deprecated: Use Example.ProtoReflect.Descriptor instead.

func (*Example) GetAnswer

func (x *Example) GetAnswer() []*Block

func (*Example) GetEmbedding

func (x *Example) GetEmbedding() []float32

func (*Example) GetId

func (x *Example) GetId() string

func (*Example) GetQuery

func (x *Example) GetQuery() *Doc

func (*Example) MarshalLogObject

func (m *Example) MarshalLogObject(enc go_uber_org_zap_zapcore.ObjectEncoder) error

func (*Example) ProtoMessage

func (*Example) ProtoMessage()

func (*Example) ProtoReflect

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

func (*Example) Reset

func (x *Example) Reset()

func (*Example) String

func (x *Example) String() string

type ExecuteRequest

type ExecuteRequest struct {
	Block *Block `protobuf:"bytes,1,opt,name=block,proto3" json:"block,omitempty"`
	// contains filtered or unexported fields
}

func (*ExecuteRequest) Descriptor deprecated

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

Deprecated: Use ExecuteRequest.ProtoReflect.Descriptor instead.

func (*ExecuteRequest) GetBlock

func (x *ExecuteRequest) GetBlock() *Block

func (*ExecuteRequest) MarshalLogObject

func (m *ExecuteRequest) MarshalLogObject(enc go_uber_org_zap_zapcore.ObjectEncoder) error

func (*ExecuteRequest) ProtoMessage

func (*ExecuteRequest) ProtoMessage()

func (*ExecuteRequest) ProtoReflect

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

func (*ExecuteRequest) Reset

func (x *ExecuteRequest) Reset()

func (*ExecuteRequest) String

func (x *ExecuteRequest) String() string

type ExecuteResponse

type ExecuteResponse struct {
	Outputs []*BlockOutput `protobuf:"bytes,1,rep,name=outputs,proto3" json:"outputs,omitempty"`
	// contains filtered or unexported fields
}

func (*ExecuteResponse) Descriptor deprecated

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

Deprecated: Use ExecuteResponse.ProtoReflect.Descriptor instead.

func (*ExecuteResponse) GetOutputs

func (x *ExecuteResponse) GetOutputs() []*BlockOutput

func (*ExecuteResponse) MarshalLogObject

func (*ExecuteResponse) ProtoMessage

func (*ExecuteResponse) ProtoMessage()

func (*ExecuteResponse) ProtoReflect

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

func (*ExecuteResponse) Reset

func (x *ExecuteResponse) Reset()

func (*ExecuteResponse) String

func (x *ExecuteResponse) String() string

type ExecuteServiceClient

type ExecuteServiceClient interface {
	// Execute executes a cell in an existing document.
	Execute(ctx context.Context, in *ExecuteRequest, opts ...grpc.CallOption) (*ExecuteResponse, error)
}

ExecuteServiceClient is the client API for ExecuteService 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.

type ExecuteServiceServer

type ExecuteServiceServer interface {
	// Execute executes a cell in an existing document.
	Execute(context.Context, *ExecuteRequest) (*ExecuteResponse, error)
	// contains filtered or unexported methods
}

ExecuteServiceServer is the server API for ExecuteService service. All implementations must embed UnimplementedExecuteServiceServer for forward compatibility

type GenerateRequest

type GenerateRequest struct {
	Doc *Doc `protobuf:"bytes,1,opt,name=doc,proto3" json:"doc,omitempty"`
	// contains filtered or unexported fields
}

func (*GenerateRequest) Descriptor deprecated

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

Deprecated: Use GenerateRequest.ProtoReflect.Descriptor instead.

func (*GenerateRequest) GetDoc

func (x *GenerateRequest) GetDoc() *Doc

func (*GenerateRequest) MarshalLogObject

func (*GenerateRequest) ProtoMessage

func (*GenerateRequest) ProtoMessage()

func (*GenerateRequest) ProtoReflect

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

func (*GenerateRequest) Reset

func (x *GenerateRequest) Reset()

func (*GenerateRequest) String

func (x *GenerateRequest) String() string

type GenerateResponse

type GenerateResponse struct {
	Blocks  []*Block `protobuf:"bytes,1,rep,name=blocks,proto3" json:"blocks,omitempty"`
	TraceId string   `protobuf:"bytes,2,opt,name=trace_id,json=traceId,proto3" json:"trace_id,omitempty"`
	// contains filtered or unexported fields
}

func (*GenerateResponse) Descriptor deprecated

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

Deprecated: Use GenerateResponse.ProtoReflect.Descriptor instead.

func (*GenerateResponse) GetBlocks

func (x *GenerateResponse) GetBlocks() []*Block

func (*GenerateResponse) GetTraceId

func (x *GenerateResponse) GetTraceId() string

func (*GenerateResponse) MarshalLogObject

func (*GenerateResponse) ProtoMessage

func (*GenerateResponse) ProtoMessage()

func (*GenerateResponse) ProtoReflect

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

func (*GenerateResponse) Reset

func (x *GenerateResponse) Reset()

func (*GenerateResponse) String

func (x *GenerateResponse) String() string

type GenerateServiceClient

type GenerateServiceClient interface {
	// Generate generates new cells given an existing document.
	Generate(ctx context.Context, in *GenerateRequest, opts ...grpc.CallOption) (*GenerateResponse, error)
}

GenerateServiceClient is the client API for GenerateService 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.

type GenerateServiceServer

type GenerateServiceServer interface {
	// Generate generates new cells given an existing document.
	Generate(context.Context, *GenerateRequest) (*GenerateResponse, error)
	// contains filtered or unexported methods
}

GenerateServiceServer is the server API for GenerateService service. All implementations must embed UnimplementedGenerateServiceServer for forward compatibility

type RAGResult

type RAGResult struct {
	Example *Example `protobuf:"bytes,1,opt,name=example,proto3" json:"example,omitempty"`
	Score   float64  `protobuf:"fixed64,2,opt,name=score,proto3" json:"score,omitempty"`
	// contains filtered or unexported fields
}

func (*RAGResult) Descriptor deprecated

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

Deprecated: Use RAGResult.ProtoReflect.Descriptor instead.

func (*RAGResult) GetExample

func (x *RAGResult) GetExample() *Example

func (*RAGResult) GetScore

func (x *RAGResult) GetScore() float64

func (*RAGResult) MarshalLogObject

func (m *RAGResult) MarshalLogObject(enc go_uber_org_zap_zapcore.ObjectEncoder) error

func (*RAGResult) ProtoMessage

func (*RAGResult) ProtoMessage()

func (*RAGResult) ProtoReflect

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

func (*RAGResult) Reset

func (x *RAGResult) Reset()

func (*RAGResult) String

func (x *RAGResult) String() string

type UnimplementedEvalServiceServer

type UnimplementedEvalServiceServer struct {
}

UnimplementedEvalServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedEvalServiceServer) List

type UnimplementedExecuteServiceServer

type UnimplementedExecuteServiceServer struct {
}

UnimplementedExecuteServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedExecuteServiceServer) Execute

type UnimplementedGenerateServiceServer

type UnimplementedGenerateServiceServer struct {
}

UnimplementedGenerateServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedGenerateServiceServer) Generate

type UnsafeEvalServiceServer

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

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

type UnsafeExecuteServiceServer

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

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

type UnsafeGenerateServiceServer

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

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

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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