prompter

package
v0.1.879 Latest Latest
Warning

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

Go to latest
Published: Jan 14, 2026 License: Apache-2.0 Imports: 7 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	contract.PrompterOperator
}

func NewClient

func NewClient(d Dependencies, opts ClientOptions) (Client, error)

type ClientOption added in v0.1.726

type ClientOption = contract.Opt[ClientOptions]

func WithTimeout added in v0.1.726

func WithTimeout(x time.Duration) ClientOption

type ClientOptions added in v0.1.726

type ClientOptions struct {
	Timeout time.Duration
}

func ApplyClientOptions added in v0.1.726

func ApplyClientOptions(opts *ClientOptions, modifiers ...ClientOption) ClientOptions

type DefaultTool

type DefaultTool struct {
	T *contract.Tool[Client]
}

func NewTool

func NewTool(c Client, opts contract.ToolOptions[Client]) *DefaultTool

func (*DefaultTool) Prompt

func (d *DefaultTool) Prompt(ctx context.Context, opts contract.PromptOptions) (string, error)

Prompt sends a prompt to the underlying LLM and retrieves the response.

type Dependencies

type Dependencies struct {
	C contract.PrompterOperator
}

type Tool

type Tool interface {
	Client
}

Jump to

Keyboard shortcuts

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