This repository has been archived on 2026-06-01. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
pulse/packages/pulse-workflows/src/workflows/coding.d.ts
T
tuanzi f3857888da
CI / test (pull_request) Has been cancelled
refactor: remove closer role from coding and coding-tdd workflows
What: Remove the closer role from coding and coding-tdd workflows.
Why: The closer role only produced a summary after reviewer approved,
adding no value — reviewer approval is sufficient to end the workflow.
Changes:
- Delete CloserMeta/TddCloserMeta types and defaultCloser implementations
- Moderator now routes directly to END after reviewer approves
- Update all tests, .js and .d.ts artifacts accordingly
- Remove closer from index exports

团子 🐰
2026-04-18 12:16:02 +00:00

35 lines
970 B
TypeScript

/**
* CodingTask WorkflowType — pure roles + START/END automaton.
*
* Roles: architect → coder → reviewer
* Trigger: coding.__start__ (external)
* Each role returns { content, meta } — adapter writes events.
*
* 小橘 🍊 (NEKO Team)
*/
import { type Role, type WorkflowType } from '@uncaged/pulse';
export type ArchitectMeta = {
targetFiles: string[];
changes: Record<string, string>;
verification: string;
};
export type CoderMeta = {
filesChanged: string[];
testsPassed: boolean;
};
export type ReviewerMeta = {
verdict: 'approved' | 'rejected';
rejectionReason: string[];
retryCount: number;
};
export type CodingRoles = {
architect: Role<ArchitectMeta>;
coder: Role<CoderMeta>;
reviewer: Role<ReviewerMeta>;
};
export declare function createCodingWorkflow(opts?: {
architectFn?: Role<ArchitectMeta>;
coderFn?: Role<CoderMeta>;
reviewerFn?: Role<ReviewerMeta>;
}): WorkflowType<CodingRoles>;