@relayflows/surface 2.0.15 → 2.0.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4,6 +4,7 @@ export type CompletionReason = (typeof COMPLETION_REASONS)[number];
4
4
  /** The closed run completion vocabulary from the journal protocol. */
5
5
  export declare const RUN_COMPLETION_REASONS: readonly ["success", "step_failed", "canceled", "budget_exceeded"];
6
6
  export type RunCompletionReason = (typeof RUN_COMPLETION_REASONS)[number];
7
- /** Authored outcomes include a human handoff; it is not a kernel terminal reason. */
8
- export type FlowCompletionReason = RunCompletionReason | 'needs_human';
7
+ /** Authored verdicts include handoff and declination without widening kernel facts. */
8
+ export declare const FLOW_COMPLETION_REASONS: readonly ["success", "step_failed", "canceled", "budget_exceeded", "needs_human", "declined"];
9
+ export type FlowCompletionReason = (typeof FLOW_COMPLETION_REASONS)[number];
9
10
  //# sourceMappingURL=completion.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"completion.d.ts","sourceRoot":"","sources":["../src/completion.ts"],"names":[],"mappings":"AAAA,uEAAuE;AACvE,eAAO,MAAM,kBAAkB,wJAUrB,CAAC;AAEX,MAAM,MAAM,gBAAgB,GAAG,CAAC,OAAO,kBAAkB,CAAC,CAAC,MAAM,CAAC,CAAC;AAEnE,sEAAsE;AACtE,eAAO,MAAM,sBAAsB,oEAKzB,CAAC;AAEX,MAAM,MAAM,mBAAmB,GAAG,CAAC,OAAO,sBAAsB,CAAC,CAAC,MAAM,CAAC,CAAC;AAE1E,qFAAqF;AACrF,MAAM,MAAM,oBAAoB,GAAG,mBAAmB,GAAG,aAAa,CAAC"}
1
+ {"version":3,"file":"completion.d.ts","sourceRoot":"","sources":["../src/completion.ts"],"names":[],"mappings":"AAAA,uEAAuE;AACvE,eAAO,MAAM,kBAAkB,wJAUrB,CAAC;AAEX,MAAM,MAAM,gBAAgB,GAAG,CAAC,OAAO,kBAAkB,CAAC,CAAC,MAAM,CAAC,CAAC;AAEnE,sEAAsE;AACtE,eAAO,MAAM,sBAAsB,oEAKzB,CAAC;AAEX,MAAM,MAAM,mBAAmB,GAAG,CAAC,OAAO,sBAAsB,CAAC,CAAC,MAAM,CAAC,CAAC;AAE1E,uFAAuF;AACvF,eAAO,MAAM,uBAAuB,+FAI1B,CAAC;AAEX,MAAM,MAAM,oBAAoB,GAAG,CAAC,OAAO,uBAAuB,CAAC,CAAC,MAAM,CAAC,CAAC"}
@@ -17,4 +17,10 @@ export const RUN_COMPLETION_REASONS = [
17
17
  "canceled",
18
18
  "budget_exceeded",
19
19
  ];
20
+ /** Authored verdicts include handoff and declination without widening kernel facts. */
21
+ export const FLOW_COMPLETION_REASONS = [
22
+ ...RUN_COMPLETION_REASONS,
23
+ 'needs_human',
24
+ 'declined',
25
+ ];
20
26
  //# sourceMappingURL=completion.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"completion.js","sourceRoot":"","sources":["../src/completion.ts"],"names":[],"mappings":"AAAA,uEAAuE;AACvE,MAAM,CAAC,MAAM,kBAAkB,GAAG;IAChC,SAAS;IACT,qBAAqB;IACrB,mBAAmB;IACnB,eAAe;IACf,SAAS;IACT,SAAS;IACT,cAAc;IACd,iBAAiB;IACjB,UAAU;CACF,CAAC;AAIX,sEAAsE;AACtE,MAAM,CAAC,MAAM,sBAAsB,GAAG;IACpC,SAAS;IACT,aAAa;IACb,UAAU;IACV,iBAAiB;CACT,CAAC"}
1
+ {"version":3,"file":"completion.js","sourceRoot":"","sources":["../src/completion.ts"],"names":[],"mappings":"AAAA,uEAAuE;AACvE,MAAM,CAAC,MAAM,kBAAkB,GAAG;IAChC,SAAS;IACT,qBAAqB;IACrB,mBAAmB;IACnB,eAAe;IACf,SAAS;IACT,SAAS;IACT,cAAc;IACd,iBAAiB;IACjB,UAAU;CACF,CAAC;AAIX,sEAAsE;AACtE,MAAM,CAAC,MAAM,sBAAsB,GAAG;IACpC,SAAS;IACT,aAAa;IACb,UAAU;IACV,iBAAiB;CACT,CAAC;AAIX,uFAAuF;AACvF,MAAM,CAAC,MAAM,uBAAuB,GAAG;IACrC,GAAG,sBAAsB;IACzB,aAAa;IACb,UAAU;CACF,CAAC"}
package/dist/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  export type { EnrollmentReceipt, Heartbeat, JournalStep, RunJournal, ScheduleState, WorkerSummary, CloudHelper, } from "./cloud.js";
2
2
  export type { AgentOptions, AgentResult, LlmOptions, Ctx } from "./context.js";
