@melihmucuk/pi-crew 1.0.8 → 1.0.10
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/agents/code-reviewer.md +58 -18
- package/agents/oracle.md +9 -4
- package/agents/planner.md +25 -3
- package/agents/quality-reviewer.md +62 -21
- package/agents/scout.md +33 -26
- package/agents/worker.md +16 -0
- package/dist/index.js +0 -20
- package/dist/integration/tools/crew-list.js +10 -18
- package/dist/integration/tools/crew-respond.js +3 -0
- package/dist/integration/tools/crew-spawn.js +2 -1
- package/package.json +1 -1
- package/prompts/pi-crew-plan.md +95 -119
- package/prompts/pi-crew-review.md +89 -115
- package/dist/prompt-injection.d.ts +0 -8
- package/dist/prompt-injection.js +0 -39
package/dist/prompt-injection.js
DELETED
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
function escapeXml(str) {
|
|
2
|
-
return str
|
|
3
|
-
.replace(/&/g, "&")
|
|
4
|
-
.replace(/</g, "<")
|
|
5
|
-
.replace(/>/g, ">")
|
|
6
|
-
.replace(/"/g, """)
|
|
7
|
-
.replace(/'/g, "'");
|
|
8
|
-
}
|
|
9
|
-
/**
|
|
10
|
-
* Format discovered agent definitions for inclusion in the system prompt.
|
|
11
|
-
* Uses XML format consistent with pi's skill injection.
|
|
12
|
-
*
|
|
13
|
-
* Returns an empty string when no agents are available.
|
|
14
|
-
*/
|
|
15
|
-
export function formatAgentsForPrompt(agents) {
|
|
16
|
-
if (agents.length === 0)
|
|
17
|
-
return "";
|
|
18
|
-
const lines = [
|
|
19
|
-
"",
|
|
20
|
-
"",
|
|
21
|
-
"---",
|
|
22
|
-
"The following subagents can be spawned via crew_spawn to handle tasks in parallel.",
|
|
23
|
-
"Use crew_list to see their current status. Interactive subagents stay alive after responding;",
|
|
24
|
-
"use crew_respond to continue and crew_done to close them.",
|
|
25
|
-
"",
|
|
26
|
-
"<available_subagents>",
|
|
27
|
-
];
|
|
28
|
-
for (const agent of agents) {
|
|
29
|
-
lines.push(" <subagent>");
|
|
30
|
-
lines.push(` <name>${escapeXml(agent.name)}</name>`);
|
|
31
|
-
lines.push(` <description>${escapeXml(agent.description)}</description>`);
|
|
32
|
-
lines.push(` <interactive>${agent.interactive ? "true" : "false"}</interactive>`);
|
|
33
|
-
lines.push(" </subagent>");
|
|
34
|
-
}
|
|
35
|
-
lines.push("</available_subagents>");
|
|
36
|
-
lines.push("---");
|
|
37
|
-
lines.push("");
|
|
38
|
-
return lines.join("\n");
|
|
39
|
-
}
|