Package com.tnsai.integration.scop
Class LLMConfiguration
java.lang.Object
com.tnsai.integration.scop.LLMConfiguration
Holds resolved LLM configuration (provider, model, temperature, endpoint, API key env var).
Extracted from SCOPBridge to reduce class size and improve testability.
Environment lookups go through EnvLoader.get(String) — the
canonical resolver used everywhere else in the framework — instead of
raw System.getenv(). EnvLoader checks System properties before
environment variables, so test overrides via -DKEY=value and
.env file loading work uniformly with the rest of the codebase.
-
Constructor Summary
ConstructorsConstructorDescriptionLLMConfiguration(String provider, String model, float temperature, int maxTokens, String endpoint, String apiKeyEnv) -
Method Summary
Modifier and TypeMethodDescriptionGets the API key environment variable name for this provider.Gets the base URL environment variable name for this provider.intgetModel()floatbooleanbooleanhasModel()booleanChecks if this provider uses OpenAI-compatible API format.booleanChecks if this provider requires an API key.Resolves the API key from environment variables.Resolves the full API endpoint URL.toString()
-
Constructor Details
-
LLMConfiguration
-
-
Method Details
-
getProvider
-
getModel
-
getTemperature
public float getTemperature() -
getMaxTokens
public int getMaxTokens() -
getEndpoint
-
getApiKeyEnv
-
hasModel
public boolean hasModel() -
hasEndpoint
public boolean hasEndpoint() -
resolveApiUrl
Resolves the full API endpoint URL. Priority: 1. Custom endpoint from annotation 2. Base URL from environment variable + path 3. Default endpoint for provider -
resolveApiKey
Resolves the API key from environment variables. Priority: 1. Custom apiKeyEnv from annotation 2. Default env var for provider -
isOpenAICompatible
public boolean isOpenAICompatible()Checks if this provider uses OpenAI-compatible API format. -
requiresApiKey
public boolean requiresApiKey()Checks if this provider requires an API key. -
getBaseUrlEnvVar
Gets the base URL environment variable name for this provider. -
getApiKeyEnvVar
Gets the API key environment variable name for this provider. -
toString
-