Class OpenAiEmbeddingModel

java.lang.Object
dev.langchain4j.model.embedding.DimensionAwareEmbeddingModel
dev.langchain4j.model.openai.OpenAiEmbeddingModel
All Implemented Interfaces:
dev.langchain4j.model.embedding.EmbeddingModel

public class OpenAiEmbeddingModel extends dev.langchain4j.model.embedding.DimensionAwareEmbeddingModel
Represents an OpenAI embedding model, such as text-embedding-ada-002.
  • Constructor Details

  • Method Details

    • knownDimension

      protected Integer knownDimension()
      Overrides:
      knownDimension in class dev.langchain4j.model.embedding.DimensionAwareEmbeddingModel
    • modelName

      public String modelName()
    • embedAll

      public dev.langchain4j.model.output.Response<List<dev.langchain4j.data.embedding.Embedding>> embedAll(List<dev.langchain4j.data.segment.TextSegment> textSegments)
    • builder