Documentation
¶
Index ¶
- type OpenAI
- func (o *OpenAI) DefineEmbedder(g *genkit.Genkit, name string) (ai.Embedder, error)
- func (o *OpenAI) DefineModel(g *genkit.Genkit, name string, info ai.ModelInfo) (ai.Model, error)
- func (o *OpenAI) Embedder(g *genkit.Genkit, name string) ai.Embedder
- func (o *OpenAI) Init(ctx context.Context, g *genkit.Genkit) error
- func (o *OpenAI) ListActions(ctx context.Context) []core.ActionDesc
- func (o *OpenAI) Model(g *genkit.Genkit, name string) ai.Model
- func (o *OpenAI) Name() string
- func (o *OpenAI) ResolveAction(g *genkit.Genkit, atype core.ActionType, name string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type OpenAI ¶
type OpenAI struct { // APIKey is the API key for the OpenAI API. If empty, the values of the environment variable "OPENAI_API_KEY" will be consulted. // Request a key at https://platform.openai.com/api-keys APIKey string // Optional: Opts are additional options for the OpenAI client. // Can include other options like WithOrganization, WithBaseURL, etc. Opts []option.RequestOption // contains filtered or unexported fields }
func (*OpenAI) DefineEmbedder ¶
func (*OpenAI) DefineModel ¶
func (*OpenAI) ListActions ¶ added in v0.6.1
func (o *OpenAI) ListActions(ctx context.Context) []core.ActionDesc
func (*OpenAI) ResolveAction ¶ added in v0.6.1
Click to show internal directories.
Click to hide internal directories.