@fro.bot/systematic 1.21.1 → 1.21.3
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/dist/index.js +21 -4
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -452,6 +452,11 @@ function createSkillTool(options) {
|
|
|
452
452
|
}
|
|
453
453
|
|
|
454
454
|
// src/index.ts
|
|
455
|
+
var INTERNAL_AGENT_SIGNATURES = [
|
|
456
|
+
"You are a title generator",
|
|
457
|
+
"You are a helpful AI assistant tasked with summarizing conversations",
|
|
458
|
+
"Summarize what was done in this conversation"
|
|
459
|
+
];
|
|
455
460
|
var __dirname2 = path4.dirname(fileURLToPath(import.meta.url));
|
|
456
461
|
var packageRoot = path4.resolve(__dirname2, "..");
|
|
457
462
|
var bundledSkillsDir = path4.join(packageRoot, "skills");
|
|
@@ -509,15 +514,27 @@ var SystematicPlugin = async ({ client, directory }) => {
|
|
|
509
514
|
}
|
|
510
515
|
const existingSystem = output.system.join(`
|
|
511
516
|
`).toLowerCase();
|
|
512
|
-
if (
|
|
517
|
+
if (INTERNAL_AGENT_SIGNATURES.some((sig) => existingSystem.includes(sig.toLowerCase()))) {
|
|
518
|
+
try {
|
|
519
|
+
await client.app.log({
|
|
520
|
+
body: {
|
|
521
|
+
service: "systematic",
|
|
522
|
+
level: "info",
|
|
523
|
+
message: "Skipping bootstrap prompt injection for internal agent"
|
|
524
|
+
}
|
|
525
|
+
});
|
|
526
|
+
} catch {}
|
|
513
527
|
return;
|
|
514
528
|
}
|
|
515
529
|
const content = getBootstrapContent(config, { bundledSkillsDir });
|
|
516
530
|
if (content) {
|
|
517
|
-
if (
|
|
518
|
-
output.system
|
|
531
|
+
if (output.system.length > 0) {
|
|
532
|
+
output.system[output.system.length - 1] += `
|
|
533
|
+
|
|
534
|
+
${content}`;
|
|
535
|
+
} else {
|
|
536
|
+
output.system.push(content);
|
|
519
537
|
}
|
|
520
|
-
output.system.push(content);
|
|
521
538
|
}
|
|
522
539
|
}
|
|
523
540
|
};
|