@xdxer/dingtalk-agent 0.1.4-beta.1 → 0.1.4-beta.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +70 -0
- package/README.en.md +397 -0
- package/README.md +500 -47
- package/dist/bin/dingtalk-agent.js +1263 -351
- package/dist/bin/dingtalk-agent.js.map +1 -1
- package/dist/src/actions.js +98 -14
- package/dist/src/actions.js.map +1 -1
- package/dist/src/agent-audit.js +460 -0
- package/dist/src/agent-audit.js.map +1 -0
- package/dist/src/agent-bindings.js +132 -0
- package/dist/src/agent-bindings.js.map +1 -0
- package/dist/src/agent-definition.js +182 -0
- package/dist/src/agent-definition.js.map +1 -0
- package/dist/src/agent-enhance.js +678 -0
- package/dist/src/agent-enhance.js.map +1 -0
- package/dist/src/agent-platform.js +158 -0
- package/dist/src/agent-platform.js.map +1 -0
- package/dist/src/bootstrap.js +125 -17
- package/dist/src/bootstrap.js.map +1 -1
- package/dist/src/config.js +1 -7
- package/dist/src/config.js.map +1 -1
- package/dist/src/development-workspace.js +736 -0
- package/dist/src/development-workspace.js.map +1 -0
- package/dist/src/doctor.js +49 -22
- package/dist/src/doctor.js.map +1 -1
- package/dist/src/dws.js +145 -0
- package/dist/src/dws.js.map +1 -1
- package/dist/src/eval-evidence.js +193 -0
- package/dist/src/eval-evidence.js.map +1 -0
- package/dist/src/init.js +1 -1
- package/dist/src/init.js.map +1 -1
- package/dist/src/invocation.js +36 -0
- package/dist/src/invocation.js.map +1 -0
- package/dist/src/lab.js +679 -0
- package/dist/src/lab.js.map +1 -0
- package/dist/src/lease.js +100 -0
- package/dist/src/lease.js.map +1 -0
- package/dist/src/map.js +157 -0
- package/dist/src/map.js.map +1 -0
- package/dist/src/memory/candidates.js +451 -0
- package/dist/src/memory/candidates.js.map +1 -0
- package/dist/src/memory/completion-evidence.js +536 -0
- package/dist/src/memory/completion-evidence.js.map +1 -0
- package/dist/src/memory/operational.js +263 -0
- package/dist/src/memory/operational.js.map +1 -0
- package/dist/src/memory/remote-state.js +478 -0
- package/dist/src/memory/remote-state.js.map +1 -0
- package/dist/src/memory/task-checkpoints.js +204 -0
- package/dist/src/memory/task-checkpoints.js.map +1 -0
- package/dist/src/multica-deploy.js +1480 -0
- package/dist/src/multica-deploy.js.map +1 -0
- package/dist/src/multica-provider.js +685 -0
- package/dist/src/multica-provider.js.map +1 -0
- package/dist/src/opencode-evals.js +1062 -0
- package/dist/src/opencode-evals.js.map +1 -0
- package/dist/src/opencode-provider.js +531 -0
- package/dist/src/opencode-provider.js.map +1 -0
- package/dist/src/opencode-workspace.js +197 -0
- package/dist/src/opencode-workspace.js.map +1 -0
- package/dist/src/perception.js +225 -0
- package/dist/src/perception.js.map +1 -0
- package/dist/src/personal-event-evals.js +595 -0
- package/dist/src/personal-event-evals.js.map +1 -0
- package/dist/src/promotion.js +786 -0
- package/dist/src/promotion.js.map +1 -0
- package/dist/src/remote-semantic-state-live-evals.js +888 -0
- package/dist/src/remote-semantic-state-live-evals.js.map +1 -0
- package/dist/src/remote-semantic-state-worker.js +38 -0
- package/dist/src/remote-semantic-state-worker.js.map +1 -0
- package/dist/src/remote-state-evals.js +501 -0
- package/dist/src/remote-state-evals.js.map +1 -0
- package/dist/src/response-gate.js +51 -0
- package/dist/src/response-gate.js.map +1 -0
- package/dist/src/robot-evals.js +770 -0
- package/dist/src/robot-evals.js.map +1 -0
- package/dist/src/sessions.js +66 -105
- package/dist/src/sessions.js.map +1 -1
- package/dist/src/setup.js +14 -12
- package/dist/src/setup.js.map +1 -1
- package/dist/src/skill-manager.js +128 -203
- package/dist/src/skill-manager.js.map +1 -1
- package/dist/src/skills.js.map +1 -1
- package/dist/src/storage-evals.js +26 -0
- package/dist/src/storage-evals.js.map +1 -0
- package/dist/src/types.js.map +1 -1
- package/dist/src/upgrade.js +137 -0
- package/dist/src/upgrade.js.map +1 -0
- package/dist/src/waits.js +5 -1
- package/dist/src/waits.js.map +1 -1
- package/dist/src/workspace.js +28 -3
- package/dist/src/workspace.js.map +1 -1
- package/docs/INSTALLATION.md +119 -14
- package/docs/SECOND-AGENT-ACCEPTANCE.md +62 -0
- package/docs/architecture/agent-memory-topology.png +0 -0
- package/docs/architecture/agent-memory-topology.svg +132 -0
- package/docs/architecture/general-agent-kernel-topology.png +0 -0
- package/docs/architecture/general-agent-kernel-topology.svg +149 -0
- package/docs/architecture/provider-bound-development-workspace.png +0 -0
- package/docs/architecture/provider-bound-development-workspace.svg +141 -0
- package/docs/architecture/task-completion-gate.png +0 -0
- package/docs/architecture/task-completion-gate.svg +191 -0
- package/docs/schemas/agent-audit-load-evidence.schema.json +14 -0
- package/docs/schemas/agent-audit.schema.json +92 -0
- package/docs/schemas/agent-bindings.schema.json +54 -0
- package/docs/schemas/agent-definition.schema.json +78 -0
- package/docs/schemas/agent-enhancement-plan.schema.json +88 -0
- package/docs/schemas/agent-enhancement-receipt.schema.json +37 -0
- package/docs/schemas/agent-platform.schema.json +13 -0
- package/docs/schemas/enriched-invocation.schema.json +46 -0
- package/docs/schemas/eval-candidate-plan.schema.json +28 -0
- package/docs/schemas/eval-candidate-result.schema.json +20 -0
- package/docs/schemas/eval-candidate.schema.json +30 -0
- package/docs/schemas/invocation.schema.json +19 -0
- package/docs/schemas/memory-candidate-proposal.schema.json +18 -0
- package/docs/schemas/memory-candidate.schema.json +76 -0
- package/docs/schemas/memory-publish-target.schema.json +25 -0
- package/docs/schemas/multica-deployment-list.schema.json +29 -0
- package/docs/schemas/multica-deployment-operation.schema.json +51 -0
- package/docs/schemas/multica-deployment-plan.schema.json +70 -0
- package/docs/schemas/multica-deployment-receipt.schema.json +87 -0
- package/docs/schemas/multica-deployment-status.schema.json +23 -0
- package/docs/schemas/multica-workspace-inspection.schema.json +77 -0
- package/docs/schemas/multica-workspace-plan.schema.json +68 -0
- package/docs/schemas/multica-workspace-resource-list.schema.json +27 -0
- package/docs/schemas/multica-workspace-status.schema.json +34 -0
- package/docs/schemas/observation.schema.json +21 -0
- package/docs/schemas/operational-memory-provider.schema.json +36 -0
- package/docs/schemas/operational-memory-record.schema.json +24 -0
- package/docs/schemas/perception-input.schema.json +56 -0
- package/docs/schemas/project.schema.json +113 -0
- package/docs/schemas/promotion-list.schema.json +36 -0
- package/docs/schemas/promotion-plan.schema.json +60 -0
- package/docs/schemas/promotion-policy.schema.json +29 -0
- package/docs/schemas/promotion-receipt.schema.json +43 -0
- package/docs/schemas/promotion-status.schema.json +23 -0
- package/docs/schemas/release-readiness.schema.json +66 -0
- package/docs/schemas/remote-semantic-state-live-eval.schema.json +60 -0
- package/docs/schemas/remote-semantic-state-manifest.schema.json +79 -0
- package/docs/schemas/remote-semantic-state-provider.schema.json +98 -0
- package/docs/schemas/response-gate.schema.json +20 -0
- package/docs/schemas/task-checkpoint.schema.json +71 -0
- package/docs/schemas/task-completion-evidence.schema.json +154 -0
- package/docs/schemas/workspace-doctor.schema.json +56 -0
- package/docs/schemas/workspace-state.schema.json +39 -0
- package/evals/baselines/2026-07-16/opencode-basic-010-completion-summary.json +123 -0
- package/evals/baselines/2026-07-16/opencode-basic-skill-required-summary.json +69 -0
- package/evals/baselines/2026-07-16/opencode-multi-surface-summary.json +63 -0
- package/evals/baselines/2026-07-16/remote-state-live-summary.json +70 -0
- package/evals/baselines/2026-07-17/agent-enhance-opencode-dogfood-summary.json +98 -0
- package/evals/baselines/2026-07-17/personal-event-live-readiness-summary.json +68 -0
- package/examples/agents/fde-coach/AGENTS.md +26 -0
- package/examples/agents/fde-coach/MEMORY.md +3 -0
- package/examples/agents/fde-coach/fields/default/field.json +24 -0
- package/examples/agents/fde-coach/knowledge/INDEX.md +4 -0
- package/examples/agents/fde-coach/skills/fde-coach/SKILL.md +13 -0
- package/examples/agents/release-manager/AGENTS.md +26 -0
- package/examples/agents/release-manager/MEMORY.md +3 -0
- package/examples/agents/release-manager/fields/default/field.json +24 -0
- package/examples/agents/release-manager/knowledge/INDEX.md +4 -0
- package/examples/agents/release-manager/skills/release-manager/SKILL.md +13 -0
- package/lab/README.md +109 -0
- package/lab/agent-eval/catalog.json +91 -0
- package/lab/agent-eval/classic-failures.json +177 -0
- package/lab/agent-eval/completion-gate-regression.json +99 -0
- package/lab/agent-eval/personal-event-live.example.json +94 -0
- package/lab/agent-eval/remote-semantic-state-live.example.json +70 -0
- package/lab/agent-eval/remote-semantic-state-provider.fixture.json +47 -0
- package/lab/agent-eval/remote-state-workspace/AGENTS.md +8 -0
- package/lab/agent-eval/remote-state-workspace/opencode.json +7 -0
- package/lab/agent-eval/remote-state-workspace/skills/remote-state-operator/SKILL.md +13 -0
- package/lab/agent-eval/remote-state.example.json +31 -0
- package/lab/agent-eval/workspace/AGENTS.md +7 -0
- package/lab/agent-eval/workspace/MEMORY.md +4 -0
- package/lab/agent-eval/workspace/artifacts/pending-review.md +3 -0
- package/lab/agent-eval/workspace/knowledge/INDEX.md +4 -0
- package/lab/agent-eval/workspace/opencode.json +20 -0
- package/lab/manifest.example.json +27 -0
- package/lab/manifest.personal-event.example.json +27 -0
- package/lab/project-workspace/README.md +11 -0
- package/lab/project-workspace/fake-multica-provider.mjs +266 -0
- package/lab/project-workspace/multica-deploy.fixture.json +29 -0
- package/lab/project-workspace/multica-readonly.fixture.json +69 -0
- package/lab/project-workspace/observation.fixture.json +14 -0
- package/lab/project-workspace/opencode-provider-suite.json +65 -0
- package/lab/project-workspace/project.fixture.json +44 -0
- package/lab/project-workspace/promotion-policy.fixture.json +15 -0
- package/lab/robot-eval/pool.example.json +30 -0
- package/lab/robot-eval/suite.json +123 -0
- package/lab/robot-eval/workspace/AGENTS.md +21 -0
- package/lab/robot-eval/workspace/MEMORY.md +3 -0
- package/lab/robot-eval/workspace/knowledge/INDEX.md +5 -0
- package/lab/robot-eval/workspace/opencode.json +22 -0
- package/lab/schemas/agent-eval-catalog.schema.json +47 -0
- package/lab/schemas/lab-manifest.schema.json +70 -0
- package/lab/schemas/personal-event-eval.schema.json +91 -0
- package/lab/schemas/remote-state-eval.schema.json +66 -0
- package/lab/schemas/robot-eval-suite.schema.json +184 -0
- package/lab/schemas/robot-pool.schema.json +56 -0
- package/package.json +26 -14
- package/skills/dingtalk-agent-boot-multica/SKILL.md +40 -0
- package/skills/dingtalk-agent-compose/SKILL.md +110 -0
- package/skills/dingtalk-agent-compose/assets/AGENTS.template.md +26 -0
- package/skills/dingtalk-agent-compose/assets/agent.bindings.dingtalk-doc.template.json +13 -0
- package/skills/dingtalk-agent-compose/assets/agent.bindings.local.template.json +13 -0
- package/skills/dingtalk-agent-compose/assets/opencode.template.json +12 -0
- package/skills/dingtalk-agent-compose/assets/role-skill.template.md +24 -0
- package/skills/dingtalk-agent-compose/evals/evals.json +94 -0
- package/skills/dingtalk-agent-compose/references/agent-definition-contract.md +55 -0
- package/skills/dingtalk-agent-compose/references/opencode-host-contract.md +65 -0
- package/skills/dingtalk-agent-compose/references/storage-routing.md +20 -0
- package/skills/dingtalk-agent-deploy/SKILL.md +60 -0
- package/skills/dingtalk-agent-deploy/references/multica-deployment-contract.md +49 -0
- package/skills/dingtalk-agent-deploy/references/promotion-observation-contract.md +49 -0
- package/skills/dingtalk-agent-eval/SKILL.md +116 -0
- package/skills/dingtalk-agent-eval/assets/eval-catalog.template.json +18 -0
- package/skills/dingtalk-agent-eval/evals/evals.json +61 -0
- package/skills/dingtalk-agent-eval/references/eval-topology.md +34 -0
- package/skills/dingtalk-agent-eval/references/evidence-contract.md +31 -0
- package/skills/dingtalk-agent-eval/references/scenario-taxonomy.md +25 -0
- package/skills/dingtalk-agent-eval/references/storage-modes.md +75 -0
- package/skills/dingtalk-basic-behavior/SKILL.md +63 -3
- package/skills/dingtalk-basic-behavior/assets/memory-candidate-proposal.json +10 -0
- package/skills/dingtalk-basic-behavior/assets/{task-checkpoint.md → task-checkpoint.json} +2 -21
- package/skills/dingtalk-basic-behavior/references/action-contract.md +2 -0
- package/skills/dingtalk-basic-behavior/references/memory-and-evolution.md +15 -1
- package/skills/dingtalk-basic-behavior/references/perception-and-gates.md +28 -0
- package/skills/dingtalk-basic-behavior/references/task-lifecycle.md +32 -7
- package/dist/src/boot.js +0 -70
- package/dist/src/boot.js.map +0 -1
- package/dist/src/duty.js +0 -74
- package/dist/src/duty.js.map +0 -1
- package/dist/src/kb.js +0 -240
- package/dist/src/kb.js.map +0 -1
- package/dist/src/runs.js +0 -79
- package/dist/src/runs.js.map +0 -1
- package/docs/ARCHITECTURE.md +0 -217
- package/docs/MINIMAL-WORKSPACE-V1.md +0 -172
- package/docs/OPEN-SOURCE-REFERENCES.md +0 -107
- package/docs/SELF-TEST.md +0 -252
- package/docs//345/206/205/347/275/221/345/256/236/347/233/270.md +0 -77
- package/evals/baselines/2026-07-14/behavior-summary.json +0 -28
- package/evals/baselines/2026-07-14/contract-summary.json +0 -18
- package/evals/baselines/2026-07-14/live-canary-summary.json +0 -25
- package/evals/baselines/2026-07-15/dingtalk-basic-behavior-0.3.0/SKILL.md +0 -72
- package/evals/baselines/2026-07-15/dingtalk-basic-behavior-0.3.0/references/action-contract.md +0 -31
- package/evals/baselines/2026-07-15/dingtalk-basic-behavior-0.3.0/references/event-to-behavior.md +0 -22
- package/evals/baselines/2026-07-15/dingtalk-basic-behavior-0.3.0/references/memory-and-evolution.md +0 -25
- package/evals/baselines/2026-07-15/dingtalk-basic-behavior-0.3.0/references/runtime-modes.md +0 -34
- package/evals/baselines/2026-07-15/task-lifecycle-summary.json +0 -50
- package/evals/evals.json +0 -316
- package/evals/fixtures/dm-ambiguous-send.json +0 -4
- package/evals/fixtures/dm-blocked.json +0 -4
- package/evals/fixtures/dm-clear.json +0 -4
- package/evals/fixtures/dm-discussion.json +0 -4
- package/evals/fixtures/dm-doc-write-no-tool.json +0 -4
- package/evals/fixtures/dm-long-task-ack.json +0 -4
- package/evals/fixtures/dm-nonblocking-gap.json +0 -4
- package/evals/fixtures/dm-structured-task.json +0 -4
- package/evals/fixtures/group.json +0 -10
- package/evals/fixtures/mentioned.json +0 -3
- package/evals/run-contract-evals.mjs +0 -1106
- package/evals/run-shadow-evals.mjs +0 -267
- package/evals/runners/README.md +0 -66
- package/evals/runners/claude-shadow.mjs +0 -533
- package/evals/schemas/action-request.schema.json +0 -77
- package/evals/shadow-evals.json +0 -133
- package/skills/AGENTS.md +0 -104
- package/skills//344/273/273/345/212/241.md +0 -48
- package/skills//345/237/272/347/241/200/350/241/214/344/270/272.md +0 -44
- package/skills//345/277/203/350/267/263.md +0 -79
- package/skills//346/266/210/346/201/257.md +0 -50
- package/skills//347/237/245/350/257/206.md +0 -55
- package/skills//350/257/204/346/265/213.md +0 -62
- package/skills//351/222/211/351/222/211.md +0 -64
- package/templates/ontology/index.md +0 -24
- package/templates/ontology/self/access.md +0 -38
- package/templates/ontology/self/role-spec.md +0 -34
- package/templates/ontology/self/workspace.md +0 -41
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://github.com/D1-2004/dingtalk-agent/docs/schemas/project.schema.json",
|
|
4
|
+
"title": "dingtalk-agent Agent Project",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["$schema", "name", "dtaVersion", "agent", "workspaces"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"$schema": { "const": "dingtalk-agent/project@1" },
|
|
10
|
+
"name": { "$ref": "#/$defs/name" },
|
|
11
|
+
"dtaVersion": { "type": "string", "minLength": 1 },
|
|
12
|
+
"agentPlatform": { "enum": ["multica-dingtalk", "deap"] },
|
|
13
|
+
"agent": {
|
|
14
|
+
"type": "object",
|
|
15
|
+
"additionalProperties": false,
|
|
16
|
+
"required": ["definition", "skills"],
|
|
17
|
+
"properties": {
|
|
18
|
+
"definition": { "type": "string", "minLength": 1 },
|
|
19
|
+
"skills": {
|
|
20
|
+
"type": "array",
|
|
21
|
+
"minItems": 1,
|
|
22
|
+
"uniqueItems": true,
|
|
23
|
+
"contains": { "const": "dingtalk-basic-behavior" },
|
|
24
|
+
"items": { "$ref": "#/$defs/name" }
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
"workspaces": {
|
|
29
|
+
"type": "object",
|
|
30
|
+
"propertyNames": {
|
|
31
|
+
"allOf": [
|
|
32
|
+
{ "$ref": "#/$defs/name" },
|
|
33
|
+
{ "not": { "const": "legacy-prepared" } }
|
|
34
|
+
]
|
|
35
|
+
},
|
|
36
|
+
"additionalProperties": { "$ref": "#/$defs/workspace" }
|
|
37
|
+
}
|
|
38
|
+
},
|
|
39
|
+
"$defs": {
|
|
40
|
+
"name": {
|
|
41
|
+
"type": "string",
|
|
42
|
+
"pattern": "^[a-z0-9](?:[a-z0-9._-]{0,62}[a-z0-9])?$"
|
|
43
|
+
},
|
|
44
|
+
"envRef": {
|
|
45
|
+
"type": "string",
|
|
46
|
+
"pattern": "^env:[A-Z_][A-Z0-9_]*$"
|
|
47
|
+
},
|
|
48
|
+
"storage": {
|
|
49
|
+
"type": "object",
|
|
50
|
+
"additionalProperties": false,
|
|
51
|
+
"required": ["memory", "knowledge"],
|
|
52
|
+
"properties": {
|
|
53
|
+
"memory": { "type": "string", "pattern": "^(local-md|dingtalk-doc):.+$" },
|
|
54
|
+
"knowledge": { "type": "string", "pattern": "^(local-md|dingtalk-doc):.+$" },
|
|
55
|
+
"artifacts": { "type": "string", "pattern": "^local-dir:.+$" }
|
|
56
|
+
}
|
|
57
|
+
},
|
|
58
|
+
"authority": {
|
|
59
|
+
"type": "object",
|
|
60
|
+
"additionalProperties": false,
|
|
61
|
+
"required": ["dwsProfileFrom", "expectedUserIdFrom"],
|
|
62
|
+
"properties": {
|
|
63
|
+
"dwsProfileFrom": { "$ref": "#/$defs/envRef" },
|
|
64
|
+
"expectedUserIdFrom": { "$ref": "#/$defs/envRef" }
|
|
65
|
+
}
|
|
66
|
+
},
|
|
67
|
+
"opencodeProvider": {
|
|
68
|
+
"type": "object",
|
|
69
|
+
"additionalProperties": false,
|
|
70
|
+
"required": ["kind", "model"],
|
|
71
|
+
"properties": {
|
|
72
|
+
"kind": { "const": "opencode" },
|
|
73
|
+
"model": { "type": "string", "minLength": 1 }
|
|
74
|
+
}
|
|
75
|
+
},
|
|
76
|
+
"multicaProvider": {
|
|
77
|
+
"type": "object",
|
|
78
|
+
"additionalProperties": false,
|
|
79
|
+
"required": ["kind", "profile", "workspaceIdFrom", "runtimeIdFrom"],
|
|
80
|
+
"properties": {
|
|
81
|
+
"kind": { "const": "multica" },
|
|
82
|
+
"profile": { "type": "string", "minLength": 1 },
|
|
83
|
+
"workspaceIdFrom": { "$ref": "#/$defs/envRef" },
|
|
84
|
+
"runtimeIdFrom": { "$ref": "#/$defs/envRef" },
|
|
85
|
+
"agentIdFrom": { "$ref": "#/$defs/envRef" }
|
|
86
|
+
}
|
|
87
|
+
},
|
|
88
|
+
"workspace": {
|
|
89
|
+
"type": "object",
|
|
90
|
+
"additionalProperties": false,
|
|
91
|
+
"required": ["stage", "provider", "storage"],
|
|
92
|
+
"properties": {
|
|
93
|
+
"stage": { "enum": ["dev", "test", "staging", "prod"] },
|
|
94
|
+
"provider": {
|
|
95
|
+
"oneOf": [
|
|
96
|
+
{ "$ref": "#/$defs/opencodeProvider" },
|
|
97
|
+
{ "$ref": "#/$defs/multicaProvider" }
|
|
98
|
+
]
|
|
99
|
+
},
|
|
100
|
+
"storage": { "$ref": "#/$defs/storage" },
|
|
101
|
+
"authority": { "$ref": "#/$defs/authority" }
|
|
102
|
+
},
|
|
103
|
+
"allOf": [
|
|
104
|
+
{
|
|
105
|
+
"if": {
|
|
106
|
+
"properties": { "provider": { "properties": { "kind": { "const": "multica" } } } }
|
|
107
|
+
},
|
|
108
|
+
"then": { "required": ["authority"] }
|
|
109
|
+
}
|
|
110
|
+
]
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://github.com/D1-2004/dingtalk-agent/docs/schemas/promotion-list.schema.json",
|
|
4
|
+
"title": "dingtalk-agent Promotion List",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["$schema", "promotions", "remoteRead", "remoteWrite", "localWrite", "triggerWrite", "sideEffect", "dingtalkSideEffect"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"$schema": { "const": "dingtalk-agent/promotion-list@1" },
|
|
10
|
+
"promotions": {
|
|
11
|
+
"type": "array",
|
|
12
|
+
"items": {
|
|
13
|
+
"type": "object",
|
|
14
|
+
"additionalProperties": false,
|
|
15
|
+
"required": ["promotionId", "receiptId", "routeId", "status", "passed", "sourceHash", "evalEvidenceHash", "deploymentHash", "observedHash"],
|
|
16
|
+
"properties": {
|
|
17
|
+
"promotionId": { "$ref": "promotion-plan.schema.json#/$defs/id" },
|
|
18
|
+
"receiptId": { "$ref": "promotion-plan.schema.json#/$defs/id" },
|
|
19
|
+
"routeId": { "$ref": "promotion-plan.schema.json#/$defs/name" },
|
|
20
|
+
"status": { "enum": ["promoted", "verifying", "failed"] },
|
|
21
|
+
"passed": { "type": "boolean" },
|
|
22
|
+
"sourceHash": { "$ref": "promotion-plan.schema.json#/$defs/hash" },
|
|
23
|
+
"evalEvidenceHash": { "$ref": "promotion-plan.schema.json#/$defs/hash" },
|
|
24
|
+
"deploymentHash": { "$ref": "promotion-plan.schema.json#/$defs/hash" },
|
|
25
|
+
"observedHash": { "$ref": "promotion-plan.schema.json#/$defs/hash" }
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
"remoteRead": { "const": false },
|
|
30
|
+
"remoteWrite": { "const": false },
|
|
31
|
+
"localWrite": { "const": false },
|
|
32
|
+
"triggerWrite": { "const": false },
|
|
33
|
+
"sideEffect": { "const": false },
|
|
34
|
+
"dingtalkSideEffect": { "const": false }
|
|
35
|
+
}
|
|
36
|
+
}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://github.com/D1-2004/dingtalk-agent/docs/schemas/promotion-plan.schema.json",
|
|
4
|
+
"title": "dingtalk-agent Promotion Plan",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["$schema", "planId", "routeId", "policyPath", "policyHash", "source", "eval", "target", "deployment", "blocking", "requiresPlanId", "requiresExplicitYes", "remoteRead", "remoteWrite", "localWrite", "triggerWrite", "sideEffect", "dingtalkSideEffect"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"$schema": { "const": "dingtalk-agent/promotion-plan@1" },
|
|
10
|
+
"planId": { "$ref": "#/$defs/id" }, "routeId": { "$ref": "#/$defs/name" },
|
|
11
|
+
"policyPath": { "type": "string", "minLength": 1 }, "policyHash": { "$ref": "#/$defs/hash" },
|
|
12
|
+
"source": { "$ref": "#/$defs/source" }, "eval": { "$ref": "#/$defs/eval" },
|
|
13
|
+
"target": { "$ref": "#/$defs/target" },
|
|
14
|
+
"deployment": { "$ref": "multica-deployment-plan.schema.json" },
|
|
15
|
+
"blocking": { "type": "array", "uniqueItems": true, "items": { "type": "string", "minLength": 1 } },
|
|
16
|
+
"requiresPlanId": { "const": true }, "requiresExplicitYes": { "const": true },
|
|
17
|
+
"remoteRead": { "const": false }, "remoteWrite": { "const": false }, "localWrite": { "const": false },
|
|
18
|
+
"triggerWrite": { "const": false }, "sideEffect": { "const": false }, "dingtalkSideEffect": { "const": false }
|
|
19
|
+
},
|
|
20
|
+
"$defs": {
|
|
21
|
+
"id": { "type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{1,127}$" },
|
|
22
|
+
"name": { "type": "string", "pattern": "^[a-z0-9](?:[a-z0-9._-]{0,62}[a-z0-9])?$" },
|
|
23
|
+
"hash": { "type": "string", "pattern": "^[a-f0-9]{64}$" },
|
|
24
|
+
"source": {
|
|
25
|
+
"type": "object", "additionalProperties": false,
|
|
26
|
+
"required": ["workspace", "stage", "sourceHash", "desiredHash", "observedHash", "definitionHash", "skills"],
|
|
27
|
+
"properties": {
|
|
28
|
+
"workspace": { "$ref": "#/$defs/name" }, "stage": { "enum": ["dev", "test", "staging", "prod"] },
|
|
29
|
+
"sourceHash": { "$ref": "#/$defs/hash" }, "desiredHash": { "$ref": "#/$defs/hash" },
|
|
30
|
+
"observedHash": { "$ref": "#/$defs/hash" }, "definitionHash": { "$ref": "#/$defs/hash" },
|
|
31
|
+
"skills": { "type": "array", "minItems": 2, "items": { "type": "object", "additionalProperties": false, "required": ["name", "hash"], "properties": { "name": { "$ref": "#/$defs/name" }, "hash": { "$ref": "#/$defs/hash" } } } }
|
|
32
|
+
}
|
|
33
|
+
},
|
|
34
|
+
"eval": {
|
|
35
|
+
"type": "object", "additionalProperties": false,
|
|
36
|
+
"required": ["runId", "evidencePath", "evidenceHash", "planHash", "suiteHash", "reportHash", "suiteId", "model", "runs", "configurations", "caseIds", "requiredSurfaces", "loadGate", "hardGate", "falseCompletionGate", "behaviorGate"],
|
|
37
|
+
"properties": {
|
|
38
|
+
"runId": { "type": "string" }, "evidencePath": { "type": "string" },
|
|
39
|
+
"evidenceHash": { "$ref": "#/$defs/hash" }, "planHash": { "$ref": "#/$defs/hash" },
|
|
40
|
+
"suiteHash": { "$ref": "#/$defs/hash" }, "reportHash": { "$ref": "#/$defs/hash" },
|
|
41
|
+
"suiteId": { "type": "string" }, "model": { "type": "string" },
|
|
42
|
+
"runs": { "type": "integer", "minimum": 0, "maximum": 10 },
|
|
43
|
+
"configurations": { "type": "array", "uniqueItems": true, "items": { "type": "string" } },
|
|
44
|
+
"caseIds": { "type": "array", "uniqueItems": true, "items": { "$ref": "#/$defs/name" } },
|
|
45
|
+
"requiredSurfaces": { "type": "array", "uniqueItems": true, "items": { "enum": ["response", "filesystem", "workspace", "artifact"] } },
|
|
46
|
+
"loadGate": { "type": "boolean" }, "hardGate": { "type": "boolean" },
|
|
47
|
+
"falseCompletionGate": { "type": "boolean" }, "behaviorGate": { "type": "boolean" }
|
|
48
|
+
}
|
|
49
|
+
},
|
|
50
|
+
"target": {
|
|
51
|
+
"type": "object", "additionalProperties": false,
|
|
52
|
+
"required": ["workspace", "stage", "desiredHash", "deploymentHash", "deploymentPlanId"],
|
|
53
|
+
"properties": {
|
|
54
|
+
"workspace": { "$ref": "#/$defs/name" }, "stage": { "enum": ["dev", "test", "staging", "prod"] },
|
|
55
|
+
"desiredHash": { "$ref": "#/$defs/hash" }, "deploymentHash": { "$ref": "#/$defs/hash" },
|
|
56
|
+
"deploymentPlanId": { "$ref": "#/$defs/id" }
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://github.com/D1-2004/dingtalk-agent/docs/schemas/promotion-policy.schema.json",
|
|
4
|
+
"title": "dingtalk-agent Promotion Policy",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["$schema", "routes"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"$schema": { "const": "dingtalk-agent/promotion-policy@1" },
|
|
10
|
+
"routes": {
|
|
11
|
+
"type": "array", "minItems": 1, "maxItems": 32,
|
|
12
|
+
"items": {
|
|
13
|
+
"type": "object", "additionalProperties": false,
|
|
14
|
+
"required": ["id", "fromWorkspace", "toWorkspace", "suite", "minimumRuns", "requiredCases", "requiredSurfaces", "requireBehaviorGate"],
|
|
15
|
+
"properties": {
|
|
16
|
+
"id": { "$ref": "#/$defs/name" },
|
|
17
|
+
"fromWorkspace": { "$ref": "#/$defs/name" },
|
|
18
|
+
"toWorkspace": { "$ref": "#/$defs/name" },
|
|
19
|
+
"suite": { "type": "string", "minLength": 1 },
|
|
20
|
+
"minimumRuns": { "type": "integer", "minimum": 1, "maximum": 10 },
|
|
21
|
+
"requiredCases": { "type": "array", "minItems": 1, "maxItems": 30, "uniqueItems": true, "items": { "$ref": "#/$defs/name" } },
|
|
22
|
+
"requiredSurfaces": { "type": "array", "minItems": 1, "uniqueItems": true, "items": { "enum": ["response", "filesystem", "workspace", "artifact"] } },
|
|
23
|
+
"requireBehaviorGate": { "type": "boolean" }
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
"$defs": { "name": { "type": "string", "pattern": "^[a-z0-9](?:[a-z0-9._-]{0,62}[a-z0-9])?$" } }
|
|
29
|
+
}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://github.com/D1-2004/dingtalk-agent/docs/schemas/promotion-receipt.schema.json",
|
|
4
|
+
"title": "dingtalk-agent Promotion Receipt",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["$schema", "promotionId", "receiptId", "planId", "routeId", "policyHash", "status", "passed", "idempotent", "source", "eval", "target", "linkHash", "failures", "evidencePath", "remoteRead", "remoteWrite", "localWrite", "triggerWrite", "sideEffect", "dingtalkSideEffect"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"$schema": { "const": "dingtalk-agent/promotion-receipt@1" },
|
|
10
|
+
"promotionId": { "$ref": "promotion-plan.schema.json#/$defs/id" },
|
|
11
|
+
"receiptId": { "$ref": "promotion-plan.schema.json#/$defs/id" },
|
|
12
|
+
"planId": { "$ref": "promotion-plan.schema.json#/$defs/id" },
|
|
13
|
+
"routeId": { "$ref": "promotion-plan.schema.json#/$defs/name" },
|
|
14
|
+
"policyHash": { "$ref": "promotion-plan.schema.json#/$defs/hash" },
|
|
15
|
+
"status": { "enum": ["promoted", "verifying", "failed"] }, "passed": { "type": "boolean" },
|
|
16
|
+
"idempotent": { "type": "boolean" },
|
|
17
|
+
"source": { "$ref": "promotion-plan.schema.json#/$defs/source" },
|
|
18
|
+
"eval": { "$ref": "promotion-plan.schema.json#/$defs/eval" },
|
|
19
|
+
"target": {
|
|
20
|
+
"type": "object",
|
|
21
|
+
"additionalProperties": false,
|
|
22
|
+
"required": ["workspace", "stage", "desiredHash", "deploymentHash", "deploymentPlanId", "deploymentReceiptId", "deploymentOperationId", "deploymentReceiptPath", "deploymentReceiptHash", "observedHash"],
|
|
23
|
+
"properties": {
|
|
24
|
+
"workspace": { "$ref": "promotion-plan.schema.json#/$defs/name" },
|
|
25
|
+
"stage": { "enum": ["dev", "test", "staging", "prod"] },
|
|
26
|
+
"desiredHash": { "$ref": "promotion-plan.schema.json#/$defs/hash" },
|
|
27
|
+
"deploymentHash": { "$ref": "promotion-plan.schema.json#/$defs/hash" },
|
|
28
|
+
"deploymentPlanId": { "$ref": "promotion-plan.schema.json#/$defs/id" },
|
|
29
|
+
"deploymentReceiptId": { "$ref": "promotion-plan.schema.json#/$defs/id" },
|
|
30
|
+
"deploymentOperationId": { "$ref": "promotion-plan.schema.json#/$defs/id" },
|
|
31
|
+
"deploymentReceiptPath": { "type": "string", "minLength": 1 },
|
|
32
|
+
"deploymentReceiptHash": { "$ref": "promotion-plan.schema.json#/$defs/hash" },
|
|
33
|
+
"observedHash": { "$ref": "promotion-plan.schema.json#/$defs/hash" }
|
|
34
|
+
}
|
|
35
|
+
},
|
|
36
|
+
"linkHash": { "$ref": "promotion-plan.schema.json#/$defs/hash" },
|
|
37
|
+
"failures": { "type": "array", "items": { "type": "string" } },
|
|
38
|
+
"evidencePath": { "type": "string", "minLength": 1 },
|
|
39
|
+
"remoteRead": { "type": "boolean" }, "remoteWrite": { "type": "boolean" }, "localWrite": { "const": true },
|
|
40
|
+
"triggerWrite": { "const": false }, "sideEffect": { "enum": ["multica-read-write", "multica-read", "none"] },
|
|
41
|
+
"dingtalkSideEffect": { "const": false }
|
|
42
|
+
}
|
|
43
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://github.com/D1-2004/dingtalk-agent/docs/schemas/promotion-status.schema.json",
|
|
4
|
+
"title": "dingtalk-agent Promotion Status",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["$schema", "available", "promotionId", "status", "passed", "integrity", "receipt", "remoteRead", "remoteWrite", "localWrite", "triggerWrite", "sideEffect", "dingtalkSideEffect"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"$schema": { "const": "dingtalk-agent/promotion-status@1" },
|
|
10
|
+
"available": { "type": "boolean" },
|
|
11
|
+
"promotionId": { "type": "string" },
|
|
12
|
+
"status": { "enum": ["promoted", "verifying", "failed", "missing"] },
|
|
13
|
+
"passed": { "type": "boolean" },
|
|
14
|
+
"integrity": { "type": "boolean" },
|
|
15
|
+
"receipt": { "oneOf": [{ "$ref": "promotion-receipt.schema.json" }, { "type": "null" }] },
|
|
16
|
+
"remoteRead": { "const": false },
|
|
17
|
+
"remoteWrite": { "const": false },
|
|
18
|
+
"localWrite": { "const": false },
|
|
19
|
+
"triggerWrite": { "const": false },
|
|
20
|
+
"sideEffect": { "const": false },
|
|
21
|
+
"dingtalkSideEffect": { "const": false }
|
|
22
|
+
}
|
|
23
|
+
}
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://github.com/D1-2004/dingtalk-agent/docs/schemas/release-readiness.schema.json",
|
|
4
|
+
"title": "dingtalk-agent Release Readiness",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["$schema", "passed", "version", "tarball", "install", "smoke", "sideEffects", "limitations"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"$schema": { "const": "dingtalk-agent/release-readiness@1" },
|
|
10
|
+
"passed": { "const": true },
|
|
11
|
+
"version": { "type": "string", "pattern": "^\\d+\\.\\d+\\.\\d+-beta\\.\\d+$" },
|
|
12
|
+
"tarball": {
|
|
13
|
+
"type": "object", "additionalProperties": false,
|
|
14
|
+
"required": ["filename", "sha256", "files", "packageSize", "unpackedSize", "requiredFiles", "forbiddenFiles"],
|
|
15
|
+
"properties": {
|
|
16
|
+
"filename": { "type": "string", "pattern": "^[A-Za-z0-9._-]+\\.tgz$" },
|
|
17
|
+
"sha256": { "type": "string", "pattern": "^[a-f0-9]{64}$" },
|
|
18
|
+
"files": { "type": "integer", "minimum": 1 },
|
|
19
|
+
"packageSize": { "type": "integer", "minimum": 1 },
|
|
20
|
+
"unpackedSize": { "type": "integer", "minimum": 1 },
|
|
21
|
+
"requiredFiles": { "type": "integer", "minimum": 1 },
|
|
22
|
+
"forbiddenFiles": { "const": 0 }
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
"install": {
|
|
26
|
+
"type": "object", "additionalProperties": false,
|
|
27
|
+
"required": ["offlineTarball", "cliEntries", "versionMatched", "canonicalSkillCopies", "composeSkillCopies", "clientsReady"],
|
|
28
|
+
"properties": {
|
|
29
|
+
"offlineTarball": { "const": true },
|
|
30
|
+
"cliEntries": { "const": 2 },
|
|
31
|
+
"versionMatched": { "const": true },
|
|
32
|
+
"canonicalSkillCopies": { "const": 1 },
|
|
33
|
+
"composeSkillCopies": { "const": 1 },
|
|
34
|
+
"clientsReady": { "const": 3 }
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
"smoke": {
|
|
38
|
+
"type": "object", "additionalProperties": false,
|
|
39
|
+
"required": ["setup", "doctor", "bootstrapDirect", "labEvalPlanOnly", "upgradeFromTarball", "rollbackDryRun"],
|
|
40
|
+
"properties": {
|
|
41
|
+
"setup": { "const": true },
|
|
42
|
+
"doctor": { "const": true },
|
|
43
|
+
"bootstrapDirect": { "const": true },
|
|
44
|
+
"labEvalPlanOnly": { "const": true },
|
|
45
|
+
"upgradeFromTarball": { "const": true },
|
|
46
|
+
"rollbackDryRun": { "const": true }
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
"sideEffects": {
|
|
50
|
+
"type": "object", "additionalProperties": false,
|
|
51
|
+
"required": ["registryPublish", "gitTag", "githubRelease", "dingtalk", "multica", "trigger"],
|
|
52
|
+
"properties": {
|
|
53
|
+
"registryPublish": { "const": false },
|
|
54
|
+
"gitTag": { "const": false },
|
|
55
|
+
"githubRelease": { "const": false },
|
|
56
|
+
"dingtalk": { "const": false },
|
|
57
|
+
"multica": { "const": false },
|
|
58
|
+
"trigger": { "const": false }
|
|
59
|
+
}
|
|
60
|
+
},
|
|
61
|
+
"limitations": {
|
|
62
|
+
"type": "array", "minItems": 1,
|
|
63
|
+
"items": { "type": "string", "minLength": 1 }
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://dingtalk-agent.dev/schemas/remote-semantic-state-live-eval.schema.json",
|
|
4
|
+
"title": "dingtalk-agent Remote Semantic State Live Eval",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": [
|
|
8
|
+
"$schema", "id", "scenario", "liveAuthorized", "provider", "requiredSkills",
|
|
9
|
+
"evidenceRoot", "write"
|
|
10
|
+
],
|
|
11
|
+
"properties": {
|
|
12
|
+
"$schema": { "const": "dingtalk-agent/remote-semantic-state-live-eval@1" },
|
|
13
|
+
"id": { "type": "string", "pattern": "^[a-z0-9][a-z0-9._-]*$" },
|
|
14
|
+
"scenario": { "const": "memory-and-storage" },
|
|
15
|
+
"liveAuthorized": { "enum": ["yes", "no"] },
|
|
16
|
+
"provider": { "$ref": "remote-semantic-state-provider.schema.json" },
|
|
17
|
+
"requiredSkills": {
|
|
18
|
+
"type": "array",
|
|
19
|
+
"minItems": 2,
|
|
20
|
+
"uniqueItems": true,
|
|
21
|
+
"items": { "type": "string", "minLength": 1 }
|
|
22
|
+
},
|
|
23
|
+
"evidenceRoot": { "type": "string", "pattern": "^\\.dingtalk-agent/.+" },
|
|
24
|
+
"write": {
|
|
25
|
+
"type": "object",
|
|
26
|
+
"additionalProperties": false,
|
|
27
|
+
"required": [
|
|
28
|
+
"allowlist", "budget", "documentSlots", "aitableFields", "driftProbe",
|
|
29
|
+
"retainMarkers"
|
|
30
|
+
],
|
|
31
|
+
"properties": {
|
|
32
|
+
"allowlist": {
|
|
33
|
+
"type": "array",
|
|
34
|
+
"minItems": 3,
|
|
35
|
+
"maxItems": 3,
|
|
36
|
+
"uniqueItems": true,
|
|
37
|
+
"items": { "type": "string", "minLength": 1 }
|
|
38
|
+
},
|
|
39
|
+
"budget": { "type": "integer", "minimum": 1, "maximum": 10 },
|
|
40
|
+
"documentSlots": {
|
|
41
|
+
"type": "array",
|
|
42
|
+
"minItems": 2,
|
|
43
|
+
"maxItems": 2,
|
|
44
|
+
"uniqueItems": true,
|
|
45
|
+
"items": { "enum": ["l1", "l3"] }
|
|
46
|
+
},
|
|
47
|
+
"aitableFields": {
|
|
48
|
+
"type": "array",
|
|
49
|
+
"minItems": 1,
|
|
50
|
+
"maxItems": 2,
|
|
51
|
+
"uniqueItems": true,
|
|
52
|
+
"items": { "enum": ["summary", "nextAction"] }
|
|
53
|
+
},
|
|
54
|
+
"driftProbe": { "const": true },
|
|
55
|
+
"retainMarkers": { "const": true }
|
|
56
|
+
}
|
|
57
|
+
},
|
|
58
|
+
"nonAdocNegativeTestUri": { "type": "string", "minLength": 1 }
|
|
59
|
+
}
|
|
60
|
+
}
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://dingtalk-agent.dev/schemas/remote-semantic-state-manifest.schema.json",
|
|
4
|
+
"title": "dingtalk-agent Remote Semantic State Manifest",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": [
|
|
8
|
+
"$schema", "providerId", "providerHash", "scopeId", "definitionHash", "authority",
|
|
9
|
+
"layers", "nextAction", "stateHash", "controlState", "pulledAt", "hash"
|
|
10
|
+
],
|
|
11
|
+
"properties": {
|
|
12
|
+
"$schema": { "const": "dingtalk-agent/remote-semantic-state-manifest@1" },
|
|
13
|
+
"providerId": { "type": "string", "minLength": 1 },
|
|
14
|
+
"providerHash": { "$ref": "#/$defs/hash" },
|
|
15
|
+
"scopeId": { "type": "string", "minLength": 1 },
|
|
16
|
+
"definitionHash": { "$ref": "#/$defs/hash" },
|
|
17
|
+
"authority": {
|
|
18
|
+
"type": "object",
|
|
19
|
+
"additionalProperties": false,
|
|
20
|
+
"required": ["profile", "expectedUserId", "actualUserId"],
|
|
21
|
+
"properties": {
|
|
22
|
+
"profile": { "type": "string", "minLength": 1 },
|
|
23
|
+
"expectedUserId": { "type": "string", "minLength": 1 },
|
|
24
|
+
"actualUserId": { "type": "string", "minLength": 1 }
|
|
25
|
+
}
|
|
26
|
+
},
|
|
27
|
+
"layers": {
|
|
28
|
+
"type": "object",
|
|
29
|
+
"additionalProperties": false,
|
|
30
|
+
"required": ["l1", "l2", "l3"],
|
|
31
|
+
"properties": {
|
|
32
|
+
"l1": { "$ref": "#/$defs/layer" },
|
|
33
|
+
"l2": { "$ref": "#/$defs/layer" },
|
|
34
|
+
"l3": { "$ref": "#/$defs/layer" }
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
"nextAction": { "type": "string", "minLength": 1 },
|
|
38
|
+
"stateHash": { "$ref": "#/$defs/hash" },
|
|
39
|
+
"controlState": {
|
|
40
|
+
"type": "object",
|
|
41
|
+
"additionalProperties": false,
|
|
42
|
+
"required": ["provider", "remoteProjection", "excludedFromRemoteMarkdown"],
|
|
43
|
+
"properties": {
|
|
44
|
+
"provider": { "const": "host-atomic-store" },
|
|
45
|
+
"remoteProjection": { "const": false },
|
|
46
|
+
"excludedFromRemoteMarkdown": {
|
|
47
|
+
"type": "array",
|
|
48
|
+
"minItems": 6,
|
|
49
|
+
"uniqueItems": true,
|
|
50
|
+
"items": { "type": "string", "minLength": 1 }
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
},
|
|
54
|
+
"pulledAt": { "type": "string", "format": "date-time" },
|
|
55
|
+
"hash": { "$ref": "#/$defs/hash" }
|
|
56
|
+
},
|
|
57
|
+
"$defs": {
|
|
58
|
+
"hash": { "type": "string", "pattern": "^[a-f0-9]{64}$" },
|
|
59
|
+
"layer": {
|
|
60
|
+
"type": "object",
|
|
61
|
+
"additionalProperties": false,
|
|
62
|
+
"required": [
|
|
63
|
+
"slot", "semanticRole", "provider", "mode", "source", "mediaType",
|
|
64
|
+
"cachePath", "remoteHash", "cacheHash"
|
|
65
|
+
],
|
|
66
|
+
"properties": {
|
|
67
|
+
"slot": { "enum": ["l1", "l2", "l3"] },
|
|
68
|
+
"semanticRole": { "type": "string", "minLength": 1 },
|
|
69
|
+
"provider": { "enum": ["dingtalk-doc", "dingtalk-aitable"] },
|
|
70
|
+
"mode": { "type": "string", "minLength": 1 },
|
|
71
|
+
"source": { "type": "string", "minLength": 1 },
|
|
72
|
+
"mediaType": { "enum": ["ALIDOC/adoc", "application/json"] },
|
|
73
|
+
"cachePath": { "type": "string", "minLength": 1 },
|
|
74
|
+
"remoteHash": { "$ref": "#/$defs/hash" },
|
|
75
|
+
"cacheHash": { "$ref": "#/$defs/hash" }
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
}
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://dingtalk-agent.dev/schemas/remote-semantic-state-provider.schema.json",
|
|
4
|
+
"title": "dingtalk-agent Remote Semantic State Provider",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["$schema", "id", "scopeId", "authority", "layers", "controlState"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"$schema": { "const": "dingtalk-agent/remote-semantic-state-provider@1" },
|
|
10
|
+
"id": { "type": "string", "pattern": "^[a-z0-9][a-z0-9._-]*$" },
|
|
11
|
+
"scopeId": { "type": "string", "minLength": 1 },
|
|
12
|
+
"authority": {
|
|
13
|
+
"type": "object",
|
|
14
|
+
"additionalProperties": false,
|
|
15
|
+
"required": ["profile", "expectedUserId"],
|
|
16
|
+
"properties": {
|
|
17
|
+
"profile": { "type": "string", "minLength": 1, "pattern": "^[^,]+$" },
|
|
18
|
+
"expectedUserId": { "type": "string", "minLength": 1 }
|
|
19
|
+
}
|
|
20
|
+
},
|
|
21
|
+
"layers": {
|
|
22
|
+
"type": "object",
|
|
23
|
+
"additionalProperties": false,
|
|
24
|
+
"required": ["l1", "l2", "l3"],
|
|
25
|
+
"properties": {
|
|
26
|
+
"l1": {
|
|
27
|
+
"type": "object",
|
|
28
|
+
"additionalProperties": false,
|
|
29
|
+
"required": ["provider", "semanticRole", "mode", "uri"],
|
|
30
|
+
"properties": {
|
|
31
|
+
"provider": { "const": "dingtalk-doc" },
|
|
32
|
+
"semanticRole": { "const": "session-working-memory" },
|
|
33
|
+
"mode": { "const": "semantic-read-only-mirror" },
|
|
34
|
+
"uri": { "type": "string", "pattern": "^dingtalk-doc:.+" }
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
"l2": {
|
|
38
|
+
"type": "object",
|
|
39
|
+
"additionalProperties": false,
|
|
40
|
+
"required": [
|
|
41
|
+
"provider", "semanticRole", "mode", "baseId", "tableId", "recordId",
|
|
42
|
+
"expected", "fields"
|
|
43
|
+
],
|
|
44
|
+
"properties": {
|
|
45
|
+
"provider": { "const": "dingtalk-aitable" },
|
|
46
|
+
"semanticRole": { "const": "structured-hot-state" },
|
|
47
|
+
"mode": { "const": "business-fact-source" },
|
|
48
|
+
"baseId": { "type": "string", "minLength": 1 },
|
|
49
|
+
"tableId": { "type": "string", "minLength": 1 },
|
|
50
|
+
"recordId": { "type": "string", "minLength": 1 },
|
|
51
|
+
"expected": {
|
|
52
|
+
"type": "object",
|
|
53
|
+
"additionalProperties": false,
|
|
54
|
+
"required": ["key", "scopeId"],
|
|
55
|
+
"properties": {
|
|
56
|
+
"key": { "type": "string", "minLength": 1 },
|
|
57
|
+
"scopeId": { "type": "string", "minLength": 1 }
|
|
58
|
+
}
|
|
59
|
+
},
|
|
60
|
+
"fields": {
|
|
61
|
+
"type": "object",
|
|
62
|
+
"additionalProperties": false,
|
|
63
|
+
"required": ["key", "scopeId", "status", "nextAction", "summary", "sourceRefs"],
|
|
64
|
+
"properties": {
|
|
65
|
+
"key": { "type": "string", "minLength": 1 },
|
|
66
|
+
"scopeId": { "type": "string", "minLength": 1 },
|
|
67
|
+
"status": { "type": "string", "minLength": 1 },
|
|
68
|
+
"nextAction": { "type": "string", "minLength": 1 },
|
|
69
|
+
"summary": { "type": "string", "minLength": 1 },
|
|
70
|
+
"sourceRefs": { "type": "string", "minLength": 1 }
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
},
|
|
75
|
+
"l3": {
|
|
76
|
+
"type": "object",
|
|
77
|
+
"additionalProperties": false,
|
|
78
|
+
"required": ["provider", "semanticRole", "mode", "uri"],
|
|
79
|
+
"properties": {
|
|
80
|
+
"provider": { "const": "dingtalk-doc" },
|
|
81
|
+
"semanticRole": { "const": "long-term-knowledge" },
|
|
82
|
+
"mode": { "const": "reviewed-knowledge-source" },
|
|
83
|
+
"uri": { "type": "string", "pattern": "^dingtalk-doc:.+" }
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
},
|
|
88
|
+
"controlState": {
|
|
89
|
+
"type": "object",
|
|
90
|
+
"additionalProperties": false,
|
|
91
|
+
"required": ["provider", "remoteProjection"],
|
|
92
|
+
"properties": {
|
|
93
|
+
"provider": { "const": "host-atomic-store" },
|
|
94
|
+
"remoteProjection": { "const": false }
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://dingtalk-agent.dev/schemas/response-gate.schema.json",
|
|
4
|
+
"title": "Response Gate Snapshot",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["$schema", "decision", "reason", "hardAllowedActions", "softChecks", "perceptionHash", "hash"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"$schema": { "const": "dingtalk-agent/response-gate@1" },
|
|
10
|
+
"decision": { "enum": ["engage", "silent", "inspect"] },
|
|
11
|
+
"reason": { "type": "string" },
|
|
12
|
+
"hardAllowedActions": {
|
|
13
|
+
"type": "array",
|
|
14
|
+
"items": { "enum": ["ack", "reply", "ask", "silence"] }
|
|
15
|
+
},
|
|
16
|
+
"softChecks": { "type": "array", "items": { "type": "string" } },
|
|
17
|
+
"perceptionHash": { "type": "string" },
|
|
18
|
+
"hash": { "type": "string" }
|
|
19
|
+
}
|
|
20
|
+
}
|