WatsonXConfig

org.llm4s.llmconnect.config.WatsonXConfig
See theWatsonXConfig companion class
object WatsonXConfig

Attributes

Companion
class
Graph
Supertypes
trait Product
trait Mirror
class Object
trait Matchable
class Any
Self type

Members list

Type members

Inherited and Abstract types

type MirroredElemLabels <: Tuple

The names of the product elements

The names of the product elements

Attributes

Inherited from:
Mirror
type MirroredLabel <: String

The name of the type

The name of the type

Attributes

Inherited from:
Mirror

Value members

Concrete methods

def fromValues(modelName: String, apiKey: String, projectId: Option[String], spaceId: Option[String], baseUrl: String, apiVersion: String, iamUrl: String)(using resolver: ContextWindowResolver): Result[WatsonXConfig]

Constructs a WatsonXConfig, resolving contextWindow and reserveCompletion from the model name. The apiKey is trimmed. A blank apiKey, baseUrl, apiVersion or iamUrl, a baseUrl or iamUrl that is not https (http is allowed for localhost, 127.0.0.1 and ::1), neither a projectId nor a spaceId, or both, is a ConfigurationError.

Constructs a WatsonXConfig, resolving contextWindow and reserveCompletion from the model name. The apiKey is trimmed. A blank apiKey, baseUrl, apiVersion or iamUrl, a baseUrl or iamUrl that is not https (http is allowed for localhost, 127.0.0.1 and ::1), neither a projectId nor a spaceId, or both, is a ConfigurationError.

Attributes

Concrete fields

val DEFAULT_API_VERSION: String

The version date sent when a section sets no apiVersion: the one IBM's Python SDK, ibm-watsonx-ai 1.8.0, sends (its utils/API_VERSION_PARAM file). watsonx.ai serves the API as of that date, so a date from before the chat API and tool calling existed asks for an older API than this client speaks. Override it with the section's apiVersion.

The version date sent when a section sets no apiVersion: the one IBM's Python SDK, ibm-watsonx-ai 1.8.0, sends (its utils/API_VERSION_PARAM file). watsonx.ai serves the API as of that date, so a date from before the chat API and tool calling existed asks for an older API than this client speaks. Override it with the section's apiVersion.

Attributes

val DEFAULT_BASE_URL: String
val DEFAULT_IAM_URL: String