Documentation
¶
Index ¶
- type Provider
- func (p *Provider) APIURL() string
- func (p *Provider) ChatWithImage(ctx context.Context, systemPrompt string, history []api.Message, ...) (string, error)
- func (p *Provider) ChatWithTools(ctx context.Context, systemPrompt string, history []api.Message, model string) (string, error)
- func (p *Provider) IsFunctionCallingEnabled() bool
- func (p *Provider) Name() string
- func (p *Provider) SetMCPTools(tools []api.OpenAIToolFunction)
- func (p *Provider) SetUsageCallback(callback api.UsageCallback)
- func (p *Provider) SupportsImages() bool
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Provider ¶
type Provider struct {
// contains filtered or unexported fields
}
Provider はGroq APIのプロバイダー実装(OpenAI互換)
func (*Provider) ChatWithImage ¶
func (p *Provider) ChatWithImage(ctx context.Context, systemPrompt string, history []api.Message, userMessage string, image *api.ImageData, model string) (string, error)
ChatWithImage は画像付きメッセージで会話を行う(非対応:テキストのみ送信)
func (*Provider) ChatWithTools ¶
func (p *Provider) ChatWithTools(ctx context.Context, systemPrompt string, history []api.Message, model string) (string, error)
ChatWithTools は Provider interface の実装(context対応)
func (*Provider) IsFunctionCallingEnabled ¶ added in v0.46.0
IsFunctionCallingEnabled は Function Calling が有効かを返す GROQ_FUNCTION_CALLING=0 で無効化可能
func (*Provider) SetMCPTools ¶ added in v0.44.0
func (p *Provider) SetMCPTools(tools []api.OpenAIToolFunction)
SetMCPTools は MCP ツール定義を設定する(Function Calling用)
func (*Provider) SetUsageCallback ¶ added in v0.46.0
func (p *Provider) SetUsageCallback(callback api.UsageCallback)
SetUsageCallback は使用量レポートのコールバックを設定する
func (*Provider) SupportsImages ¶
SupportsImages は画像入力対応を返す
Click to show internal directories.
Click to hide internal directories.