Class TransformersEmbeddingModelAutoConfiguration
java.lang.Object
org.springframework.ai.autoconfigure.transformers.TransformersEmbeddingModelAutoConfiguration
@AutoConfiguration
@EnableConfigurationProperties(TransformersEmbeddingModelProperties.class)
@ConditionalOnClass({ai.onnxruntime.OrtSession.class,ai.djl.huggingface.tokenizers.HuggingFaceTokenizer.class,TransformersEmbeddingModel.class})
public class TransformersEmbeddingModelAutoConfiguration
extends Object
- Author:
- Christian Tzolov
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionembeddingModel
(TransformersEmbeddingModelProperties properties, org.springframework.beans.factory.ObjectProvider<io.micrometer.observation.ObservationRegistry> observationRegistry, org.springframework.beans.factory.ObjectProvider<EmbeddingModelObservationConvention> observationConvention)
-
Constructor Details
-
TransformersEmbeddingModelAutoConfiguration
public TransformersEmbeddingModelAutoConfiguration()
-
-
Method Details
-
embeddingModel
@Bean @ConditionalOnMissingBean @ConditionalOnProperty(prefix="spring.ai.embedding.transformer", name="enabled", havingValue="true", matchIfMissing=true) public TransformersEmbeddingModel embeddingModel(TransformersEmbeddingModelProperties properties, org.springframework.beans.factory.ObjectProvider<io.micrometer.observation.ObservationRegistry> observationRegistry, org.springframework.beans.factory.ObjectProvider<EmbeddingModelObservationConvention> observationConvention)
-