evolcore 0.0.20 → 0.0.22
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 +65 -0
- package/README.md +58 -9
- package/bin/codex-managed-hook.mjs +3 -0
- package/bin/install-codex-managed-hooks.mjs +3 -1
- package/dist/agents/baseagent.js +10 -6
- package/dist/agents/claude-runner.js +393 -108
- package/dist/agents/codex-app-server-client.js +41 -7
- package/dist/agents/codex-runner.js +1292 -220
- package/dist/agents/ecagent-runner.js +171 -61
- package/dist/agents/gemini-runner.js +130 -30
- package/dist/agents/request-identity.js +25 -0
- package/dist/agents/runner-types.js +19 -0
- package/dist/aun/aid/agentmd.js +59 -2
- package/dist/aun/aid/identity.js +4 -1
- package/dist/aun/aid/index.js +1 -1
- package/dist/aun/msg/group.js +72 -6
- package/dist/aun/msg/history.js +213 -36
- package/dist/aun/msg/managed-operation.js +58 -9
- package/dist/aun/msg/p2p.js +5 -0
- package/dist/aun/outbox.js +189 -80
- package/dist/aun/service-proxy.js +43 -25
- package/dist/channels/aun.js +618 -123
- package/dist/channels/daemon.js +6 -1
- package/dist/cli/agent-command.js +4 -3
- package/dist/cli/agent.js +66 -56
- package/dist/cli/aun-commands.js +177 -42
- package/dist/cli/command-log.js +10 -11
- package/dist/cli/contact.js +1 -0
- package/dist/cli/daemon-commands.js +98 -123
- package/dist/cli/init.js +27 -15
- package/dist/cli/task-context.js +50 -0
- package/dist/cli/trigger-command.js +14 -5
- package/dist/cli/watch-logs.js +10 -3
- package/dist/config/builtin-roles.js +1 -0
- package/dist/config/config-field-policy.js +19 -5
- package/dist/config/config-manager.js +167 -22
- package/dist/config/contact-book-store.js +25 -3
- package/dist/config/contact-operation-service.js +32 -1
- package/dist/config/contact-request-service.js +44 -0
- package/dist/config/daemon-services.js +186 -0
- package/dist/config/gateway-config.js +20 -9
- package/dist/config/role-service.js +54 -3
- package/dist/config/schema-migration.js +550 -0
- package/dist/config-store.js +151 -9
- package/dist/core/agent-application-service.js +279 -0
- package/dist/core/audit/log-integrity.js +102 -0
- package/dist/core/auth/agent-delegation.js +43 -1
- package/dist/core/auth/auth-gateway.js +41 -4
- package/dist/core/auth/authorization-audit.js +216 -8
- package/dist/core/auth/operation-authorizer.js +41 -1
- package/dist/core/auth/operation-catalog.js +9 -1
- package/dist/core/bootstrap-messages.js +8 -0
- package/dist/core/bootstrap-service.js +99 -27
- package/dist/core/causation/aun-association.js +7 -4
- package/dist/core/command/agent-control.js +56 -16
- package/dist/core/command/command-handler.js +311 -44
- package/dist/core/command/connect-menu.js +3 -4
- package/dist/core/command/group-menu.js +5 -7
- package/dist/core/command/menu-handler.js +288 -80
- package/dist/core/command/menu-protocol.js +1 -1
- package/dist/core/command/role-menu.js +21 -11
- package/dist/core/command/slash-gate.js +85 -18
- package/dist/core/command/slash-handler.js +377 -36
- package/dist/core/data-migration.js +11 -1
- package/dist/core/event-catalog.js +37 -0
- package/dist/core/evolagent.js +4 -0
- package/dist/core/handoff/dispatcher.js +4 -0
- package/dist/core/handoff/runtime.js +33 -3
- package/dist/core/handoff/store.js +32 -9
- package/dist/core/inference/text-inference.js +7 -15
- package/dist/core/message/im-renderer.js +90 -87
- package/dist/core/message/{inbound-admission.js → message-admission.js} +51 -1
- package/dist/core/message/message-bridge.js +184 -12
- package/dist/core/message/message-log.js +47 -7
- package/dist/core/message/message-queue.js +227 -16
- package/dist/core/message/message-utils.js +12 -5
- package/dist/core/message/response-engine.js +658 -109
- package/dist/core/message/send-receipt.js +1 -0
- package/dist/core/message/stream-debouncer.js +9 -2
- package/dist/core/model/model-catalog.js +23 -15
- package/dist/core/model/model-diagnostics.js +28 -10
- package/dist/core/permission/approval-gateway.js +180 -6
- package/dist/core/permission/ec-command-parser.js +627 -69
- package/dist/core/permission/mode.js +18 -3
- package/dist/core/{protected-paths.js → permission/protected-paths.js} +27 -14
- package/dist/core/permission/readonly-shell-query.js +263 -9
- package/dist/core/permission/sandbox-runtime.js +159 -1
- package/dist/core/permission/tool-error-code.js +12 -0
- package/dist/core/permission/tool-policy.js +618 -23
- package/dist/core/session/session-fs-store.js +154 -5
- package/dist/core/session/session-manager.js +329 -30
- package/dist/core/session/session-renew.js +37 -13
- package/dist/core/session/session-turn-coordinator.js +16 -5
- package/dist/eck/kit-renderer.js +1 -1
- package/dist/index.js +316 -50
- package/dist/ipc.js +459 -29
- package/dist/paths.js +82 -7
- package/dist/response-system/context-builder.js +1 -7
- package/dist/response-system/engines/v1/proactive-flow.js +7 -2
- package/dist/stats/price-resolver.js +4 -0
- package/dist/trigger/anomaly-store.js +1 -0
- package/dist/trigger/feedback.js +70 -7
- package/dist/trigger/history.js +79 -4
- package/dist/trigger/legacy-session-history.js +2 -2
- package/dist/trigger/parser.js +13 -3
- package/dist/trigger/scheduler.js +20 -3
- package/dist/trigger/validation.js +6 -1
- package/dist/utils/atomic-write.js +27 -0
- package/dist/utils/ecweb-utils.js +16 -2
- package/dist/utils/error-utils.js +4 -1
- package/dist/utils/logger.js +30 -6
- package/dist/utils/process-tree-stats.js +24 -4
- package/dist/utils/process-tree-worker.js +31 -0
- package/dist/utils/project-path.js +1 -2
- package/dist/utils/tool-summary.js +59 -0
- package/dist/utils/windows-shell-trust.js +201 -0
- package/kits/docs/INDEX.md +1 -1
- package/kits/docs/evolcore/INDEX.md +3 -3
- package/kits/docs/evolcore/agent-create.md +146 -0
- package/kits/docs/evolcore/agent.md +6 -0
- package/kits/docs/evolcore/contact.md +7 -1
- package/kits/docs/evolcore/group-collaboration.md +251 -0
- package/kits/docs/evolcore/group-rules.md +1 -19
- package/kits/docs/evolcore/group.md +3 -1
- package/kits/docs/evolcore/msg.md +16 -0
- package/kits/docs/evolcore/trigger.md +6 -3
- package/kits/docs/prompt-loading-architecture.md +6 -0
- package/kits/eck_message_manifest.json +6 -6
- package/kits/schemas/_meta.json +7 -4
- package/kits/schemas/agent-config.schema.11.json +13 -0
- package/kits/schemas/agent-config.schema.12.json +427 -0
- package/kits/schemas/daemon.schema.5.json +0 -1
- package/kits/schemas/daemon.schema.6.json +131 -0
- package/kits/schemas/defaults.schema.5.json +15 -3
- package/kits/schemas/migrations/README.md +3 -1
- package/kits/schemas/relation-config.schema.8.json +13 -0
- package/kits/schemas/role-config.schema.1.json +1 -2
- package/kits/schemas/single-session.schema.3.json +32 -0
- package/kits/templates/message-fragments/item.md +1 -1
- package/kits/templates/roles/admin.json +1 -0
- package/kits/templates/roles/member.json +1 -0
- package/kits/templates/roles/visitor.json +1 -0
- package/kits/templates/system-fragments/bootstrap.md +2 -1
- package/kits/templates/system-fragments/commands.md +2 -2
- package/package.json +6 -3
- package/skills/eclink/SKILL.md +2 -0
- package/dist/config/aun-gateway-config.js +0 -2
|
@@ -195,7 +195,20 @@
|
|
|
195
195
|
"type": "object",
|
|
196
196
|
"propertyNames": { "minLength": 1 },
|
|
197
197
|
"additionalProperties": { "type": "string" }
|
|
198
|
+
},
|
|
199
|
+
"auxiliaryModel": {
|
|
200
|
+
"type": "string",
|
|
201
|
+
"minLength": 1,
|
|
202
|
+
"description": "Session Renew 语义连续性判断使用的 direct 辅助模型。"
|
|
203
|
+
},
|
|
204
|
+
"auxiliaryEffort": {
|
|
205
|
+
"type": "string",
|
|
206
|
+
"enum": ["low", "medium", "high", "xhigh", "max"],
|
|
207
|
+
"description": "Session Renew 辅助模型的可选推理强度。"
|
|
198
208
|
}
|
|
209
|
+
},
|
|
210
|
+
"dependencies": {
|
|
211
|
+
"auxiliaryEffort": ["auxiliaryModel"]
|
|
199
212
|
}
|
|
200
213
|
}
|
|
201
214
|
},
|
|
@@ -0,0 +1,427 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"$id": "agent-config.schema.12.json",
|
|
4
|
+
"title": "AgentConfig v12 (agents/{aid}/config.json)",
|
|
5
|
+
"description": "Agent v12 主配置。备用模型链只允许在 defaults.json 定义。",
|
|
6
|
+
"x-logical-name": "agent-config",
|
|
7
|
+
"x-scope": "agent",
|
|
8
|
+
"type": "object",
|
|
9
|
+
"additionalProperties": true,
|
|
10
|
+
"not": {
|
|
11
|
+
"description": "禁止旧权限字段和已迁移到 relation role 的 admins。",
|
|
12
|
+
"anyOf": [
|
|
13
|
+
{
|
|
14
|
+
"description": "禁止旧版顶层 permissionMode;权限模式由独立角色策略决定。",
|
|
15
|
+
"required": [
|
|
16
|
+
"permissionMode"
|
|
17
|
+
]
|
|
18
|
+
},
|
|
19
|
+
{
|
|
20
|
+
"description": "禁止旧版内嵌 roles;角色定义和默认角色已迁移到独立 roles/ 配置域。",
|
|
21
|
+
"required": [
|
|
22
|
+
"roles"
|
|
23
|
+
]
|
|
24
|
+
},
|
|
25
|
+
{
|
|
26
|
+
"description": "admin 关系身份由 AUN 私聊 relation role 管理。",
|
|
27
|
+
"required": [
|
|
28
|
+
"admins"
|
|
29
|
+
]
|
|
30
|
+
},
|
|
31
|
+
{
|
|
32
|
+
"description": "debug 是 daemon 进程级配置,不进入 Agent 覆盖链。",
|
|
33
|
+
"required": [
|
|
34
|
+
"debug"
|
|
35
|
+
]
|
|
36
|
+
}
|
|
37
|
+
]
|
|
38
|
+
},
|
|
39
|
+
"required": [
|
|
40
|
+
"aid",
|
|
41
|
+
"channels"
|
|
42
|
+
],
|
|
43
|
+
"properties": {
|
|
44
|
+
"$schema_version": {
|
|
45
|
+
"type": "number",
|
|
46
|
+
"const": 12,
|
|
47
|
+
"default": 12,
|
|
48
|
+
"x-merge": "scalar",
|
|
49
|
+
"description": "配置 Schema 版本;v12 添加 Agent 级群聊 slash 提及校验开关"
|
|
50
|
+
},
|
|
51
|
+
"aid": {
|
|
52
|
+
"type": "string",
|
|
53
|
+
"x-merge": "scalar",
|
|
54
|
+
"description": "Agent 的全局唯一身份标识"
|
|
55
|
+
},
|
|
56
|
+
"enabled": {
|
|
57
|
+
"type": "boolean",
|
|
58
|
+
"default": true,
|
|
59
|
+
"x-merge": "scalar",
|
|
60
|
+
"description": "是否启用 Agent;缺省按启用处理"
|
|
61
|
+
},
|
|
62
|
+
"lifecycle": {
|
|
63
|
+
"type": "string",
|
|
64
|
+
"default": "active",
|
|
65
|
+
"enum": [
|
|
66
|
+
"created",
|
|
67
|
+
"bootstrapping",
|
|
68
|
+
"active"
|
|
69
|
+
],
|
|
70
|
+
"x-merge": "scalar",
|
|
71
|
+
"description": "agent 生命周期状态;缺失时按 active 处理",
|
|
72
|
+
"x-enumDescriptions": {
|
|
73
|
+
"created": "已创建,尚未进入引导流程",
|
|
74
|
+
"bootstrapping": "引导中(初始化配置/身份)",
|
|
75
|
+
"active": "已激活,正常运行"
|
|
76
|
+
}
|
|
77
|
+
},
|
|
78
|
+
"initialized": {
|
|
79
|
+
"type": "boolean",
|
|
80
|
+
"x-merge": "scalar",
|
|
81
|
+
"description": "是否已完成 Agent 初始化流程"
|
|
82
|
+
},
|
|
83
|
+
"owners": {
|
|
84
|
+
"type": "array",
|
|
85
|
+
"items": {
|
|
86
|
+
"type": "string",
|
|
87
|
+
"description": "一个 Agent owner 的身份标识,通常为 AID。"
|
|
88
|
+
},
|
|
89
|
+
"uniqueItems": true,
|
|
90
|
+
"x-merge": "list",
|
|
91
|
+
"description": "Agent 所有者身份列表;用于 owner 级控制和通知"
|
|
92
|
+
},
|
|
93
|
+
"access": {
|
|
94
|
+
"type": "object",
|
|
95
|
+
"x-merge": "dict",
|
|
96
|
+
"additionalProperties": false,
|
|
97
|
+
"required": [
|
|
98
|
+
"policyMode",
|
|
99
|
+
"requestLimit"
|
|
100
|
+
],
|
|
101
|
+
"properties": {
|
|
102
|
+
"policyMode": {
|
|
103
|
+
"type": "string",
|
|
104
|
+
"enum": [
|
|
105
|
+
"open",
|
|
106
|
+
"contacts",
|
|
107
|
+
"owners"
|
|
108
|
+
],
|
|
109
|
+
"description": "私聊和群聊准入策略:开放、仅联系人或仅 Owner。"
|
|
110
|
+
},
|
|
111
|
+
"requestLimit": {
|
|
112
|
+
"type": "object",
|
|
113
|
+
"additionalProperties": false,
|
|
114
|
+
"required": [
|
|
115
|
+
"maxTimes",
|
|
116
|
+
"coolDown"
|
|
117
|
+
],
|
|
118
|
+
"properties": {
|
|
119
|
+
"maxTimes": {
|
|
120
|
+
"type": "integer",
|
|
121
|
+
"minimum": 1,
|
|
122
|
+
"maximum": 100000,
|
|
123
|
+
"description": "每个 Agent、每个渠道实例在窗口内最多发送的准入控制消息数。"
|
|
124
|
+
},
|
|
125
|
+
"coolDown": {
|
|
126
|
+
"type": "integer",
|
|
127
|
+
"minimum": 1,
|
|
128
|
+
"maximum": 86400,
|
|
129
|
+
"description": "准入控制消息限额的冷却窗口,单位秒。"
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
},
|
|
134
|
+
"description": "Agent 自身的消息准入策略;不参与 defaults 或 relation 覆盖链。"
|
|
135
|
+
},
|
|
136
|
+
"channels": {
|
|
137
|
+
"type": "array",
|
|
138
|
+
"items": {
|
|
139
|
+
"type": "object",
|
|
140
|
+
"allOf": [
|
|
141
|
+
{
|
|
142
|
+
"if": {
|
|
143
|
+
"properties": { "type": { "const": "aun" } },
|
|
144
|
+
"required": ["type"]
|
|
145
|
+
},
|
|
146
|
+
"then": { "not": { "required": ["gatewayUrl"] } }
|
|
147
|
+
}
|
|
148
|
+
],
|
|
149
|
+
"description": "一个渠道实例配置;具体字段由渠道类型及其适配器定义。"
|
|
150
|
+
},
|
|
151
|
+
"x-merge": "list",
|
|
152
|
+
"description": "Agent 绑定的消息渠道实例列表"
|
|
153
|
+
},
|
|
154
|
+
"aun": {
|
|
155
|
+
"type": "object",
|
|
156
|
+
"x-merge": "dict",
|
|
157
|
+
"description": "Agent 级 AUN 通信配置",
|
|
158
|
+
"properties": {
|
|
159
|
+
"gatewayUrl": {
|
|
160
|
+
"not": {},
|
|
161
|
+
"description": "已移除;网关由 fastaun 缓存和 AID discovery 决定"
|
|
162
|
+
},
|
|
163
|
+
"defaultEncrypt": {
|
|
164
|
+
"not": {},
|
|
165
|
+
"description": "不支持在 Agent 配置;请使用 daemon.json.aun.defaultEncrypt"
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
},
|
|
169
|
+
"models": {
|
|
170
|
+
"type": "object",
|
|
171
|
+
"x-merge": "dict",
|
|
172
|
+
"description": "Agent 级模型别名、注册表或模型覆盖配置"
|
|
173
|
+
},
|
|
174
|
+
"active_baseagent": {
|
|
175
|
+
"type": "string",
|
|
176
|
+
"x-merge": "scalar",
|
|
177
|
+
"description": "默认使用的 base agent 标识,例如 claude 或 codex"
|
|
178
|
+
},
|
|
179
|
+
"baseagents": {
|
|
180
|
+
"type": "object",
|
|
181
|
+
"x-merge": "dict",
|
|
182
|
+
"description": "各 base agent 的模型、推理强度及运行参数;备用模型链只能在 defaults.json 配置。",
|
|
183
|
+
"additionalProperties": {
|
|
184
|
+
"not": {
|
|
185
|
+
"type": "object",
|
|
186
|
+
"required": ["fallbackModels"]
|
|
187
|
+
},
|
|
188
|
+
"properties": {
|
|
189
|
+
"headers": {
|
|
190
|
+
"type": "object",
|
|
191
|
+
"propertyNames": { "pattern": "^[!#$%&'*+.^_`|~0-9A-Za-z-]+$" },
|
|
192
|
+
"additionalProperties": { "type": "string", "pattern": "^[^\\u0000\\r\\n]*$" }
|
|
193
|
+
},
|
|
194
|
+
"queryParams": {
|
|
195
|
+
"type": "object",
|
|
196
|
+
"propertyNames": { "minLength": 1 },
|
|
197
|
+
"additionalProperties": { "type": "string" }
|
|
198
|
+
},
|
|
199
|
+
"auxiliaryModel": {
|
|
200
|
+
"type": "string",
|
|
201
|
+
"minLength": 1,
|
|
202
|
+
"description": "Session Renew 语义连续性判断使用的 direct 辅助模型。"
|
|
203
|
+
},
|
|
204
|
+
"auxiliaryEffort": {
|
|
205
|
+
"type": "string",
|
|
206
|
+
"enum": ["low", "medium", "high", "xhigh", "max"],
|
|
207
|
+
"description": "Session Renew 辅助模型的可选推理强度。"
|
|
208
|
+
}
|
|
209
|
+
},
|
|
210
|
+
"dependencies": {
|
|
211
|
+
"auxiliaryEffort": ["auxiliaryModel"]
|
|
212
|
+
}
|
|
213
|
+
}
|
|
214
|
+
},
|
|
215
|
+
"projects": {
|
|
216
|
+
"type": "object",
|
|
217
|
+
"x-merge": "dict",
|
|
218
|
+
"description": "Agent 可用项目路径和项目选择配置"
|
|
219
|
+
},
|
|
220
|
+
"capabilities": {
|
|
221
|
+
"type": "object",
|
|
222
|
+
"x-merge": "dict",
|
|
223
|
+
"description": "Agent 能力开关及能力参数"
|
|
224
|
+
},
|
|
225
|
+
"readonlySourceDiagnostics": {
|
|
226
|
+
"type": "boolean",
|
|
227
|
+
"x-merge": "scalar",
|
|
228
|
+
"default": false,
|
|
229
|
+
"description": "允许只读会话在显式源码目录内执行受限、可证明只读的诊断查询"
|
|
230
|
+
},
|
|
231
|
+
"observable": {
|
|
232
|
+
"type": "boolean",
|
|
233
|
+
"default": true,
|
|
234
|
+
"x-merge": "scalar",
|
|
235
|
+
"description": "是否将 Agent 的入站和出站消息转发给 owners;默认开启"
|
|
236
|
+
},
|
|
237
|
+
"chatmode": {
|
|
238
|
+
"type": "object",
|
|
239
|
+
"x-merge": "dict",
|
|
240
|
+
"default": {
|
|
241
|
+
"private": "interactive",
|
|
242
|
+
"group": "proactive",
|
|
243
|
+
"nothuman": "proactive"
|
|
244
|
+
},
|
|
245
|
+
"properties": {
|
|
246
|
+
"private": {
|
|
247
|
+
"enum": [
|
|
248
|
+
"interactive",
|
|
249
|
+
"proactive"
|
|
250
|
+
],
|
|
251
|
+
"description": "人类私聊场景的投递方式",
|
|
252
|
+
"x-enumDescriptions": {
|
|
253
|
+
"interactive": "同步交互:输出即回复",
|
|
254
|
+
"proactive": "主动推送:CLI 回复 + 思考投影"
|
|
255
|
+
}
|
|
256
|
+
},
|
|
257
|
+
"group": {
|
|
258
|
+
"enum": [
|
|
259
|
+
"interactive",
|
|
260
|
+
"proactive"
|
|
261
|
+
],
|
|
262
|
+
"description": "群聊场景的投递方式",
|
|
263
|
+
"x-enumDescriptions": {
|
|
264
|
+
"interactive": "同步交互:输出即回复",
|
|
265
|
+
"proactive": "主动推送:CLI 回复 + 思考投影"
|
|
266
|
+
}
|
|
267
|
+
},
|
|
268
|
+
"nothuman": {
|
|
269
|
+
"enum": [
|
|
270
|
+
"interactive",
|
|
271
|
+
"proactive"
|
|
272
|
+
],
|
|
273
|
+
"description": "非人类(agent)私聊场景的投递方式",
|
|
274
|
+
"x-enumDescriptions": {
|
|
275
|
+
"interactive": "同步交互:输出即回复",
|
|
276
|
+
"proactive": "主动推送:CLI 回复 + 思考投影"
|
|
277
|
+
}
|
|
278
|
+
}
|
|
279
|
+
},
|
|
280
|
+
"additionalProperties": false,
|
|
281
|
+
"description": "chatmode 场景默认表;出厂默认值即此 default(agent 级改默认,关系级按键覆盖)。键封闭 private/group/nothuman,值枚举 interactive/proactive"
|
|
282
|
+
},
|
|
283
|
+
"mentionMode": {
|
|
284
|
+
"type": "string",
|
|
285
|
+
"enum": [
|
|
286
|
+
"disabled",
|
|
287
|
+
"mention-only"
|
|
288
|
+
],
|
|
289
|
+
"default": "disabled",
|
|
290
|
+
"x-merge": "scalar",
|
|
291
|
+
"description": "@ 处理策略(顶层通用参数)",
|
|
292
|
+
"x-enumDescriptions": {
|
|
293
|
+
"disabled": "处理所有消息",
|
|
294
|
+
"mention-only": "只处理被 @ 的消息,未 @ 作引用上下文"
|
|
295
|
+
}
|
|
296
|
+
},
|
|
297
|
+
"groupSlashRequireMentions": {
|
|
298
|
+
"type": "boolean",
|
|
299
|
+
"default": true,
|
|
300
|
+
"x-merge": "scalar",
|
|
301
|
+
"description": "AUN 群聊 slash 命令是否必须携带结构化 mentions;默认必须"
|
|
302
|
+
},
|
|
303
|
+
"model": {
|
|
304
|
+
"type": "string",
|
|
305
|
+
"x-merge": "scalar",
|
|
306
|
+
"description": "主会话模型(顶层通用参数);无默认值,缺省时由响应模式/全局默认决定"
|
|
307
|
+
},
|
|
308
|
+
"responseMode": {
|
|
309
|
+
"type": "string",
|
|
310
|
+
"x-merge": "scalar",
|
|
311
|
+
"description": "响应模式 id(标量);候选清单/默认值来自注册表,非 schema。关系级>agent级>注册表首选"
|
|
312
|
+
},
|
|
313
|
+
"responseModeParams": {
|
|
314
|
+
"type": "object",
|
|
315
|
+
"x-merge": "dict",
|
|
316
|
+
"description": "响应模式特有参数字典,按模式 id 分桶:{ [modeId]: {...} }"
|
|
317
|
+
},
|
|
318
|
+
"flush_delay": {
|
|
319
|
+
"type": "number",
|
|
320
|
+
"minimum": 0,
|
|
321
|
+
"default": 3,
|
|
322
|
+
"x-merge": "scalar",
|
|
323
|
+
"description": "流式出站消息的批量刷新间隔,单位为秒;默认 3 秒"
|
|
324
|
+
},
|
|
325
|
+
"debounce": {
|
|
326
|
+
"type": "number",
|
|
327
|
+
"minimum": 0,
|
|
328
|
+
"default": 0,
|
|
329
|
+
"x-merge": "scalar",
|
|
330
|
+
"description": "入站消息合并窗口,单位为秒;0 表示不合并,默认 0"
|
|
331
|
+
},
|
|
332
|
+
"show_activities": {
|
|
333
|
+
"type": "string",
|
|
334
|
+
"enum": [
|
|
335
|
+
"all",
|
|
336
|
+
"text",
|
|
337
|
+
"none"
|
|
338
|
+
],
|
|
339
|
+
"default": "all",
|
|
340
|
+
"x-merge": "scalar",
|
|
341
|
+
"description": "中间输出展示范围(仅对 interactive 私聊有意义)",
|
|
342
|
+
"x-enumDescriptions": {
|
|
343
|
+
"all": "文本 + activity",
|
|
344
|
+
"text": "仅文本",
|
|
345
|
+
"none": "全部静默"
|
|
346
|
+
}
|
|
347
|
+
},
|
|
348
|
+
"session_renew": {
|
|
349
|
+
"type": "object",
|
|
350
|
+
"x-merge": "dict",
|
|
351
|
+
"additionalProperties": false,
|
|
352
|
+
"description": "会话超时后的续接判定",
|
|
353
|
+
"properties": {
|
|
354
|
+
"enabled": {
|
|
355
|
+
"type": "boolean",
|
|
356
|
+
"default": false,
|
|
357
|
+
"description": "是否启用超时后的会话连续性判定"
|
|
358
|
+
},
|
|
359
|
+
"after_hours": {
|
|
360
|
+
"type": "number",
|
|
361
|
+
"exclusiveMinimum": 0,
|
|
362
|
+
"default": 24,
|
|
363
|
+
"description": "距最后一条有效对话超过该小时数才触发判定"
|
|
364
|
+
},
|
|
365
|
+
"fallback_action": {
|
|
366
|
+
"type": "string",
|
|
367
|
+
"enum": [
|
|
368
|
+
"continue",
|
|
369
|
+
"new"
|
|
370
|
+
],
|
|
371
|
+
"default": "continue",
|
|
372
|
+
"description": "无法判定时的兜底动作",
|
|
373
|
+
"x-enumDescriptions": {
|
|
374
|
+
"continue": "继续沿用当前会话",
|
|
375
|
+
"new": "开启新会话"
|
|
376
|
+
}
|
|
377
|
+
}
|
|
378
|
+
}
|
|
379
|
+
},
|
|
380
|
+
"group_venue_sync": {
|
|
381
|
+
"type": "object",
|
|
382
|
+
"x-merge": "dict",
|
|
383
|
+
"description": "AUN 群资源同步配置;控制规则文件路径、资源索引路径、条目/字节限制及刷新间隔。"
|
|
384
|
+
},
|
|
385
|
+
"groupRules": {
|
|
386
|
+
"type": "object",
|
|
387
|
+
"x-merge": "dict",
|
|
388
|
+
"additionalProperties": false,
|
|
389
|
+
"properties": {
|
|
390
|
+
"mode": {
|
|
391
|
+
"type": "string",
|
|
392
|
+
"enum": [
|
|
393
|
+
"load",
|
|
394
|
+
"ignore"
|
|
395
|
+
],
|
|
396
|
+
"default": "load",
|
|
397
|
+
"description": "是否读取并注入 AUN 群已发布的 /rules.md;默认 load。"
|
|
398
|
+
}
|
|
399
|
+
},
|
|
400
|
+
"description": "本 Agent 对 AUN 群规则的本地加载策略。"
|
|
401
|
+
},
|
|
402
|
+
"render": {
|
|
403
|
+
"type": "object",
|
|
404
|
+
"x-merge": "dict",
|
|
405
|
+
"description": "私聊、群聊及注入内容使用的渲染器标识配置。"
|
|
406
|
+
},
|
|
407
|
+
"sessionManifests": {
|
|
408
|
+
"type": "object",
|
|
409
|
+
"x-merge": "dict",
|
|
410
|
+
"description": "会话类型到 manifest 文件的映射,用于选择对应的系统提示词清单。"
|
|
411
|
+
},
|
|
412
|
+
"enable_rich_content": {
|
|
413
|
+
"type": "boolean",
|
|
414
|
+
"x-merge": "scalar",
|
|
415
|
+
"description": "是否允许渠道使用富内容消息;未设置时由渠道能力和运行时默认决定"
|
|
416
|
+
},
|
|
417
|
+
"extra_backup": {
|
|
418
|
+
"type": "array",
|
|
419
|
+
"items": {
|
|
420
|
+
"type": "object",
|
|
421
|
+
"description": "一个额外备份规则,包含相对 path 和可选的文件匹配 pattern。"
|
|
422
|
+
},
|
|
423
|
+
"x-merge": "list",
|
|
424
|
+
"description": "配置快照需要额外包含的文件声明;不得指向 .env。"
|
|
425
|
+
}
|
|
426
|
+
}
|
|
427
|
+
}
|
|
@@ -63,7 +63,6 @@
|
|
|
63
63
|
"description": "AUN 进程配置",
|
|
64
64
|
"x-merge": "dict",
|
|
65
65
|
"properties": {
|
|
66
|
-
"encryptionSeed": { "type": ["string", "null"], "description": "已废弃兼容字段;EvolCore 固定使用内置值,检测到其他值时拒绝启动并提示联系管理人员" },
|
|
67
66
|
"gatewayUrl": {
|
|
68
67
|
"not": {},
|
|
69
68
|
"description": "已移除;网关由 fastaun 缓存和 AID discovery 决定"
|
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"$id": "daemon.schema.6.json",
|
|
4
|
+
"title": "ProcessConfig v6 (daemon.json)",
|
|
5
|
+
"description": "进程级配置:daemon 自身运行配置,链外独立作用域,不进覆盖链。",
|
|
6
|
+
"x-logical-name": "daemon",
|
|
7
|
+
"x-scope": "process",
|
|
8
|
+
"type": "object",
|
|
9
|
+
"additionalProperties": false,
|
|
10
|
+
"properties": {
|
|
11
|
+
"$schema_version": { "type": "number", "const": 6, "default": 6, "x-merge": "scalar" },
|
|
12
|
+
"aid": { "type": "string", "description": "daemon 默认身份 AID", "x-merge": "scalar" },
|
|
13
|
+
"owners": {
|
|
14
|
+
"type": "array",
|
|
15
|
+
"items": { "type": "string" },
|
|
16
|
+
"description": "进程控制面鉴权名单(谁能远程管 daemon)",
|
|
17
|
+
"x-merge": "list"
|
|
18
|
+
},
|
|
19
|
+
"fullaccess": {
|
|
20
|
+
"type": "object",
|
|
21
|
+
"description": "daemon-owner 批准的按调用宿主级执行功能;默认关闭",
|
|
22
|
+
"x-merge": "dict",
|
|
23
|
+
"additionalProperties": false,
|
|
24
|
+
"properties": {
|
|
25
|
+
"enabled": { "type": "boolean", "default": false, "description": "启用 /fa 与 Trigger permissionMode=fullaccess" }
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
"debug": {
|
|
29
|
+
"type": "object",
|
|
30
|
+
"description": "进程级调试配置;唯一合法来源为 daemon.json,不参与 Agent 覆盖链",
|
|
31
|
+
"x-merge": "dict",
|
|
32
|
+
"additionalProperties": false,
|
|
33
|
+
"properties": {
|
|
34
|
+
"logLevel": { "type": "string", "enum": ["DEBUG", "INFO", "WARN", "ERROR"], "description": "daemon 日志级别" },
|
|
35
|
+
"aunTrace": { "type": "boolean", "description": "是否记录 AUN 协议 trace" },
|
|
36
|
+
"aunSdkLog": { "type": "boolean", "description": "是否启用 AUN SDK 调试日志" },
|
|
37
|
+
"upmsg": { "type": "boolean", "description": "是否向 Agent owner 发送 daemon 上线通知" },
|
|
38
|
+
"eckSnapshots": { "type": "boolean", "default": false, "description": "是否写入可能包含敏感上下文的 ECK 旁路调试快照" }
|
|
39
|
+
}
|
|
40
|
+
},
|
|
41
|
+
"tunnel": {
|
|
42
|
+
"type": "object",
|
|
43
|
+
"description": "内网穿透配置",
|
|
44
|
+
"x-merge": "dict",
|
|
45
|
+
"properties": {
|
|
46
|
+
"targets": { "type": "array", "description": "穿透目标列表", "items": { "type": "object" } }
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
"aun": {
|
|
50
|
+
"type": "object",
|
|
51
|
+
"description": "AUN 进程配置",
|
|
52
|
+
"x-merge": "dict",
|
|
53
|
+
"properties": {
|
|
54
|
+
"gatewayUrl": { "not": {}, "description": "已移除;网关由 fastaun 缓存和 AID discovery 决定" },
|
|
55
|
+
"defaultAidDomain": {
|
|
56
|
+
"type": "string",
|
|
57
|
+
"pattern": "^[A-Za-z0-9](?:[A-Za-z0-9-]{0,61}[A-Za-z0-9])?(?:\\.[A-Za-z0-9](?:[A-Za-z0-9-]{0,61}[A-Za-z0-9])?)+$",
|
|
58
|
+
"description": "自动生成控制 AID 与 benchmark AID 使用的后缀域名;不影响已有 AID"
|
|
59
|
+
},
|
|
60
|
+
"minEvolVersion": { "type": "string", "pattern": "^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$", "description": "AUN Menu 允许的最低 Evol 客户端版本;省略时不限制" },
|
|
61
|
+
"menuTokenRequired": { "type": "boolean", "default": false, "description": "是否要求普通 AUN Menu 请求携带有效 menu_token;默认 false" },
|
|
62
|
+
"defaultEncrypt": { "type": "boolean", "description": "所有 daemon 管理的 AUN 通道共用的出站默认加密值;省略时为 true" }
|
|
63
|
+
}
|
|
64
|
+
},
|
|
65
|
+
"services": {
|
|
66
|
+
"type": "array",
|
|
67
|
+
"description": "daemon 管理的本机服务及其可选 AUN 代理",
|
|
68
|
+
"x-merge": "list",
|
|
69
|
+
"items": {
|
|
70
|
+
"type": "object",
|
|
71
|
+
"additionalProperties": false,
|
|
72
|
+
"required": ["name", "enabled"],
|
|
73
|
+
"properties": {
|
|
74
|
+
"name": {
|
|
75
|
+
"type": "string",
|
|
76
|
+
"pattern": "^[a-z0-9_-]+$",
|
|
77
|
+
"description": "服务的逻辑标识,同时作为 AUN 代理路由名;ecweb 表示本机 EC Web 服务实例"
|
|
78
|
+
},
|
|
79
|
+
"enabled": { "type": "boolean", "default": true, "description": "是否启用本机服务实例" },
|
|
80
|
+
"port": { "type": "integer", "minimum": 1, "maximum": 65535, "description": "本机服务期望监听端口" },
|
|
81
|
+
"proxy": {
|
|
82
|
+
"type": "object",
|
|
83
|
+
"additionalProperties": false,
|
|
84
|
+
"allOf": [
|
|
85
|
+
{
|
|
86
|
+
"if": { "properties": { "enabled": { "const": true }, "source": { "const": "static" } }, "required": ["enabled", "source"] },
|
|
87
|
+
"then": { "required": ["endpoint", "visibility"] }
|
|
88
|
+
},
|
|
89
|
+
{
|
|
90
|
+
"if": { "properties": { "enabled": { "const": true } }, "required": ["enabled"] },
|
|
91
|
+
"then": { "required": ["source", "visibility"] }
|
|
92
|
+
}
|
|
93
|
+
],
|
|
94
|
+
"properties": {
|
|
95
|
+
"enabled": { "type": "boolean", "default": false, "description": "是否通过 AUN Service Proxy 暴露该服务" },
|
|
96
|
+
"source": { "type": "string", "enum": ["instance", "static"], "description": "instance 表示自动发现同名本机服务;static 使用 endpoint 显式回连" },
|
|
97
|
+
"endpoint": { "type": "string", "maxLength": 2048, "description": "source=static 时使用的本机 HTTP/HTTPS 或 WS/WSS 回连地址" },
|
|
98
|
+
"serviceType": { "type": "string", "enum": ["http", "websocket", "ssh"], "default": "http", "description": "AUN 中公布的服务类型" },
|
|
99
|
+
"visibility": { "type": "string", "enum": ["public", "private", "aun-auth"], "default": "private", "description": "AUN Service Proxy 访问策略" },
|
|
100
|
+
"metadata": {
|
|
101
|
+
"type": "object",
|
|
102
|
+
"description": "非敏感服务描述;不得包含 endpoint、token、secret、cookie 等敏感信息",
|
|
103
|
+
"additionalProperties": { "type": "string", "maxLength": 8192 }
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
},
|
|
110
|
+
"configSnapshots": { "type": "boolean", "default": true, "description": "是否自动维护配置快照、启动日志和自检回落", "x-merge": "scalar" },
|
|
111
|
+
"idleMonitor": {
|
|
112
|
+
"type": "object",
|
|
113
|
+
"description": "流式输出空闲监控配置",
|
|
114
|
+
"x-merge": "dict",
|
|
115
|
+
"properties": {
|
|
116
|
+
"enabled": { "type": "boolean", "default": true, "description": "是否启用空闲监控" },
|
|
117
|
+
"timeout": { "type": "number", "default": 120, "description": "空闲超时秒数" },
|
|
118
|
+
"apiRetryTimeout": { "type": "number", "description": "API 重试尝试连续无事件时的超时秒数;未设置时继承 timeout" },
|
|
119
|
+
"maxExecutionTime": { "type": "number", "description": "单个任务总执行时限(秒);未配置、非数字或小于等于 0 表示不限制" }
|
|
120
|
+
}
|
|
121
|
+
},
|
|
122
|
+
"watch": {
|
|
123
|
+
"type": "object",
|
|
124
|
+
"description": "日志监听配置",
|
|
125
|
+
"x-merge": "dict",
|
|
126
|
+
"properties": {
|
|
127
|
+
"logTypes": { "type": "array", "description": "要监听的日志类型", "items": { "type": "string" } }
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
}
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
},
|
|
25
25
|
"active_baseagent": {
|
|
26
26
|
"type": "string",
|
|
27
|
-
"description": "当前活跃的 base agent(claude/codex/gemini)。暂存于此,待权限体系实现后迁移。",
|
|
27
|
+
"description": "当前活跃的 base agent(claude/codex/gemini/ecagent)。暂存于此,待权限体系实现后迁移。",
|
|
28
28
|
"x-merge": "scalar"
|
|
29
29
|
},
|
|
30
30
|
"baseagents": {
|
|
@@ -45,6 +45,16 @@
|
|
|
45
45
|
"propertyNames": { "minLength": 1 },
|
|
46
46
|
"additionalProperties": { "type": "string" }
|
|
47
47
|
},
|
|
48
|
+
"auxiliaryModel": {
|
|
49
|
+
"type": "string",
|
|
50
|
+
"minLength": 1,
|
|
51
|
+
"description": "Session Renew 语义连续性判断使用的 direct 辅助模型。"
|
|
52
|
+
},
|
|
53
|
+
"auxiliaryEffort": {
|
|
54
|
+
"type": "string",
|
|
55
|
+
"enum": ["low", "medium", "high", "xhigh", "max"],
|
|
56
|
+
"description": "Session Renew 辅助模型的可选推理强度。"
|
|
57
|
+
},
|
|
48
58
|
"fallbackModels": {
|
|
49
59
|
"type": "array",
|
|
50
60
|
"maxItems": 3,
|
|
@@ -59,6 +69,9 @@
|
|
|
59
69
|
}
|
|
60
70
|
}
|
|
61
71
|
}
|
|
72
|
+
},
|
|
73
|
+
"dependencies": {
|
|
74
|
+
"auxiliaryEffort": ["auxiliaryModel"]
|
|
62
75
|
}
|
|
63
76
|
}
|
|
64
77
|
},
|
|
@@ -66,8 +79,8 @@
|
|
|
66
79
|
"type": "object",
|
|
67
80
|
"description": "项目路径配置",
|
|
68
81
|
"x-merge": "dict",
|
|
82
|
+
"additionalProperties": false,
|
|
69
83
|
"properties": {
|
|
70
|
-
"rootPath": { "type": "string", "description": "全局项目根路径" },
|
|
71
84
|
"defaultPath": { "type": "string", "description": "全局默认项目路径" }
|
|
72
85
|
}
|
|
73
86
|
},
|
|
@@ -77,7 +90,6 @@
|
|
|
77
90
|
"x-merge": "dict",
|
|
78
91
|
"properties": {
|
|
79
92
|
"keystorePath": { "type": "string" },
|
|
80
|
-
"encryptionSeed": { "type": "string" },
|
|
81
93
|
"gatewayUrl": { "not": {}, "description": "已移除;网关由 fastaun 缓存和 AID discovery 决定" },
|
|
82
94
|
"defaultEncrypt": {
|
|
83
95
|
"not": {},
|
|
@@ -25,4 +25,6 @@ export function migrate(old: object): object; // 旧版本完整 JSON → 新
|
|
|
25
25
|
- 历史 schema 文件全部保留(`{逻辑名}.schema.{版本}.json`)。
|
|
26
26
|
- 每个迁移函数 default-export `migrate`,由 ConfigManager 动态 import。
|
|
27
27
|
|
|
28
|
-
|
|
28
|
+
当前完整配置 schema 的历史迁移仍按各自模块维护。响应模式桶的
|
|
29
|
+
`single-session` v2→v3 数据迁移集中在 `src/config/schema-migration.ts`,
|
|
30
|
+
扫描并更新 defaults、Agent、Relation 配置文件,并在 daemon 启动前自动执行。
|
|
@@ -46,7 +46,20 @@
|
|
|
46
46
|
"type": "object",
|
|
47
47
|
"propertyNames": { "minLength": 1 },
|
|
48
48
|
"additionalProperties": { "type": "string" }
|
|
49
|
+
},
|
|
50
|
+
"auxiliaryModel": {
|
|
51
|
+
"type": "string",
|
|
52
|
+
"minLength": 1,
|
|
53
|
+
"description": "Session Renew 语义连续性判断使用的 direct 辅助模型。"
|
|
54
|
+
},
|
|
55
|
+
"auxiliaryEffort": {
|
|
56
|
+
"type": "string",
|
|
57
|
+
"enum": ["low", "medium", "high", "xhigh", "max"],
|
|
58
|
+
"description": "Session Renew 辅助模型的可选推理强度。"
|
|
49
59
|
}
|
|
60
|
+
},
|
|
61
|
+
"dependencies": {
|
|
62
|
+
"auxiliaryEffort": ["auxiliaryModel"]
|
|
50
63
|
}
|
|
51
64
|
}
|
|
52
65
|
},
|