refactor: remove name from WorkflowDefinition, fix threadId type errors
WorkflowDefinition no longer carries 'name' — name is a registry-level concern, not a bundle property. Also fixed all missing threadId in test fixtures to match the updated ThreadContext type. 小橘 <xiaoju@shazhou.work>
This commit is contained in:
@@ -167,6 +167,7 @@ export async function executeThread(
|
||||
}
|
||||
|
||||
const bundleOptions: WorkflowFnOptions = {
|
||||
threadId: io.threadId,
|
||||
isDryRun: options.isDryRun,
|
||||
maxRounds: options.maxRounds,
|
||||
};
|
||||
|
||||
@@ -89,7 +89,6 @@ export type Moderator<M extends RoleMeta> = (
|
||||
|
||||
/** Complete workflow definition as authored by users. */
|
||||
export type WorkflowDefinition<M extends RoleMeta> = {
|
||||
name: string;
|
||||
roles: { [K in keyof M & string]: Role<M[K]> };
|
||||
moderator: Moderator<M>;
|
||||
};
|
||||
|
||||
@@ -136,7 +136,7 @@ function parseRunControlPayload(rec: Record<string, unknown>): RunCommand | null
|
||||
threadId,
|
||||
workflowName,
|
||||
prompt,
|
||||
options: { threadId, isDryRun, maxRounds },
|
||||
options: { isDryRun, maxRounds },
|
||||
steps: parsedSteps.steps,
|
||||
stepTimestamps: parsedSteps.stepTimestamps,
|
||||
forkSourceThreadId,
|
||||
|
||||
Reference in New Issue
Block a user