Interface LangChain4jOpenAiConfig.OpenAiConfig

Enclosing interface:
LangChain4jOpenAiConfig

public static interface LangChain4jOpenAiConfig.OpenAiConfig
  • Method Details

    • baseUrl

      @WithDefault("https://api.openai.com/v1/") String baseUrl()
      Base URL of OpenAI API
    • tlsConfigurationName

      Optional<String> tlsConfigurationName()
      If set, the named TLS configuration with the configured name will be applied to the REST Client
    • apiKey

      @WithDefault("dummy") String apiKey()
      OpenAI API key
    • organizationId

      Optional<String> organizationId()
      OpenAI Organization ID (https://platform.openai.com/docs/api-reference/organization-optional)
    • timeout

      @ConfigDocDefault("10s") @WithDefault("${quarkus.langchain4j.timeout}") Optional<Duration> timeout()
      Timeout for OpenAI calls
    • maxRetries

      @WithDefault("1") Integer maxRetries()
      Deprecated.
      Using the built-in fault tolerance mechanisms is not recommended. If possible, use MicroProfile Fault Tolerance instead.
      The maximum number of times to retry. 1 means exactly one attempt, with retrying disabled.
    • logRequests

      @ConfigDocDefault("false") @WithDefault("${quarkus.langchain4j.log-requests}") Optional<Boolean> logRequests()
      Whether the OpenAI client should log requests
    • logResponses

      @ConfigDocDefault("false") @WithDefault("${quarkus.langchain4j.log-responses}") Optional<Boolean> logResponses()
      Whether the OpenAI client should log responses
    • enableIntegration

      @WithDefault("true") Boolean enableIntegration()
      Whether to enable the integration. Defaults to true, which means requests are made to the OpenAI provider. Set to false to disable all requests.
    • proxyType

      @WithDefault("HTTP") String proxyType()
      The Proxy type
    • proxyHost

      Optional<String> proxyHost()
      The Proxy host
    • proxyPort

      @WithDefault("3128") Integer proxyPort()
      The Proxy port
    • chatModel

      ChatModelConfig chatModel()
      Chat model related settings
    • embeddingModel

      EmbeddingModelConfig embeddingModel()
      Embedding model related settings
    • moderationModel

      ModerationModelConfig moderationModel()
      Moderation model related settings
    • imageModel

      ImageModelConfig imageModel()
      Image model related settings