@sema-agent/server 7.141.0 → 7.142.0
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/MIGRATION.md +215 -0
- package/USAGE.md +67 -12
- package/dist/approval-ask-audit-store.d.ts +54 -38
- package/dist/approval-ask-audit-store.js +58 -39
- package/dist/approval-card.d.ts +8 -8
- package/dist/approval-crash-convergence.d.ts +17 -7
- package/dist/approval-crash-convergence.js +94 -22
- package/dist/approval-deny-reasons.d.ts +34 -30
- package/dist/approval-deny-reasons.js +21 -6
- package/dist/approval-policy-settlement.d.ts +1 -1
- package/dist/approval-reconciler.d.ts +33 -1
- package/dist/approval-reconciler.js +43 -40
- package/dist/auth-bridge.d.ts +9 -6
- package/dist/auth-bridge.js +9 -3
- package/dist/boot/adoption.js +2 -1
- package/dist/boot/budget-tracing.d.ts +16 -0
- package/dist/boot/budget-tracing.js +10 -6
- package/dist/boot/device-lane.d.ts +1 -1
- package/dist/boot/execution-env.d.ts +24 -4
- package/dist/boot/execution-env.js +26 -23
- package/dist/boot/execution-lane.js +2 -1
- package/dist/boot/exit-boundary.js +5 -4
- package/dist/boot/memory-consolidation.js +2 -1
- package/dist/boot/parked-revive-gate.js +2 -1
- package/dist/boot/permission-rules-audit.d.ts +0 -28
- package/dist/boot/permission-rules-audit.js +2 -1
- package/dist/boot/read-deny-anchor-audit.js +2 -1
- package/dist/boot/reapers.js +4 -3
- package/dist/boot/resolve-spec.js +11 -2
- package/dist/boot/retention-lane.js +5 -3
- package/dist/boot/runner-deps.js +16 -13
- package/dist/boot/runtime-caps.js +3 -2
- package/dist/boot/session-faces.js +4 -3
- package/dist/boot/shutdown.js +3 -2
- package/dist/boot/stage-04-stores.js +3 -2
- package/dist/boot/stage-05-execution-env.d.ts +1 -1
- package/dist/boot/stage-05-execution-env.js +8 -6
- package/dist/boot/stage-06-runners.d.ts +1 -1
- package/dist/boot/stage-06-runners.js +2 -1
- package/dist/boot/stage-07-capability-layer.d.ts +1 -1
- package/dist/boot/stage-07-capability-layer.js +2 -1
- package/dist/boot/stage-08-reapers.d.ts +1 -1
- package/dist/boot/stage-08-reapers.js +3 -2
- package/dist/boot/stage-09-leader.d.ts +1 -1
- package/dist/boot/stage-10-http-server.d.ts +1 -1
- package/dist/boot/stage-10-http-server.js +5 -4
- package/dist/boot/stores.js +3 -2
- package/dist/boot/web-admin.js +17 -17
- package/dist/boot/webfetch-summarize-lane.js +2 -1
- package/dist/boot/workflow-orchestration.js +3 -2
- package/dist/capabilities/builtin-tools.d.ts +2 -1
- package/dist/capabilities/builtin-tools.js +2 -4
- package/dist/capabilities/composite-members.d.ts +2 -1
- package/dist/capabilities/composite-members.js +2 -1
- package/dist/capability-facts.d.ts +24 -0
- package/dist/capability-facts.js +23 -0
- package/dist/config-catalog.js +1 -0
- package/dist/config-types.d.ts +15 -4
- package/dist/config.d.ts +6 -0
- package/dist/config.js +17 -3
- package/dist/execution-lane-caps.d.ts +2 -1
- package/dist/fleet/fleet-bus.d.ts +6 -3
- package/dist/hooks/hook-runner.d.ts +6 -0
- package/dist/hooks/hook-runner.js +30 -1
- package/dist/http/dispatch.js +4 -2
- package/dist/http/execution-context.d.ts +2 -2
- package/dist/http/idempotency.d.ts +1 -1
- package/dist/http/principal-gate.d.ts +3 -1
- package/dist/http/principal-gate.js +17 -8
- package/dist/http/resume-legs.js +5 -9
- package/dist/http/route-table.js +2 -0
- package/dist/http/routes/attachments.js +18 -0
- package/dist/http/routes/capabilities.js +5 -2
- package/dist/http/routes/memory-policy.js +26 -6
- package/dist/http/routes/runs.js +3 -3
- package/dist/http/routes/session-memory-sync.d.ts +63 -0
- package/dist/http/routes/session-memory-sync.js +157 -0
- package/dist/http/routes/sessions-list.d.ts +2 -1
- package/dist/http/routes/tasks.js +7 -5
- package/dist/http/run-read-face.d.ts +7 -0
- package/dist/http/run-read-face.js +9 -3
- package/dist/http/send.d.ts +5 -0
- package/dist/http/send.js +9 -2
- package/dist/http/server.d.ts +14 -8
- package/dist/http/server.js +2 -4
- package/dist/http/submit-replay.d.ts +4 -3
- package/dist/http/submit-replay.js +2 -2
- package/dist/http/sync-submit-body.d.ts +21 -4
- package/dist/http/sync-submit-body.js +13 -0
- package/dist/identity-source.d.ts +21 -2
- package/dist/identity-source.js +6 -0
- package/dist/memory-incident-sink.d.ts +19 -6
- package/dist/memory-incident-sink.js +8 -4
- package/dist/memory-sync-client.d.ts +21 -21
- package/dist/memory-sync-client.js +50 -42
- package/dist/memory-sync-identity.d.ts +24 -0
- package/dist/memory-sync-identity.js +57 -0
- package/dist/memory-sync.d.ts +7 -1
- package/dist/memory-sync.js +6 -3
- package/dist/observability/fail-open.d.ts +27 -10
- package/dist/observability/fail-open.js +20 -7
- package/dist/observability/run-terminal.d.ts +92 -34
- package/dist/observability/run-terminal.js +167 -162
- package/dist/plugins/approval-ask-store-file.d.ts +14 -4
- package/dist/plugins/approval-ask-store-file.js +48 -7
- package/dist/plugins/approval-ask-store-memory.d.ts +2 -1
- package/dist/plugins/approval-ask-store-memory.js +9 -8
- package/dist/plugins/approval-ask-store-sql.d.ts +42 -10
- package/dist/plugins/approval-ask-store-sql.js +49 -19
- package/dist/plugins/file-run-store.d.ts +6 -1
- package/dist/plugins/file-run-store.js +11 -1
- package/dist/plugins/local-session-store.d.ts +36 -7
- package/dist/plugins/local-session-store.js +76 -32
- package/dist/plugins/local-task-attachment-store.d.ts +12 -2
- package/dist/plugins/local-task-attachment-store.js +67 -43
- package/dist/plugins/memory-key-guards.d.ts +3 -3
- package/dist/plugins/memory-run-store.d.ts +6 -1
- package/dist/plugins/memory-run-store.js +11 -1
- package/dist/plugins/one-time-migrations.d.ts +27 -1
- package/dist/plugins/one-time-migrations.js +57 -3
- package/dist/plugins/remote-env-e2b.d.ts +23 -4
- package/dist/plugins/remote-env-e2b.js +111 -28
- package/dist/plugins/remote-env-k8s.d.ts +31 -5
- package/dist/plugins/remote-env-k8s.js +86 -19
- package/dist/plugins/remote-env-local-docker.d.ts +15 -3
- package/dist/plugins/remote-env-local-docker.js +40 -12
- package/dist/plugins/run-store-sql.d.ts +9 -1
- package/dist/plugins/run-store-sql.js +9 -1
- package/dist/plugins/store-backend.d.ts +10 -7
- package/dist/plugins/store-backend.js +1 -0
- package/dist/plugins/store-contracts.d.ts +26 -1
- package/dist/plugins/store-contracts.js +3 -0
- package/dist/plugins/task-attachment-store.d.ts +112 -14
- package/dist/plugins/task-attachment-store.js +221 -28
- package/dist/plugins/workspace-fill.d.ts +60 -0
- package/dist/plugins/workspace-fill.js +106 -0
- package/dist/project-bundle.d.ts +38 -0
- package/dist/project-bundle.js +609 -0
- package/dist/run-local.js +2 -8
- package/dist/runs.js +1 -2
- package/dist/sandbox-egress-policy.d.ts +4 -1
- package/dist/sandbox-egress-policy.js +3 -1
- package/dist/sandbox-git-plane.d.ts +31 -12
- package/dist/sandbox-git-plane.js +24 -4
- package/dist/security.d.ts +9 -0
- package/dist/security.js +8 -0
- package/dist/session-error-wire.d.ts +24 -0
- package/dist/session-error-wire.js +7 -0
- package/dist/task-settings.d.ts +10 -2
- package/dist/task-settings.js +15 -2
- package/dist/terminal.d.ts +39 -19
- package/dist/terminal.js +65 -22
- package/dist/tool-approval.d.ts +4 -3
- package/dist/tool-approval.js +12 -14
- package/dist/trace/core-keyset-guard.d.ts +123 -6
- package/dist/trace/engine-notice-wire.d.ts +8 -2
- package/dist/trace/engine-notice-wire.js +4 -2
- package/dist/trace/exit-seat.d.ts +2 -1
- package/dist/trace/ledger-sink.d.ts +8 -4
- package/dist/trace/ledger-sink.js +2 -2
- package/dist/trace/project.d.ts +18 -1
- package/dist/trace/project.js +16 -0
- package/dist/trace/self-minted-wire.d.ts +251 -2
- package/dist/trace/self-minted-wire.js +82 -0
- package/dist/trace/wire-projection-faces.d.ts +1 -1
- package/dist/trace/wire-projection-faces.js +1 -1
- package/dist/web-admin-client/apply-effective.js +21 -1
- package/dist/web-admin-client/effective-keys.js +2 -0
- package/dist/web-admin-client/types.d.ts +4 -0
- package/package.json +1 -1
- package/wire-changes/server@7.142.0.json +639 -0
|
@@ -140,7 +140,7 @@ export declare const SELF_MINTED_WIRE: {
|
|
|
140
140
|
};
|
|
141
141
|
};
|
|
142
142
|
/**
|
|
143
|
-
* 审批问的**无人决终态归因**:`POST /v1/tasks/:taskId/asks/:askId/decision` 410 `gone.ask` 体的 `cause`(问账行 `denied_reason`
|
|
143
|
+
* 审批问的**无人决终态归因**:`POST /v1/tasks/:taskId/asks/:askId/decision` 410 `gone.ask` 体的 `cause`(问账行 `ending_cause` 列经终态成因读口读出的词;7.142.0 列由 `denied_reason` 按意义改名、触发成因另起 `park_trigger` 一列 —— wire 键与值域不变)。
|
|
144
144
|
* 词表属主 = `approval-deny-reasons.ts` 的 `APPROVAL_ENDING_CAUSES`(落这一列的那一子集 `AskRowEndingCause`;`satisfies Record<AskRowEndingCause, …>`:表加词而本行没跟 ⇒ tsc 红)。
|
|
145
145
|
* 7.124.0:键名 `deniedReason` → `cause`(硬破坏,零别名;值域不变 + `run_exited` / `batch_sibling_withdrawn` 两个新词)—— 老成员的属性格因此从 `-` 变成 `key:cause`(清单记 `changed`)。
|
|
146
146
|
* 7.116.0 +2:启动收敛(承载它的进程没了)的两个词 —— 与 `crashConvergedCause` 同词(同一问在两个读面上一个成因)。
|
|
@@ -702,6 +702,20 @@ export declare const SELF_MINTED_WIRE: {
|
|
|
702
702
|
attr: string;
|
|
703
703
|
since: string;
|
|
704
704
|
};
|
|
705
|
+
unreadable: {
|
|
706
|
+
attr: string;
|
|
707
|
+
since: string;
|
|
708
|
+
};
|
|
709
|
+
};
|
|
710
|
+
};
|
|
711
|
+
/** 会话列表行 `unreadable` 标记的整个键闭集:`errorCode` —— 读口打开这只会话时答的码(open 面那一张码表,与全局兜底同读)。 */
|
|
712
|
+
readonly sessionsListRowUnreadableKey: {
|
|
713
|
+
readonly at: "GET /v1/sessions sessions[].unreadable 键(<键> → 在场律)";
|
|
714
|
+
readonly members: {
|
|
715
|
+
errorCode: {
|
|
716
|
+
attr: string;
|
|
717
|
+
since: string;
|
|
718
|
+
};
|
|
705
719
|
};
|
|
706
720
|
};
|
|
707
721
|
/** `tool_end` 帧 `gate.disposition`(denied 臂)上的键(<臂>#<键> → 在场律;回放面 `GET /v1/runs/:id/events` 同读):`extension` —— hook 层拒且拒者的扩展注册名已知时 = 那张注册的名字(过出口座)。 */
|
|
@@ -940,9 +954,47 @@ export declare const SELF_MINTED_WIRE: {
|
|
|
940
954
|
};
|
|
941
955
|
};
|
|
942
956
|
};
|
|
957
|
+
/**
|
|
958
|
+
* `POST /v1/attachments` 上传项目包 mime(`application/vnd.sema.project-bundle`)而体过不了项目包的读者 ⇒ 400 `attachment.bundle_invalid`,拒体的 `reason`(一种拒因一个词;另带 `path` = 被拒条目的落点,读得出才在)。
|
|
959
|
+
* 词表属主 = `project-bundle.ts` 的 `PROJECT_BUNDLE_INVALID_REASONS`(唯一铸点 `readProjectBundle`,上传与播种同一只读者);`satisfies Record<ProjectBundleInvalidReason, …>`。行为钉:`test/project-bundle.test.ts`。
|
|
960
|
+
*/
|
|
961
|
+
readonly projectBundleInvalidReason: {
|
|
962
|
+
readonly at: "400 attachment.bundle_invalid reason(上传项目包 mime 的体过不了项目包的读者;另带 path?)";
|
|
963
|
+
readonly members: {
|
|
964
|
+
not_archive: {
|
|
965
|
+
attr: string;
|
|
966
|
+
since: string;
|
|
967
|
+
};
|
|
968
|
+
unsafe_path: {
|
|
969
|
+
attr: string;
|
|
970
|
+
since: string;
|
|
971
|
+
};
|
|
972
|
+
entry_type: {
|
|
973
|
+
attr: string;
|
|
974
|
+
since: string;
|
|
975
|
+
};
|
|
976
|
+
reserved_path: {
|
|
977
|
+
attr: string;
|
|
978
|
+
since: string;
|
|
979
|
+
};
|
|
980
|
+
duplicate_path: {
|
|
981
|
+
attr: string;
|
|
982
|
+
since: string;
|
|
983
|
+
};
|
|
984
|
+
expanded_too_large: {
|
|
985
|
+
attr: string;
|
|
986
|
+
since: string;
|
|
987
|
+
};
|
|
988
|
+
too_many_entries: {
|
|
989
|
+
attr: string;
|
|
990
|
+
since: string;
|
|
991
|
+
};
|
|
992
|
+
};
|
|
993
|
+
};
|
|
943
994
|
/**
|
|
944
995
|
* 提交幂等(契约 §0.7:幂等 = 资源行上的唯一键)上 wire 的面:同步腿读行重放体的 `replay` 键、两只按键读的读口、
|
|
945
|
-
* `Idempotency-Key` 命中一条读不到 / 不是这次 taskId 所指的行时的 409(7.125.0);同键异体(绑定那一行的请求体与这次不同)的 409(7.126.0)
|
|
996
|
+
* `Idempotency-Key` 命中一条读不到 / 不是这次 taskId 所指的行时的 409(7.125.0);同键异体(绑定那一行的请求体与这次不同)的 409(7.126.0);
|
|
997
|
+
* 同键重放体的信封(7.142.0 起 = 首答的信封;此前 = run 行读面,退役成员记在 `retired`)。
|
|
946
998
|
* 行为由 `test/submit-idempotency-one-ledger.test.ts` 钉。
|
|
947
999
|
*/
|
|
948
1000
|
readonly submitIdempotency: {
|
|
@@ -968,6 +1020,17 @@ export declare const SELF_MINTED_WIRE: {
|
|
|
968
1020
|
readonly attr: 409;
|
|
969
1021
|
readonly since: "7.126.0";
|
|
970
1022
|
};
|
|
1023
|
+
readonly "POST /v1/tasks|/v1/tasks/stream#replay_first_answer_envelope(\u540C\u952E\u91CD\u653E\u7684\u4F53 = \u9996\u7B54\u7684\u4FE1\u5C01 + replay: true:\u7EC8\u5C40 = \u5F15\u64CE\u7ED3\u679C(result \u662F\u4E32),\u505C\u9A7B = \u7ED3\u679C + \u56DE\u6267\u4E09\u952E,\u884C\u8FD8\u5728\u8DD1 = \u56DE\u6267\u4E09\u952E;\u6D41\u5F0F\u817F\u653E\u8FDB done.result)": {
|
|
1024
|
+
readonly attr: 200;
|
|
1025
|
+
readonly since: "7.142.0";
|
|
1026
|
+
};
|
|
1027
|
+
};
|
|
1028
|
+
readonly retired: {
|
|
1029
|
+
readonly "POST /v1/tasks|/v1/tasks/stream#replay_run_read_face(\u540C\u952E\u91CD\u653E\u7684\u4F53 = GET /v1/runs/:id \u7684\u8BFB\u9762 + replay: true:result \u662F\u5BF9\u8C61,\u5916\u52A0 status / errorCode / heldBy \u7B49\u8BFB\u9762\u952E)": {
|
|
1030
|
+
readonly attr: 200;
|
|
1031
|
+
readonly since: "7.125.0";
|
|
1032
|
+
readonly until: "7.142.0";
|
|
1033
|
+
};
|
|
971
1034
|
};
|
|
972
1035
|
};
|
|
973
1036
|
/**
|
|
@@ -1400,6 +1463,10 @@ export declare const SELF_MINTED_WIRE: {
|
|
|
1400
1463
|
readonly attr: 500;
|
|
1401
1464
|
readonly since: "7.139.0";
|
|
1402
1465
|
};
|
|
1466
|
+
readonly "POST /v1/approvals/:sessionId/decide#parked_principal_lane_not_permitted(\u505C\u9A7B\u8D4E\u56DE;\u5361\u7684\u4E3B\u4F53\u6B64\u523B\u4E0D\u88AB\u8BB8\u53EF\u672C\u90E8\u7F72\u7684\u6267\u884C\u8F66\u9053;approve \u4E0E deny \u540C\u7B54;\u8BA4\u9886\u4E4B\u524D,\u505C\u9A7B\u884C\u4E0D\u52A8\u3001\u5361\u4ECD\u5F85\u51B3;\u4F53 resume_blocked_by_policy + blockedBy execution_lane_not_allowed + allowedLanes + lane + retriable)": {
|
|
1467
|
+
readonly attr: 409;
|
|
1468
|
+
readonly since: "7.139.0";
|
|
1469
|
+
};
|
|
1403
1470
|
readonly "PATCH /v1/sessions/:id#mirror_row(\u53EA\u8BFB\u955C\u50CF\u884C\u4E0A\u7684\u5199,\u5E26\u4E0D\u5E26 expectedRowTag;\u4F53 conflict.session_mirror + forkPath)": {
|
|
1404
1471
|
readonly attr: 409;
|
|
1405
1472
|
readonly since: "7.139.0";
|
|
@@ -1432,6 +1499,18 @@ export declare const SELF_MINTED_WIRE: {
|
|
|
1432
1499
|
readonly attr: 400;
|
|
1433
1500
|
readonly since: "7.140.0";
|
|
1434
1501
|
};
|
|
1502
|
+
readonly "POST /v1/memory/sync/:scope#identity_undeclared(DB \u8BB0\u5FC6\u5E73\u9762\u6CA1\u58F0\u660E MEMORY_SYNC_SERVE_IDENTITY;\u9274\u6743\u4E4B\u540E;\u4F53 feature.memory_sync_serve_disabled)": {
|
|
1503
|
+
readonly attr: 501;
|
|
1504
|
+
readonly since: "7.142.0";
|
|
1505
|
+
};
|
|
1506
|
+
readonly "POST /v1/memory/sync/:scope#peer_not_declared_identity(peer \u4E0D\u662F\u540C\u6B65\u8EAB\u4EFD\u7684\u89C4\u8303\u5F62 / \u5E26\u51ED\u636E / \u975E http(s) / \u8D85\u5BBD / \u7A7A\u4E32;\u4F53 request.field_invalid + field peer + reason)": {
|
|
1507
|
+
readonly attr: 400;
|
|
1508
|
+
readonly since: "7.142.0";
|
|
1509
|
+
};
|
|
1510
|
+
readonly "POST /v1/memory/sync/:scope#peer_not_this_center(peer \u662F\u89C4\u8303\u5F62\u4F46\u4E0D\u7B49\u4E8E\u672C\u4E2D\u5FC3\u58F0\u660E\u7684\u8EAB\u4EFD;\u96F6\u8BFB\u96F6\u5199;\u4F53 config.memory_sync_target_mismatch)": {
|
|
1511
|
+
readonly attr: 409;
|
|
1512
|
+
readonly since: "7.142.0";
|
|
1513
|
+
};
|
|
1435
1514
|
};
|
|
1436
1515
|
};
|
|
1437
1516
|
/**
|
|
@@ -1486,6 +1565,77 @@ export declare const SELF_MINTED_WIRE: {
|
|
|
1486
1565
|
};
|
|
1487
1566
|
};
|
|
1488
1567
|
};
|
|
1568
|
+
/**
|
|
1569
|
+
* 同步身份「声明的身份」座位的拒因词(判序):形的四词逐字是契约包 URL 判官的词;`credential` = 规范化之后带凭据;`too-long` = 规范化之后装不进中心 `peer` 列(190);
|
|
1570
|
+
* `not-canonical` = 值本身没缺陷、但不是它自己的规范形。两张拒体同一张词表:会话记忆同步触发口的 `target`、中心侧同步口的 `peer`。
|
|
1571
|
+
*/
|
|
1572
|
+
readonly memorySyncIdentityFlaw: {
|
|
1573
|
+
readonly at: "400 request.field_invalid reason(POST /v1/sessions/:id/memory/sync 的 target · POST /v1/memory/sync/:scope 的 peer;另带 field)";
|
|
1574
|
+
readonly members: {
|
|
1575
|
+
"not-http-url": {
|
|
1576
|
+
attr: string;
|
|
1577
|
+
since: string;
|
|
1578
|
+
};
|
|
1579
|
+
userinfo: {
|
|
1580
|
+
attr: string;
|
|
1581
|
+
since: string;
|
|
1582
|
+
};
|
|
1583
|
+
query: {
|
|
1584
|
+
attr: string;
|
|
1585
|
+
since: string;
|
|
1586
|
+
};
|
|
1587
|
+
fragment: {
|
|
1588
|
+
attr: string;
|
|
1589
|
+
since: string;
|
|
1590
|
+
};
|
|
1591
|
+
credential: {
|
|
1592
|
+
attr: string;
|
|
1593
|
+
since: string;
|
|
1594
|
+
};
|
|
1595
|
+
"too-long": {
|
|
1596
|
+
attr: string;
|
|
1597
|
+
since: string;
|
|
1598
|
+
};
|
|
1599
|
+
"not-canonical": {
|
|
1600
|
+
attr: string;
|
|
1601
|
+
since: string;
|
|
1602
|
+
};
|
|
1603
|
+
};
|
|
1604
|
+
};
|
|
1605
|
+
/** 会话记忆同步触发口的 wire 面(`<面>#<键>` → 读法 / 在场律)。200 体 = 引擎 `memorySyncReportOf` 的产物原样(键属主在引擎);本仓不加汇总键。 */
|
|
1606
|
+
readonly sessionMemorySyncWire: {
|
|
1607
|
+
readonly at: "POST /v1/sessions/:id/memory/sync(<面>#<键> → 读法 / 在场律)";
|
|
1608
|
+
readonly members: {
|
|
1609
|
+
readonly "body#target": {
|
|
1610
|
+
readonly attr: "required;the only key;the target engine's GET /v1/capabilities memorySyncServe.identity verbatim;not a declared sync identity ⇒ 400 request.field_invalid";
|
|
1611
|
+
readonly since: "7.142.0";
|
|
1612
|
+
};
|
|
1613
|
+
readonly "200#target": {
|
|
1614
|
+
readonly attr: "always;engine report verbatim";
|
|
1615
|
+
readonly since: "7.142.0";
|
|
1616
|
+
};
|
|
1617
|
+
readonly "200#sourceRevision": {
|
|
1618
|
+
readonly attr: "always;the session leafId read in the same head read as the owner gate";
|
|
1619
|
+
readonly since: "7.142.0";
|
|
1620
|
+
};
|
|
1621
|
+
readonly "200#scopes": {
|
|
1622
|
+
readonly attr: "always;the read set: latest settled run's effectiveMemoryScopes (mounted ⇒ scope keys in serving order; memoryless / none ⇒ [])";
|
|
1623
|
+
readonly since: "7.142.0";
|
|
1624
|
+
};
|
|
1625
|
+
readonly "200#layers": {
|
|
1626
|
+
readonly attr: "present-iff no whole-round refusal;one entry per read-set layer the round ran (engine outcome synced | incomplete | refused | failed)";
|
|
1627
|
+
readonly since: "7.142.0";
|
|
1628
|
+
};
|
|
1629
|
+
readonly "200#refused": {
|
|
1630
|
+
readonly attr: "present-iff whole-round refusal;{code: config.memory_sync_target_mismatch | session_active, message}";
|
|
1631
|
+
readonly since: "7.142.0";
|
|
1632
|
+
};
|
|
1633
|
+
readonly "409 conflict.session_memory_unobserved#activeTaskId": {
|
|
1634
|
+
readonly attr: "present-iff the session has a run in flight";
|
|
1635
|
+
readonly since: "7.142.0";
|
|
1636
|
+
};
|
|
1637
|
+
};
|
|
1638
|
+
};
|
|
1489
1639
|
/**
|
|
1490
1640
|
* 拒体 / 应答体**句子的形**里本版换了或新增的(`<码>#<座>` → 句型)。句子是展示文本,机读分支按 `errorCode` / `field` / `reason`;本表登记的是「句型换了」,
|
|
1491
1641
|
* 给按字面匹配句子的消费方对账(码、状态、体键在这些成员上都没变,变的只有 `message`)。`attr` 写句型的骨架(`<…>` 是占位),旧句型写在 CHANGELOG 对应条里。
|
|
@@ -1764,6 +1914,10 @@ export declare const SELF_MINTED_WIRE: {
|
|
|
1764
1914
|
readonly attr: "store";
|
|
1765
1915
|
readonly since: "7.136.0";
|
|
1766
1916
|
};
|
|
1917
|
+
readonly MEMORY_SYNC_SERVE_IDENTITY: {
|
|
1918
|
+
readonly attr: "memory";
|
|
1919
|
+
readonly since: "7.142.0";
|
|
1920
|
+
};
|
|
1767
1921
|
};
|
|
1768
1922
|
};
|
|
1769
1923
|
/**
|
|
@@ -1787,6 +1941,101 @@ export declare const SELF_MINTED_WIRE: {
|
|
|
1787
1941
|
};
|
|
1788
1942
|
};
|
|
1789
1943
|
};
|
|
1944
|
+
/**
|
|
1945
|
+
* fleet 流 `hook_notice` / `hook_non_blocking_failure` 的 `reason`(附录 E.2)。前四词随这一族上 wire(7.48.0),`matcher_over_budget` 7.133.0;
|
|
1946
|
+
* `url_not_allowed`(7.142.0)= http 条目被 http hook 名单拦下、一个字节都没发(`hooks/hook-runner.ts` 的 http 腿,契约包判官答拦)。
|
|
1947
|
+
*/
|
|
1948
|
+
readonly hookNonBlockingFailureReason: {
|
|
1949
|
+
readonly at: "fleet stream hook_notice kind:hook_non_blocking_failure reason";
|
|
1950
|
+
readonly members: {
|
|
1951
|
+
exit_nonzero: {
|
|
1952
|
+
attr: string;
|
|
1953
|
+
since: string;
|
|
1954
|
+
};
|
|
1955
|
+
timeout: {
|
|
1956
|
+
attr: string;
|
|
1957
|
+
since: string;
|
|
1958
|
+
};
|
|
1959
|
+
spawn_failed: {
|
|
1960
|
+
attr: string;
|
|
1961
|
+
since: string;
|
|
1962
|
+
};
|
|
1963
|
+
bad_json: {
|
|
1964
|
+
attr: string;
|
|
1965
|
+
since: string;
|
|
1966
|
+
};
|
|
1967
|
+
matcher_over_budget: {
|
|
1968
|
+
attr: string;
|
|
1969
|
+
since: string;
|
|
1970
|
+
};
|
|
1971
|
+
url_not_allowed: {
|
|
1972
|
+
attr: string;
|
|
1973
|
+
since: string;
|
|
1974
|
+
};
|
|
1975
|
+
};
|
|
1976
|
+
};
|
|
1977
|
+
/** fleet 流 `hook_notice` / `hook_managed_unrun` 的 `reason`(附录 E.2-bis;这一族 7.133.0 上 wire)。`url_not_allowed`(7.142.0)同上一集:托管组的 http 条目被名单拦下 ⇒ 未跑成(失效关闭)。 */
|
|
1978
|
+
readonly hookManagedUnrunReason: {
|
|
1979
|
+
readonly at: "fleet stream hook_notice kind:hook_managed_unrun reason";
|
|
1980
|
+
readonly members: {
|
|
1981
|
+
matcher_invalid: {
|
|
1982
|
+
attr: string;
|
|
1983
|
+
since: string;
|
|
1984
|
+
};
|
|
1985
|
+
llm_carrier_unavailable: {
|
|
1986
|
+
attr: string;
|
|
1987
|
+
since: string;
|
|
1988
|
+
};
|
|
1989
|
+
llm_cap: {
|
|
1990
|
+
attr: string;
|
|
1991
|
+
since: string;
|
|
1992
|
+
};
|
|
1993
|
+
powershell_unsupported: {
|
|
1994
|
+
attr: string;
|
|
1995
|
+
since: string;
|
|
1996
|
+
};
|
|
1997
|
+
if_unevaluable: {
|
|
1998
|
+
attr: string;
|
|
1999
|
+
since: string;
|
|
2000
|
+
};
|
|
2001
|
+
budget_exhausted: {
|
|
2002
|
+
attr: string;
|
|
2003
|
+
since: string;
|
|
2004
|
+
};
|
|
2005
|
+
spawn_failed: {
|
|
2006
|
+
attr: string;
|
|
2007
|
+
since: string;
|
|
2008
|
+
};
|
|
2009
|
+
timeout: {
|
|
2010
|
+
attr: string;
|
|
2011
|
+
since: string;
|
|
2012
|
+
};
|
|
2013
|
+
exit_nonzero: {
|
|
2014
|
+
attr: string;
|
|
2015
|
+
since: string;
|
|
2016
|
+
};
|
|
2017
|
+
bad_json: {
|
|
2018
|
+
attr: string;
|
|
2019
|
+
since: string;
|
|
2020
|
+
};
|
|
2021
|
+
decision_out_of_set: {
|
|
2022
|
+
attr: string;
|
|
2023
|
+
since: string;
|
|
2024
|
+
};
|
|
2025
|
+
evidence_unavailable: {
|
|
2026
|
+
attr: string;
|
|
2027
|
+
since: string;
|
|
2028
|
+
};
|
|
2029
|
+
rewrite_unsettled: {
|
|
2030
|
+
attr: string;
|
|
2031
|
+
since: string;
|
|
2032
|
+
};
|
|
2033
|
+
url_not_allowed: {
|
|
2034
|
+
attr: string;
|
|
2035
|
+
since: string;
|
|
2036
|
+
};
|
|
2037
|
+
};
|
|
2038
|
+
};
|
|
1790
2039
|
/** 本仓在出口对 core 值做的变换(值变、键不变)。 */
|
|
1791
2040
|
readonly wireValueRule: {
|
|
1792
2041
|
readonly at: "出口值变换(<端点>#<键> → 变换)";
|
|
@@ -258,6 +258,13 @@ export const SELF_MINTED_WIRE = {
|
|
|
258
258
|
at: "GET /v1/sessions sessions[] 行键 = PATCH /v1/sessions/:id 200 体 = 409 conflict.session_row_changed currentRow(<键> → 在场律)",
|
|
259
259
|
members: {
|
|
260
260
|
rowTag: { attr: "present-iff the row can be written conditionally (the store has the row write primitive and the row carries an incarnation)", since: "7.139.0" },
|
|
261
|
+
unreadable: { attr: "present-iff the session head's leaf cannot be read (the file backend: the archive header is corrupt / truncated, or the archive cannot be read); the SQL backends never carry it; PATCH answers 500 for such a session before writing, so its 200 / 409 rows never carry it", since: "7.142.0" },
|
|
262
|
+
},
|
|
263
|
+
},
|
|
264
|
+
sessionsListRowUnreadableKey: {
|
|
265
|
+
at: "GET /v1/sessions sessions[].unreadable 键(<键> → 在场律)",
|
|
266
|
+
members: {
|
|
267
|
+
errorCode: { attr: "always; the errorCode GET /v1/sessions/:id answers for the same session (corrupt_session | internal.error today)", since: "7.142.0" },
|
|
261
268
|
},
|
|
262
269
|
},
|
|
263
270
|
toolEndGateDispositionKey: {
|
|
@@ -352,6 +359,18 @@ export const SELF_MINTED_WIRE = {
|
|
|
352
359
|
no_authorizer_session: { attr: "-", since: "7.137.0" },
|
|
353
360
|
},
|
|
354
361
|
},
|
|
362
|
+
projectBundleInvalidReason: {
|
|
363
|
+
at: "400 attachment.bundle_invalid reason(上传项目包 mime 的体过不了项目包的读者;另带 path?)",
|
|
364
|
+
members: {
|
|
365
|
+
not_archive: { attr: "-", since: "7.142.0" },
|
|
366
|
+
unsafe_path: { attr: "-", since: "7.142.0" },
|
|
367
|
+
entry_type: { attr: "-", since: "7.142.0" },
|
|
368
|
+
reserved_path: { attr: "-", since: "7.142.0" },
|
|
369
|
+
duplicate_path: { attr: "-", since: "7.142.0" },
|
|
370
|
+
expanded_too_large: { attr: "-", since: "7.142.0" },
|
|
371
|
+
too_many_entries: { attr: "-", since: "7.142.0" },
|
|
372
|
+
},
|
|
373
|
+
},
|
|
355
374
|
submitIdempotency: {
|
|
356
375
|
at: "提交幂等(<端点>#<面> → 应答状态)",
|
|
357
376
|
members: {
|
|
@@ -360,6 +379,10 @@ export const SELF_MINTED_WIRE = {
|
|
|
360
379
|
"GET /v1/leader?idempotencyKey": { attr: 200, since: "7.125.0" },
|
|
361
380
|
"POST /v1/runs|/v1/tasks Idempotency-Key#conflict.run_exists": { attr: 409, since: "7.125.0" },
|
|
362
381
|
"POST /v1/runs|/v1/tasks Idempotency-Key#conflict.idempotency_payload_mismatch": { attr: 409, since: "7.126.0" },
|
|
382
|
+
"POST /v1/tasks|/v1/tasks/stream#replay_first_answer_envelope(同键重放的体 = 首答的信封 + replay: true:终局 = 引擎结果(result 是串),停驻 = 结果 + 回执三键,行还在跑 = 回执三键;流式腿放进 done.result)": { attr: 200, since: "7.142.0" },
|
|
383
|
+
},
|
|
384
|
+
retired: {
|
|
385
|
+
"POST /v1/tasks|/v1/tasks/stream#replay_run_read_face(同键重放的体 = GET /v1/runs/:id 的读面 + replay: true:result 是对象,外加 status / errorCode / heldBy 等读面键)": { attr: 200, since: "7.125.0", until: "7.142.0" },
|
|
363
386
|
},
|
|
364
387
|
},
|
|
365
388
|
builtinScenario: {
|
|
@@ -503,6 +526,7 @@ export const SELF_MINTED_WIRE = {
|
|
|
503
526
|
"POST /v1/assistant/tasks/:id/plan_review#checkpointId_current(体带当前门的身份;受理形与不带键同)": { attr: 200, since: "7.137.0" },
|
|
504
527
|
"POST /v1/tasks|/v1/tasks/stream|/v1/runs#rewindFiles(新提交;体 request.body_shape + unknownKeys [rewindFiles])": { attr: 400, since: "7.139.0" },
|
|
505
528
|
"POST /v1/side-query#uncoded_error_with_preflight_prefix(没有引擎码、英文开头与前缀表同形的错误;体 internal.error)": { attr: 500, since: "7.139.0" },
|
|
529
|
+
"POST /v1/approvals/:sessionId/decide#parked_principal_lane_not_permitted(停驻赎回;卡的主体此刻不被许可本部署的执行车道;approve 与 deny 同答;认领之前,停驻行不动、卡仍待决;体 resume_blocked_by_policy + blockedBy execution_lane_not_allowed + allowedLanes + lane + retriable)": { attr: 409, since: "7.139.0" },
|
|
506
530
|
"PATCH /v1/sessions/:id#mirror_row(只读镜像行上的写,带不带 expectedRowTag;体 conflict.session_mirror + forkPath)": { attr: 409, since: "7.139.0" },
|
|
507
531
|
"PATCH /v1/sessions/:id#owner_changed_after_gate(门那一读之后同一会话的属主被改;体 not_found.session)": { attr: 404, since: "7.139.0" },
|
|
508
532
|
"PATCH /v1/sessions/:id#expectedRowTag_stale(行已不在那只标签上;体 conflict.session_row_changed + currentRow)": { attr: 409, since: "7.139.0" },
|
|
@@ -511,6 +535,9 @@ export const SELF_MINTED_WIRE = {
|
|
|
511
535
|
"POST /v1/memory/erase|POST /v1/sessions/:id/memory/erase#erasure_store_unjudged(抹除落到部署的店之外的那只店:点名的层住在个人挂载上,或按会话抹除而这只会话在另一只店有贡献 / 那只店的账读不出;体 memory.erasure_store_unjudged,什么都没删)": { attr: 409, since: "7.140.0" },
|
|
512
536
|
"POST /v1/memory/export|POST /v1/memory/import|GET /v1/memory/origin/external|POST /v1/memory/erase#layers_span_two_stores(请求点名的层分住两只店;体 request.memory_layer)": { attr: 400, since: "7.140.0" },
|
|
513
537
|
"记忆诸口 + POST /v1/admin/memory/consolidation/run|GET /v1/admin/memory/consolidation|GET /v1/memory/export|POST /v1/memory/sync/:scope#layer_unreadable(请求点名的层引擎读不出;体 request.memory_layer)": { attr: 400, since: "7.140.0" },
|
|
538
|
+
"POST /v1/memory/sync/:scope#identity_undeclared(DB 记忆平面没声明 MEMORY_SYNC_SERVE_IDENTITY;鉴权之后;体 feature.memory_sync_serve_disabled)": { attr: 501, since: "7.142.0" },
|
|
539
|
+
"POST /v1/memory/sync/:scope#peer_not_declared_identity(peer 不是同步身份的规范形 / 带凭据 / 非 http(s) / 超宽 / 空串;体 request.field_invalid + field peer + reason)": { attr: 400, since: "7.142.0" },
|
|
540
|
+
"POST /v1/memory/sync/:scope#peer_not_this_center(peer 是规范形但不等于本中心声明的身份;零读零写;体 config.memory_sync_target_mismatch)": { attr: 409, since: "7.142.0" },
|
|
514
541
|
},
|
|
515
542
|
},
|
|
516
543
|
memoryLayerSeatKey: {
|
|
@@ -535,6 +562,30 @@ export const SELF_MINTED_WIRE = {
|
|
|
535
562
|
delete_cursor: { attr: "-", since: "7.141.0" },
|
|
536
563
|
},
|
|
537
564
|
},
|
|
565
|
+
memorySyncIdentityFlaw: {
|
|
566
|
+
at: "400 request.field_invalid reason(POST /v1/sessions/:id/memory/sync 的 target · POST /v1/memory/sync/:scope 的 peer;另带 field)",
|
|
567
|
+
members: {
|
|
568
|
+
"not-http-url": { attr: "-", since: "7.142.0" },
|
|
569
|
+
userinfo: { attr: "-", since: "7.142.0" },
|
|
570
|
+
query: { attr: "-", since: "7.142.0" },
|
|
571
|
+
fragment: { attr: "-", since: "7.142.0" },
|
|
572
|
+
credential: { attr: "-", since: "7.142.0" },
|
|
573
|
+
"too-long": { attr: "-", since: "7.142.0" },
|
|
574
|
+
"not-canonical": { attr: "-", since: "7.142.0" },
|
|
575
|
+
},
|
|
576
|
+
},
|
|
577
|
+
sessionMemorySyncWire: {
|
|
578
|
+
at: "POST /v1/sessions/:id/memory/sync(<面>#<键> → 读法 / 在场律)",
|
|
579
|
+
members: {
|
|
580
|
+
"body#target": { attr: "required;the only key;the target engine's GET /v1/capabilities memorySyncServe.identity verbatim;not a declared sync identity ⇒ 400 request.field_invalid", since: "7.142.0" },
|
|
581
|
+
"200#target": { attr: "always;engine report verbatim", since: "7.142.0" },
|
|
582
|
+
"200#sourceRevision": { attr: "always;the session leafId read in the same head read as the owner gate", since: "7.142.0" },
|
|
583
|
+
"200#scopes": { attr: "always;the read set: latest settled run's effectiveMemoryScopes (mounted ⇒ scope keys in serving order; memoryless / none ⇒ [])", since: "7.142.0" },
|
|
584
|
+
"200#layers": { attr: "present-iff no whole-round refusal;one entry per read-set layer the round ran (engine outcome synced | incomplete | refused | failed)", since: "7.142.0" },
|
|
585
|
+
"200#refused": { attr: "present-iff whole-round refusal;{code: config.memory_sync_target_mismatch | session_active, message}", since: "7.142.0" },
|
|
586
|
+
"409 conflict.session_memory_unobserved#activeTaskId": { attr: "present-iff the session has a run in flight", since: "7.142.0" },
|
|
587
|
+
},
|
|
588
|
+
},
|
|
538
589
|
refusalSentenceForm: {
|
|
539
590
|
at: "拒体 message 的句型(<码>#<座> → 句型骨架;码 / 状态 / 机读位不变)",
|
|
540
591
|
members: {
|
|
@@ -626,6 +677,7 @@ export const SELF_MINTED_WIRE = {
|
|
|
626
677
|
at: "GET /v1/config/catalog rows[](<行名> → 域;只登本版新增的行)",
|
|
627
678
|
members: {
|
|
628
679
|
SEALED_KEY_DIR: { attr: "store", since: "7.136.0" },
|
|
680
|
+
MEMORY_SYNC_SERVE_IDENTITY: { attr: "memory", since: "7.142.0" },
|
|
629
681
|
},
|
|
630
682
|
},
|
|
631
683
|
deviceProtocolRevision: {
|
|
@@ -636,6 +688,36 @@ export const SELF_MINTED_WIRE = {
|
|
|
636
688
|
3: { attr: "+name_too_long", since: "7.137.0" },
|
|
637
689
|
},
|
|
638
690
|
},
|
|
691
|
+
hookNonBlockingFailureReason: {
|
|
692
|
+
at: "fleet stream hook_notice kind:hook_non_blocking_failure reason",
|
|
693
|
+
members: {
|
|
694
|
+
exit_nonzero: { attr: "-", since: "7.48.0" },
|
|
695
|
+
timeout: { attr: "-", since: "7.48.0" },
|
|
696
|
+
spawn_failed: { attr: "-", since: "7.48.0" },
|
|
697
|
+
bad_json: { attr: "-", since: "7.48.0" },
|
|
698
|
+
matcher_over_budget: { attr: "-", since: "7.133.0" },
|
|
699
|
+
url_not_allowed: { attr: "-", since: "7.142.0" },
|
|
700
|
+
},
|
|
701
|
+
},
|
|
702
|
+
hookManagedUnrunReason: {
|
|
703
|
+
at: "fleet stream hook_notice kind:hook_managed_unrun reason",
|
|
704
|
+
members: {
|
|
705
|
+
matcher_invalid: { attr: "-", since: "7.133.0" },
|
|
706
|
+
llm_carrier_unavailable: { attr: "-", since: "7.133.0" },
|
|
707
|
+
llm_cap: { attr: "-", since: "7.133.0" },
|
|
708
|
+
powershell_unsupported: { attr: "-", since: "7.133.0" },
|
|
709
|
+
if_unevaluable: { attr: "-", since: "7.133.0" },
|
|
710
|
+
budget_exhausted: { attr: "-", since: "7.133.0" },
|
|
711
|
+
spawn_failed: { attr: "-", since: "7.133.0" },
|
|
712
|
+
timeout: { attr: "-", since: "7.133.0" },
|
|
713
|
+
exit_nonzero: { attr: "-", since: "7.133.0" },
|
|
714
|
+
bad_json: { attr: "-", since: "7.133.0" },
|
|
715
|
+
decision_out_of_set: { attr: "-", since: "7.133.0" },
|
|
716
|
+
evidence_unavailable: { attr: "-", since: "7.133.0" },
|
|
717
|
+
rewrite_unsettled: { attr: "-", since: "7.133.0" },
|
|
718
|
+
url_not_allowed: { attr: "-", since: "7.142.0" },
|
|
719
|
+
},
|
|
720
|
+
},
|
|
639
721
|
wireValueRule: {
|
|
640
722
|
at: "出口值变换(<端点>#<键> → 变换)",
|
|
641
723
|
members: {
|
|
@@ -243,7 +243,7 @@ export declare const WIRE_PROJECTION_FACES: {
|
|
|
243
243
|
readonly projector: "engineNoticeEventData";
|
|
244
244
|
readonly coreType: "EngineNotice";
|
|
245
245
|
readonly excluded: readonly [];
|
|
246
|
-
readonly minted: readonly ["ts"];
|
|
246
|
+
readonly minted: readonly ["ts", "eventId"];
|
|
247
247
|
};
|
|
248
248
|
readonly memory_import_report: {
|
|
249
249
|
readonly projector: "buildImportReportWire";
|
|
@@ -71,7 +71,7 @@ export const WIRE_PROJECTION_FACES = {
|
|
|
71
71
|
return WIRE_PROJECTION_FACES.wiring_manifest_tenant.mintedConditional;
|
|
72
72
|
},
|
|
73
73
|
},
|
|
74
|
-
engine_notice: { projector: "engineNoticeEventData", coreType: "EngineNotice", excluded: [], minted: ["ts"] },
|
|
74
|
+
engine_notice: { projector: "engineNoticeEventData", coreType: "EngineNotice", excluded: [], minted: ["ts", "eventId"] },
|
|
75
75
|
memory_import_report: { projector: "buildImportReportWire", coreType: "MemoryImportReport", excluded: [], minted: [] },
|
|
76
76
|
origin_clearance_row: {
|
|
77
77
|
projector: "buildClearanceRowWire",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { expandTiers, modelOriginOf, resolveTaskModel as coreResolveTaskModel } from "@sema-agent/core";
|
|
2
|
-
import { CATALOG_REPLACES_ENV_MODELS_CODE, WEB_ADMIN_ENV, narrowAtMention, resolveActiveTiers, resolveCatalogDefaultModel } from "@sema-agent/settings-schema";
|
|
2
|
+
import { CATALOG_REPLACES_ENV_MODELS_CODE, SandboxGitConfig, WEB_ADMIN_ENV, formatConfigPath, narrowAtMention, resolveActiveTiers, resolveCatalogDefaultModel, sanitizeZodError } from "@sema-agent/settings-schema";
|
|
3
3
|
import { modelKeyPoison } from "../key-resolver.js";
|
|
4
4
|
import { buildEnvModelIdNotServedNotice, mintCapabilityKeys, readAtMention, servedModelTableLeg } from "../model-select.js";
|
|
5
5
|
import { applyAutoCompactWindow, buildModelCostKey, ownCredentialHitsInForce, parseAutonomy, unmatchableToolNamesRefusal } from "../config.js";
|
|
@@ -135,6 +135,7 @@ export function applyEffective(config, eff, logger, opts) {
|
|
|
135
135
|
}
|
|
136
136
|
}
|
|
137
137
|
const servedBefore = servedModelTableLeg(config);
|
|
138
|
+
const sandboxGitBefore = config.sandboxGit;
|
|
138
139
|
commitStaged(config, staged);
|
|
139
140
|
if (ordered)
|
|
140
141
|
appliedGeneration.set(config, gen);
|
|
@@ -169,6 +170,8 @@ export function applyEffective(config, eff, logger, opts) {
|
|
|
169
170
|
logger?.info("web_admin_runtime_hot", staged.hot.infoLine);
|
|
170
171
|
if (Object.keys(staged.projects).length > 0)
|
|
171
172
|
logger?.info("web_admin_projects", { projects: Object.keys(staged.projects) });
|
|
173
|
+
if (JSON.stringify(sandboxGitBefore) !== JSON.stringify(staged.sandboxGit))
|
|
174
|
+
logger?.info("web_admin_sandbox_git", { version: staged.version, origins: staged.sandboxGit?.origins.map((e) => e.origin) ?? null });
|
|
172
175
|
return true;
|
|
173
176
|
}
|
|
174
177
|
function declareCandidateWithheldEnv(seats, modelApiKeyEnv, version) {
|
|
@@ -216,6 +219,10 @@ function commitStaged(config, staged) {
|
|
|
216
219
|
if (staged.hot.setCommandPolicy)
|
|
217
220
|
config.commandPolicy = staged.hot.commandPolicyNext;
|
|
218
221
|
mutateInPlace(config.projects, staged.projects);
|
|
222
|
+
if (staged.sandboxGit !== undefined)
|
|
223
|
+
config.sandboxGit = staged.sandboxGit;
|
|
224
|
+
else
|
|
225
|
+
delete config.sandboxGit;
|
|
219
226
|
}
|
|
220
227
|
export const MODEL_PLANE_DOMAINS = ["models"];
|
|
221
228
|
const MODEL_PLANE_SURFACES = {
|
|
@@ -472,6 +479,7 @@ function stageEffective(config, eff, logger, opts) {
|
|
|
472
479
|
...(Array.isArray(r.defaultScopes) ? { defaultScopes: r.defaultScopes.filter((x) => typeof x === "string") } : {}),
|
|
473
480
|
};
|
|
474
481
|
}
|
|
482
|
+
const sandboxGit = stageSandboxGit(eff, logger);
|
|
475
483
|
return {
|
|
476
484
|
version: typeof eff.version === "number" && Number.isFinite(eff.version) ? eff.version : 0,
|
|
477
485
|
modelPlaneGroup,
|
|
@@ -479,8 +487,20 @@ function stageEffective(config, eff, logger, opts) {
|
|
|
479
487
|
limits,
|
|
480
488
|
hot,
|
|
481
489
|
projects,
|
|
490
|
+
sandboxGit,
|
|
482
491
|
};
|
|
483
492
|
}
|
|
493
|
+
const SANDBOX_GIT_REFUSED_EFFECT = "the block is read as routing no git origins (the sandbox git plane reads no_origins; no new sandbox pod carries the credential broker) — the rest of this candidate applies; fix the block at the console (it is judged by the contract's SandboxGitConfig)";
|
|
494
|
+
function stageSandboxGit(eff, logger) {
|
|
495
|
+
if (eff.sandboxGit === undefined)
|
|
496
|
+
return undefined;
|
|
497
|
+
const judged = SandboxGitConfig.safeParse(eff.sandboxGit);
|
|
498
|
+
if (judged.success)
|
|
499
|
+
return judged.data;
|
|
500
|
+
const issues = sanitizeZodError(judged.error).issues.map((i) => `${i.path.length === 0 ? "sandboxGit" : `sandboxGit.${formatConfigPath(i.path.map((seg) => (typeof seg === "number" ? seg : String(seg))))}`}: ${i.message}`);
|
|
501
|
+
logger?.warn("web_admin_sandbox_git_refused", { version: typeof eff.version === "number" ? eff.version : 0, issues, effect: SANDBOX_GIT_REFUSED_EFFECT });
|
|
502
|
+
return undefined;
|
|
503
|
+
}
|
|
484
504
|
export function centerManagedConfigKeys(eff) {
|
|
485
505
|
const out = new Set();
|
|
486
506
|
if (!eff)
|
|
@@ -13,6 +13,7 @@ const EFFECTIVE_CONFIG_KEY_TABLE = {
|
|
|
13
13
|
plugins: true,
|
|
14
14
|
readFace: true,
|
|
15
15
|
prompts: true,
|
|
16
|
+
sandboxGit: true,
|
|
16
17
|
};
|
|
17
18
|
export const EFFECTIVE_CONFIG_KEYS = Object.keys(EFFECTIVE_CONFIG_KEY_TABLE);
|
|
18
19
|
export const EFFECTIVE_ENVELOPE_KEYS = ["version", "updatedAt"];
|
|
@@ -25,6 +26,7 @@ export const GOVERNANCE_DOMAIN_KEYS = Object.keys(GOVERNANCE_DOMAIN_KEY_TABLE);
|
|
|
25
26
|
export const NON_DOMAIN_EFFECTIVE_KEYS = {
|
|
26
27
|
a2a: "R-15 裁开域([4384]),但 settings-schema 至 1.3.0 未开(DOMAINS 无 a2a)——S-31 件2 BLOCKED on schema:远端腿靠 readEffectiveWire 的 open-world verbatim 透传(DESIGN-269),本地腿不可达(FileConfigStore 只读 PORTABLE_DOMAINS)。schema 开域之日按墓碑流程收线。",
|
|
27
28
|
readFace: "R-15 裁**暂不开域**([4384]:env 逐键恒赢语义下收益薄,⚪ 呈现制过渡)——#A4 的远端腿同靠 open-world 透传;本地腿四键由 env / 引擎默认独占。若来日改裁开域,同上墓碑机制。",
|
|
29
|
+
sandboxGit: "契约的 wire-only 键(settings-schema 14.7.0 `EffectiveWire.sandboxGit`):web-admin 按部署登记册投影,不是存储域 —— `buildEffective` 从不产它、`readEffectiveWire` 逐字承运;判它的唯一座位 `SandboxGitConfig` 在 stageEffective 调一次。本地腿不可达(`config.d` 只读便携域)⇒ 本地配置源恒缺席(沙箱 git 平面读 `no_origins`)。",
|
|
28
30
|
};
|
|
29
31
|
export const DOMAINS_NOT_CONSUMED_BY_SERVER = {
|
|
30
32
|
rosters: "center 写面域:center 端 resolveEffectiveForWorker 把 roster 解析进 per-worker /effective 的 models 视图——server 消费的是解析产物,不读原始域。",
|
|
@@ -392,6 +392,10 @@ export interface EffectiveConfig {
|
|
|
392
392
|
/** prompts 域(中心层;wire 形只有一种 = 契约包 `EffectivePromptsWire` `{ schemaVersion: 2, artifact }`)—— 判法只在候选判官一处
|
|
393
393
|
* (`prompts-domain-validate.ts` 的 `judgePromptsWire`,经 `judgeConfigCandidate`),本 interface 只声明键位存在(unknown:判官是唯一解释者,这里不复刻形)。 */
|
|
394
394
|
prompts?: unknown;
|
|
395
|
+
/** 沙箱 git 平面的有效配置块(契约 `EffectiveWire.sandboxGit`:wire-only 的非域顶层键,web-admin 按部署登记册投影,读腿逐字承运、不判)——
|
|
396
|
+
* 可选、无默认:缺席 = 这个部署没有投影这一块。本 interface 只声明键位(unknown:与 `prompts` 同形);判它的唯一座位是契约 `SandboxGitConfig`,
|
|
397
|
+
* 在 `stageEffective` 里调一次(判过 ⇒ `config.sandboxGit`;判不过 ⇒ 当作没有任何 origin + 一行 `web_admin_sandbox_git_refused`,契约 §12.8)。 */
|
|
398
|
+
sandboxGit?: unknown;
|
|
395
399
|
}
|
|
396
400
|
/** (stage7 P5,registry-core 0.8 `execution` 域): the center-resolved per-principal execution
|
|
397
401
|
* ruling riding the caps view. `required=false` / ruling absent = no enforcement (legacy). `allowedLanes` is
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sema-agent/server",
|
|
3
|
-
"version": "7.
|
|
3
|
+
"version": "7.142.0",
|
|
4
4
|
"description": "Sema Server — the server/API implementation layer for Sema, wiring core, registry, model providers, and cloud agent execution. Built on @sema-agent/core.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "BUSL-1.1",
|