AgentWorkshop.Scheduler (AgentWorkshop v0.3.0)

Copy Markdown View Source

Periodic task scheduler for Workshop agents.

Runs agent prompts on a recurring interval. Each schedule is a GenServer that calls cast/2 on each tick.

Usage from IEx

import AgentWorkshop.Workshop

every(:monitor, "Check CI status", interval: :timer.minutes(5))
schedules()          # list active schedules
cancel(:monitor)     # stop a schedule

Behavior

  • Each tick calls cast(name, prompt) (non-blocking)
  • If the agent is busy (cast queued), the tick is skipped
  • Schedules survive agent resets but not Workshop restarts
  • PubSub event {:schedule, :tick, name} on each run

Summary

Functions

Returns a specification to start this module under a supervisor.

Functions

child_spec(init_arg)

Returns a specification to start this module under a supervisor.

See Supervisor.