A provider-specific key in a named provider section: one the fixed fields of NamedProviderConfig do not cover.
Declaring the key is what makes it part of the section. The section validator checks required keys, fills in defaults and resolves deprecated aliases before the descriptor sees the section, and the descriptor reads the result from NamedProviderConfig.extras. A key in a section that no descriptor declares is reported as unknown and not passed on.
Values are strings, as they are in HOCON; a descriptor that needs a number or a boolean parses it in buildConfig and reports a malformed value there.
Value parameters
- default
-
value used when the section omits the key. A key with a default is never missing, so
requiredis then moot. - deprecatedAliases
-
older names for this key. A section that sets an alias instead of
namestill works, with a deprecation warning per alias used; one that setsnameand an alias, or two aliases, to different values is an error. An alias may be a former extra key, or one of the built-in fields in ProviderConfigSpec.BuiltinAliasKeys - which is how a provider moves off a repurposed field (Vertex AI'sendpointbecameproject).provider,modelandheaderscannot be aliases, and a spec naming one fails validation. - description
-
what the key means, shown when a required one is missing - e.g.
"the GCP project ID that owns your Vertex AI resources". - env
-
the conventional environment variable for this key, if it has one. Named sections read no variable by themselves, so the missing-key message shows the binding that reads it -
key = ${?VAR}- rather than telling the user to set a variable nothing would read. - name
-
the key as written in
llm4s.providers.<name>, e.g."region". Must not be one of ProviderConfigSpec.BuiltinKeys. - required
-
a section without this key (and without a default) is invalid.
Attributes
- Companion
- object
- Graph
-
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass Any