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

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(schedule:, data: nil, initial_message: nil, overlap_policy: nil, user_data: 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:

  • 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

  • initial_message (String) (defaults to: nil)

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

  • 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.

  • user_data (Object) (defaults to: nil)

    Optional data rendered into the variation’s user_message_template when each

  • 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 53

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)


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

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

#initial_messageString?

Optional initial message passed to CreateObjective on each fire. Becomes the first user message in the objective’s chat history. When unset, the fired objective defers to the selected variation’s user_message_template.

Returns:

  • (String, nil)


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

optional :initial_message, String, api_name: :initialMessage

#overlap_policySymbol, ...

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



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

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.



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

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

#user_dataObject?

Optional data rendered into the variation’s user_message_template when each fired objective is created. Separate from ‘data`, which renders the system prompt template.

Returns:

  • (Object, nil)


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

optional :user_data, Cadenya::Internal::Type::Unknown, api_name: :userData

#variation_idString?

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

Returns:

  • (String, nil)


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

optional :variation_id, String, api_name: :variationId