Class JlamaEmbeddingModelConfig.BuilderBase<BUILDER extends JlamaEmbeddingModelConfig.BuilderBase<BUILDER,PROTOTYPE>,PROTOTYPE extends JlamaEmbeddingModelConfig>
java.lang.Object
io.helidon.integrations.langchain4j.providers.jlama.JlamaEmbeddingModelConfig.BuilderBase<BUILDER,PROTOTYPE>
- Type Parameters:
BUILDER
- type of the builder extending this abstract builderPROTOTYPE
- type of the prototype interface that would be built byPrototype.Builder.buildPrototype()
- All Implemented Interfaces:
Prototype.Builder<BUILDER,
,PROTOTYPE> ConfigBuilderSupport.ConfiguredBuilder<BUILDER,
,PROTOTYPE> ConfigBuilderSupport.ConfiguredBuilder<BUILDER,
PROTOTYPE>
- Direct Known Subclasses:
JlamaEmbeddingModelConfig.Builder
- Enclosing interface:
JlamaEmbeddingModelConfig
public abstract static class JlamaEmbeddingModelConfig.BuilderBase<BUILDER extends JlamaEmbeddingModelConfig.BuilderBase<BUILDER,PROTOTYPE>,PROTOTYPE extends JlamaEmbeddingModelConfig>
extends Object
implements ConfigBuilderSupport.ConfiguredBuilder<BUILDER,PROTOTYPE>
Fluent API builder base for
JlamaEmbeddingModelConfig
.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected static class
Generated implementation of the prototype, can be extended by descendant prototype implementations. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGenerated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.authToken(java.lang.String)
Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.authToken(java.lang.String)
Clear existing value of this property.Clear existing value of this property.Clear existing value of this property.Clear existing value of this property.Clear existing value of this property.Clear existing value of this property.config()
If this instance was configured, this would be the config instance used.Deprecated.Update builder from configuration (node of this type).boolean
enabled()
If set tofalse
(default), JlamaEmbeddingModel will not be available even if configured.enabled
(boolean enabled) If set tofalse
(default), JlamaEmbeddingModel will not be available even if configured.from
(JlamaEmbeddingModelConfig prototype) Update this builder from an existing prototype instance.from
(JlamaEmbeddingModelConfig.BuilderBase<?, ?> builder) Update this builder from an existing prototype builder instance.Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.modelCachePath(java.nio.file.Path)
modelCachePath
(Path modelCachePath) Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.modelCachePath(java.nio.file.Path)
Configure the model name.Configure the model name.Optional
<com.github.tjake.jlama.model.functions.Generator.PoolingType> Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.poolingType(com.github.tjake.jlama.model.functions.Generator.PoolingType)
poolingType
(com.github.tjake.jlama.model.functions.Generator.PoolingType poolingType) Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.poolingType(com.github.tjake.jlama.model.functions.Generator.PoolingType)
protected void
Handles providers and decorators.Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.quantizeModelAtRuntime(java.lang.Boolean)
quantizeModelAtRuntime
(boolean quantizeModelAtRuntime) Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.quantizeModelAtRuntime(java.lang.Boolean)
Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.threadCount(java.lang.Integer)
threadCount
(int threadCount) Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.threadCount(java.lang.Integer)
toString()
protected void
Validates required properties.Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.workingDirectory(java.nio.file.Path)
workingDirectory
(Path workingDirectory) Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.workingDirectory(java.nio.file.Path)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface io.helidon.builder.api.Prototype.Builder
buildPrototype, self
-
Constructor Details
-
BuilderBase
protected BuilderBase()Protected to support extensibility.
-
-
Method Details
-
from
Update this builder from an existing prototype instance. This method disables automatic service discovery.- Parameters:
prototype
- existing prototype to update this builder from- Returns:
- updated builder instance
-
from
Update this builder from an existing prototype builder instance.- Parameters:
builder
- existing builder prototype to update this builder from- Returns:
- updated builder instance
-
config
Deprecated.Update builder from configuration (node of this type). If a value is present in configuration, it would override currently configured values.- Specified by:
config
in interfaceConfigBuilderSupport.ConfiguredBuilder<BUILDER extends JlamaEmbeddingModelConfig.BuilderBase<BUILDER,
PROTOTYPE>, PROTOTYPE extends JlamaEmbeddingModelConfig> - Parameters:
config
- configuration instance used to obtain values to update this builder- Returns:
- updated builder instance
-
config
Update builder from configuration (node of this type). If a value is present in configuration, it would override currently configured values.- Specified by:
config
in interfaceConfigBuilderSupport.ConfiguredBuilder<BUILDER extends JlamaEmbeddingModelConfig.BuilderBase<BUILDER,
PROTOTYPE>, PROTOTYPE extends JlamaEmbeddingModelConfig> - Parameters:
config
- configuration instance used to obtain values to update this builder- Returns:
- updated builder instance
-
enabled
If set tofalse
(default), JlamaEmbeddingModel will not be available even if configured.- Parameters:
enabled
- whether JlamaEmbeddingModel is enabled, defaults tofalse
- Returns:
- updated builder instance
- See Also:
-
clearModelCachePath
Clear existing value of this property.- Returns:
- updated builder instance
- See Also:
-
modelCachePath
Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.modelCachePath(java.nio.file.Path)
- Parameters:
modelCachePath
- Path property- Returns:
- updated builder instance
- See Also:
-
clearWorkingDirectory
Clear existing value of this property.- Returns:
- updated builder instance
- See Also:
-
workingDirectory
Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.workingDirectory(java.nio.file.Path)
- Parameters:
workingDirectory
- Path property- Returns:
- updated builder instance
- See Also:
-
clearAuthToken
Clear existing value of this property.- Returns:
- updated builder instance
- See Also:
-
authToken
Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.authToken(java.lang.String)
- Parameters:
authToken
- String property- Returns:
- updated builder instance
- See Also:
-
clearPoolingType
Clear existing value of this property.- Returns:
- updated builder instance
- See Also:
-
poolingType
public BUILDER poolingType(com.github.tjake.jlama.model.functions.Generator.PoolingType poolingType) Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.poolingType(com.github.tjake.jlama.model.functions.Generator.PoolingType)
- Parameters:
poolingType
- PoolingType property- Returns:
- updated builder instance
- See Also:
-
clearThreadCount
Clear existing value of this property.- Returns:
- updated builder instance
- See Also:
-
threadCount
Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.threadCount(java.lang.Integer)
- Parameters:
threadCount
- Integer property- Returns:
- updated builder instance
- See Also:
-
clearQuantizeModelAtRuntime
Clear existing value of this property.- Returns:
- updated builder instance
- See Also:
-
quantizeModelAtRuntime
Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.quantizeModelAtRuntime(java.lang.Boolean)
- Parameters:
quantizeModelAtRuntime
- Boolean property- Returns:
- updated builder instance
- See Also:
-
modelName
Configure the model name.- Parameters:
modelName
- model name- Returns:
- updated builder instance
- See Also:
-
enabled
public boolean enabled()If set tofalse
(default), JlamaEmbeddingModel will not be available even if configured.- Returns:
- the enabled
-
modelCachePath
Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.modelCachePath(java.nio.file.Path)
- Returns:
- the model cache path
-
workingDirectory
Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.workingDirectory(java.nio.file.Path)
- Returns:
- the working directory
-
authToken
Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.authToken(java.lang.String)
- Returns:
- the auth token
-
poolingType
Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.poolingType(com.github.tjake.jlama.model.functions.Generator.PoolingType)
- Returns:
- the pooling type
-
threadCount
Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.threadCount(java.lang.Integer)
- Returns:
- the thread count
-
quantizeModelAtRuntime
Generated fromJlamaEmbeddingModel.JlamaEmbeddingModelBuilder.quantizeModelAtRuntime(java.lang.Boolean)
- Returns:
- the quantize model at runtime
-
modelName
Configure the model name.- Returns:
- the model name
-
config
If this instance was configured, this would be the config instance used.- Returns:
- config node used to configure this builder, or empty if not configured
-
toString
-
preBuildPrototype
protected void preBuildPrototype()Handles providers and decorators. -
validatePrototype
protected void validatePrototype()Validates required properties.
-
config(io.helidon.config.Config)