Documentation
¶
Index ¶
Constants ¶
View Source
const ( ProviderOpenAI = providers.ProviderOpenAI ProviderOpenAICompatible = providers.ProviderOpenAICompatible ProviderGoogle = providers.ProviderGoogle ProviderVertex = providers.ProviderVertex ProviderAnthropic = providers.ProviderAnthropic ProviderBedrock = providers.ProviderBedrock ProviderAzure = providers.ProviderAzure ProviderMistral = providers.ProviderMistral ProviderGroq = providers.ProviderGroq ProviderDeepSeek = providers.ProviderDeepSeek ProviderXAI = providers.ProviderXAI ProviderCerebras = providers.ProviderCerebras ProviderOpenRouter = providers.ProviderOpenRouter ProviderCohere = providers.ProviderCohere )
Provider name constants — aliased from the providers package so callers that import factory.ProviderX continue to compile.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ProviderLocator ¶
type ProviderLocator interface {
Get(provider string) (providers.Client, error)
GetTester(provider string) (providers.ConnectionTester, error)
}
func NewProviderLocator ¶
func NewProviderLocator() ProviderLocator
NewProviderLocator builds one client per provider up front and reuses it for the lifetime of the locator. Provider clients are stateless wrappers over an HTTP connection pool, so constructing a fresh one per request (as before) threw away connection reuse and defeated per-client caches (e.g. the Bedrock SDK client pool). The map is read-only after construction, so Get is safe for concurrent use.
Click to show internal directories.
Click to hide internal directories.