feat: add four-phase role description (identity/prepare/execute/report)
- Extend RoleDefinition with identity, prepare, execute, report fields - Make systemPrompt optional (nullable) for four-phase workflows - Update ROLE_DEFINITION JSON Schema (all new fields optional) - Update validate.ts to accept new fields - Update workflow.ts to strip null fields before CAS storage - Update thread read to prefer identity over systemPrompt - Add --version flag to uwf CLI - Bump all packages to 0.5.0 Refs #359
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@uncaged/workflow-protocol",
|
||||
"version": "0.1.0",
|
||||
"version": "0.5.0",
|
||||
"files": [
|
||||
"src",
|
||||
"dist",
|
||||
|
||||
@@ -2,10 +2,14 @@ import type { JSONSchema } from "@uncaged/json-cas";
|
||||
|
||||
const ROLE_DEFINITION: JSONSchema = {
|
||||
type: "object",
|
||||
required: ["description", "systemPrompt", "outputSchema"],
|
||||
required: ["description", "outputSchema"],
|
||||
properties: {
|
||||
description: { type: "string" },
|
||||
systemPrompt: { type: "string" },
|
||||
identity: { type: "string" },
|
||||
prepare: { type: "string" },
|
||||
execute: { type: "string" },
|
||||
report: { type: "string" },
|
||||
outputSchema: { type: "string", format: "cas_ref" },
|
||||
},
|
||||
additionalProperties: false,
|
||||
|
||||
@@ -18,7 +18,11 @@ export type StepRecord = {
|
||||
|
||||
export type RoleDefinition = {
|
||||
description: string;
|
||||
systemPrompt: string;
|
||||
systemPrompt: string | null;
|
||||
identity: string | null;
|
||||
prepare: string | null;
|
||||
execute: string | null;
|
||||
report: string | null;
|
||||
outputSchema: CasRef;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user