evolcore 0.0.19 → 0.0.21
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 +43 -1
- package/README.md +60 -9
- package/bin/install-codex-managed-hooks.mjs +61 -0
- package/dist/agents/baseagent.js +10 -6
- package/dist/agents/claude-runner.js +383 -111
- package/dist/agents/codex-app-server-client.js +10 -2
- package/dist/agents/codex-runner.js +405 -137
- package/dist/agents/ecagent-runner.js +174 -63
- 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 +66 -2
- package/dist/aun/aid/identity.js +4 -1
- package/dist/aun/aid/index.js +1 -1
- package/dist/aun/msg/group.js +86 -9
- package/dist/aun/msg/history.js +213 -36
- package/dist/aun/msg/managed-operation.js +58 -9
- package/dist/aun/msg/p2p.js +26 -11
- package/dist/aun/outbox.js +295 -68
- package/dist/aun/service-proxy.js +43 -25
- package/dist/channels/aun.js +1004 -273
- 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 +81 -121
- package/dist/cli/index.js +1 -0
- package/dist/cli/init.js +76 -24
- package/dist/cli/restart-monitor.js +3 -3
- package/dist/cli/task-context.js +46 -0
- package/dist/cli/trigger-command.js +1 -1
- package/dist/cli/watch-logs.js +10 -3
- package/dist/config/builtin-roles.js +1 -0
- package/dist/config/config-field-policy.js +16 -5
- package/dist/config/config-manager.js +226 -24
- package/dist/config/config-operation-service.js +1 -2
- 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 +29 -16
- package/dist/config/lifecycle.js +16 -5
- package/dist/config/role-service.js +54 -3
- package/dist/config/schema-migration.js +550 -0
- package/dist/config-store.js +161 -12
- 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 +31 -1
- package/dist/core/auth/auth-gateway.js +33 -4
- package/dist/core/auth/authorization-audit.js +155 -4
- package/dist/core/auth/operation-authorizer.js +41 -1
- package/dist/core/auth/operation-catalog.js +9 -1
- package/dist/core/bootstrap-messages.js +2 -2
- package/dist/core/bootstrap-service.js +27 -38
- package/dist/core/causation/aun-association.js +7 -4
- package/dist/core/channel-loader.js +0 -2
- package/dist/core/command/agent-control.js +56 -16
- package/dist/core/command/command-handler.js +290 -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 +279 -80
- 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 +350 -32
- package/dist/core/event-catalog.js +5 -0
- package/dist/core/evolagent.js +9 -4
- package/dist/core/handoff/dispatcher.js +4 -0
- package/dist/core/handoff/runtime.js +10 -0
- package/dist/core/handoff/store.js +32 -9
- package/dist/core/inference/text-inference.js +7 -15
- package/dist/core/message/im-renderer.js +83 -84
- package/dist/core/message/{inbound-admission.js → message-admission.js} +51 -1
- package/dist/core/message/message-bridge.js +124 -10
- package/dist/core/message/message-log.js +14 -7
- package/dist/core/message/message-queue.js +206 -16
- package/dist/core/message/message-utils.js +12 -5
- package/dist/core/message/response-engine.js +495 -72
- 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 +465 -56
- package/dist/core/permission/mode.js +18 -3
- package/dist/core/{protected-paths.js → permission/protected-paths.js} +17 -5
- package/dist/core/permission/readonly-shell-query.js +263 -9
- package/dist/core/permission/sandbox-runtime.js +205 -13
- package/dist/core/permission/tool-policy.js +673 -62
- package/dist/core/relation/peer-identity.js +18 -0
- package/dist/core/session/session-fs-store.js +154 -5
- package/dist/core/session/session-manager.js +299 -30
- package/dist/core/session/session-renew.js +19 -12
- package/dist/core/session/session-turn-coordinator.js +11 -4
- package/dist/eck/kit-renderer.js +18 -9
- package/dist/index.js +283 -65
- package/dist/ipc.js +374 -24
- package/dist/paths.js +64 -7
- package/dist/response-system/context-builder.js +1 -7
- package/dist/trigger/anomaly-store.js +1 -0
- package/dist/trigger/feedback.js +56 -5
- package/dist/trigger/history.js +79 -4
- package/dist/trigger/legacy-session-history.js +2 -2
- package/dist/trigger/parser.js +3 -2
- 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 +21 -2
- 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/stats.js +52 -18
- package/dist/utils/welcome.js +2 -2
- package/kits/docs/INDEX.md +1 -1
- package/kits/docs/evolcore/INDEX.md +1 -1
- package/kits/docs/evolcore/contact.md +7 -1
- package/kits/docs/evolcore/msg.md +16 -0
- package/kits/rules/01-overview.md +1 -1
- package/kits/rules/03-identity.md +1 -1
- package/kits/rules/05-venue.md +1 -1
- package/kits/schemas/_meta.json +10 -5
- package/kits/schemas/agent-config.schema.10.json +2 -1
- package/kits/schemas/agent-config.schema.11.json +421 -0
- package/kits/schemas/daemon.schema.5.json +135 -0
- package/kits/schemas/daemon.schema.6.json +131 -0
- package/kits/schemas/defaults.schema.5.json +119 -0
- 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/roles/admin.json +1 -0
- package/kits/templates/roles/member.json +1 -0
- package/kits/templates/roles/visitor.json +1 -0
- package/package.json +7 -3
- package/skills/eclink/SKILL.md +2 -0
|
@@ -0,0 +1,421 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"$id": "agent-config.schema.11.json",
|
|
4
|
+
"title": "AgentConfig v11 (agents/{aid}/config.json)",
|
|
5
|
+
"description": "Agent v11 主配置。备用模型链只允许在 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": 11,
|
|
47
|
+
"default": 11,
|
|
48
|
+
"x-merge": "scalar",
|
|
49
|
+
"description": "配置 Schema 版本;v11 移除 AUN gateway override"
|
|
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
|
+
"model": {
|
|
298
|
+
"type": "string",
|
|
299
|
+
"x-merge": "scalar",
|
|
300
|
+
"description": "主会话模型(顶层通用参数);无默认值,缺省时由响应模式/全局默认决定"
|
|
301
|
+
},
|
|
302
|
+
"responseMode": {
|
|
303
|
+
"type": "string",
|
|
304
|
+
"x-merge": "scalar",
|
|
305
|
+
"description": "响应模式 id(标量);候选清单/默认值来自注册表,非 schema。关系级>agent级>注册表首选"
|
|
306
|
+
},
|
|
307
|
+
"responseModeParams": {
|
|
308
|
+
"type": "object",
|
|
309
|
+
"x-merge": "dict",
|
|
310
|
+
"description": "响应模式特有参数字典,按模式 id 分桶:{ [modeId]: {...} }"
|
|
311
|
+
},
|
|
312
|
+
"flush_delay": {
|
|
313
|
+
"type": "number",
|
|
314
|
+
"minimum": 0,
|
|
315
|
+
"default": 3,
|
|
316
|
+
"x-merge": "scalar",
|
|
317
|
+
"description": "流式出站消息的批量刷新间隔,单位为秒;默认 3 秒"
|
|
318
|
+
},
|
|
319
|
+
"debounce": {
|
|
320
|
+
"type": "number",
|
|
321
|
+
"minimum": 0,
|
|
322
|
+
"default": 0,
|
|
323
|
+
"x-merge": "scalar",
|
|
324
|
+
"description": "入站消息合并窗口,单位为秒;0 表示不合并,默认 0"
|
|
325
|
+
},
|
|
326
|
+
"show_activities": {
|
|
327
|
+
"type": "string",
|
|
328
|
+
"enum": [
|
|
329
|
+
"all",
|
|
330
|
+
"text",
|
|
331
|
+
"none"
|
|
332
|
+
],
|
|
333
|
+
"default": "all",
|
|
334
|
+
"x-merge": "scalar",
|
|
335
|
+
"description": "中间输出展示范围(仅对 interactive 私聊有意义)",
|
|
336
|
+
"x-enumDescriptions": {
|
|
337
|
+
"all": "文本 + activity",
|
|
338
|
+
"text": "仅文本",
|
|
339
|
+
"none": "全部静默"
|
|
340
|
+
}
|
|
341
|
+
},
|
|
342
|
+
"session_renew": {
|
|
343
|
+
"type": "object",
|
|
344
|
+
"x-merge": "dict",
|
|
345
|
+
"additionalProperties": false,
|
|
346
|
+
"description": "会话超时后的续接判定",
|
|
347
|
+
"properties": {
|
|
348
|
+
"enabled": {
|
|
349
|
+
"type": "boolean",
|
|
350
|
+
"default": false,
|
|
351
|
+
"description": "是否启用超时后的会话连续性判定"
|
|
352
|
+
},
|
|
353
|
+
"after_hours": {
|
|
354
|
+
"type": "number",
|
|
355
|
+
"exclusiveMinimum": 0,
|
|
356
|
+
"default": 24,
|
|
357
|
+
"description": "距最后一条有效对话超过该小时数才触发判定"
|
|
358
|
+
},
|
|
359
|
+
"fallback_action": {
|
|
360
|
+
"type": "string",
|
|
361
|
+
"enum": [
|
|
362
|
+
"continue",
|
|
363
|
+
"new"
|
|
364
|
+
],
|
|
365
|
+
"default": "continue",
|
|
366
|
+
"description": "无法判定时的兜底动作",
|
|
367
|
+
"x-enumDescriptions": {
|
|
368
|
+
"continue": "继续沿用当前会话",
|
|
369
|
+
"new": "开启新会话"
|
|
370
|
+
}
|
|
371
|
+
}
|
|
372
|
+
}
|
|
373
|
+
},
|
|
374
|
+
"group_venue_sync": {
|
|
375
|
+
"type": "object",
|
|
376
|
+
"x-merge": "dict",
|
|
377
|
+
"description": "AUN 群资源同步配置;控制规则文件路径、资源索引路径、条目/字节限制及刷新间隔。"
|
|
378
|
+
},
|
|
379
|
+
"groupRules": {
|
|
380
|
+
"type": "object",
|
|
381
|
+
"x-merge": "dict",
|
|
382
|
+
"additionalProperties": false,
|
|
383
|
+
"properties": {
|
|
384
|
+
"mode": {
|
|
385
|
+
"type": "string",
|
|
386
|
+
"enum": [
|
|
387
|
+
"load",
|
|
388
|
+
"ignore"
|
|
389
|
+
],
|
|
390
|
+
"default": "load",
|
|
391
|
+
"description": "是否读取并注入 AUN 群已发布的 /rules.md;默认 load。"
|
|
392
|
+
}
|
|
393
|
+
},
|
|
394
|
+
"description": "本 Agent 对 AUN 群规则的本地加载策略。"
|
|
395
|
+
},
|
|
396
|
+
"render": {
|
|
397
|
+
"type": "object",
|
|
398
|
+
"x-merge": "dict",
|
|
399
|
+
"description": "私聊、群聊及注入内容使用的渲染器标识配置。"
|
|
400
|
+
},
|
|
401
|
+
"sessionManifests": {
|
|
402
|
+
"type": "object",
|
|
403
|
+
"x-merge": "dict",
|
|
404
|
+
"description": "会话类型到 manifest 文件的映射,用于选择对应的系统提示词清单。"
|
|
405
|
+
},
|
|
406
|
+
"enable_rich_content": {
|
|
407
|
+
"type": "boolean",
|
|
408
|
+
"x-merge": "scalar",
|
|
409
|
+
"description": "是否允许渠道使用富内容消息;未设置时由渠道能力和运行时默认决定"
|
|
410
|
+
},
|
|
411
|
+
"extra_backup": {
|
|
412
|
+
"type": "array",
|
|
413
|
+
"items": {
|
|
414
|
+
"type": "object",
|
|
415
|
+
"description": "一个额外备份规则,包含相对 path 和可选的文件匹配 pattern。"
|
|
416
|
+
},
|
|
417
|
+
"x-merge": "list",
|
|
418
|
+
"description": "配置快照需要额外包含的文件声明;不得指向 .env。"
|
|
419
|
+
}
|
|
420
|
+
}
|
|
421
|
+
}
|
|
@@ -0,0 +1,135 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"$id": "daemon.schema.5.json",
|
|
4
|
+
"title": "ProcessConfig v5 (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": 5, "default": 5, "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
|
+
"debug": {
|
|
20
|
+
"type": "object",
|
|
21
|
+
"description": "进程级调试配置;唯一合法来源为 daemon.json,不参与 Agent 覆盖链",
|
|
22
|
+
"x-merge": "dict",
|
|
23
|
+
"additionalProperties": false,
|
|
24
|
+
"properties": {
|
|
25
|
+
"logLevel": {
|
|
26
|
+
"type": "string",
|
|
27
|
+
"enum": ["DEBUG", "INFO", "WARN", "ERROR"],
|
|
28
|
+
"description": "daemon 日志级别"
|
|
29
|
+
},
|
|
30
|
+
"flusherDiag": {
|
|
31
|
+
"type": "boolean",
|
|
32
|
+
"description": "是否启用消息 flusher 诊断"
|
|
33
|
+
},
|
|
34
|
+
"aunTrace": {
|
|
35
|
+
"type": "boolean",
|
|
36
|
+
"description": "是否记录 AUN 协议 trace"
|
|
37
|
+
},
|
|
38
|
+
"aunSdkLog": {
|
|
39
|
+
"type": "boolean",
|
|
40
|
+
"description": "是否启用 AUN SDK 调试日志"
|
|
41
|
+
},
|
|
42
|
+
"upmsg": {
|
|
43
|
+
"type": "boolean",
|
|
44
|
+
"description": "是否向 Agent owner 发送 daemon 上线通知"
|
|
45
|
+
},
|
|
46
|
+
"eckSnapshots": {
|
|
47
|
+
"type": "boolean",
|
|
48
|
+
"default": false,
|
|
49
|
+
"description": "是否写入可能包含敏感上下文的 ECK 旁路调试快照"
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
},
|
|
53
|
+
"tunnel": {
|
|
54
|
+
"type": "object",
|
|
55
|
+
"description": "内网穿透配置",
|
|
56
|
+
"x-merge": "dict",
|
|
57
|
+
"properties": {
|
|
58
|
+
"targets": { "type": "array", "description": "穿透目标列表", "items": { "type": "object" } }
|
|
59
|
+
}
|
|
60
|
+
},
|
|
61
|
+
"aun": {
|
|
62
|
+
"type": "object",
|
|
63
|
+
"description": "AUN 进程配置",
|
|
64
|
+
"x-merge": "dict",
|
|
65
|
+
"properties": {
|
|
66
|
+
"gatewayUrl": {
|
|
67
|
+
"not": {},
|
|
68
|
+
"description": "已移除;网关由 fastaun 缓存和 AID discovery 决定"
|
|
69
|
+
},
|
|
70
|
+
"defaultAidDomain": {
|
|
71
|
+
"type": "string",
|
|
72
|
+
"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])?)+$",
|
|
73
|
+
"description": "自动生成控制 AID 与 benchmark AID 使用的后缀域名;不影响已有 AID"
|
|
74
|
+
},
|
|
75
|
+
"minEvolVersion": {
|
|
76
|
+
"type": "string",
|
|
77
|
+
"pattern": "^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$",
|
|
78
|
+
"description": "AUN Menu 允许的最低 Evol 客户端版本;省略时不限制"
|
|
79
|
+
},
|
|
80
|
+
"menuTokenRequired": {
|
|
81
|
+
"type": "boolean",
|
|
82
|
+
"default": false,
|
|
83
|
+
"description": "是否要求普通 AUN Menu 请求携带有效 menu_token;默认 false"
|
|
84
|
+
},
|
|
85
|
+
"defaultEncrypt": {
|
|
86
|
+
"type": "boolean",
|
|
87
|
+
"description": "所有 daemon 管理的 AUN 通道共用的出站默认加密值;省略时为 true"
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
},
|
|
91
|
+
"serviceProxy": {
|
|
92
|
+
"type": "object",
|
|
93
|
+
"description": "AUN Service Proxy:把一个本地 HTTP/WS 服务暴露到 AUN 网络",
|
|
94
|
+
"x-merge": "dict",
|
|
95
|
+
"properties": {
|
|
96
|
+
"enabled": { "type": "boolean", "description": "是否启用 Service Proxy" },
|
|
97
|
+
"services": { "type": "array", "description": "暴露到 AUN 的本地服务列表", "items": { "type": "object" } }
|
|
98
|
+
}
|
|
99
|
+
},
|
|
100
|
+
"configSnapshots": {
|
|
101
|
+
"type": "boolean",
|
|
102
|
+
"default": true,
|
|
103
|
+
"description": "是否自动维护配置快照、启动日志和自检回落",
|
|
104
|
+
"x-merge": "scalar"
|
|
105
|
+
},
|
|
106
|
+
"idleMonitor": {
|
|
107
|
+
"type": "object",
|
|
108
|
+
"description": "流式输出空闲监控配置",
|
|
109
|
+
"x-merge": "dict",
|
|
110
|
+
"properties": {
|
|
111
|
+
"enabled": { "type": "boolean", "default": true, "description": "是否启用空闲监控" },
|
|
112
|
+
"timeout": { "type": "number", "default": 120, "description": "空闲超时秒数" },
|
|
113
|
+
"retryAttemptTimeout": { "type": "number", "description": "API 重试尝试连续无事件时的超时秒数;未设置时继承 timeout" },
|
|
114
|
+
"maxExecutionTime": { "type": "number", "description": "单个任务总执行时限(秒);未配置、非数字或小于等于 0 表示不限制" }
|
|
115
|
+
}
|
|
116
|
+
},
|
|
117
|
+
"ecweb": {
|
|
118
|
+
"type": "object",
|
|
119
|
+
"description": "web 控制台开关/端口",
|
|
120
|
+
"x-merge": "dict",
|
|
121
|
+
"properties": {
|
|
122
|
+
"enabled": { "type": "boolean", "description": "是否启用 web 控制台" },
|
|
123
|
+
"port": { "type": "number", "description": "web 控制台监听端口" }
|
|
124
|
+
}
|
|
125
|
+
},
|
|
126
|
+
"watch": {
|
|
127
|
+
"type": "object",
|
|
128
|
+
"description": "日志监听配置",
|
|
129
|
+
"x-merge": "dict",
|
|
130
|
+
"properties": {
|
|
131
|
+
"logTypes": { "type": "array", "description": "要监听的日志类型", "items": { "type": "string" } }
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
}
|