Package com.sap.ai.sdk.foundationmodels.openai

# Class OpenAiBatchInput

java.lang.Object
com.sap.ai.sdk.foundationmodels.openai.OpenAiBatchInput

public class OpenAiBatchInput extends Object
Represents a batch input for OpenAI chat completion requests.

This class converts a list of OpenAiChatCompletionRequest objects into JSONL format suitable for batch processing.

Since:
  1.20.0

- ## Nested Class Summary

  Nested Classes
  Modifier and Type
  Class
  Description
  `static final record`
  `OpenAiBatchInput.SingleRequest`
  Represents a single batch request in OpenAI batch format.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `OpenAiBatchInput(OpenAiChatCompletionRequest... chatCompletionRequests)`
  Constructs an OpenAiBatchInput from a list of OpenAiChatCompletionRequest objects.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `String`
  `toString()`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- ## Constructor Details

  - ### OpenAiBatchInput

    @Beta public OpenAiBatchInput(@Nonnull OpenAiChatCompletionRequest... chatCompletionRequests)
    Constructs an OpenAiBatchInput from a list of OpenAiChatCompletionRequest objects.
    Parameters:
      `chatCompletionRequests` - the list of chat completion requests to include in the batch

- ## Method Details

  - ### toString

    @Nonnull public String toString()
    Overrides:
      `toString` in class `Object`