From 291fc391793fe29fcfadaac8b81a8da01c8d4a77 Mon Sep 17 00:00:00 2001 From: JCAI Main Agent Date: Mon, 27 Jul 2026 01:56:06 +0800 Subject: [PATCH] =?UTF-8?q?chore:=20=E5=88=B7=E6=96=B0=E5=A5=91=E7=BA=A6?= =?UTF-8?q?=E5=BF=AB=E7=85=A7(process=20=E5=87=BA=E5=8F=A3)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../api/src/modules/process/contract.d.ts | 21 +++++++++++++++++++ .../apps/api/src/modules/process/index.d.ts | 7 +++++++ 2 files changed, 28 insertions(+) create mode 100644 api-report/apps/api/src/modules/process/contract.d.ts create mode 100644 api-report/apps/api/src/modules/process/index.d.ts diff --git a/api-report/apps/api/src/modules/process/contract.d.ts b/api-report/apps/api/src/modules/process/contract.d.ts new file mode 100644 index 0000000..5239bdc --- /dev/null +++ b/api-report/apps/api/src/modules/process/contract.d.ts @@ -0,0 +1,21 @@ +/** + * module: process —— 对外类型(编码规范 §10.1;语义出处 OS 03)。 + * + * 流程层:流程包定义与版本、**边映射闭合校验**、工作流实例 + * (网关 / 审批点 / 失败走向 / 负责人四策略 / 聚合)。 + * + * M5 进行中:domain 已落(闭合校验 / 四策略解析 / 状态聚合), + * 用例与 Mastra 工作流编译随后(编码规范 §6.1)。 + */ +import type { ClosureReport, ClosureViolation, OwnerSpec, ProcessPackage, WorkflowState } from '@contracts'; +import type { ActivityContractFace, ClosureInput } from './internal/domain/closure.ts'; +import type { Candidate, NodeInstance, ResolveContext, Resolution } from './internal/domain/owner-resolution.ts'; +export type { ActivityContractFace, Candidate, ClosureInput, ClosureReport, ClosureViolation, NodeInstance, OwnerSpec, ProcessPackage, ResolveContext, Resolution, WorkflowState, }; +export declare class NotPublishableError extends Error { + readonly report: ClosureReport; + constructor(report: ClosureReport); +} +export declare class PositionVacantError extends Error { + readonly position: string; + constructor(position: string); +} diff --git a/api-report/apps/api/src/modules/process/index.d.ts b/api-report/apps/api/src/modules/process/index.d.ts new file mode 100644 index 0000000..a2750cf --- /dev/null +++ b/api-report/apps/api/src/modules/process/index.d.ts @@ -0,0 +1,7 @@ +/** + * module: process —— 唯一出口。只做 re-export,不写逻辑(编码规范 §10.1)。 + */ +export type { ActivityContractFace, Candidate, ClosureInput, ClosureReport, ClosureViolation, NodeInstance, OwnerSpec, ProcessPackage, ResolveContext, Resolution, WorkflowState, } from './contract.ts'; +export { NotPublishableError, PositionVacantError } from './contract.ts'; +export { checkClosure, publishable } from './internal/domain/closure.ts'; +export { aggregateWorkflowState, FAILURE_DIGESTIONS, isDigested, nextInstanceNumber, resolveOwner, } from './internal/domain/owner-resolution.ts';