ScheduleTaskTool class

Schedules a named task to run after a specified delay.

The tool stores the scheduled task in memory and fires a callback (if provided) when the delay elapses. It does NOT create a real OS scheduler entry — use a cron library for persistent scheduling.

Inheritance

Constructors

ScheduleTaskTool({void onTaskDue(String taskName, DateTime dueAt)?, ConsciousnessLogger? logger})

Properties

description → String
One-sentence description included in the system prompt.
no setteroverride
hashCode → int
The hash code for this object.
no setterinherited
inputSchema → Map<String, String>
Schema of expected input keys and their descriptions.
no setteroverride
isIdempotent → bool
Whether this tool can safely be retried on failure.
no setterinherited
name → String
Unique snake_case name the LLM uses to invoke this tool.
no setteroverride
onTaskDue → void Function(String taskName, DateTime dueAt)?
Optional callback fired when a scheduled task becomes due.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
scheduled → Map<String, DateTime>
Returns all currently scheduled tasks.
no setter

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
run(Map<String, dynamic> input) → Future<ToolResult>
Executes the tool with the given input map.
override
toString() → String
A string representation of this object.
inherited
validate(Map<String, dynamic> input) → String?
Validates the input map against inputSchema.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited