models

package
v0.11.2 Latest Latest
Warning

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

Go to latest
Published: Jun 10, 2025 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateProvider

func CreateProvider(ctx context.Context, config *ProviderConfig) (model.ToolCallingChatModel, error)

CreateProvider creates an eino ToolCallingChatModel based on the provider configuration

Types

type GeminiChatModel added in v0.11.2

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

GeminiChatModel implements the eino ToolCallingChatModel interface for Google Gemini

func NewGeminiChatModel added in v0.11.2

func NewGeminiChatModel(ctx context.Context, apiKey, modelName string) (*GeminiChatModel, error)

func (*GeminiChatModel) BindForcedTools added in v0.11.2

func (g *GeminiChatModel) BindForcedTools(tools []*schema.ToolInfo) error

func (*GeminiChatModel) BindTools added in v0.11.2

func (g *GeminiChatModel) BindTools(tools []*schema.ToolInfo) error

func (*GeminiChatModel) Generate added in v0.11.2

func (g *GeminiChatModel) Generate(ctx context.Context, input []*schema.Message, opts ...model.Option) (*schema.Message, error)

func (*GeminiChatModel) GetType added in v0.11.2

func (g *GeminiChatModel) GetType() string

func (*GeminiChatModel) IsCallbacksEnabled added in v0.11.2

func (g *GeminiChatModel) IsCallbacksEnabled() bool

func (*GeminiChatModel) Stream added in v0.11.2

func (g *GeminiChatModel) Stream(ctx context.Context, input []*schema.Message, opts ...model.Option) (*schema.StreamReader[*schema.Message], error)

func (*GeminiChatModel) WithTools added in v0.11.2

func (g *GeminiChatModel) WithTools(tools []*schema.ToolInfo) (model.ToolCallingChatModel, error)

type ProviderConfig

type ProviderConfig struct {
	ModelString      string
	SystemPrompt     string
	AnthropicAPIKey  string
	AnthropicBaseURL string
	OpenAIAPIKey     string
	OpenAIBaseURL    string
	GoogleAPIKey     string
}

ProviderConfig holds configuration for creating LLM providers

Jump to

Keyboard shortcuts

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