ProviderModelTypes

org.llm4s.types.ProviderModelTypes

Type-safe identifier types for the multi-provider configuration system.

Each identifier is an opaque type over String, giving distinct compile-time types to values that are otherwise interchangeable raw strings. This makes it a compile error to pass, for example, an ApiKey where a ModelName is expected, at zero runtime cost.

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Members list

Type members

Classlikes

object ApiKey

Companion for the ApiKey opaque type.

Companion for the ApiKey opaque type.

Attributes

Supertypes
class Object
trait Matchable
class Any
Self type
ApiKey.type
object BaseUrl

Companion for the BaseUrl opaque type.

Companion for the BaseUrl opaque type.

Attributes

Supertypes
class Object
trait Matchable
class Any
Self type
BaseUrl.type
object ModelName

Companion for the ModelName opaque type.

Companion for the ModelName opaque type.

Attributes

Supertypes
class Object
trait Matchable
class Any
Self type
ModelName.type

Enumeration of all supported LLM provider kinds.

Enumeration of all supported LLM provider kinds.

Attributes

Companion
object
Supertypes
trait Enum
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all
object ProviderKind

Companion object with lookup utilities for ProviderKind.

Companion object with lookup utilities for ProviderKind.

Attributes

Companion
enum
Supertypes
trait Sum
trait Mirror
class Object
trait Matchable
class Any
Self type
object ProviderName

Companion for the ProviderName opaque type.

Companion for the ProviderName opaque type.

Attributes

Supertypes
class Object
trait Matchable
class Any
Self type

Types

opaque type ApiKey

A secret key used to authenticate with a provider.

A secret key used to authenticate with a provider.

Attributes

opaque type BaseUrl

The base URL of a provider's API endpoint, e.g. "https://api.openai.com/v1".

The base URL of a provider's API endpoint, e.g. "https://api.openai.com/v1".

Attributes

opaque type ModelName

A model identifier, e.g. "gpt-4o" or "claude-sonnet-4-5".

A model identifier, e.g. "gpt-4o" or "claude-sonnet-4-5".

Attributes

opaque type ProviderName

A provider identifier, e.g. "openai" or "anthropic".

A provider identifier, e.g. "openai" or "anthropic".

Attributes

Extensions

Extensions

extension (kind: ProviderKind)
def name: String

Returns the canonical lowercase name string for this ProviderKind.

Returns the canonical lowercase name string for this ProviderKind.

Attributes

Returns

The provider name string (e.g. "openai", "anthropic").

extension (value: ModelName)
def asString: String

Returns the underlying model name string.

Returns the underlying model name string.

Attributes

extension (value: BaseUrl)
def asUrl: String

Returns the underlying base URL string.

Returns the underlying base URL string.

Attributes

extension (value: ApiKey)
def asKey: String

Returns the underlying key string.

Returns the underlying key string.

Attributes

extension (value: ProviderName)
def asName: String

Returns the underlying provider name string.

Returns the underlying provider name string.

Attributes