java.lang.Object
com.agentforge4j.llm.fake.FakeConfiguration
- All Implemented Interfaces:
LlmClientConfiguration
Configuration for the fake provider. Unlike HTTP providers, the load-bearing field is the
FakeResponseSource
— the shared per-run store that the registration API (test runner / demo flow) also holds — so the
FakeLlmClientFactory-built client and the registration API resolve against one store.
Wire this through the embedding application or programmatic withLlmProvider(...); the
env/system-property bootstrap discovery path supplies a generic configuration and cannot carry a source, so it does
not configure the fake provider (the same way Ollama requires its own configuration subtype).
-
Constructor Summary
ConstructorsConstructorDescriptionFakeConfiguration(FakeResponseSource responseSource) Creates a configuration with the default model id and a zero connect timeout.FakeConfiguration(FakeResponseSource responseSource, String defaultModel, Duration connectTimeout) Creates a configuration with an explicit default model and connect timeout. -
Method Summary
Modifier and TypeMethodDescriptionHTTP connect timeout for outbound requests to this provider.Default model when a request does not setLlmExecutionRequest.model().Provider id for this configuration (must align with the matchingLlmClientFactory).Returns the shared scripted response source the client resolves against.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.agentforge4j.llm.LlmClientConfiguration
getApiKeyReference, getBaseUrl, getOptions, getRetryPolicy, requireBaseUrl
-
Constructor Details
-
FakeConfiguration
Creates a configuration with the default model id and a zero connect timeout.- Parameters:
responseSource- the scripted response source; must not benull
-
FakeConfiguration
public FakeConfiguration(FakeResponseSource responseSource, String defaultModel, Duration connectTimeout) Creates a configuration with an explicit default model and connect timeout.- Parameters:
responseSource- the scripted response source; must not benulldefaultModel- default model id reported to callers; must not be blankconnectTimeout- nominal connect timeout (unused by the fake transport); must not benull
-
-
Method Details
-
getProviderName
Description copied from interface:LlmClientConfigurationProvider id for this configuration (must align with the matchingLlmClientFactory).- Specified by:
getProviderNamein interfaceLlmClientConfiguration- Returns:
- non-blank provider id such as
"openai"or"ollama"
-
getDefaultModel
Description copied from interface:LlmClientConfigurationDefault model when a request does not setLlmExecutionRequest.model().- Specified by:
getDefaultModelin interfaceLlmClientConfiguration- Returns:
- non-blank default model id for this provider
-
getConnectTimeout
Description copied from interface:LlmClientConfigurationHTTP connect timeout for outbound requests to this provider.- Specified by:
getConnectTimeoutin interfaceLlmClientConfiguration- Returns:
- connect timeout duration
-
responseSource
Returns the shared scripted response source the client resolves against.- Returns:
- the response source; never
null
-