public interface LlmClientConfigurationAdapter
Provider-owned mapping from a provider's
agentforge4j.llm.<providerId>.* configuration subtree to a neutral
LlmClientConfiguration. It lives in the provider module — alongside the provider's LlmClientFactory —
so the provider, which owns its option-key vocabulary, also owns its property mapping. Discovered via
ServiceLoader, mirroring LlmClientFactory.
Implementations must remain framework-neutral.
-
Method Summary
Modifier and TypeMethodDescriptionMaps this provider's configuration subtree to the neutral configuration the provider'sLlmClientFactoryconsumes.default booleanWhether this provider is configured by the given subtree.
-
Method Details
-
providerId
String providerId()- Returns:
- the provider id this adapter configures; must match the namespace segment
(
agentforge4j.llm.<providerId>) and the matchingLlmClientFactory.getProviderName()
-
isConfigured
Whether this provider is configured by the given subtree. The default is "any property present"; override where the provider's activation condition is stricter (for example an API key is required) or different (for example anenabledflag, or credentials that are not an API key).- Parameters:
raw- this provider's configuration subtree- Returns:
truewhen the provider should be activated
-
adapt
Maps this provider's configuration subtree to the neutral configuration the provider'sLlmClientFactoryconsumes. Provider-specific validation stays in the factory / its neutral-configuration mapping; this method only translates property keys to neutral fields and the provider's dotted option vocabulary.- Parameters:
raw- this provider's configuration subtree (only called whenisConfigured(RawProviderConfiguration))- Returns:
- the neutral client configuration
-