dialogue

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Jan 29, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FailbackDialogueGenerator

type FailbackDialogueGenerator[T any] struct {
	// contains filtered or unexported fields
}

func NewFailbackDialogueGenerator

func NewFailbackDialogueGenerator[T any](generators ...Generator[T]) *FailbackDialogueGenerator[T]

func (*FailbackDialogueGenerator[T]) GenerateDialogue

func (g *FailbackDialogueGenerator[T]) GenerateDialogue(ctx context.Context, req *types.ToolRequest[T]) (string, error)

func (*FailbackDialogueGenerator[T]) GenerateDialogueStream

func (g *FailbackDialogueGenerator[T]) GenerateDialogueStream(ctx context.Context, req *types.ToolRequest[T]) (*schema.StreamReader[string], error)

type Generator

type Generator[T any] interface {
	GenerateDialogue(ctx context.Context, req *types.ToolRequest[T]) (string, error)
	GenerateDialogueStream(ctx context.Context, req *types.ToolRequest[T]) (*schema.StreamReader[string], error)
}

type LocalDialogueGenerator

type LocalDialogueGenerator[T any] struct{}

func (*LocalDialogueGenerator[T]) GenerateDialogue

func (g *LocalDialogueGenerator[T]) GenerateDialogue(ctx context.Context, req *types.ToolRequest[T]) (string, error)

func (*LocalDialogueGenerator[T]) GenerateDialogueStream

func (g *LocalDialogueGenerator[T]) GenerateDialogueStream(ctx context.Context, req *types.ToolRequest[T]) (*schema.StreamReader[string], error)

type ToolBasedDialogueGenerator

type ToolBasedDialogueGenerator[T any] struct {
	Lang string
	// contains filtered or unexported fields
}

func NewToolBasedDialogueGenerator

func NewToolBasedDialogueGenerator[T any](chatModel model.ToolCallingChatModel) *ToolBasedDialogueGenerator[T]

func (*ToolBasedDialogueGenerator[T]) GenerateDialogue

func (g *ToolBasedDialogueGenerator[T]) GenerateDialogue(ctx context.Context, req *types.ToolRequest[T]) (string, error)

func (*ToolBasedDialogueGenerator[T]) GenerateDialogueStream

func (g *ToolBasedDialogueGenerator[T]) GenerateDialogueStream(ctx context.Context, req *types.ToolRequest[T]) (*schema.StreamReader[string], error)

Jump to

Keyboard shortcuts

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