Class: Cadenya::Models::Agents::AgentScheduleSpec

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/cadenya/models/agents/agent_schedule_spec.rb

Defined Under Namespace

Modules: OverlapPolicy, Status

Instance Attribute Summary collapse

Class Method 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(initial_message:, schedule:, data: nil, overlap_policy: nil, status: nil, variation_id: nil) ⇒ Object

Some parameter documentations has been truncated, see Cadenya::Models::Agents::AgentScheduleSpec for more details.

AgentScheduleSpec is the user-provided configuration for a schedule.

Parameters:

  • initial_message (String)

    The initial message passed to CreateObjective on each fire. Becomes the

  • schedule (Cadenya::Models::Agents::AgentScheduleSpecSchedule)

    Schedule defines WHEN the schedule fires. Temporal-style structured form:

  • data (Object) (defaults to: nil)

    Optional input data passed to the objective. If the agent has an

  • overlap_policy (Symbol, Cadenya::Models::Agents::AgentScheduleSpec::OverlapPolicy) (defaults to: nil)

    What to do when the previous run is still in flight. Defaults to SKIP.

  • status (Symbol, Cadenya::Models::Agents::AgentScheduleSpec::Status) (defaults to: nil)

    Lifecycle. Defaults to ACTIVE on create when unspecified.

  • variation_id (String) (defaults to: nil)

    Optional explicit variation. When unset, the agent’s variation_selection_mode



# File 'lib/cadenya/models/agents/agent_schedule_spec.rb', line 50

Instance Attribute Details

#dataObject?

Optional input data passed to the objective. If the agent has an input_data_schema, this must satisfy it.

Returns:

  • (Object, nil)


27
# File 'lib/cadenya/models/agents/agent_schedule_spec.rb', line 27

optional :data, Cadenya::Internal::Type::Unknown

#initial_messageString

The initial message passed to CreateObjective on each fire. Becomes the first user message in the objective’s chat history.

Returns:

  • (String)


12
# File 'lib/cadenya/models/agents/agent_schedule_spec.rb', line 12

required :initial_message, String, api_name: :initialMessage

#overlap_policySymbol, ...

What to do when the previous run is still in flight. Defaults to SKIP.



33
34
35
# File 'lib/cadenya/models/agents/agent_schedule_spec.rb', line 33

optional :overlap_policy,
enum: -> { Cadenya::Agents::AgentScheduleSpec::OverlapPolicy },
api_name: :overlapPolicy

#scheduleCadenya::Models::Agents::AgentScheduleSpecSchedule

Schedule defines WHEN the schedule fires. Temporal-style structured form: a list of calendar rules (wall-clock) and/or interval rules (duration), OR’d together. At least one rule is required.



20
# File 'lib/cadenya/models/agents/agent_schedule_spec.rb', line 20

required :schedule, -> { Cadenya::Agents::AgentScheduleSpecSchedule }

#statusSymbol, ...

Lifecycle. Defaults to ACTIVE on create when unspecified.



41
# File 'lib/cadenya/models/agents/agent_schedule_spec.rb', line 41

optional :status, enum: -> { Cadenya::Agents::AgentScheduleSpec::Status }

#variation_idString?

Optional explicit variation. When unset, the agent’s variation_selection_mode chooses per fire.

Returns:

  • (String, nil)


48
# File 'lib/cadenya/models/agents/agent_schedule_spec.rb', line 48

optional :variation_id, String, api_name: :variationId

Class Method Details

.valuesArray<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/cadenya/models/agents/agent_schedule_spec.rb', line 78