@tomflow/proflow-agent-gateway 0.1.10 → 0.1.12
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.
- package/CHANGELOG.md +12 -0
- package/DOCS.md +32 -8
- package/SETUP.md +13 -4
- package/dist/deployment/adapter.d.ts +38 -16
- package/dist/deployment/adapter.js +47 -17
- package/dist/deployment/descriptor.d.ts +1 -1
- package/dist/deployment/descriptor.js +1 -1
- package/package.json +11 -11
- package/proflow.module.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# @tomflow/proflow-agent-gateway
|
|
2
2
|
|
|
3
|
+
## 0.1.12
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Distinguish dependency blocking from verified failure, expose Module-owned status diagnostics, remove automatic docs paging, consolidate start checks, add contextual help, and clarify uninstall output.
|
|
8
|
+
|
|
9
|
+
## 0.1.11
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- Upgrade the ProFlow terminal experience, stream Registry and package-manager progress, publish structured Chinese Module documentation, and provide numbered package-owned Setup assistants.
|
|
14
|
+
|
|
3
15
|
## 0.1.10
|
|
4
16
|
|
|
5
17
|
### Patch Changes
|
package/DOCS.md
CHANGED
|
@@ -1,14 +1,38 @@
|
|
|
1
|
-
# agent-gateway
|
|
1
|
+
# agent-gateway — 智能体动作网关
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
## 模块定位与作用
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
Agent Gateway(智能体网关)是 Custom GPT Actions 的唯一公网入口。它负责认证角色身份、校验请求、路由到领域 Public API,并把结果规范化返回 ChatGPT。
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
## 主要能力
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
- 校验 Role Bearer Key、请求 Schema、权限和版本。
|
|
10
|
+
- 路由 Task、Agent Runtime 与 Execution 的公开能力。
|
|
11
|
+
- 暴露静态 OpenAPI 所需的 HTTPS Action 接口,不保存业务数据。
|
|
10
12
|
|
|
11
|
-
|
|
12
|
-
- Dev Tunnel(开发隧道)已经提供可公开访问的 HTTPS 地址。
|
|
13
|
+
## 提供的 API 与 Public Contract
|
|
13
14
|
|
|
14
|
-
|
|
15
|
+
- 提供 `custom-gpt-actions-gateway` Contract,版本 `1.0.0`。
|
|
16
|
+
- 对外提供 Custom GPT Actions HTTP API;内部只调用已声明的领域 Contract。
|
|
17
|
+
|
|
18
|
+
## 依赖的 Module、Contract 和外部资源
|
|
19
|
+
|
|
20
|
+
- 依赖 `agent-runtime`、`task-orchestration`、`execution`、`platform-host` 和 `public-ingress`,兼容版本均为 `>=1.0.0 <2.0.0`。
|
|
21
|
+
|
|
22
|
+
## 运行形态与生命周期
|
|
23
|
+
|
|
24
|
+
类型为 Service(服务),由独立进程监听本地端口,经 Dev Tunnel 暴露公开 HTTPS 地址。
|
|
25
|
+
|
|
26
|
+
## 使用方式
|
|
27
|
+
|
|
28
|
+
完成 Platform Host 与 Dev Tunnel 配置后运行 `platform start`。Custom GPT 使用各自 Role Key 调用该网关。
|
|
29
|
+
|
|
30
|
+
## 职责边界与限制
|
|
31
|
+
|
|
32
|
+
不直接读取数据库、不执行 Shell/Git、不推进 Task,也不拥有 Tunnel 登录和域名生命周期。
|
|
33
|
+
|
|
34
|
+
## 术语
|
|
35
|
+
|
|
36
|
+
- Gateway(网关):外部协议与内部领域接口之间的受控适配层。
|
|
37
|
+
- Public Ingress(公网入口):由 Dev Tunnel 提供的 HTTPS 访问能力。
|
|
38
|
+
- Bearer Key(持有者凭据):用于识别固定 Role 的认证信息。
|
package/SETUP.md
CHANGED
|
@@ -1,10 +1,19 @@
|
|
|
1
1
|
# @tomflow/proflow-agent-gateway — Module Setup
|
|
2
2
|
|
|
3
|
-
## STEP-AGENT-GATEWAY-01 —
|
|
3
|
+
## STEP-AGENT-GATEWAY-01 — 准备公开入口
|
|
4
|
+
|
|
5
|
+
Responsible: EXTERNAL
|
|
6
|
+
Interactive executable: `platform setup --module dev-tunnel`
|
|
7
|
+
Non-interactive executable: `platform setup --module dev-tunnel`
|
|
8
|
+
Required inputs: persistent Tunnel and public HTTPS URL
|
|
9
|
+
Verify: `platform status`
|
|
10
|
+
Success condition: `dev-tunnel.setupStatus=READY`.
|
|
11
|
+
|
|
12
|
+
## STEP-AGENT-GATEWAY-02 — 启动平台主服务
|
|
4
13
|
|
|
5
14
|
Responsible: AI
|
|
6
|
-
Interactive executable: `platform setup --module
|
|
7
|
-
Non-interactive executable: `platform setup --module
|
|
15
|
+
Interactive executable: `platform setup --module platform-host`
|
|
16
|
+
Non-interactive executable: `platform setup --module platform-host`
|
|
8
17
|
Required inputs: none
|
|
9
18
|
Verify: `platform status`
|
|
10
|
-
Success condition: `
|
|
19
|
+
Success condition: `platform-host.setupStatus=READY`.
|
|
@@ -6,7 +6,7 @@ export declare const behaviorAdapter: {
|
|
|
6
6
|
ok: true;
|
|
7
7
|
status: "SUCCEEDED";
|
|
8
8
|
moduleRef: "agent-gateway";
|
|
9
|
-
moduleVersion: "0.1.
|
|
9
|
+
moduleVersion: "0.1.12";
|
|
10
10
|
data: {
|
|
11
11
|
localBaseUrl: string;
|
|
12
12
|
publicBaseUrl?: string;
|
|
@@ -20,7 +20,7 @@ export declare const behaviorAdapter: {
|
|
|
20
20
|
readonly ok: true;
|
|
21
21
|
readonly status: "SUCCEEDED";
|
|
22
22
|
readonly moduleRef: "agent-gateway";
|
|
23
|
-
readonly moduleVersion: "0.1.
|
|
23
|
+
readonly moduleVersion: "0.1.12";
|
|
24
24
|
};
|
|
25
25
|
observedEffects: string[];
|
|
26
26
|
}>;
|
|
@@ -30,10 +30,17 @@ export declare const behaviorAdapter: {
|
|
|
30
30
|
ok: true;
|
|
31
31
|
status: "SUCCEEDED";
|
|
32
32
|
moduleRef: "agent-gateway";
|
|
33
|
-
moduleVersion: "0.1.
|
|
33
|
+
moduleVersion: "0.1.12";
|
|
34
34
|
data: {
|
|
35
|
-
setupStatus: "
|
|
35
|
+
setupStatus: "BLOCKED" | "READY";
|
|
36
36
|
runtimeStatus: "RUNNING" | "STOPPED";
|
|
37
|
+
issues?: {
|
|
38
|
+
scope: "SETUP";
|
|
39
|
+
code: string;
|
|
40
|
+
message: string;
|
|
41
|
+
relatedModuleRefs: string[];
|
|
42
|
+
nextCommand: string;
|
|
43
|
+
}[];
|
|
37
44
|
};
|
|
38
45
|
};
|
|
39
46
|
observedEffects: never[];
|
|
@@ -44,11 +51,11 @@ export declare const behaviorAdapter: {
|
|
|
44
51
|
readonly ok: true;
|
|
45
52
|
readonly status: "SUCCEEDED";
|
|
46
53
|
readonly moduleRef: "agent-gateway";
|
|
47
|
-
readonly moduleVersion: "0.1.
|
|
54
|
+
readonly moduleVersion: "0.1.12";
|
|
48
55
|
} | {
|
|
49
56
|
contract: "deployment.result.v1";
|
|
50
57
|
moduleRef: "agent-gateway";
|
|
51
|
-
moduleVersion: "0.1.
|
|
58
|
+
moduleVersion: "0.1.12";
|
|
52
59
|
ok: false;
|
|
53
60
|
status: "FAILED";
|
|
54
61
|
error: {
|
|
@@ -59,17 +66,32 @@ export declare const behaviorAdapter: {
|
|
|
59
66
|
data: {
|
|
60
67
|
readonly steps: readonly [{
|
|
61
68
|
readonly id: "STEP-AGENT-GATEWAY-01";
|
|
62
|
-
readonly title: "
|
|
69
|
+
readonly title: "等待 Public Ingress";
|
|
70
|
+
readonly description: "Gateway 需要稳定的公开 HTTPS 地址。";
|
|
63
71
|
readonly state: "BLOCKED";
|
|
64
72
|
readonly responsible: "EXTERNAL";
|
|
65
73
|
readonly execution: {
|
|
66
|
-
readonly interactive: "platform setup --module
|
|
67
|
-
readonly nonInteractive: "platform setup --module
|
|
74
|
+
readonly interactive: "platform setup --module dev-tunnel";
|
|
75
|
+
readonly nonInteractive: "platform setup --module dev-tunnel";
|
|
68
76
|
};
|
|
69
77
|
readonly requiredInputs: readonly [];
|
|
70
78
|
readonly verify: "platform status";
|
|
71
79
|
readonly successCondition: "配置状态变为“已就绪”";
|
|
72
|
-
readonly blockedReason: "
|
|
80
|
+
readonly blockedReason: "dev-tunnel 尚未发布 publicBaseUrl";
|
|
81
|
+
}, {
|
|
82
|
+
readonly id: "STEP-AGENT-GATEWAY-02";
|
|
83
|
+
readonly title: "等待 Platform Host";
|
|
84
|
+
readonly description: "Gateway 下游应用端点和凭据尚不可用。";
|
|
85
|
+
readonly state: "BLOCKED";
|
|
86
|
+
readonly responsible: "EXTERNAL";
|
|
87
|
+
readonly execution: {
|
|
88
|
+
readonly interactive: "platform setup --module platform-host";
|
|
89
|
+
readonly nonInteractive: "platform setup --module platform-host";
|
|
90
|
+
};
|
|
91
|
+
readonly requiredInputs: readonly [];
|
|
92
|
+
readonly verify: "platform status";
|
|
93
|
+
readonly successCondition: "platform-host 已发布 endpoint、stateRoot 和 transport credential";
|
|
94
|
+
readonly blockedReason: "platform-host 尚未就绪";
|
|
73
95
|
}];
|
|
74
96
|
};
|
|
75
97
|
};
|
|
@@ -81,7 +103,7 @@ export declare const behaviorAdapter: {
|
|
|
81
103
|
ok: true;
|
|
82
104
|
status: "SUCCEEDED";
|
|
83
105
|
moduleRef: "agent-gateway";
|
|
84
|
-
moduleVersion: "0.1.
|
|
106
|
+
moduleVersion: "0.1.12";
|
|
85
107
|
data: {
|
|
86
108
|
docs: string;
|
|
87
109
|
};
|
|
@@ -94,7 +116,7 @@ export declare const behaviorAdapter: {
|
|
|
94
116
|
ok: true;
|
|
95
117
|
status: "SUCCEEDED";
|
|
96
118
|
moduleRef: "agent-gateway";
|
|
97
|
-
moduleVersion: "0.1.
|
|
119
|
+
moduleVersion: "0.1.12";
|
|
98
120
|
data: {
|
|
99
121
|
host: string;
|
|
100
122
|
port: number;
|
|
@@ -105,7 +127,7 @@ export declare const behaviorAdapter: {
|
|
|
105
127
|
result: {
|
|
106
128
|
contract: "deployment.result.v1";
|
|
107
129
|
moduleRef: "agent-gateway";
|
|
108
|
-
moduleVersion: "0.1.
|
|
130
|
+
moduleVersion: "0.1.12";
|
|
109
131
|
ok: false;
|
|
110
132
|
status: "FAILED";
|
|
111
133
|
error: {
|
|
@@ -122,7 +144,7 @@ export declare const behaviorAdapter: {
|
|
|
122
144
|
readonly ok: true;
|
|
123
145
|
readonly status: "SUCCEEDED";
|
|
124
146
|
readonly moduleRef: "agent-gateway";
|
|
125
|
-
readonly moduleVersion: "0.1.
|
|
147
|
+
readonly moduleVersion: "0.1.12";
|
|
126
148
|
};
|
|
127
149
|
observedEffects: string[];
|
|
128
150
|
} | {
|
|
@@ -131,11 +153,11 @@ export declare const behaviorAdapter: {
|
|
|
131
153
|
readonly ok: true;
|
|
132
154
|
readonly status: "SUCCEEDED";
|
|
133
155
|
readonly moduleRef: "agent-gateway";
|
|
134
|
-
readonly moduleVersion: "0.1.
|
|
156
|
+
readonly moduleVersion: "0.1.12";
|
|
135
157
|
} | {
|
|
136
158
|
contract: "deployment.result.v1";
|
|
137
159
|
moduleRef: "agent-gateway";
|
|
138
|
-
moduleVersion: "0.1.
|
|
160
|
+
moduleVersion: "0.1.12";
|
|
139
161
|
ok: false;
|
|
140
162
|
status: "FAILED";
|
|
141
163
|
error: {
|
|
@@ -14,17 +14,33 @@ const blockedSetupPlan = {
|
|
|
14
14
|
steps: [
|
|
15
15
|
{
|
|
16
16
|
id: "STEP-AGENT-GATEWAY-01",
|
|
17
|
-
title: "
|
|
17
|
+
title: "等待 Public Ingress",
|
|
18
|
+
description: "Gateway 需要稳定的公开 HTTPS 地址。",
|
|
18
19
|
state: "BLOCKED",
|
|
19
20
|
responsible: "EXTERNAL",
|
|
20
21
|
execution: {
|
|
21
|
-
interactive: "platform setup --module
|
|
22
|
-
nonInteractive: "platform setup --module
|
|
22
|
+
interactive: "platform setup --module dev-tunnel",
|
|
23
|
+
nonInteractive: "platform setup --module dev-tunnel",
|
|
23
24
|
},
|
|
24
25
|
requiredInputs: [],
|
|
25
26
|
verify: "platform status",
|
|
26
27
|
successCondition: "配置状态变为“已就绪”",
|
|
27
|
-
blockedReason: "
|
|
28
|
+
blockedReason: "dev-tunnel 尚未发布 publicBaseUrl",
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
id: "STEP-AGENT-GATEWAY-02",
|
|
32
|
+
title: "等待 Platform Host",
|
|
33
|
+
description: "Gateway 下游应用端点和凭据尚不可用。",
|
|
34
|
+
state: "BLOCKED",
|
|
35
|
+
responsible: "EXTERNAL",
|
|
36
|
+
execution: {
|
|
37
|
+
interactive: "platform setup --module platform-host",
|
|
38
|
+
nonInteractive: "platform setup --module platform-host",
|
|
39
|
+
},
|
|
40
|
+
requiredInputs: [],
|
|
41
|
+
verify: "platform status",
|
|
42
|
+
successCondition: "platform-host 已发布 endpoint、stateRoot 和 transport credential",
|
|
43
|
+
blockedReason: "platform-host 尚未就绪",
|
|
28
44
|
},
|
|
29
45
|
],
|
|
30
46
|
};
|
|
@@ -106,20 +122,34 @@ export const behaviorAdapter = {
|
|
|
106
122
|
observedEffects: service ? ["Manage the declared service process"] : [],
|
|
107
123
|
};
|
|
108
124
|
},
|
|
109
|
-
status: async (context) =>
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
: "
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
125
|
+
status: async (context) => {
|
|
126
|
+
const ready = await dependencies(context);
|
|
127
|
+
return {
|
|
128
|
+
result: {
|
|
129
|
+
...base,
|
|
130
|
+
data: {
|
|
131
|
+
setupStatus: ready ? "READY" : "BLOCKED",
|
|
132
|
+
runtimeStatus: (await running(context))
|
|
133
|
+
? "RUNNING"
|
|
134
|
+
: "STOPPED",
|
|
135
|
+
...(ready
|
|
136
|
+
? {}
|
|
137
|
+
: {
|
|
138
|
+
issues: [
|
|
139
|
+
{
|
|
140
|
+
scope: "SETUP",
|
|
141
|
+
code: "UPSTREAM_NOT_READY",
|
|
142
|
+
message: "等待 dev-tunnel 发布公开 HTTPS 地址,并等待 platform-host 发布下游端点与传输凭据",
|
|
143
|
+
relatedModuleRefs: ["dev-tunnel", "platform-host"],
|
|
144
|
+
nextCommand: "platform setup --module dev-tunnel",
|
|
145
|
+
},
|
|
146
|
+
],
|
|
147
|
+
}),
|
|
148
|
+
},
|
|
119
149
|
},
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
}
|
|
150
|
+
observedEffects: [],
|
|
151
|
+
};
|
|
152
|
+
},
|
|
123
153
|
setup: async (context) => ({
|
|
124
154
|
result: (await dependencies(context))
|
|
125
155
|
? base
|
|
@@ -3,7 +3,7 @@ export declare const descriptor: {
|
|
|
3
3
|
readonly contractVersion: "1.0.0";
|
|
4
4
|
readonly moduleRef: "agent-gateway";
|
|
5
5
|
readonly packageName: "@tomflow/proflow-agent-gateway";
|
|
6
|
-
readonly moduleVersion: "0.1.
|
|
6
|
+
readonly moduleVersion: "0.1.12";
|
|
7
7
|
readonly kind: "service";
|
|
8
8
|
readonly templateVersion: "1.0.0";
|
|
9
9
|
readonly platformCompatibility: ">=1.0.0 <2.0.0";
|
|
@@ -3,7 +3,7 @@ export const descriptor = {
|
|
|
3
3
|
contractVersion: "1.0.0",
|
|
4
4
|
moduleRef: "agent-gateway",
|
|
5
5
|
packageName: "@tomflow/proflow-agent-gateway",
|
|
6
|
-
moduleVersion: "0.1.
|
|
6
|
+
moduleVersion: "0.1.12",
|
|
7
7
|
kind: "service",
|
|
8
8
|
templateVersion: "1.0.0",
|
|
9
9
|
platformCompatibility: ">=1.0.0 <2.0.0",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tomflow/proflow-agent-gateway",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.12",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
@@ -25,18 +25,18 @@
|
|
|
25
25
|
],
|
|
26
26
|
"dependencies": {
|
|
27
27
|
"zod": "4.1.12",
|
|
28
|
-
"@tomflow/proflow-module-contract": "^0.1.
|
|
28
|
+
"@tomflow/proflow-module-contract": "^0.1.12"
|
|
29
29
|
},
|
|
30
30
|
"devDependencies": {
|
|
31
|
-
"@tomflow/proflow-agent-runtime": "^0.1.
|
|
32
|
-
"@tomflow/proflow-
|
|
33
|
-
"@tomflow/proflow-execution-
|
|
34
|
-
"@tomflow/proflow-execution-runtime": "^0.1.
|
|
35
|
-
"@tomflow/proflow-platform-host": "^0.1.
|
|
36
|
-
"@tomflow/proflow-task-
|
|
37
|
-
"@tomflow/proflow-task-
|
|
38
|
-
"@tomflow/proflow-
|
|
39
|
-
"@tomflow/proflow-
|
|
31
|
+
"@tomflow/proflow-agent-runtime": "^0.1.9",
|
|
32
|
+
"@tomflow/proflow-execution-browser-extension": "^0.1.12",
|
|
33
|
+
"@tomflow/proflow-execution-local": "^0.1.11",
|
|
34
|
+
"@tomflow/proflow-execution-runtime": "^0.1.13",
|
|
35
|
+
"@tomflow/proflow-platform-host": "^0.1.12",
|
|
36
|
+
"@tomflow/proflow-task-migration-runner": "^0.1.10",
|
|
37
|
+
"@tomflow/proflow-task-orchestration": "^0.1.8",
|
|
38
|
+
"@tomflow/proflow-task-store-sqlite": "^0.1.10",
|
|
39
|
+
"@tomflow/proflow-deployment-conformance": "^0.1.10"
|
|
40
40
|
},
|
|
41
41
|
"description": "The sole Custom GPT Actions HTTP ingress and OpenAI transport anti-corruption layer.",
|
|
42
42
|
"keywords": [
|
package/proflow.module.json
CHANGED