3
- export { COMPLETION_REASONS, RUN_COMPLETION_REASONS, type CompletionReason, type RunCompletionReason, type FlowCompletionReason, } from "./completion.js";
3
+ export { COMPLETION_REASONS, RUN_COMPLETION_REASONS, FLOW_COMPLETION_REASONS, type CompletionReason, type RunCompletionReason, type FlowCompletionReason, } from "./completion.js";
4
4
  export type { Step, NamedGate, ReferencesInputNamedGate, SubprocessNamedGate, WordCountBoundsNamedGate, RegexMatchNamedGate, } from "./step.js";
5
5
  export { flow, type FlowHandle, type TriggeredFlowHandle, type FlowHeader, } from "./flow.js";
6
6
  export { flowRunWritebackIdempotency, type SlackHelper, type SlackReceipt, type SlackBlock, type SlackAttachment, type SlackPostMessage, type SlackPostOptions, } from "./slack.js";
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,YAAY,EACV,iBAAiB,EACjB,SAAS,EACT,WAAW,EACX,UAAU,EACV,aAAa,EACb,aAAa,EACb,WAAW,GACZ,MAAM,YAAY,CAAC;AACpB,YAAY,EAAE,YAAY,EAAE,WAAW,EAAE,UAAU,EAAE,GAAG,EAAE,MAAM,cAAc,CAAC;AAC/E,OAAO,EACL,kBAAkB,EAClB,sBAAsB,EACtB,KAAK,gBAAgB,EACrB,KAAK,mBAAmB,EACxB,KAAK,oBAAoB,GAC1B,MAAM,iBAAiB,CAAC;AACzB,YAAY,EACV,IAAI,EACJ,SAAS,EACT,wBAAwB,EACxB,mBAAmB,EACnB,wBAAwB,EACxB,mBAAmB,GACp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,KAAK,UAAU,EACf,KAAK,mBAAmB,EACxB,KAAK,UAAU,GAChB,MAAM,WAAW,CAAC;AACnB,OAAO,EACL,2BAA2B,EAC3B,KAAK,WAAW,EAChB,KAAK,YAAY,EACjB,KAAK,UAAU,EACf,KAAK,eAAe,EACpB,KAAK,gBAAgB,EACrB,KAAK,gBAAgB,GACtB,MAAM,YAAY,CAAC;AACpB,YAAY,EAAE,OAAO,EAAE,MAAM,oBAAoB,CAAC;AAClD,YAAY,EAAE,YAAY,EAAE,aAAa,EAAE,mBAAmB,EAAE,YAAY,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AACnH,OAAO,EAAE,OAAO,EAAE,KAAK,aAAa,EAAE,KAAK,aAAa,EAAE,KAAK,YAAY,EAAE,MAAM,eAAe,CAAC;AACnG,cAAc,qBAAqB,CAAC;AACpC,YAAY,EAAE,qBAAqB,EAAE,MAAM,uBAAuB,CAAC;AACnE,YAAY,EAAE,YAAY,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC"}
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- export { COMPLETION_REASONS, RUN_COMPLETION_REASONS, } from "./completion.js";
1
+ export { COMPLETION_REASONS, RUN_COMPLETION_REASONS, FLOW_COMPLETION_REASONS, } from "./completion.js";
2
2
  export { flow, } from "./flow.js";
3
3
  export { flowRunWritebackIdempotency, } from "./slack.js";
4
4
  export { webhook } from "./triggers.js";
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAUA,OAAO,EACL,kBAAkB,EAClB,sBAAsB,GAIvB,MAAM,iBAAiB,CAAC;AASzB,OAAO,EACL,IAAI,GAIL,MAAM,WAAW,CAAC;AACnB,OAAO,EACL,2BAA2B,GAO5B,MAAM,YAAY,CAAC;AAGpB,OAAO,EAAE,OAAO,EAA6D,MAAM,eAAe,CAAC;AACnG,cAAc,qBAAqB,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAUA,OAAO,EACL,kBAAkB,EAClB,sBAAsB,EACtB,uBAAuB,GAIxB,MAAM,iBAAiB,CAAC;AASzB,OAAO,EACL,IAAI,GAIL,MAAM,WAAW,CAAC;AACnB,OAAO,EACL,2BAA2B,GAO5B,MAAM,YAAY,CAAC;AAGpB,OAAO,EAAE,OAAO,EAA6D,MAAM,eAAe,CAAC;AACnG,cAAc,qBAAqB,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@relayflows/surface",
3
- "version": "2.0.15",
3
+ "version": "2.0.16",
4
4
  "description": "TypeScript authoring surface for Relayflows.",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
package/src/completion.ts CHANGED
@@ -23,5 +23,11 @@ export const RUN_COMPLETION_REASONS = [
23
23
 
24
24
  export type RunCompletionReason = (typeof RUN_COMPLETION_REASONS)[number];
25
25
 
26
- /** Authored outcomes include a human handoff; it is not a kernel terminal reason. */
27
- export type FlowCompletionReason = RunCompletionReason | 'needs_human';
26
+ /** Authored verdicts include handoff and declination without widening kernel facts. */
27
+ export const FLOW_COMPLETION_REASONS = [
28
+ ...RUN_COMPLETION_REASONS,
29
+ 'needs_human',
30
+ 'declined',
31
+ ] as const;
32
+
33
+ export type FlowCompletionReason = (typeof FLOW_COMPLETION_REASONS)[number];
package/src/index.ts CHANGED
@@ -11,6 +11,7 @@ export type { AgentOptions, AgentResult, LlmOptions, Ctx } from "./context.js";
11
11
  export {
12
12
  COMPLETION_REASONS,
13
13
  RUN_COMPLETION_REASONS,
14
+ FLOW_COMPLETION_REASONS,
14
15
  type CompletionReason,
15
16
  type RunCompletionReason,
16
17
  type FlowCompletionReason,