Class DocumentEmbeddingRequest

java.lang.Object
org.springframework.ai.embedding.DocumentEmbeddingRequest
All Implemented Interfaces:
ModelRequest<List<org.springframework.ai.document.Document>>

public class DocumentEmbeddingRequest extends Object implements ModelRequest<List<org.springframework.ai.document.Document>>
Represents a request to embed a list of documents.
Since:
1.0.0
Author:
Christian Tzolov, Thomas Vitale
  • Constructor Details

    • DocumentEmbeddingRequest

      public DocumentEmbeddingRequest(org.springframework.ai.document.Document... inputs)
    • DocumentEmbeddingRequest

      public DocumentEmbeddingRequest(List<org.springframework.ai.document.Document> inputs)
    • DocumentEmbeddingRequest

      public DocumentEmbeddingRequest(List<org.springframework.ai.document.Document> inputs, EmbeddingOptions options)
  • Method Details

    • getInstructions

      public List<org.springframework.ai.document.Document> getInstructions()
      Description copied from interface: ModelRequest
      Retrieves the instructions or input required by the AI model.
      Specified by:
      getInstructions in interface ModelRequest<List<org.springframework.ai.document.Document>>
      Returns:
      the instructions or input required by the AI model
    • getOptions

      public EmbeddingOptions getOptions()
      Description copied from interface: ModelRequest
      Retrieves the customizable options for AI model interactions.
      Specified by:
      getOptions in interface ModelRequest<List<org.springframework.ai.document.Document>>
      Returns:
      the customizable options for AI model interactions