providers

package
v0.1.4 Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2026 License: GPL-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Provider

type Provider interface {
	// Name returns the canonical lowercase name of this provider (e.g. "openai").
	Name() string
	// Query sends a prompt to the AI and returns the text response.
	Query(ctx context.Context, systemPrompt, userPrompt string) (string, error)
}

Provider is the common interface for all AI backends.

func New

func New(name string, cfg config.Config) (Provider, error)

New instantiates the named provider using the given config.

func NewActive

func NewActive(cfg config.Config) (Provider, error)

NewActive instantiates the provider set as active in cfg.

Jump to

Keyboard shortcuts

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