Ragex.AI.Provider.Registry
(Ragex v0.13.0)
View Source
Registry for AI providers.
Manages registration, discovery, and selection of AI providers.
Summary
Functions
Returns a specification to start this module under a supervisor.
Get current active provider from config
Get provider by name
Get provider module by name.
List all registered providers
Register a provider module
Functions
Returns a specification to start this module under a supervisor.
See Supervisor.
Get current active provider from config
Get provider by name
Get provider module by name.
Alias for get/1 with more explicit naming.
Parameters
provider_name: Provider identifier atom (e.g.,:deepseek_r1,:openai,:anthropic)
Returns
{:ok, module}- Provider module if registered{:error, :not_found}- Provider not found in registry
Examples
iex> Registry.get_provider(:deepseek_r1)
{:ok, Ragex.AI.Provider.DeepSeekR1}
iex> Registry.get_provider(:unknown)
{:error, :not_found}
List all registered providers
Register a provider module