llm

package
v0.4.7 Latest Latest
Warning

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

Go to latest
Published: Aug 16, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LLM

type LLM struct {
	// contains filtered or unexported fields
}

func NewFromConfig added in v0.1.7

func NewFromConfig(cfg LLMConfig) (*LLM, error)

func NewOpenAI

func NewOpenAI(cfg openai.OpenAIConfig) (*LLM, error)

func (*LLM) Prompt

func (llm *LLM) Prompt(ctx context.Context, promptTpl string, values map[string]any) (string, error)

type LLMConfig added in v0.1.7

type LLMConfig struct {
	OpenAI openai.OpenAIConfig
}

Jump to

Keyboard shortcuts

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