Interface LlmProvider

All Superinterfaces:
PluginProvider

public interface LlmProvider extends PluginProvider
Integration provider contract for LLM/LlmModel service integrations. Plugins implement this interface to register an LlmModel integration type under Admin > Integrations. Similar to IPAMProvider, this creates its own AccountIntegrationType and related LlmIntegrationType during plugin load.
  • Method Details

    • getCategory

      default String getCategory()
      The integration category used for routing and grouping.
      Returns:
      the category string
    • getIcon

      Icon getIcon()
      Returns the integration logo for display.
      Returns:
      Icon representation of assets stored in the plugin's src/assets
    • getOptionTypes

      default List<OptionType> getOptionTypes()
      Provide custom configuration options when creating a new integration.
      Returns:
      a List of OptionType
    • getCreatable

      default Boolean getCreatable()
      Flags if the user can create this integration type.
      Returns:
      true if creatable; false otherwise
    • getDescription

      default String getDescription()
      Description for the provider-backed integration type.
      Returns:
      integration description text
    • getEnabled

      default Boolean getEnabled()
      Flags if this integration type is enabled.
      Returns:
      true if enabled
    • getChatSupported

      default Boolean getChatSupported()
      Indicates whether the provider supports chat completions.
      Returns:
      true if chat completion is supported
    • getStreamingChatSupported

      default Boolean getStreamingChatSupported()
      Indicates whether the provider supports streaming chat completions.
      Returns:
      true if streaming is supported
    • getEmbeddingSupported

      default Boolean getEmbeddingSupported()
      Indicates whether the provider supports embedding generation.
      Returns:
      true if embeddings are supported
    • validate

      default ServiceResponse validate(LlmIntegration languageModelIntegration, Map opts)
      Validation method used to validate inputs applied to the integration upon save.
      Parameters:
      languageModelIntegration - the integration being validated
      opts - custom payload options
      Returns:
      a response indicating validity
    • refresh

      void refresh(LlmIntegration languageModelIntegration)
      Called periodically to refresh and sync data from the provider.
      Parameters:
      languageModelIntegration - the integration to refresh
    • generateResponse

      ServiceResponse<LlmChatResponse> generateResponse(LlmIntegration languageModelIntegration, LlmChatRequest request, Map opts)
      Performs a non-streaming response generation request.
      Parameters:
      languageModelIntegration - integration configuration
      request - response generation request payload
      opts - optional call options
      Returns:
      response containing the generated output
    • streamResponse

      default void streamResponse(LlmIntegration languageModelIntegration, LlmChatRequest request, LlmStreamingResponseHandler handler, Map opts)
      Performs a streaming response generation request.
      Parameters:
      languageModelIntegration - integration configuration
      request - response generation request payload
      handler - streaming callback handler
      opts - optional call options