Class: Anthropic::Models::Beta::Messages::BetaMessageBatch

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/anthropic/models/beta/messages/beta_message_batch.rb

Overview

Defined Under Namespace

Modules: ProcessingStatus

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, inspect, #inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize(id: , archived_at: , cancel_initiated_at: , created_at: , ended_at: , expires_at: , processing_status: , request_counts: , results_url: , type: :message_batch) ⇒ void

Some parameter documentations has been truncated, see Anthropic::Models::Beta::Messages::BetaMessageBatch for more details.

Parameters:

  • id (String) (defaults to: )

    Unique object identifier.

  • archived_at (Time, nil) (defaults to: )

    RFC 3339 datetime string representing the time at which the Message Batch was ar

  • cancel_initiated_at (Time, nil) (defaults to: )

    RFC 3339 datetime string representing the time at which cancellation was initiat

  • created_at (Time) (defaults to: )

    RFC 3339 datetime string representing the time at which the Message Batch was cr

  • ended_at (Time, nil) (defaults to: )

    RFC 3339 datetime string representing the time at which processing for the Messa

  • expires_at (Time) (defaults to: )

    RFC 3339 datetime string representing the time at which the Message Batch will e

  • processing_status (Symbol, Anthropic::Models::Beta::Messages::BetaMessageBatch::ProcessingStatus) (defaults to: )

    Processing status of the Message Batch.

  • request_counts (Anthropic::Models::Beta::Messages::BetaMessageBatchRequestCounts) (defaults to: )

    Tallies requests within the Message Batch, categorized by their status.

  • results_url (String, nil) (defaults to: )

    URL to a .jsonl file containing the results of the Message Batch requests. Spe

  • type (Symbol, :message_batch) (defaults to: :message_batch)

    Object type.



# File 'lib/anthropic/models/beta/messages/beta_message_batch.rb', line 89

Instance Attribute Details

#archived_atTime?

RFC 3339 datetime string representing the time at which the Message Batch was archived and its results became unavailable.

Returns:

  • (Time, nil)


22
# File 'lib/anthropic/models/beta/messages/beta_message_batch.rb', line 22

required :archived_at, Time, nil?: true

#cancel_initiated_atTime?

RFC 3339 datetime string representing the time at which cancellation was initiated for the Message Batch. Specified only if cancellation was initiated.

Returns:

  • (Time, nil)


29
# File 'lib/anthropic/models/beta/messages/beta_message_batch.rb', line 29

required :cancel_initiated_at, Time, nil?: true

#created_atTime

RFC 3339 datetime string representing the time at which the Message Batch was created.

Returns:

  • (Time)


36
# File 'lib/anthropic/models/beta/messages/beta_message_batch.rb', line 36

required :created_at, Time

#ended_atTime?

RFC 3339 datetime string representing the time at which processing for the Message Batch ended. Specified only once processing ends.

Processing ends when every request in a Message Batch has either succeeded, errored, canceled, or expired.

Returns:

  • (Time, nil)


46
# File 'lib/anthropic/models/beta/messages/beta_message_batch.rb', line 46

required :ended_at, Time, nil?: true

#expires_atTime

RFC 3339 datetime string representing the time at which the Message Batch will expire and end processing, which is 24 hours after creation.

Returns:

  • (Time)


53
# File 'lib/anthropic/models/beta/messages/beta_message_batch.rb', line 53

required :expires_at, Time

#idString

Unique object identifier.

The format and length of IDs may change over time.

Returns:

  • (String)


15
# File 'lib/anthropic/models/beta/messages/beta_message_batch.rb', line 15

required :id, String

#processing_statusSymbol, Anthropic::Models::Beta::Messages::BetaMessageBatch::ProcessingStatus

Processing status of the Message Batch.



59
# File 'lib/anthropic/models/beta/messages/beta_message_batch.rb', line 59

required :processing_status, enum: -> { Anthropic::Beta::Messages::BetaMessageBatch::ProcessingStatus }

#request_countsAnthropic::Models::Beta::Messages::BetaMessageBatchRequestCounts

Tallies requests within the Message Batch, categorized by their status.

Requests start as processing and move to one of the other statuses only once processing of the entire batch ends. The sum of all values always matches the total number of requests in the batch.



69
# File 'lib/anthropic/models/beta/messages/beta_message_batch.rb', line 69

required :request_counts, -> { Anthropic::Beta::Messages::BetaMessageBatchRequestCounts }

#results_urlString?

URL to a .jsonl file containing the results of the Message Batch requests. Specified only once processing ends.

Results in the file are not guaranteed to be in the same order as requests. Use the custom_id field to match results to requests.

Returns:

  • (String, nil)


79
# File 'lib/anthropic/models/beta/messages/beta_message_batch.rb', line 79

required :results_url, String, nil?: true

#typeSymbol, :message_batch

Object type.

For Message Batches, this is always "message_batch".

Returns:

  • (Symbol, :message_batch)


87
# File 'lib/anthropic/models/beta/messages/beta_message_batch.rb', line 87

required :type, const: :message_batch