@bf-meishijian/aip 0.0.26 → 0.0.28
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 +6 -2
- package/dist/cli.d.ts.map +1 -1
- package/dist/cli.js +6 -2
- package/dist/cli.js.map +1 -1
- package/dist/diagnostics.d.ts.map +1 -1
- package/dist/general-run-client.d.ts +21 -4
- package/dist/general-run-client.d.ts.map +1 -1
- package/dist/general-run-client.js +3 -0
- package/dist/general-run-client.js.map +1 -1
- package/dist/general-run-manager.d.ts +1 -1
- package/dist/general-run-manager.d.ts.map +1 -1
- package/dist/general-run-manager.js +13 -50
- package/dist/general-run-manager.js.map +1 -1
- package/dist/general-run-tools.d.ts +6 -9
- package/dist/general-run-tools.d.ts.map +1 -1
- package/dist/general-run-tools.js +99 -128
- package/dist/general-run-tools.js.map +1 -1
- package/dist/host-status.d.ts.map +1 -1
- package/dist/live-employee.d.ts +2 -3
- package/dist/live-employee.d.ts.map +1 -1
- package/dist/live-employee.js +35 -429
- package/dist/live-employee.js.map +1 -1
- package/dist/local-employee-runtime.d.ts +29 -0
- package/dist/local-employee-runtime.d.ts.map +1 -0
- package/dist/local-employee-runtime.js +487 -0
- package/dist/local-employee-runtime.js.map +1 -0
- package/dist/pi-model-service.d.ts.map +1 -1
- package/dist/platform-client.d.ts.map +1 -1
- package/dist/state.d.ts +2 -2
- package/dist/state.js +2 -2
- package/package.json +4 -4
|
@@ -1,18 +1,17 @@
|
|
|
1
1
|
import { randomUUID } from "node:crypto";
|
|
2
|
-
import {
|
|
3
|
-
import { createEditToolDefinition, createFindToolDefinition, createGrepToolDefinition, createLsToolDefinition, createReadToolDefinition, createWriteToolDefinition, } from "@earendil-works/pi-coding-agent";
|
|
2
|
+
import { resolveHostShell } from "@ai-platform/api-contracts";
|
|
4
3
|
import { redactHostText } from "./host-log.js";
|
|
5
|
-
import {
|
|
4
|
+
import { localEmployeeRuntime } from "./local-employee-runtime.js";
|
|
6
5
|
import { PlatformClientError } from "./platform-client.js";
|
|
7
6
|
export function generalRunTools(options) {
|
|
8
|
-
const { spec, binding, client, cwd,
|
|
9
|
-
|
|
10
|
-
const resources = spec.input
|
|
11
|
-
?.resourceBindings;
|
|
12
|
-
const declaredTools = selectManagedAgentToolsForRun(manifest, spec.resolvedAgentConfig.enabledOptionalToolIds, undefined, resources);
|
|
13
|
-
const tools = validateManagedAgentToolSnapshot(manifest, spec.resolvedAgentConfig.tools, undefined, declaredTools);
|
|
14
|
-
const names = [];
|
|
7
|
+
const { spec, binding, client, cwd, initial } = options;
|
|
8
|
+
let current = initial;
|
|
15
9
|
const platformNames = new Map();
|
|
10
|
+
const updateNames = (config) => {
|
|
11
|
+
for (const tool of config.toolDefinitions)
|
|
12
|
+
platformNames.set(tool.name, tool.execution === "NATIVE" ? "workspace.command" : tool.handler);
|
|
13
|
+
};
|
|
14
|
+
updateNames(initial);
|
|
16
15
|
const callIds = new Map();
|
|
17
16
|
const toolCallId = (sourceId) => {
|
|
18
17
|
let id = callIds.get(sourceId);
|
|
@@ -22,130 +21,102 @@ export function generalRunTools(options) {
|
|
|
22
21
|
}
|
|
23
22
|
return id;
|
|
24
23
|
};
|
|
25
|
-
const
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
createEditToolDefinition(cwd),
|
|
35
|
-
createFindToolDefinition(cwd),
|
|
36
|
-
createGrepToolDefinition(cwd),
|
|
37
|
-
createLsToolDefinition(cwd),
|
|
38
|
-
]) {
|
|
39
|
-
definitions.push(native);
|
|
40
|
-
platformNames.set(native.name, tool.id);
|
|
41
|
-
}
|
|
24
|
+
const invoke = async (name, id, input, signal) => {
|
|
25
|
+
try {
|
|
26
|
+
return await client.tool(spec.runId, name, {
|
|
27
|
+
...binding,
|
|
28
|
+
toolCallId: id,
|
|
29
|
+
idempotencyKey: id,
|
|
30
|
+
graphNodeId: "general-pi",
|
|
31
|
+
input,
|
|
32
|
+
}, signal);
|
|
42
33
|
}
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
34
|
+
catch (error) {
|
|
35
|
+
if (!(error instanceof PlatformClientError) || error.status >= 500)
|
|
36
|
+
options.protocolLost();
|
|
37
|
+
throw error;
|
|
38
|
+
}
|
|
39
|
+
};
|
|
40
|
+
const shell = resolveHostShell(process.platform, initial.environmentVariables ?? {});
|
|
41
|
+
const live = localEmployeeRuntime({
|
|
42
|
+
initial,
|
|
43
|
+
runId: spec.runId,
|
|
44
|
+
runRoot: cwd,
|
|
45
|
+
member: "employee",
|
|
46
|
+
...(options.isClosing ? { isClosing: options.isClosing } : {}),
|
|
47
|
+
load: async (purpose, file, call) => {
|
|
48
|
+
if (purpose === "SKILL_READ" && file) {
|
|
49
|
+
const metadata = current.agent.skills.find((item) => item.id === file.skillId && item.path === file.skillPath);
|
|
50
|
+
if (!metadata)
|
|
51
|
+
throw new Error("EMPLOYEE_SKILL_FILE_UNAVAILABLE");
|
|
52
|
+
const response = await invoke("employee.read_skill", call?.toolName === "employee_read_skill" ? toolCallId(call.id) : randomUUID(), { skillName: metadata.name, path: metadata.path });
|
|
53
|
+
if (response.result.outcome !== "SUCCEEDED")
|
|
54
|
+
throw new Error("EMPLOYEE_SKILL_FILE_UNAVAILABLE");
|
|
55
|
+
}
|
|
56
|
+
current = await client.employeeConfig(spec.runId, { ...binding, purpose, ...file });
|
|
57
|
+
updateNames(current);
|
|
58
|
+
return current;
|
|
59
|
+
},
|
|
60
|
+
prompt: (config, locations) => [
|
|
61
|
+
config.agent.systemPrompt,
|
|
62
|
+
`当前为通用员工会话,工作目录:${cwd}。本地命令工具使用 ${shell.name},按实际工具反馈操作;连接中断或结果未知不表示执行成功。`,
|
|
63
|
+
`当前绑定技能目录(元数据,使用前显式读取 SKILL.md):\n${config.agent.skills
|
|
64
|
+
.filter((file) => file.path === "SKILL.md")
|
|
65
|
+
.map((file) => `${file.name}:${file.description ?? ""}\nSKILL.md:${locations.get(`${file.id}:${file.path}`)}`)
|
|
66
|
+
.join("\n") || "无"}`,
|
|
67
|
+
].join("\n\n"),
|
|
68
|
+
platformTool: async (definition, sourceId, args, signal) => {
|
|
69
|
+
const response = await invoke(definition.handler, toolCallId(sourceId), args, signal);
|
|
70
|
+
return { content: [{ type: "text", text: JSON.stringify(response.result) }], details: {} };
|
|
71
|
+
},
|
|
72
|
+
wrapTool: (definition) => ({
|
|
73
|
+
...definition,
|
|
74
|
+
async execute(id, args, signal, update, context) {
|
|
75
|
+
await options.beforeTool();
|
|
76
|
+
let result;
|
|
77
|
+
const native = platformNames.get(definition.name) === "workspace.command";
|
|
78
|
+
const record = async (outcome) => {
|
|
79
|
+
if (!native)
|
|
80
|
+
return;
|
|
81
|
+
const factId = toolCallId(id);
|
|
82
|
+
const input = args;
|
|
56
83
|
try {
|
|
57
|
-
|
|
84
|
+
await client.recordToolFacts(spec.runId, {
|
|
58
85
|
...binding,
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
return {
|
|
71
|
-
content: [{ type: "text", text: JSON.stringify(response.result) }],
|
|
72
|
-
details: {},
|
|
73
|
-
};
|
|
74
|
-
},
|
|
75
|
-
});
|
|
76
|
-
platformNames.set(tool.providerName, tool.id);
|
|
77
|
-
}
|
|
78
|
-
}
|
|
79
|
-
names.push(...definitions.map((definition) => definition.name));
|
|
80
|
-
const extension = (api) => {
|
|
81
|
-
for (const definition of definitions) {
|
|
82
|
-
api.registerTool({
|
|
83
|
-
...definition,
|
|
84
|
-
async execute(id, args, signal, update, context) {
|
|
85
|
-
await options.beforeTool();
|
|
86
|
-
let result;
|
|
87
|
-
const native = platformNames.get(definition.name) === "workspace.command";
|
|
88
|
-
const record = async (outcome) => {
|
|
89
|
-
if (!native)
|
|
90
|
-
return;
|
|
91
|
-
const factId = toolCallId(id);
|
|
92
|
-
const input = args;
|
|
93
|
-
try {
|
|
94
|
-
await client.recordToolFacts(spec.runId, {
|
|
95
|
-
...binding,
|
|
96
|
-
facts: [
|
|
97
|
-
{
|
|
98
|
-
toolCallId: factId,
|
|
99
|
-
idempotencyKey: factId,
|
|
100
|
-
graphNodeId: "general-pi",
|
|
101
|
-
toolName: "workspace.command",
|
|
102
|
-
outcome,
|
|
103
|
-
input: {
|
|
104
|
-
command: redactHostText(options.redact(typeof input.command === "string"
|
|
105
|
-
? input.command
|
|
106
|
-
: `${definition.name} ${typeof input.path === "string" ? input.path : cwd}`)),
|
|
107
|
-
},
|
|
108
|
-
...(outcome === "FAILED" ? { errorCode: "LOCAL_TOOL_FAILED" } : {}),
|
|
86
|
+
facts: [
|
|
87
|
+
{
|
|
88
|
+
toolCallId: factId,
|
|
89
|
+
idempotencyKey: factId,
|
|
90
|
+
graphNodeId: "general-pi",
|
|
91
|
+
toolName: "workspace.command",
|
|
92
|
+
outcome,
|
|
93
|
+
input: {
|
|
94
|
+
command: redactHostText(typeof input.command === "string"
|
|
95
|
+
? input.command
|
|
96
|
+
: `${definition.name} ${typeof input.path === "string" ? input.path : cwd}`),
|
|
109
97
|
},
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
options.protocolLost();
|
|
115
|
-
throw error;
|
|
116
|
-
}
|
|
117
|
-
};
|
|
118
|
-
try {
|
|
119
|
-
result = await definition.execute(id, args, signal, update, context);
|
|
98
|
+
...(outcome === "FAILED" ? { errorCode: "LOCAL_TOOL_FAILED" } : {}),
|
|
99
|
+
},
|
|
100
|
+
],
|
|
101
|
+
});
|
|
120
102
|
}
|
|
121
103
|
catch (error) {
|
|
122
|
-
|
|
123
|
-
throw
|
|
104
|
+
options.protocolLost();
|
|
105
|
+
throw error;
|
|
124
106
|
}
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
};
|
|
140
|
-
return { extension, names, platformNames, toolCallId, shell };
|
|
141
|
-
}
|
|
142
|
-
function redactValues(value, redact) {
|
|
143
|
-
if (typeof value === "string")
|
|
144
|
-
return redact(value);
|
|
145
|
-
if (Array.isArray(value))
|
|
146
|
-
return value.map((item) => redactValues(item, redact));
|
|
147
|
-
if (value && typeof value === "object")
|
|
148
|
-
return Object.fromEntries(Object.entries(value).map(([key, item]) => [key, redactValues(item, redact)]));
|
|
149
|
-
return value;
|
|
107
|
+
};
|
|
108
|
+
try {
|
|
109
|
+
result = await definition.execute(id, args, signal, update, context);
|
|
110
|
+
}
|
|
111
|
+
catch (error) {
|
|
112
|
+
await record("FAILED");
|
|
113
|
+
throw error;
|
|
114
|
+
}
|
|
115
|
+
await record(result.isError === true ? "FAILED" : "SUCCEEDED");
|
|
116
|
+
return result;
|
|
117
|
+
},
|
|
118
|
+
}),
|
|
119
|
+
});
|
|
120
|
+
return { ...live, names: initial.activeToolNames, platformNames, toolCallId, shell };
|
|
150
121
|
}
|
|
151
122
|
//# sourceMappingURL=general-run-tools.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"general-run-tools.js","sourceRoot":"","sources":["../src/general-run-tools.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AACzC,OAAO,
|
|
1
|
+
{"version":3,"file":"general-run-tools.js","sourceRoot":"","sources":["../src/general-run-tools.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AACzC,OAAO,EAAmB,gBAAgB,EAAE,MAAM,4BA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CAAC,EAAE,EAAE,EAAE;;;;iBAWg57Q,0DAAsB;qBAA0D,0DAAsB;iBAAsD,0DAAsB;oBAAyD,0DAAsB;kBAAuD,0DAAsB;mBAAwD,0DAAsB;iBAAsD,0DAAsB;;;oBAA8G,0DAAsB;;;;+BAA+J,0DAAsB;;;GAD/t9Q"}
|
package/dist/live-employee.d.ts
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { type AgentSession, type ExtensionFactory } from "@earendil-works/pi-coding-agent";
|
|
2
1
|
import type { PlatformClient } from "./platform-client.js";
|
|
3
2
|
export type TeamMember = string;
|
|
4
3
|
export type EmployeeConfig = Awaited<ReturnType<PlatformClient["employeeConfig"]>>;
|
|
@@ -12,7 +11,7 @@ export declare function liveEmployee(client: Pick<PlatformClient, "employeeConfi
|
|
|
12
11
|
}, initial: EmployeeConfig, runRoot: string, team?: boolean, release?: boolean, phase?: "PREPARATION" | "DEVELOPMENT" | "DEPLOYMENT", isClosing?: () => boolean, executionContext?: () => string, onTerminalClose?: () => void, options?: {
|
|
13
12
|
child?: boolean;
|
|
14
13
|
}): {
|
|
15
|
-
extension: ExtensionFactory;
|
|
16
|
-
attach: (session: AgentSession) => void;
|
|
14
|
+
extension: import("@earendil-works/pi-coding-agent").ExtensionFactory;
|
|
15
|
+
attach: (session: import("@earendil-works/pi-coding-agent").AgentSession) => void;
|
|
17
16
|
};
|
|
18
17
|
//# sourceMappingURL=live-employee.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"live-employee.d.ts","sourceRoot":"","sources":["../src/live-employee.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"live-employee.d.ts","sourceRoot":"","sources":["../src/live-employee.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAE3D,MAAM,MAAM,UAAU,GAAG,MAAM,CAAC;AAChC,MAAM,MAAM,cAAc,GAAG,OAAO,CAAC,UAAU,CAAC,cAAc,CAAC,gBAAgB,CAAC,CAAC,CAAC,CAAC;AACnF,wBAAgB,cAAc,CAC5B,MAAM,EAAE,cAAc,EACtB,SAAS,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,EAC9B,IAAI,UAAO,EACX,MAAM,GAAE,aAAa,GAAG,aAAa,GAAG,YAA4B,EACpE,QAAQ,UAAQ,EAChB,KAAK,UAAQ,UAiCd;AAED,wBAAgB,YAAY,CAC1B,MAAM,EAAE,IAAI,CAAC,cAAc,EAAE,gBAAgB,GAAG,cAAc,CAAC,EAC/D,KAAK,EAAE,MAAM,EACb,OAAO,EAAE;IACP,MAAM,EAAE,MAAM,CAAC;IACf,UAAU,EAAE,MAAM,CAAC;IACnB,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,UAAU,CAAC;IACnB,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB,EACD,OAAO,EAAE,cAAc,EACvB,OAAO,EAAE,MAAM,EACf,IAAI,UAAO,EACX,OAAO,UAAQ,EACf,KAAK,GAAE,aAAa,GAAG,aAAa,GAAG,YAA4B,EACnE,SAAS,GAAE,MAAM,OAAqB,EACtC,gBAAgB,GAAE,MAAM,MAAiB,EACzC,eAAe,GAAE,MAAM,IAAe,EACtC,OAAO,GAAE;IAAE,KAAK,CAAC,EAAE,OAAO,CAAA;CAAO;;;EA4ClC"}
|