feat: rename design_task to research_task and update related documentation

This commit is contained in:
Lauren ten Hoor
2026-02-16 18:47:01 +08:00
parent d87b9f68a2
commit b57ede0863
15 changed files with 249 additions and 173 deletions

View File

@@ -201,25 +201,6 @@ export const DEFAULT_WORKFLOW: WorkflowConfig = {
on: { [WorkflowEvent.APPROVE]: "todo" },
},
// ── Architect track ─────────────────────────────────────────
toDesign: {
type: StateType.QUEUE,
role: "architect",
label: "To Design",
color: "#0075ca",
priority: 1,
on: { [WorkflowEvent.PICKUP]: "designing" },
},
designing: {
type: StateType.ACTIVE,
role: "architect",
label: "Designing",
color: "#d4c5f9",
on: {
[WorkflowEvent.COMPLETE]: "planning",
[WorkflowEvent.BLOCKED]: "refining",
},
},
},
};
@@ -437,6 +418,14 @@ export function findStateKeyByLabel(workflow: WorkflowConfig, label: string): st
return Object.entries(workflow.states).find(([, s]) => s.label === label)?.[0] ?? null;
}
/**
* Check if a role has any workflow states (queue, active, etc.).
* Roles without workflow states (e.g. architect) are dispatched by tool only.
*/
export function hasWorkflowStates(workflow: WorkflowConfig, role: Role): boolean {
return Object.values(workflow.states).some((s) => s.role === role);
}
// ---------------------------------------------------------------------------
// Completion rules — derived from transitions
// ---------------------------------------------------------------------------