@gencode/server 0.3.10 → 0.3.11
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 +9 -0
- package/README.md +20 -2
- package/dist/index.d.ts +4 -2
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,14 @@
|
|
|
1
1
|
# @gencode/server
|
|
2
2
|
|
|
3
|
+
## 0.3.11
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 6a3da33: `aimax-server` 的 `POST /run` 请求现在明确按完整 `aimax run` 参数合同接收 `run` 字段,使用 camelCase JSON 字段名传递 CLI 选项。调用方可以通过 server 模式传入 `resumeRequestId`、`resumeInputJson`、`resumeFromFile` 等 HITL / UI Tool 恢复参数;这些字段会沿用既有 CLI run 路径执行,执行进度和结果仍通过已配置的 stdout、callback 或 websocket 输出。
|
|
8
|
+
- Updated dependencies [0334050]
|
|
9
|
+
- @gencode/agents@0.17.2
|
|
10
|
+
- @gencode/cli@0.15.2
|
|
11
|
+
|
|
3
12
|
## 0.3.10
|
|
4
13
|
|
|
5
14
|
### Patch Changes
|
package/README.md
CHANGED
|
@@ -18,8 +18,13 @@ If the accepted `/run` request does not provide `run.pluginsConfig` and does not
|
|
|
18
18
|
override `AIMAX_PLUGINS_CONFIG` in request `env`, the run inherits the startup
|
|
19
19
|
plugins config path so the CLI execution uses the preloaded plugin registry.
|
|
20
20
|
|
|
21
|
-
`POST /run` accepts
|
|
22
|
-
|
|
21
|
+
`POST /run` accepts the same run options as `aimax run` under `run`, using the
|
|
22
|
+
CLI `RunOptions` camelCase field names. For example, `--session-id` becomes
|
|
23
|
+
`sessionId`, `--resume-request-id` becomes `resumeRequestId`, and
|
|
24
|
+
`--resume-input-json` becomes `resumeInputJson`.
|
|
25
|
+
|
|
26
|
+
For structured message input, pass `run.messages` instead of encoding JSON into
|
|
27
|
+
`run.message`:
|
|
23
28
|
|
|
24
29
|
```json
|
|
25
30
|
{
|
|
@@ -40,3 +45,16 @@ message input, pass `run.messages` instead of encoding JSON into `run.message`:
|
|
|
40
45
|
|
|
41
46
|
`run.messages` uses the same structured Message format as `aimax run --from-file`.
|
|
42
47
|
`run.message` remains plain user text and is not JSON-parsed by the server.
|
|
48
|
+
|
|
49
|
+
Resume-related run options are also forwarded through the same CLI path:
|
|
50
|
+
|
|
51
|
+
```json
|
|
52
|
+
{
|
|
53
|
+
"run": {
|
|
54
|
+
"dataDir": "/data/user1",
|
|
55
|
+
"sessionId": "sess-001",
|
|
56
|
+
"resumeRequestId": "hitl-001",
|
|
57
|
+
"resumeInputJson": "{\"action\":\"submit\",\"values\":{\"approved\":true}}"
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
```
|
package/dist/index.d.ts
CHANGED
|
@@ -1,10 +1,12 @@
|
|
|
1
|
+
import { RunOptions } from "@gencode/cli";
|
|
2
|
+
|
|
1
3
|
//#region src/server.d.ts
|
|
2
4
|
type AimaxServerStatus = "starting" | "warming" | "ready" | "ready_degraded" | "running" | "draining" | "exiting";
|
|
3
5
|
type ServerRunRequest = {
|
|
4
6
|
env?: ServerRequestEnv;
|
|
5
7
|
run: ServerRunOptions;
|
|
6
8
|
};
|
|
7
|
-
type ServerRunOptions =
|
|
9
|
+
type ServerRunOptions = RunOptions;
|
|
8
10
|
type ServerRequestEnv = Record<string, string | number | boolean | null>;
|
|
9
11
|
type SystemWarmState = {
|
|
10
12
|
runtimeInitialized: true;
|
|
@@ -36,4 +38,4 @@ type AimaxServerHandle = {
|
|
|
36
38
|
};
|
|
37
39
|
declare function createAimaxServer(options?: AimaxServerOptions): AimaxServerHandle;
|
|
38
40
|
//#endregion
|
|
39
|
-
export { type AimaxServerHandle, type AimaxServerOptions, type AimaxServerStatus, type ServerRequestEnv, type ServerRunRequest, createAimaxServer };
|
|
41
|
+
export { type AimaxServerHandle, type AimaxServerOptions, type AimaxServerStatus, type ServerRequestEnv, type ServerRunOptions, type ServerRunRequest, createAimaxServer };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gencode/server",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.11",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"bin": {
|
|
6
6
|
"aimax-server": "./dist/bin.js"
|
|
@@ -19,8 +19,8 @@
|
|
|
19
19
|
"access": "public"
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
|
-
"@gencode/
|
|
23
|
-
"@gencode/
|
|
22
|
+
"@gencode/cli": "0.15.2",
|
|
23
|
+
"@gencode/agents": "0.17.2"
|
|
24
24
|
},
|
|
25
25
|
"devDependencies": {
|
|
26
26
|
"@types/node": "^22.0.0",
|