Interface ContentRetrieverConfig

All Superinterfaces:
Prototype.Api
All Known Implementing Classes:
ContentRetrieverConfig.BuilderBase.ContentRetrieverConfigImpl

public interface ContentRetrieverConfig extends Prototype.Api
Configuration for LangChain4j ContentRetriever components.

Instances of this configuration are created from the config and define how a content retriever is selected and initialized (for example, embedding-store backed retrievers).

See Also:
  • Method Details

    • builder

      Create a new fluent API builder to customize configuration.
      Returns:
      a new builder
    • builder

      Create a new fluent API builder from an existing instance.
      Parameters:
      instance - an existing instance used as a base for the builder
      Returns:
      a builder based on an instance
    • create

      static ContentRetrieverConfig create(Config config)
      Create a new instance from configuration.
      Parameters:
      config - used to configure the new instance
      Returns:
      a new instance configured from configuration
    • create

      @Deprecated static ContentRetrieverConfig create(Config config)
      Create a new instance from configuration.
      Parameters:
      config - used to configure the new instance
      Returns:
      a new instance configured from configuration
    • enabled

      boolean enabled()
      If set to false, component will be disabled even if configured.
      Returns:
      whether the component should be enabled
    • type

      Type of content retriever to create.
      Returns:
      the content retriever type
    • embeddingStore

      String embeddingStore()
      Embedding store to use in the content retriever.

      The value identifies a named service that provides embedding store implementation used to retrieve relevant content.

      Returns:
      the embedding store service name
    • embeddingModel

      Optional<String> embeddingModel()
      Explicit embedding model to use in the content retriever.

      If empty, the default embedding model is used (as resolved by the service registry). If set, the value identifies a named service that provides embedding model bean.

      Returns:
      embedding model reference if configured
    • displayName

      Optional<String> displayName()
      Display name for this content retriever configuration.
      Returns:
      the display name if configured
    • maxResults

      Optional<Integer> maxResults()
      Maximum number of results to return from the retriever.

      If empty, the retriever implementation default is used.

      Returns:
      maximum results if configured
    • minScore

      Optional<Double> minScore()
      Minimum score threshold for retrieved results.

      If empty, the retriever implementation default is used.

      Returns:
      minimum score if configured