@teamclaws/teamclaw 2026.3.26-2 → 2026.4.2-2
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/README.md +52 -8
- package/cli.mjs +538 -224
- package/index.ts +76 -27
- package/openclaw.plugin.json +53 -28
- package/package.json +5 -2
- package/skills/teamclaw/SKILL.md +213 -0
- package/skills/teamclaw/references/api-quick-ref.md +117 -0
- package/skills/teamclaw-setup/SKILL.md +81 -0
- package/skills/teamclaw-setup/references/install-modes.md +136 -0
- package/skills/teamclaw-setup/references/validation-checklist.md +73 -0
- package/src/config.ts +44 -16
- package/src/controller/controller-capacity.ts +2 -2
- package/src/controller/controller-service.ts +193 -47
- package/src/controller/controller-tools.ts +102 -2
- package/src/controller/delivery-report.ts +563 -0
- package/src/controller/http-server.ts +1907 -172
- package/src/controller/kickoff-orchestrator.ts +292 -0
- package/src/controller/managed-gateway-process.ts +330 -0
- package/src/controller/orchestration-manifest.ts +69 -1
- package/src/controller/preview-manager.ts +676 -0
- package/src/controller/prompt-injector.ts +116 -67
- package/src/controller/role-inference.ts +41 -0
- package/src/controller/websocket.ts +3 -1
- package/src/controller/worker-provisioning.ts +429 -74
- package/src/discovery.ts +1 -1
- package/src/git-collaboration.ts +198 -47
- package/src/identity.ts +12 -2
- package/src/interaction-contracts.ts +179 -3
- package/src/networking.ts +99 -0
- package/src/openclaw-workspace.ts +478 -11
- package/src/prompt-policy.ts +381 -0
- package/src/roles.ts +37 -36
- package/src/state.ts +40 -1
- package/src/task-executor.ts +282 -78
- package/src/types.ts +150 -7
- package/src/ui/app.js +1403 -175
- package/src/ui/assets/teamclaw-app-icon.png +0 -0
- package/src/ui/index.html +122 -40
- package/src/ui/style.css +829 -143
- package/src/worker/http-handler.ts +40 -4
- package/src/worker/prompt-injector.ts +9 -38
- package/src/worker/skill-installer.ts +2 -2
- package/src/worker/tools.ts +31 -5
- package/src/worker/worker-service.ts +49 -8
- package/src/workspace-browser.ts +20 -7
- package/src/controller/local-worker-manager.ts +0 -533
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
import type {
|
|
2
|
+
ClarificationQuestionOption,
|
|
3
|
+
ClarificationQuestionSchema,
|
|
2
4
|
ControllerManifestCreatedTask,
|
|
3
5
|
ControllerManifestDeferredTask,
|
|
4
6
|
ControllerOrchestrationManifest,
|
|
@@ -53,6 +55,67 @@ export function normalizeOptionalManifestText(raw: unknown): string | undefined
|
|
|
53
55
|
return normalized || undefined;
|
|
54
56
|
}
|
|
55
57
|
|
|
58
|
+
export function normalizeClarificationOptions(raw: unknown): ClarificationQuestionOption[] {
|
|
59
|
+
if (!Array.isArray(raw)) {
|
|
60
|
+
return [];
|
|
61
|
+
}
|
|
62
|
+
return raw
|
|
63
|
+
.filter((entry): entry is Record<string, unknown> => !!entry && typeof entry === "object")
|
|
64
|
+
.map((entry) => ({
|
|
65
|
+
value: typeof entry.value === "string" ? entry.value.trim() : "",
|
|
66
|
+
label: typeof entry.label === "string" ? entry.label.trim() : "",
|
|
67
|
+
hint: typeof entry.hint === "string" && entry.hint.trim() ? entry.hint.trim() : undefined,
|
|
68
|
+
}))
|
|
69
|
+
.filter((entry) => entry.value && entry.label);
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
export function normalizeClarificationQuestionSchema(raw: unknown): ClarificationQuestionSchema | undefined {
|
|
73
|
+
if (!raw || typeof raw !== "object") {
|
|
74
|
+
return undefined;
|
|
75
|
+
}
|
|
76
|
+
const input = raw as Record<string, unknown>;
|
|
77
|
+
const kind = typeof input.kind === "string" ? input.kind.trim() : "";
|
|
78
|
+
const title = typeof input.title === "string" ? input.title.trim() : "";
|
|
79
|
+
if (!title || !["single-select", "multi-select", "number", "text"].includes(kind)) {
|
|
80
|
+
return undefined;
|
|
81
|
+
}
|
|
82
|
+
const options = normalizeClarificationOptions(input.options);
|
|
83
|
+
const schema: ClarificationQuestionSchema = {
|
|
84
|
+
kind: kind as ClarificationQuestionSchema["kind"],
|
|
85
|
+
title,
|
|
86
|
+
description: normalizeOptionalManifestText(input.description),
|
|
87
|
+
required: input.required == null ? true : Boolean(input.required),
|
|
88
|
+
allowOther: Boolean(input.allowOther),
|
|
89
|
+
placeholder: normalizeOptionalManifestText(input.placeholder),
|
|
90
|
+
unit: normalizeOptionalManifestText(input.unit),
|
|
91
|
+
};
|
|
92
|
+
if (options.length > 0) {
|
|
93
|
+
schema.options = options;
|
|
94
|
+
}
|
|
95
|
+
if (typeof input.min === "number" && Number.isFinite(input.min)) {
|
|
96
|
+
schema.min = input.min;
|
|
97
|
+
}
|
|
98
|
+
if (typeof input.max === "number" && Number.isFinite(input.max)) {
|
|
99
|
+
schema.max = input.max;
|
|
100
|
+
}
|
|
101
|
+
if (typeof input.step === "number" && Number.isFinite(input.step)) {
|
|
102
|
+
schema.step = input.step;
|
|
103
|
+
}
|
|
104
|
+
if ((schema.kind === "single-select" || schema.kind === "multi-select") && (!schema.options || schema.options.length === 0)) {
|
|
105
|
+
return undefined;
|
|
106
|
+
}
|
|
107
|
+
return schema;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
export function normalizeClarificationQuestionSchemas(raw: unknown): ClarificationQuestionSchema[] {
|
|
111
|
+
if (!Array.isArray(raw)) {
|
|
112
|
+
return [];
|
|
113
|
+
}
|
|
114
|
+
return raw
|
|
115
|
+
.map((entry) => normalizeClarificationQuestionSchema(entry))
|
|
116
|
+
.filter((entry): entry is ClarificationQuestionSchema => Boolean(entry));
|
|
117
|
+
}
|
|
118
|
+
|
|
56
119
|
export function normalizeManifestCreatedTasks(raw: unknown): ControllerManifestCreatedTask[] {
|
|
57
120
|
if (!Array.isArray(raw)) {
|
|
58
121
|
return [];
|
|
@@ -91,15 +154,20 @@ export function normalizeControllerManifest(raw: unknown): ControllerOrchestrati
|
|
|
91
154
|
if (!requirementSummary) {
|
|
92
155
|
return null;
|
|
93
156
|
}
|
|
157
|
+
const clarificationSchemas = normalizeClarificationQuestionSchemas(input.clarificationSchemas);
|
|
158
|
+
const clarificationQuestions = normalizeManifestStringList(input.clarificationQuestions);
|
|
94
159
|
return {
|
|
95
160
|
version: typeof input.version === "string" && input.version.trim() ? input.version.trim() : "1.0",
|
|
161
|
+
projectName: typeof input.projectName === "string" && input.projectName.trim() ? input.projectName.trim() : undefined,
|
|
96
162
|
requirementSummary,
|
|
97
163
|
requiredRoles: normalizeManifestRoleList(input.requiredRoles),
|
|
98
164
|
clarificationsNeeded: Boolean(input.clarificationsNeeded),
|
|
99
|
-
clarificationQuestions:
|
|
165
|
+
clarificationQuestions: clarificationQuestions.length > 0 ? clarificationQuestions : clarificationSchemas.map((entry) => entry.title),
|
|
166
|
+
clarificationSchemas,
|
|
100
167
|
createdTasks: normalizeManifestCreatedTasks(input.createdTasks),
|
|
101
168
|
deferredTasks: normalizeManifestDeferredTasks(input.deferredTasks),
|
|
102
169
|
handoffPlan: normalizeOptionalManifestText(input.handoffPlan),
|
|
103
170
|
notes: normalizeOptionalManifestText(input.notes),
|
|
171
|
+
requirementFullyComplete: Boolean(input.requirementFullyComplete),
|
|
104
172
|
};
|
|
105
173
|
}
|