Documentation
¶
Overview ¶
Package auto provides zero-config service construction on top of llm.Service.
Index ¶
- Constants
- func New(ctx context.Context, opts ...Option) (*llm.Service, error)
- type Option
- func WithAnthropic() Option
- func WithBedrock() Option
- func WithClaude(store claude.TokenStore) Option
- func WithClaudeAccount(name string, store claude.TokenStore) Option
- func WithClaudeLocal() Option
- func WithCodexLocal() Option
- func WithDockerModelRunner(opts ...llm.Option) Option
- func WithGlobalAlias(alias string, targets ...string) Option
- func WithGlobalAliases(aliases map[string][]string) Option
- func WithHTTPClient(client *http.Client) Option
- func WithLLMOptions(opts ...llm.Option) Option
- func WithName(name string) Option
- func WithOllama() Option
- func WithOpenAI() Option
- func WithOpenRouter() Option
- func WithoutAutoDetect() Option
- func WithoutBedrock() Option
- func WithoutBuiltinAliases() Option
- func WithoutCodex() Option
- func WithoutDockerMR() Option
- func WithoutOllama() Option
- func WithoutProvider(providerType string) Option
Constants ¶
View Source
const ( ProviderClaude = "claude" ProviderBedrock = "bedrock" ProviderCodex = "codex" ProviderOpenAI = "openai" ProviderOpenRouter = "openrouter" ProviderAnthropic = "anthropic" ProviderMiniMax = "minimax" ProviderOllama = "ollama" ProviderDockerMR = "dockermr" )
Provider type names.
View Source
const ( EnvOpenAIKey = "OPENAI_API_KEY" EnvOpenAIKeyAlt = "OPENAI_KEY" EnvOpenRouterKey = "OPENROUTER_API_KEY" EnvAnthropicKey = "ANTHROPIC_API_KEY" EnvMiniMaxKey = "MINIMAX_API_KEY" )
Environment variable names.
View Source
const ( AliasFast = "fast" AliasDefault = "default" AliasPowerful = "powerful" )
Built-in top-level aliases provided by provider/auto.
View Source
const (
AliasCodex = "codex"
)
Common provider/user alias names.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Option ¶
type Option func(*config)
func WithAnthropic ¶
func WithAnthropic() Option
func WithBedrock ¶
func WithBedrock() Option
func WithClaude ¶
func WithClaude(store claude.TokenStore) Option
func WithClaudeAccount ¶
func WithClaudeAccount(name string, store claude.TokenStore) Option
func WithClaudeLocal ¶
func WithClaudeLocal() Option
func WithCodexLocal ¶
func WithCodexLocal() Option
func WithDockerModelRunner ¶
func WithGlobalAlias ¶
func WithGlobalAliases ¶
func WithHTTPClient ¶
func WithLLMOptions ¶
func WithOllama ¶
func WithOllama() Option
func WithOpenAI ¶
func WithOpenAI() Option
func WithOpenRouter ¶
func WithOpenRouter() Option
func WithoutAutoDetect ¶
func WithoutAutoDetect() Option
func WithoutBedrock ¶
func WithoutBedrock() Option
func WithoutBuiltinAliases ¶
func WithoutBuiltinAliases() Option
func WithoutCodex ¶
func WithoutCodex() Option
func WithoutDockerMR ¶
func WithoutDockerMR() Option
func WithoutOllama ¶
func WithoutOllama() Option
func WithoutProvider ¶
Click to show internal directories.
Click to hide internal directories.