Skip to main content

Module batch

Module batch 

Source
Expand description

Batch processing: start_batch, get_batch_status, get_batch_results, cancel_batch and list_batches.

Design: docs/01-architecture/11-other-modalities.md §8.

Structs§

BatchCancelResult
Result of cancelling a batch.
BatchError
Error reported for a batch or a batch item.
BatchId
Identifier of a provider batch job.
BatchListItem
One entry of a batch listing.
BatchListResult
Result of listing batches.
BatchRequestCounts
Request counts of a batch.
BatchStartOptions
Options for starting a batch.
BatchStartResult
Result of starting a batch.
BatchStatus
Normalized status of a batch.
BatchWarning
A warning attached to a batch start, optionally scoped to one request.
CancelBatch
Builder returned by cancel_batch; .await runs the call.
GetBatchResults
Builder returned by get_batch_results; .await opens the stream.
GetBatchStatus
Builder returned by get_batch_status; .await runs the call.
ImageBatchRequest
An image generation request of a batch.
ImageBatchResult
Successful image item of a batch.
ListBatches
Builder returned by list_batches; .await runs the call.
StartBatch
Builder returned by start_batch; .await submits the batch.
TextBatchRequest
A text generation request of a batch (the settings part of generate_text, without callbacks or cancellation).
TextBatchResult
Successful text item of a batch: the shape of one generate_text step.

Enums§

BatchItem
Outcome of one request, tagged by status.
BatchRequest
A request of a batch.
BatchResultItem
One item of get_batch_results.
BatchState
Normalized batch state.
ModelBatchRequest
One request of a batch, tagged by type.

Functions§

cancel_batch
Cancels a batch. Fails with an unsupported functionality error when the provider does not implement cancellation.
get_batch_results
Streams the results of a finished batch.
get_batch_status
Fetches the normalized status of a batch.
list_batches
Lists batches. Fails with an unsupported functionality error when the provider does not implement listing.
start_batch
Starts a batch.

Type Aliases§

BatchResults
The stream returned by get_batch_results.