@elementumai/edk 0.8.0-preview.11 → 0.8.2-alpha.5
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 +510 -324
- package/dist-sdk/src/catalog/ai-provider-models.d.ts +30 -0
- package/dist-sdk/src/catalog/ai-provider-models.js +63 -0
- package/dist-sdk/src/catalog/factories.d.ts +56 -3
- package/dist-sdk/src/catalog/factories.js +83 -4
- package/dist-sdk/src/catalog/from-authoring.js +19 -2
- package/dist-sdk/src/catalog/index.d.ts +3 -2
- package/dist-sdk/src/catalog/index.js +3 -2
- package/dist-sdk/src/catalog/org.d.ts +1 -1
- package/dist-sdk/src/catalog/org.js +134 -50
- package/dist-sdk/src/catalog/render.d.ts +13 -1
- package/dist-sdk/src/catalog/render.js +21 -4
- package/dist-sdk/src/catalog/token.js +18 -0
- package/dist-sdk/src/catalog/types.d.ts +75 -3
- package/dist-sdk/src/catalog/types.js +3 -0
- package/dist-sdk/src/core/system-fields.d.ts +2 -0
- package/dist-sdk/src/core/system-fields.js +2 -0
- package/dist-sdk/src/core/types/ai-provider.d.ts +10 -23
- package/dist-sdk/src/core/types/ai-provider.js +1 -25
- package/dist-sdk/src/core/types/app.d.ts +26 -1
- package/dist-sdk/src/engine/build/context.d.ts +58 -0
- package/dist-sdk/src/engine/build/context.js +11 -1
- package/dist-sdk/src/engine/build/source-context.d.ts +45 -0
- package/dist-sdk/src/engine/build/source-context.js +23 -0
- package/dist-sdk/src/engine/pull/context.d.ts +15 -0
- package/dist-sdk/src/engine/pull/org.d.ts +10 -0
- package/dist-sdk/src/engine/pull/org.js +34 -4
- package/dist-sdk/src/engine/tf/index.d.ts +2 -2
- package/dist-sdk/src/engine/tf/index.js +2 -2
- package/dist-sdk/src/engine/tf/labels.d.ts +54 -0
- package/dist-sdk/src/engine/tf/labels.js +75 -0
- package/dist-sdk/src/engine/tf/parse.d.ts +15 -0
- package/dist-sdk/src/engine/tf/parse.js +162 -0
- package/dist-sdk/src/entities/access-policy/build.d.ts +26 -0
- package/dist-sdk/src/entities/access-policy/build.js +7 -0
- package/dist-sdk/src/entities/access-policy/filter.d.ts +61 -0
- package/dist-sdk/src/entities/access-policy/filter.js +83 -0
- package/dist-sdk/src/entities/access-policy/from-tf.d.ts +66 -0
- package/dist-sdk/src/entities/access-policy/from-tf.js +187 -0
- package/dist-sdk/src/entities/access-policy/module.d.ts +3 -0
- package/dist-sdk/src/entities/access-policy/module.js +17 -0
- package/dist-sdk/src/entities/access-policy/to-tf.d.ts +43 -0
- package/dist-sdk/src/entities/access-policy/to-tf.js +164 -0
- package/dist-sdk/src/entities/access-policy/types.d.ts +4 -0
- package/dist-sdk/src/entities/access-policy/types.js +10 -0
- package/dist-sdk/src/entities/agent/build.d.ts +2 -0
- package/dist-sdk/src/entities/agent/build.js +1 -0
- package/dist-sdk/src/entities/agent/deserializer/print-agent-v2.d.ts +38 -3
- package/dist-sdk/src/entities/agent/deserializer/print-agent-v2.js +257 -32
- package/dist-sdk/src/entities/agent/from-tf.d.ts +29 -9
- package/dist-sdk/src/entities/agent/from-tf.js +146 -19
- package/dist-sdk/src/entities/agent/index.d.ts +1 -1
- package/dist-sdk/src/entities/agent/module.js +14 -4
- package/dist-sdk/src/entities/agent/to-tf.d.ts +46 -1
- package/dist-sdk/src/entities/agent/to-tf.js +160 -14
- package/dist-sdk/src/entities/agent/tools.d.ts +88 -9
- package/dist-sdk/src/entities/agent/tools.js +46 -7
- package/dist-sdk/src/entities/agent-a2a-skill/from-tf.d.ts +17 -0
- package/dist-sdk/src/entities/agent-a2a-skill/from-tf.js +64 -0
- package/dist-sdk/src/entities/agent-a2a-skill/module.d.ts +4 -0
- package/dist-sdk/src/entities/agent-a2a-skill/module.js +14 -0
- package/dist-sdk/src/entities/agent-a2a-skill/to-tf.d.ts +40 -0
- package/dist-sdk/src/entities/agent-a2a-skill/to-tf.js +47 -0
- package/dist-sdk/src/entities/agent-tool/from-tf.d.ts +51 -4
- package/dist-sdk/src/entities/agent-tool/from-tf.js +131 -35
- package/dist-sdk/src/entities/agent-tool/to-tf.d.ts +11 -4
- package/dist-sdk/src/entities/agent-tool/to-tf.js +176 -30
- package/dist-sdk/src/entities/agent-tool/types.d.ts +5 -4
- package/dist-sdk/src/entities/agent-tool/types.js +38 -6
- package/dist-sdk/src/entities/app/build.d.ts +91 -13
- package/dist-sdk/src/entities/app/build.js +63 -5
- package/dist-sdk/src/entities/app/deserializer/normalize.d.ts +3 -0
- package/dist-sdk/src/entities/app/from-tf.d.ts +1 -1
- package/dist-sdk/src/entities/app/from-tf.js +32 -22
- package/dist-sdk/src/entities/app/index.d.ts +4 -1
- package/dist-sdk/src/entities/app/index.js +2 -1
- package/dist-sdk/src/entities/app/module.js +10 -2
- package/dist-sdk/src/entities/app/to-tf.d.ts +5 -0
- package/dist-sdk/src/entities/app/to-tf.js +45 -4
- package/dist-sdk/src/entities/automation/build.d.ts +57 -13
- package/dist-sdk/src/entities/automation/build.js +62 -42
- package/dist-sdk/src/entities/automation/deserializer/ast.d.ts +25 -8
- package/dist-sdk/src/entities/automation/deserializer/print-automation.d.ts +16 -1
- package/dist-sdk/src/entities/automation/deserializer/print-automation.js +206 -47
- package/dist-sdk/src/entities/automation/filter.d.ts +37 -3
- package/dist-sdk/src/entities/automation/filter.js +54 -3
- package/dist-sdk/src/entities/automation/from-tf.d.ts +26 -27
- package/dist-sdk/src/entities/automation/from-tf.js +1344 -222
- package/dist-sdk/src/entities/automation/index.d.ts +4 -0
- package/dist-sdk/src/entities/automation/index.js +4 -0
- package/dist-sdk/src/entities/automation/module.js +29 -32
- package/dist-sdk/src/entities/automation/operators.d.ts +29 -2
- package/dist-sdk/src/entities/automation/operators.js +27 -1
- package/dist-sdk/src/entities/automation/output-key-wire-name.d.ts +19 -0
- package/dist-sdk/src/entities/automation/output-key-wire-name.js +24 -0
- package/dist-sdk/src/entities/automation/script-code.d.ts +10 -21
- package/dist-sdk/src/entities/automation/script-code.js +272 -5
- package/dist-sdk/src/entities/automation/tasks.d.ts +125 -19
- package/dist-sdk/src/entities/automation/tasks.js +83 -15
- package/dist-sdk/src/entities/automation/to-tf.d.ts +10 -29
- package/dist-sdk/src/entities/automation/to-tf.js +1291 -230
- package/dist-sdk/src/entities/automation/triggers.d.ts +9 -1
- package/dist-sdk/src/entities/automation/types.d.ts +29 -4
- package/dist-sdk/src/entities/automation/types.js +76 -46
- package/dist-sdk/src/entities/element/build.d.ts +44 -13
- package/dist-sdk/src/entities/element/build.js +45 -3
- package/dist-sdk/src/entities/element/from-tf.d.ts +1 -1
- package/dist-sdk/src/entities/element/from-tf.js +28 -14
- package/dist-sdk/src/entities/element/index.d.ts +4 -1
- package/dist-sdk/src/entities/element/index.js +2 -1
- package/dist-sdk/src/entities/element/module.js +4 -1
- package/dist-sdk/src/entities/element/to-tf.js +26 -3
- package/dist-sdk/src/entities/field/build.d.ts +61 -14
- package/dist-sdk/src/entities/field/build.js +10 -0
- package/dist-sdk/src/entities/field/calc/runtime.js +4 -0
- package/dist-sdk/src/entities/field/from-tf.d.ts +5 -3
- package/dist-sdk/src/entities/field/from-tf.js +118 -7
- package/dist-sdk/src/entities/field/module.js +3 -2
- package/dist-sdk/src/entities/field/to-tf.d.ts +46 -11
- package/dist-sdk/src/entities/field/to-tf.js +166 -17
- package/dist-sdk/src/entities/field/types.d.ts +26 -0
- package/dist-sdk/src/entities/field/types.js +34 -12
- package/dist-sdk/src/entities/file-reader/build.d.ts +108 -50
- package/dist-sdk/src/entities/file-reader/build.js +23 -23
- package/dist-sdk/src/entities/file-reader/deserializer/print-file-reader.d.ts +6 -0
- package/dist-sdk/src/entities/file-reader/deserializer/print-file-reader.js +109 -0
- package/dist-sdk/src/entities/file-reader/from-tf.d.ts +13 -0
- package/dist-sdk/src/entities/file-reader/from-tf.js +172 -0
- package/dist-sdk/src/entities/file-reader/index.d.ts +8 -3
- package/dist-sdk/src/entities/file-reader/index.js +7 -2
- package/dist-sdk/src/entities/file-reader/module.d.ts +3 -0
- package/dist-sdk/src/entities/file-reader/module.js +115 -0
- package/dist-sdk/src/entities/file-reader/to-tf.d.ts +14 -0
- package/dist-sdk/src/entities/file-reader/to-tf.js +84 -0
- package/dist-sdk/src/entities/file-reader/types.d.ts +32 -0
- package/dist-sdk/src/entities/file-reader/types.js +30 -0
- package/dist-sdk/src/entities/org/ai-provider.d.ts +13 -0
- package/dist-sdk/src/entities/org/ai-provider.js +46 -0
- package/dist-sdk/src/entities/org/connector.d.ts +8 -1
- package/dist-sdk/src/entities/org/connector.js +12 -14
- package/dist-sdk/src/entities/org/group.js +10 -1
- package/dist-sdk/src/entities/org/index.d.ts +1 -0
- package/dist-sdk/src/entities/org/index.js +1 -0
- package/dist-sdk/src/entities/org/user.js +10 -1
- package/dist-sdk/src/entities/shared/filters/ast.d.ts +59 -9
- package/dist-sdk/src/entities/shared/filters/types.d.ts +1 -1
- package/dist-sdk/src/entities/shared/tool-field-ref.d.ts +17 -0
- package/dist-sdk/src/entities/shared/tool-field-ref.js +46 -0
- package/dist-sdk/src/entities/shared/types/field-types.d.ts +10 -1
- package/dist-sdk/src/entities/shared/types/field-types.js +9 -0
- package/dist-sdk/src/entities/skill/deserializer/print-skill-v2.d.ts +19 -0
- package/dist-sdk/src/entities/skill/deserializer/print-skill-v2.js +128 -11
- package/dist-sdk/src/entities/skill/from-tf.js +4 -3
- package/dist-sdk/src/entities/skill/index.d.ts +1 -1
- package/dist-sdk/src/entities/skill/module.js +7 -1
- package/dist-sdk/src/entities/skill/to-tf.d.ts +26 -0
- package/dist-sdk/src/entities/skill/to-tf.js +65 -4
- package/dist-sdk/src/entities/skill/tools.d.ts +37 -8
- package/dist-sdk/src/entities/skill/tools.js +43 -1
- package/dist-sdk/src/entities/skill-tool/from-tf.d.ts +34 -4
- package/dist-sdk/src/entities/skill-tool/from-tf.js +128 -18
- package/dist-sdk/src/entities/skill-tool/to-tf.d.ts +13 -1
- package/dist-sdk/src/entities/skill-tool/to-tf.js +164 -25
- package/dist-sdk/src/entities/skill-tool/types.d.ts +5 -7
- package/dist-sdk/src/entities/skill-tool/types.js +47 -11
- package/dist-sdk/src/entities/view/from-tf.d.ts +6 -2
- package/dist-sdk/src/entities/view/from-tf.js +11 -9
- package/dist-sdk/src/entities/view/to-tf.d.ts +9 -7
- package/dist-sdk/src/entities/view/to-tf.js +39 -18
- package/dist-sdk/src/entities/view/types.d.ts +1 -1
- package/dist-sdk/src/entities/view/types.js +1 -1
- package/dist-sdk/src/graph/deferred-catalog-render.d.ts +0 -5
- package/dist-sdk/src/graph/deferred-catalog-render.js +1 -20
- package/dist-sdk/src/graph/index.d.ts +8 -0
- package/dist-sdk/src/graph/index.js +13 -9
- package/dist-sdk/src/graph/modules.js +8 -1
- package/dist-sdk/src/graph/types.d.ts +98 -4
- package/package.json +49 -16
- package/dist-sdk/src/entities/automation/value-ref-tf.d.ts +0 -76
- package/dist-sdk/src/entities/automation/value-ref-tf.js +0 -190
|
@@ -14,10 +14,67 @@
|
|
|
14
14
|
* aren't authored yet, so there's nothing to emit for them.
|
|
15
15
|
*/
|
|
16
16
|
import { EntityTfError } from "../../engine/entity.js";
|
|
17
|
-
import { expr, tsLabelToTfLabel } from "../../engine/tf/index.js";
|
|
17
|
+
import { appScopedResourceLabel, expr, sanitizeName, tsLabelToTfLabel } from "../../engine/tf/index.js";
|
|
18
18
|
import { skillToolToTf } from "../skill-tool/to-tf.js";
|
|
19
19
|
import { APP_RESOURCE_TYPE } from "../app/module.js";
|
|
20
20
|
import { SKILL_RESOURCE_TYPE } from "./module.js";
|
|
21
|
+
function toSortableSkills(entities) {
|
|
22
|
+
const out = [];
|
|
23
|
+
for (const entity of entities) {
|
|
24
|
+
if (entity.kind !== "skill")
|
|
25
|
+
continue;
|
|
26
|
+
const payload = entity.payload;
|
|
27
|
+
out.push({ refName: entity.refName, name: payload?.skill?.name ?? "", tools: payload?.tools ?? [] });
|
|
28
|
+
}
|
|
29
|
+
return out;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* Mirrors ei's cross-skill tool-name disambiguation (`cmd/elementum/export/
|
|
33
|
+
* imports.go`'s `skillNames`/`toolNames` counting maps) — a same-app,
|
|
34
|
+
* same-named tool on two different skills is not a collision on the
|
|
35
|
+
* platform: ei's exporter walks `app.Skills` (each skill's tools in turn)
|
|
36
|
+
* and gives the first occurrence of a sanitized tool name the bare label,
|
|
37
|
+
* each later occurrence `_1`, `_2`, … Board issue #310's live capture
|
|
38
|
+
* (2026-08-18, against a deliberately-collided app) confirmed the walk
|
|
39
|
+
* order is ascending by the skill's display NAME — not creation order, not
|
|
40
|
+
* authoring-file order. Ordering of tools WITHIN one skill wasn't
|
|
41
|
+
* observable live (each capture skill carried only one tool); authored
|
|
42
|
+
* array order is assumed there pending a capture that can confirm it.
|
|
43
|
+
*
|
|
44
|
+
* Returns suffixes ("" for the first occurrence, "_1", "_2", … after)
|
|
45
|
+
* keyed by `${skillRefName}#${toolIndex}` — the tool's position in its own
|
|
46
|
+
* skill's authored `tools` array, NOT a global index.
|
|
47
|
+
*/
|
|
48
|
+
export function computeToolLabelSuffixes(siblingSkills) {
|
|
49
|
+
// refName tie-breaker (stable, unique per app): two skills can't share a
|
|
50
|
+
// display name in practice — ei's exporter has never demonstrated a tie —
|
|
51
|
+
// but sort() is not guaranteed stable across engines, so a same-name pair
|
|
52
|
+
// could otherwise silently swap which one gets the bare label between
|
|
53
|
+
// runs. refName (the authoring filename) is always unique within an app,
|
|
54
|
+
// making the overall ordering deterministic even in that case.
|
|
55
|
+
const sorted = toSortableSkills(siblingSkills).sort((a, b) => {
|
|
56
|
+
if (a.name < b.name)
|
|
57
|
+
return -1;
|
|
58
|
+
if (a.name > b.name)
|
|
59
|
+
return 1;
|
|
60
|
+
return a.refName < b.refName ? -1 : a.refName > b.refName ? 1 : 0;
|
|
61
|
+
});
|
|
62
|
+
const counts = new Map();
|
|
63
|
+
const suffixes = new Map();
|
|
64
|
+
for (const skill of sorted) {
|
|
65
|
+
skill.tools.forEach((entry, index) => {
|
|
66
|
+
const typeKey = Object.keys(entry)[0];
|
|
67
|
+
if (typeKey === undefined)
|
|
68
|
+
return;
|
|
69
|
+
const inner = entry[typeKey];
|
|
70
|
+
const base = sanitizeName(inner?.name ?? "");
|
|
71
|
+
const count = counts.get(base) ?? 0;
|
|
72
|
+
counts.set(base, count + 1);
|
|
73
|
+
suffixes.set(`${skill.refName}#${index}`, count > 0 ? `_${count}` : "");
|
|
74
|
+
});
|
|
75
|
+
}
|
|
76
|
+
return suffixes;
|
|
77
|
+
}
|
|
21
78
|
/** `elementum_agentic_skill` + one tool resource per implemented tool, in the platform's dialect. */
|
|
22
79
|
export function skillToTf(entity, ctx) {
|
|
23
80
|
if (entity.kind !== "skill") {
|
|
@@ -28,7 +85,7 @@ export function skillToTf(entity, ctx) {
|
|
|
28
85
|
if (payload === null || typeof payload !== "object" || elementum === undefined) {
|
|
29
86
|
throw new EntityTfError(`skill "${entity.refName}" has no skill payload — was it built with defineSkill?`);
|
|
30
87
|
}
|
|
31
|
-
const tfLabel = tsLabelToTfLabel(entity.refName);
|
|
88
|
+
const tfLabel = appScopedResourceLabel(ctx.appTfLabel, tsLabelToTfLabel(entity.refName));
|
|
32
89
|
const name = elementum.name ?? "";
|
|
33
90
|
const attrs = {
|
|
34
91
|
owner_id: expr.resourceAttr(APP_RESOURCE_TYPE, ctx.appTfLabel, ["id"]),
|
|
@@ -42,17 +99,21 @@ export function skillToTf(entity, ctx) {
|
|
|
42
99
|
if (elementum.properties !== undefined) {
|
|
43
100
|
attrs["properties"] = JSON.stringify(elementum.properties);
|
|
44
101
|
}
|
|
102
|
+
const toolLabelSuffixes = computeToolLabelSuffixes(ctx.siblingEntities ?? [entity]);
|
|
45
103
|
const blocks = [{ kind: "resource", type: SKILL_RESOURCE_TYPE, label: tfLabel, attrs }];
|
|
46
|
-
|
|
104
|
+
(payload.tools ?? []).forEach((entry, index) => {
|
|
47
105
|
const tool = skillToolToTf(entry, {
|
|
48
106
|
appRefName: ctx.appRefName,
|
|
49
107
|
appTfLabel: ctx.appTfLabel,
|
|
50
108
|
skillTfLabel: tfLabel,
|
|
109
|
+
labelSuffix: toolLabelSuffixes.get(`${entity.refName}#${index}`) ?? "",
|
|
51
110
|
foreignAppRef: (l, n) => ctx.orgRefs.foreignApp(l, n),
|
|
111
|
+
foreignElementRef: (l, n) => ctx.orgRefs.foreignElement(l, n),
|
|
112
|
+
foreignFieldRef: (t, l, o, n) => ctx.orgRefs.foreignField(t, l, o, n),
|
|
52
113
|
diagnostics: ctx.diagnostics,
|
|
53
114
|
});
|
|
54
115
|
if (tool !== undefined)
|
|
55
116
|
blocks.push(tool.block);
|
|
56
|
-
}
|
|
117
|
+
});
|
|
57
118
|
return { blocks, address: `${SKILL_RESOURCE_TYPE}.${tfLabel}` };
|
|
58
119
|
}
|
|
@@ -9,7 +9,8 @@
|
|
|
9
9
|
* Search/record fields require `name` + `description` (matching the v1 skill
|
|
10
10
|
* serializer, which always emits them).
|
|
11
11
|
*/
|
|
12
|
-
import type { AgentRef, AspectRef,
|
|
12
|
+
import type { AgentRef, AspectRef, AutomationCatalogRef, FieldRef, SearchTableRef } from "../../catalog/index.js";
|
|
13
|
+
import type { AgentToolRunAs, RunAutomationToolV2 } from "../agent/tools.js";
|
|
13
14
|
/** A handle-form skill tool: an `AgenticSkillToolCreateInput` with ref tokens. */
|
|
14
15
|
export type SkillTool = Record<string, unknown>;
|
|
15
16
|
export type SkillToolStatus = "ACTIVE" | "INACTIVE";
|
|
@@ -18,6 +19,20 @@ export interface SkillSearchField {
|
|
|
18
19
|
readonly name: string;
|
|
19
20
|
readonly description: string;
|
|
20
21
|
}
|
|
22
|
+
/**
|
|
23
|
+
* A search-tool field identified by a raw platform id rather than a
|
|
24
|
+
* FieldRef token — the field belongs to a foreign/out-of-scope aspect ei
|
|
25
|
+
* can't resolve to a resource reference (board issue #169; mirrors
|
|
26
|
+
* `entities/agent/tools.ts`'s `AgentSearchRawIdField`). There's no way to
|
|
27
|
+
* author one directly; it only arises from `edk pull app` round-tripping an
|
|
28
|
+
* existing tool.
|
|
29
|
+
*/
|
|
30
|
+
export interface SkillSearchRawIdField {
|
|
31
|
+
readonly fieldId: string;
|
|
32
|
+
readonly name: string;
|
|
33
|
+
readonly description: string;
|
|
34
|
+
}
|
|
35
|
+
export type SkillSearchFieldInput = SkillSearchField | SkillSearchRawIdField;
|
|
21
36
|
export interface SkillRecordField {
|
|
22
37
|
readonly field: FieldRef;
|
|
23
38
|
readonly name: string;
|
|
@@ -25,20 +40,34 @@ export interface SkillRecordField {
|
|
|
25
40
|
readonly required: boolean;
|
|
26
41
|
readonly defaultValue?: string;
|
|
27
42
|
}
|
|
43
|
+
/** A create/update-record field identified by a raw platform id — see {@link SkillSearchRawIdField}. */
|
|
44
|
+
export interface SkillRecordRawIdField {
|
|
45
|
+
readonly fieldId: string;
|
|
46
|
+
readonly name: string;
|
|
47
|
+
readonly description: string;
|
|
48
|
+
readonly required: boolean;
|
|
49
|
+
}
|
|
50
|
+
export type SkillRecordFieldInput = SkillRecordField | SkillRecordRawIdField;
|
|
28
51
|
interface CommonToolOptions {
|
|
29
52
|
readonly name: string;
|
|
30
53
|
readonly description: string;
|
|
31
54
|
readonly status?: SkillToolStatus;
|
|
32
55
|
readonly startMessage?: string;
|
|
56
|
+
readonly runAs?: AgentToolRunAs;
|
|
33
57
|
}
|
|
34
|
-
export
|
|
35
|
-
readonly
|
|
36
|
-
}
|
|
37
|
-
|
|
58
|
+
export type AutomationToolV2<A extends AutomationCatalogRef = AutomationCatalogRef> = RunAutomationToolV2<A> & {
|
|
59
|
+
readonly status?: SkillToolStatus;
|
|
60
|
+
};
|
|
61
|
+
/**
|
|
62
|
+
* Run an on-demand automation with input/output record keys constrained by
|
|
63
|
+
* the selected automation's generated catalog type. Required trigger params
|
|
64
|
+
* must be mapped and output keys autocomplete, matching agentRunAutomation.
|
|
65
|
+
*/
|
|
66
|
+
export declare function skillAutomation<A extends AutomationCatalogRef>(opts: AutomationToolV2<A>): SkillTool;
|
|
38
67
|
export interface SkillSearchAspectToolV2 extends CommonToolOptions {
|
|
39
68
|
readonly aspect: AspectRef;
|
|
40
69
|
readonly queryDescription: string;
|
|
41
|
-
readonly fields: readonly
|
|
70
|
+
readonly fields: readonly SkillSearchFieldInput[];
|
|
42
71
|
/** Maximum number of records the search returns. */
|
|
43
72
|
readonly limit?: number;
|
|
44
73
|
}
|
|
@@ -54,12 +83,12 @@ export interface SkillSearchTableToolV2 extends CommonToolOptions {
|
|
|
54
83
|
export declare function skillSearchTable(opts: SkillSearchTableToolV2): SkillTool;
|
|
55
84
|
export interface SkillCreateRecordToolV2 extends CommonToolOptions {
|
|
56
85
|
readonly aspect: AspectRef;
|
|
57
|
-
readonly fields: readonly
|
|
86
|
+
readonly fields: readonly SkillRecordFieldInput[];
|
|
58
87
|
}
|
|
59
88
|
export declare function skillCreateRecord(opts: SkillCreateRecordToolV2): SkillTool;
|
|
60
89
|
export interface SkillUpdateRecordToolV2 extends CommonToolOptions {
|
|
61
90
|
readonly aspect: AspectRef;
|
|
62
|
-
readonly fields: readonly
|
|
91
|
+
readonly fields: readonly SkillRecordFieldInput[];
|
|
63
92
|
readonly handleDescription: string;
|
|
64
93
|
}
|
|
65
94
|
export declare function skillUpdateRecord(opts: SkillUpdateRecordToolV2): SkillTool;
|
|
@@ -12,9 +12,18 @@ function common(opts) {
|
|
|
12
12
|
description: opts.description,
|
|
13
13
|
status: opts.status ?? "ACTIVE",
|
|
14
14
|
...(opts.startMessage !== undefined ? { startMessage: opts.startMessage } : {}),
|
|
15
|
+
...(opts.runAs !== undefined ? { runAs: opts.runAs } : {}),
|
|
15
16
|
};
|
|
16
17
|
}
|
|
17
18
|
function searchFieldToken(f) {
|
|
19
|
+
if ("fieldId" in f) {
|
|
20
|
+
// Raw platform id fallback — see SkillSearchRawIdField's comment.
|
|
21
|
+
return {
|
|
22
|
+
fieldId: f.fieldId,
|
|
23
|
+
name: f.name,
|
|
24
|
+
description: f.description,
|
|
25
|
+
};
|
|
26
|
+
}
|
|
18
27
|
return {
|
|
19
28
|
fieldId: f.field,
|
|
20
29
|
clientHandle: f.field,
|
|
@@ -23,6 +32,15 @@ function searchFieldToken(f) {
|
|
|
23
32
|
};
|
|
24
33
|
}
|
|
25
34
|
function recordFieldToken(f) {
|
|
35
|
+
if ("fieldId" in f) {
|
|
36
|
+
// Raw platform id fallback — see SkillRecordRawIdField's comment.
|
|
37
|
+
return {
|
|
38
|
+
fieldId: f.fieldId,
|
|
39
|
+
name: f.name,
|
|
40
|
+
description: f.description,
|
|
41
|
+
required: f.required,
|
|
42
|
+
};
|
|
43
|
+
}
|
|
26
44
|
return {
|
|
27
45
|
fieldId: f.field,
|
|
28
46
|
clientHandle: f.field,
|
|
@@ -32,8 +50,32 @@ function recordFieldToken(f) {
|
|
|
32
50
|
...(f.defaultValue !== undefined ? { defaultValue: f.defaultValue } : {}),
|
|
33
51
|
};
|
|
34
52
|
}
|
|
53
|
+
/**
|
|
54
|
+
* Run an on-demand automation with input/output record keys constrained by
|
|
55
|
+
* the selected automation's generated catalog type. Required trigger params
|
|
56
|
+
* must be mapped and output keys autocomplete, matching agentRunAutomation.
|
|
57
|
+
*/
|
|
35
58
|
export function skillAutomation(opts) {
|
|
36
|
-
|
|
59
|
+
const inputEntries = Object.entries((opts.inputs ?? {}));
|
|
60
|
+
const inputs = inputEntries.map(([parameterName, spec]) => ({
|
|
61
|
+
parameterName,
|
|
62
|
+
displayName: spec.name ?? parameterName,
|
|
63
|
+
description: spec.description,
|
|
64
|
+
...(spec.required !== undefined ? { required: spec.required } : {}),
|
|
65
|
+
}));
|
|
66
|
+
const outputEntries = Object.entries((opts.outputs ?? {}));
|
|
67
|
+
const outputs = outputEntries.map(([workflowPropertyName, spec]) => ({
|
|
68
|
+
workflowPropertyName,
|
|
69
|
+
displayName: spec?.name ?? workflowPropertyName,
|
|
70
|
+
}));
|
|
71
|
+
return {
|
|
72
|
+
automation: {
|
|
73
|
+
...common(opts),
|
|
74
|
+
automationId: opts.automation,
|
|
75
|
+
...(inputs.length > 0 ? { inputs } : {}),
|
|
76
|
+
...(outputs.length > 0 ? { outputs } : {}),
|
|
77
|
+
},
|
|
78
|
+
};
|
|
37
79
|
}
|
|
38
80
|
export function skillSearchAspect(opts) {
|
|
39
81
|
return {
|
|
@@ -6,9 +6,17 @@
|
|
|
6
6
|
*/
|
|
7
7
|
import { type FromTfContext } from "../../engine/pull/context.js";
|
|
8
8
|
import { type TfBlock } from "../../engine/tf/index.js";
|
|
9
|
+
import type { AgentToolRunAs } from "../agent/tools.js";
|
|
9
10
|
export interface NormalizedSkillToolField {
|
|
10
|
-
/** The field's bag key in the
|
|
11
|
-
readonly key
|
|
11
|
+
/** The field's bag key in the TARGET aspect's `fields: {}` (bijective image of its label). Mutually exclusive with `rawFieldId`. */
|
|
12
|
+
readonly key?: string;
|
|
13
|
+
/**
|
|
14
|
+
* Raw platform field id — board issue #169. When the tool's target is a
|
|
15
|
+
* foreign/out-of-scope aspect (not recursively exported), ei has no field
|
|
16
|
+
* resource to reference and falls back to a bare id. Mutually exclusive
|
|
17
|
+
* with `key`; exactly one is always set.
|
|
18
|
+
*/
|
|
19
|
+
readonly rawFieldId?: string;
|
|
12
20
|
readonly name?: string;
|
|
13
21
|
readonly description?: string;
|
|
14
22
|
readonly required?: boolean;
|
|
@@ -19,23 +27,45 @@ export type NormalizedSkillToolTarget = {
|
|
|
19
27
|
/** A foreign app via `data.elementum_app.<label>` — `name` from the stream's data block. */
|
|
20
28
|
readonly kind: "foreignApp";
|
|
21
29
|
readonly name: string;
|
|
30
|
+
} | {
|
|
31
|
+
/** A foreign ELEMENT via `data.elementum_element.<label>` — `name` from the stream's data block (board issue #42). */
|
|
32
|
+
readonly kind: "foreignElement";
|
|
33
|
+
readonly name: string;
|
|
22
34
|
};
|
|
23
35
|
export interface NormalizedSkillTool {
|
|
24
|
-
readonly typeKey: "createRecord" | "searchAspect";
|
|
36
|
+
readonly typeKey: "createRecord" | "searchAspect" | "updateRecord" | "runAgent" | "automation";
|
|
25
37
|
readonly name: string;
|
|
26
38
|
readonly description: string;
|
|
27
39
|
/** Present only when it differs from the default ("ACTIVE"). */
|
|
28
40
|
readonly status?: "INACTIVE";
|
|
29
41
|
readonly startMessage?: string;
|
|
30
|
-
readonly target
|
|
42
|
+
readonly target?: NormalizedSkillToolTarget;
|
|
31
43
|
readonly fields?: readonly NormalizedSkillToolField[];
|
|
32
44
|
readonly queryDescription?: string;
|
|
33
45
|
readonly limit?: number;
|
|
46
|
+
readonly handleDescription?: string;
|
|
47
|
+
readonly targetAgentKey?: string;
|
|
48
|
+
readonly workerTaskPrompt?: string;
|
|
49
|
+
readonly automationKey?: string;
|
|
50
|
+
readonly inputs?: readonly {
|
|
51
|
+
readonly parameterName: string;
|
|
52
|
+
readonly displayName?: string;
|
|
53
|
+
readonly description?: string;
|
|
54
|
+
readonly required?: boolean;
|
|
55
|
+
}[];
|
|
56
|
+
readonly outputs?: readonly {
|
|
57
|
+
readonly workflowPropertyName: string;
|
|
58
|
+
readonly displayName?: string;
|
|
59
|
+
readonly description?: string;
|
|
60
|
+
}[];
|
|
61
|
+
readonly runAs?: AgentToolRunAs;
|
|
34
62
|
}
|
|
35
63
|
export interface SkillToolOwner {
|
|
36
64
|
/** The owning app's resource type + tfLabel. */
|
|
37
65
|
readonly appType: string;
|
|
38
66
|
readonly appLabel: string;
|
|
67
|
+
/** Namespace tf label for stripping `apps_<ns>_` child labels. */
|
|
68
|
+
readonly ownerTfLabel: string;
|
|
39
69
|
/** The owning skill's resource type + tfLabel. */
|
|
40
70
|
readonly skillType: string;
|
|
41
71
|
readonly skillLabel: string;
|
|
@@ -6,8 +6,8 @@
|
|
|
6
6
|
*/
|
|
7
7
|
import { EntityTfError } from "../../engine/entity.js";
|
|
8
8
|
import { optionalString, resourceRefLabel } from "../../engine/pull/context.js";
|
|
9
|
-
import { isTfExpr,
|
|
10
|
-
import {
|
|
9
|
+
import { isTfExpr, scopedLabelToBagKey } from "../../engine/tf/index.js";
|
|
10
|
+
import { resolveToolFieldKey } from "../shared/tool-field-ref.js";
|
|
11
11
|
import { KNOWN_SKILL_TOOL_ATTRS, SKILL_TOOL_SUB_TYPE_BY_RESOURCE, UNAUTHORABLE_SKILL_TOOL_ATTRS, } from "./types.js";
|
|
12
12
|
/**
|
|
13
13
|
* One tool block → its normalized shape; undefined = skipped with a
|
|
@@ -43,10 +43,106 @@ export function skillToolFromTf(block, owner, ctx) {
|
|
|
43
43
|
ctx.diagnostics.push(`${where}: skill_id does not reference ${owner.skillType}.${owner.skillLabel}; skipped`);
|
|
44
44
|
return undefined;
|
|
45
45
|
}
|
|
46
|
+
const startMessage = optionalString(attrs, "start_message", where, ctx);
|
|
47
|
+
const status = optionalString(attrs, "status", where, ctx);
|
|
48
|
+
let runAs;
|
|
49
|
+
const runAsValue = optionalString(attrs, "run_as", where, ctx);
|
|
50
|
+
if (runAsValue === "current_user")
|
|
51
|
+
runAs = { currentUser: true };
|
|
52
|
+
else if (runAsValue === "publisher")
|
|
53
|
+
runAs = { publisher: true };
|
|
54
|
+
else if (runAsValue === "service_account") {
|
|
55
|
+
const serviceAccountId = optionalString(attrs, "service_account_id", where, ctx);
|
|
56
|
+
if (serviceAccountId !== undefined && serviceAccountId !== "") {
|
|
57
|
+
runAs = { serviceAccount: { serviceAccount: serviceAccountId } };
|
|
58
|
+
}
|
|
59
|
+
else {
|
|
60
|
+
ctx.diagnostics.push(`${where}: run_as is service_account but service_account_id is missing; dropped`);
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
else if (runAsValue !== undefined) {
|
|
64
|
+
ctx.diagnostics.push(`${where}: unsupported run_as ${JSON.stringify(runAsValue)}; dropped`);
|
|
65
|
+
}
|
|
66
|
+
const common = {
|
|
67
|
+
name,
|
|
68
|
+
description: optionalString(attrs, "description", where, ctx) ?? "",
|
|
69
|
+
...(status === "INACTIVE" && { status: "INACTIVE" }),
|
|
70
|
+
...(startMessage !== undefined && { startMessage }),
|
|
71
|
+
...(runAs !== undefined && { runAs }),
|
|
72
|
+
};
|
|
73
|
+
if (subType.typeKey === "runAgent") {
|
|
74
|
+
const targetLabel = resourceRefLabel(attrs["target_agent_id"], "elementum_agent");
|
|
75
|
+
if (targetLabel === undefined) {
|
|
76
|
+
ctx.diagnostics.push(`${where}: target_agent_id is not an elementum_agent resource reference; skipped`);
|
|
77
|
+
return undefined;
|
|
78
|
+
}
|
|
79
|
+
return {
|
|
80
|
+
typeKey: "runAgent",
|
|
81
|
+
...common,
|
|
82
|
+
targetAgentKey: scopedLabelToBagKey(owner.ownerTfLabel, targetLabel),
|
|
83
|
+
workerTaskPrompt: optionalString(attrs, "worker_task_prompt", where, ctx) ?? "",
|
|
84
|
+
};
|
|
85
|
+
}
|
|
86
|
+
if (subType.typeKey === "automation") {
|
|
87
|
+
const automation = attrs["automation_id"];
|
|
88
|
+
const automationLabel = isTfExpr(automation) &&
|
|
89
|
+
automation.$expr === "resource-attr" &&
|
|
90
|
+
(automation.type === "elementum_workflow_publish" || automation.type === "elementum_automation")
|
|
91
|
+
? automation.label
|
|
92
|
+
: undefined;
|
|
93
|
+
if (automationLabel === undefined) {
|
|
94
|
+
ctx.diagnostics.push(`${where}: automation_id is not an automation/workflow_publish resource reference; skipped`);
|
|
95
|
+
return undefined;
|
|
96
|
+
}
|
|
97
|
+
const inputs = [];
|
|
98
|
+
for (const item of Array.isArray(attrs["inputs"]) ? attrs["inputs"] : []) {
|
|
99
|
+
if (typeof item !== "object" || item === null || Array.isArray(item) || isTfExpr(item))
|
|
100
|
+
continue;
|
|
101
|
+
const rec = item;
|
|
102
|
+
if (typeof rec["parameter_name"] !== "string" || rec["parameter_name"] === "") {
|
|
103
|
+
ctx.diagnostics.push(`${where}: inputs item has no parameter_name; dropped`);
|
|
104
|
+
continue;
|
|
105
|
+
}
|
|
106
|
+
inputs.push({
|
|
107
|
+
parameterName: rec["parameter_name"],
|
|
108
|
+
...(typeof rec["display_name"] === "string" && { displayName: rec["display_name"] }),
|
|
109
|
+
...(typeof rec["description"] === "string" && { description: rec["description"] }),
|
|
110
|
+
...(typeof rec["required"] === "boolean" && { required: rec["required"] }),
|
|
111
|
+
});
|
|
112
|
+
}
|
|
113
|
+
const outputs = [];
|
|
114
|
+
for (const item of Array.isArray(attrs["outputs"]) ? attrs["outputs"] : []) {
|
|
115
|
+
if (typeof item !== "object" || item === null || Array.isArray(item) || isTfExpr(item))
|
|
116
|
+
continue;
|
|
117
|
+
const rec = item;
|
|
118
|
+
if (typeof rec["workflow_property_name"] !== "string" || rec["workflow_property_name"] === "") {
|
|
119
|
+
ctx.diagnostics.push(`${where}: outputs item has no workflow_property_name; dropped`);
|
|
120
|
+
continue;
|
|
121
|
+
}
|
|
122
|
+
outputs.push({
|
|
123
|
+
workflowPropertyName: rec["workflow_property_name"],
|
|
124
|
+
...(typeof rec["display_name"] === "string" && { displayName: rec["display_name"] }),
|
|
125
|
+
...(typeof rec["description"] === "string" && { description: rec["description"] }),
|
|
126
|
+
});
|
|
127
|
+
}
|
|
128
|
+
return {
|
|
129
|
+
typeKey: "automation",
|
|
130
|
+
...common,
|
|
131
|
+
automationKey: scopedLabelToBagKey(owner.ownerTfLabel, automationLabel),
|
|
132
|
+
...(inputs.length > 0 && { inputs }),
|
|
133
|
+
...(outputs.length > 0 && { outputs }),
|
|
134
|
+
};
|
|
135
|
+
}
|
|
46
136
|
// Target: the owning app's resource ref = self; a data.elementum_app ref =
|
|
47
137
|
// a foreign app, resolved to its display name via the stream's data block.
|
|
48
138
|
const targetAttr = attrs["target_id"];
|
|
49
139
|
let target;
|
|
140
|
+
// The tool's fields are scoped under the RESOLVED target aspect, not
|
|
141
|
+
// always the owning app (board issue #169) — a field on a foreign
|
|
142
|
+
// app/element carries that aspect's own label, mirroring the
|
|
143
|
+
// foreignApp/foreignElement resolution below.
|
|
144
|
+
let fieldScopeLabel = owner.ownerTfLabel;
|
|
145
|
+
let fieldScope = "app";
|
|
50
146
|
const selfLabel = resourceRefLabel(targetAttr, owner.appType);
|
|
51
147
|
if (selfLabel === owner.appLabel) {
|
|
52
148
|
target = { kind: "self" };
|
|
@@ -58,6 +154,18 @@ export function skillToolFromTf(block, owner, ctx) {
|
|
|
58
154
|
return undefined;
|
|
59
155
|
}
|
|
60
156
|
target = { kind: "foreignApp", name: appName };
|
|
157
|
+
fieldScopeLabel = targetAttr.label;
|
|
158
|
+
}
|
|
159
|
+
else if (isTfExpr(targetAttr) && targetAttr.$expr === "data-attr" && targetAttr.type === "elementum_element") {
|
|
160
|
+
// Board issue #42: an aspect target can be an element, not just an app.
|
|
161
|
+
const elementName = ctx.dataName("elementum_element", targetAttr.label);
|
|
162
|
+
if (elementName === undefined) {
|
|
163
|
+
ctx.diagnostics.push(`${where}: target_id references data.elementum_element.${targetAttr.label} but the stream has no such data block; skipped`);
|
|
164
|
+
return undefined;
|
|
165
|
+
}
|
|
166
|
+
target = { kind: "foreignElement", name: elementName };
|
|
167
|
+
fieldScopeLabel = targetAttr.label;
|
|
168
|
+
fieldScope = "element";
|
|
61
169
|
}
|
|
62
170
|
else {
|
|
63
171
|
ctx.diagnostics.push(`${where}: target_id has an unrecognized shape (${JSON.stringify(targetAttr)}); skipped`);
|
|
@@ -73,22 +181,26 @@ export function skillToolFromTf(block, owner, ctx) {
|
|
|
73
181
|
continue;
|
|
74
182
|
}
|
|
75
183
|
const rec = item;
|
|
76
|
-
const
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
184
|
+
const fieldKey = resolveToolFieldKey(rec["field_id"], fieldScopeLabel, fieldScope);
|
|
185
|
+
// A field on a foreign/out-of-scope aspect has no field resource ei
|
|
186
|
+
// can reference — it falls back to a bare platform id, confirmed live
|
|
187
|
+
// (board issue #169). Preserve it (raw-id TODO placeholder) rather
|
|
188
|
+
// than silently dropping the field.
|
|
189
|
+
const rawFieldId = fieldKey === undefined && typeof rec["field_id"] === "string" && rec["field_id"] !== "" ? rec["field_id"] : undefined;
|
|
190
|
+
if (fieldKey === undefined && rawFieldId === undefined) {
|
|
81
191
|
ctx.diagnostics.push(`${where}: fields item's field_id is not a field resource reference; dropped`);
|
|
82
192
|
continue;
|
|
83
193
|
}
|
|
84
194
|
fields.push({
|
|
85
|
-
key:
|
|
195
|
+
...(fieldKey !== undefined ? { key: fieldKey } : { rawFieldId: rawFieldId }),
|
|
86
196
|
...(typeof rec["name"] === "string" && { name: rec["name"] }),
|
|
87
197
|
...(typeof rec["description"] === "string" && { description: rec["description"] }),
|
|
88
|
-
// The provider's own schema docs
|
|
89
|
-
// "
|
|
90
|
-
//
|
|
91
|
-
|
|
198
|
+
// The provider's own schema docs `required` on search-tool fields as
|
|
199
|
+
// "Not used by search tools" — it's platform-generated noise (see
|
|
200
|
+
// to-tf.ts), so it's excluded here too rather than echoed into
|
|
201
|
+
// authored source.
|
|
202
|
+
...((subType.typeKey === "createRecord" || subType.typeKey === "updateRecord") &&
|
|
203
|
+
typeof rec["required"] === "boolean" && { required: rec["required"] }),
|
|
92
204
|
});
|
|
93
205
|
}
|
|
94
206
|
if (fields.length === 0)
|
|
@@ -103,19 +215,17 @@ export function skillToolFromTf(block, owner, ctx) {
|
|
|
103
215
|
if (subType.typeKey === "searchAspect" && attrs["filter_variables"] !== undefined) {
|
|
104
216
|
ctx.diagnostics.push(`${where}: filter_variables are not supported on the terraform path yet; a rebuilt stream will omit them`);
|
|
105
217
|
}
|
|
106
|
-
const startMessage = optionalString(attrs, "start_message", where, ctx);
|
|
107
|
-
const status = optionalString(attrs, "status", where, ctx);
|
|
108
218
|
return {
|
|
109
219
|
typeKey: subType.typeKey,
|
|
110
|
-
|
|
111
|
-
description: optionalString(attrs, "description", where, ctx) ?? "",
|
|
112
|
-
...(status === "INACTIVE" && { status }),
|
|
113
|
-
...(startMessage !== undefined && { startMessage }),
|
|
220
|
+
...common,
|
|
114
221
|
target,
|
|
115
222
|
...(fields !== undefined && { fields }),
|
|
116
223
|
...(subType.typeKey === "searchAspect" && {
|
|
117
224
|
queryDescription: optionalString(attrs, "query_description", where, ctx) ?? "",
|
|
118
225
|
}),
|
|
119
226
|
...(typeof attrs["result_limit"] === "number" && { limit: attrs["result_limit"] }),
|
|
227
|
+
...(subType.typeKey === "updateRecord" && {
|
|
228
|
+
handleDescription: optionalString(attrs, "handle_description", where, ctx) ?? "",
|
|
229
|
+
}),
|
|
120
230
|
};
|
|
121
231
|
}
|
|
@@ -6,15 +6,27 @@
|
|
|
6
6
|
* (`skill_id`) — this module never names the skill or app resource types.
|
|
7
7
|
* Mirrors `entities/agent-tool/to-tf.ts`.
|
|
8
8
|
*/
|
|
9
|
-
import { type TfBlock } from "../../engine/tf/index.js";
|
|
9
|
+
import { type TfBlock, type TfValue } from "../../engine/tf/index.js";
|
|
10
10
|
export interface SkillToolToTfContext {
|
|
11
11
|
/** The owning app's refName + tfLabel (namespace) — self-target detection + app_id. */
|
|
12
12
|
readonly appRefName: string;
|
|
13
13
|
readonly appTfLabel: string;
|
|
14
14
|
/** The owning skill's tfLabel. */
|
|
15
15
|
readonly skillTfLabel: string;
|
|
16
|
+
/**
|
|
17
|
+
* Cross-skill disambiguation suffix ("", "_1", "_2", …) — mirrors ei's
|
|
18
|
+
* own tool-name collision handling across different skills in the same
|
|
19
|
+
* app (board issue #310). Computed by the caller (`skillToTf`) via
|
|
20
|
+
* `computeToolLabelSuffixes`; empty when absent (single-skill contexts,
|
|
21
|
+
* most unit tests).
|
|
22
|
+
*/
|
|
23
|
+
readonly labelSuffix?: string;
|
|
16
24
|
/** Records a foreign-app data lookup for data.tf; returns its tfLabel. */
|
|
17
25
|
foreignAppRef(tfLabel: string, name: string): void;
|
|
26
|
+
/** Records a foreign-ELEMENT data lookup for data.tf (board issue #42). */
|
|
27
|
+
foreignElementRef(tfLabel: string, name: string): void;
|
|
28
|
+
/** Records a `data.elementum_field` lookup for a field owned by a foreign app/element. */
|
|
29
|
+
foreignFieldRef(type: string, tfLabel: string, objectId: TfValue, name: string): void;
|
|
18
30
|
/** Degradations land here — reported by the caller, never silent. */
|
|
19
31
|
readonly diagnostics: string[];
|
|
20
32
|
}
|