elizav1grpc

package
v1.6.2-20230726230109-... Latest Latest
Warning

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

Go to latest
Published: unknown License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ElizaService_Say_FullMethodName       = "/buf.connect.demo.eliza.v1.ElizaService/Say"
	ElizaService_Converse_FullMethodName  = "/buf.connect.demo.eliza.v1.ElizaService/Converse"
	ElizaService_Introduce_FullMethodName = "/buf.connect.demo.eliza.v1.ElizaService/Introduce"
)

Variables

View Source
var ElizaService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "buf.connect.demo.eliza.v1.ElizaService",
	HandlerType: (*ElizaServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Say",
			Handler:    _ElizaService_Say_Handler,
		},
	},
	Streams: []grpc.StreamDesc{
		{
			StreamName:    "Converse",
			Handler:       _ElizaService_Converse_Handler,
			ServerStreams: true,
			ClientStreams: true,
		},
		{
			StreamName:    "Introduce",
			Handler:       _ElizaService_Introduce_Handler,
			ServerStreams: true,
		},
	},
	Metadata: "buf/connect/demo/eliza/v1/eliza.proto",
}

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

Functions

func RegisterElizaServiceServer

func RegisterElizaServiceServer(s grpc.ServiceRegistrar, srv ElizaServiceServer)

Types

type ElizaServiceClient

type ElizaServiceClient interface {
	// Say is a unary request demo. This method should allow for a one sentence
	// response given a one sentence request.
	Say(ctx context.Context, in *v1.SayRequest, opts ...grpc.CallOption) (*v1.SayResponse, error)
	// Converse is a bi-directional streaming request demo. This method should allow for
	// many requests and many responses.
	Converse(ctx context.Context, opts ...grpc.CallOption) (grpc.BidiStreamingClient[v1.ConverseRequest, v1.ConverseResponse], error)
	// Introduce is a server-streaming request demo.  This method allows for a single request that will return a series
	// of responses
	Introduce(ctx context.Context, in *v1.IntroduceRequest, opts ...grpc.CallOption) (grpc.ServerStreamingClient[v1.IntroduceResponse], error)
}

ElizaServiceClient is the client API for ElizaService 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.

ElizaService provides a way to talk to the ELIZA, which is a port of the DOCTOR script for Joseph Weizenbaum's original ELIZA program. Created in the mid-1960s at the MIT Artificial Intelligence Laboratory, ELIZA demonstrates the superficiality of human-computer communication. DOCTOR simulates a psychotherapist, and is commonly found as an Easter egg in emacs distributions.

func NewElizaServiceClient

func NewElizaServiceClient(cc grpc.ClientConnInterface) ElizaServiceClient

type ElizaServiceServer

type ElizaServiceServer interface {
	// Say is a unary request demo. This method should allow for a one sentence
	// response given a one sentence request.
	Say(context.Context, *v1.SayRequest) (*v1.SayResponse, error)
	// Converse is a bi-directional streaming request demo. This method should allow for
	// many requests and many responses.
	Converse(grpc.BidiStreamingServer[v1.ConverseRequest, v1.ConverseResponse]) error
	// Introduce is a server-streaming request demo.  This method allows for a single request that will return a series
	// of responses
	Introduce(*v1.IntroduceRequest, grpc.ServerStreamingServer[v1.IntroduceResponse]) error
}

ElizaServiceServer is the server API for ElizaService service. All implementations should embed UnimplementedElizaServiceServer for forward compatibility.

ElizaService provides a way to talk to the ELIZA, which is a port of the DOCTOR script for Joseph Weizenbaum's original ELIZA program. Created in the mid-1960s at the MIT Artificial Intelligence Laboratory, ELIZA demonstrates the superficiality of human-computer communication. DOCTOR simulates a psychotherapist, and is commonly found as an Easter egg in emacs distributions.

type ElizaService_ConverseClient

type ElizaService_ConverseClient = grpc.BidiStreamingClient[v1.ConverseRequest, v1.ConverseResponse]

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

type ElizaService_ConverseServer

type ElizaService_ConverseServer = grpc.BidiStreamingServer[v1.ConverseRequest, v1.ConverseResponse]

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

type ElizaService_IntroduceClient

type ElizaService_IntroduceClient = grpc.ServerStreamingClient[v1.IntroduceResponse]

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

type ElizaService_IntroduceServer

type ElizaService_IntroduceServer = grpc.ServerStreamingServer[v1.IntroduceResponse]

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

type UnimplementedElizaServiceServer

type UnimplementedElizaServiceServer struct{}

UnimplementedElizaServiceServer should 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 (UnimplementedElizaServiceServer) Converse

func (UnimplementedElizaServiceServer) Introduce

func (UnimplementedElizaServiceServer) Say

type UnsafeElizaServiceServer

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

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

Source Files

  • eliza_grpc.pb.go

Jump to

Keyboard shortcuts

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