Ask, then classify again
advisor
Ask an advisor. Classify the task again. Stay on the same task.
ganda task work <id> --routine advisor
Select a node, or run the path that the host uses.
How you write it
You write the routine in C#. Each call adds one node. Build makes the intermediate representation.
public static RoutineDefinition Build()
{
return Routine.Named(RoutineId)
.Oracle<TaskWork.Continue>("advisor", schema: "Continue.ClosedEnum", pack: Pack.None, budget: Budget.Small)
.Oracle<TaskWork.Classify>("classify", schema: "Classify.ClosedEnum", pack: Pack.None, budget: Budget.Small)
.Switch<TaskWork.Classify>(sw => sw
.When(TaskWork.Classify.Rfc)
.When(TaskWork.Classify.Debate)
.When(TaskWork.Classify.Advisor)
.When(TaskWork.Classify.Implement)
.When(TaskWork.Classify.Trivial))
.Compute("continue", Continue)
.Build();
}The file is source/timewarp-taratibu/routines/advisor/advisor.cs. Taratibu master 53de8c4.
Why this shape
Advice that does not go back into the closed list becomes a side talk. This run asks for advice. Then it requires a new decision: Rfc, Debate, Advisor, Implement, or Trivial. Then the run stops. This run does not do the task.
What you get
- The second classification is on this routine. It is not a loop inside planning. It is not on task-work.
- Each result goes to continue. A later run can use that result.
- There is no gate.
Rules
- You must give a task id.
- If the advisor oracle is Blocked, the host stops. The classify node does not stop the host.
The drawing follows the D2 file in the repo. Node ids do not change. Ganda connects the commands. Ganda does not change the graph.