Skip to main content

Module task

Module task 

Source
Expand description

AI Task snapshot.

Task stores a stable unit of work derived from a plan or created by Libra as a delegated work item.

§How to use this object

  • Create a Task when a PlanStep needs its own durable execution unit.
  • Fill parent, intent, origin_step_id, and dependencies before persistence if those provenance links are known.
  • Keep the stored object stable; define a new task snapshot only when the work definition itself changes.

§How it works with other objects

  • Task.origin_step_id links the task back to the stable PlanStep.step_id.
  • Run.task links execution attempts to the task.
  • TaskEvent records lifecycle changes such as running / blocked / done / failed.

§How Libra should call it

Libra should derive ready queues, dependency resolution, and current task status from Task plus TaskEvent and Run history. Those mutable scheduling views do not belong on the Task object itself.

Structs§

Task
Stable work definition used by the scheduler and execution layer.

Enums§

GoalType