Expand description
Batch generation (batchGenerateContent): inline or file-based input,
status, results, cancel and list.
Derived from the Vercel AI SDK (Apache-2.0, Copyright 2023 Vercel, Inc.),
translated from TypeScript to Rust and modified; see NOTICE.
Structs§
- Batch
Operation - A long-running batch operation.
- Batch
Operation Metadata - Metadata of a batch operation.
- Batch
Result Line - One line of a batch results file (
{key, response?, error?}). - Batch
Stats - Request counts of a batch.
- Google
Batch - Batch service backed by
batchGenerateContent. - Prepared
Batch Request - A prepared batch request: the
generateContentbody and its warnings.
Constants§
- DISPLAY_
NAME_ PREFIX - Prefix of the generated batch display names.
- FAMILY
- Provider id family.
- INLINE_
MAX_ BYTES - Inline request bodies stay below this many bytes; larger batches are uploaded as a JSONL file.
- INPUT_
FILE_ MAX_ BYTES - Maximum size of an uploaded JSONL input file.
Functions§
- convert_
line - Converts one result line.
- map_
status - Maps an operation to the normalized status.
- rpc_
error - Maps an RPC status to a batch error.