@shipers-dev/multi 0.6.6 → 0.6.7
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 -7
- package/package.json +1 -1
- package/src/index.ts +15 -7
package/dist/index.js
CHANGED
|
@@ -5574,7 +5574,7 @@ var LOG_PATH2 = join2(MULTI_DIR, "logs", "agent.log");
|
|
|
5574
5574
|
var SKILLS_DIR = join2(MULTI_DIR, "skills");
|
|
5575
5575
|
var STOP_PATH = join2(MULTI_DIR, "stop.flag");
|
|
5576
5576
|
var TASKS_DB_PATH = join2(MULTI_DIR, "tasks.db");
|
|
5577
|
-
var VERSION = "0.6.
|
|
5577
|
+
var VERSION = "0.6.7";
|
|
5578
5578
|
var COMMANDS = {
|
|
5579
5579
|
setup: "Register this device with a workspace",
|
|
5580
5580
|
connect: "Connect device to realtime hub and execute assigned tasks",
|
|
@@ -6225,11 +6225,18 @@ _${bits.join(" \xB7 ")}_`);
|
|
|
6225
6225
|
const base = `${task.title}
|
|
6226
6226
|
|
|
6227
6227
|
${task.description || ""}`.trim();
|
|
6228
|
-
let userPart
|
|
6228
|
+
let userPart;
|
|
6229
|
+
if (task.followup) {
|
|
6230
|
+
const cleanFollowup = stripSelfMention(task.followup, preferType);
|
|
6231
|
+
userPart = `# New user message \u2014 THIS is the current request
|
|
6232
|
+
|
|
6233
|
+
${cleanFollowup}
|
|
6229
6234
|
|
|
6230
6235
|
---
|
|
6231
|
-
|
|
6232
|
-
|
|
6236
|
+
*Earlier thread (${task.key} "${task.title}") is only background context. Do not re-address the original task unless the new message explicitly refers back to it.*`;
|
|
6237
|
+
} else {
|
|
6238
|
+
userPart = stripSelfMention(base || task.title, preferType);
|
|
6239
|
+
}
|
|
6233
6240
|
if (attachmentRefs.length) {
|
|
6234
6241
|
const lines = attachmentRefs.map((a) => `- ${a.filename}: ${a.path}`).join(`
|
|
6235
6242
|
`);
|
|
@@ -6338,11 +6345,18 @@ ${body}
|
|
|
6338
6345
|
const base = `${task.title}
|
|
6339
6346
|
|
|
6340
6347
|
${task.description || ""}`.trim();
|
|
6341
|
-
let userPart
|
|
6348
|
+
let userPart;
|
|
6349
|
+
if (task.followup) {
|
|
6350
|
+
const cleanFollowup = stripSelfMention(task.followup, preferType);
|
|
6351
|
+
userPart = `# New user message \u2014 THIS is the current request
|
|
6352
|
+
|
|
6353
|
+
${cleanFollowup}
|
|
6342
6354
|
|
|
6343
6355
|
---
|
|
6344
|
-
|
|
6345
|
-
|
|
6356
|
+
*Earlier thread (${task.key} "${task.title}") is only background context. Do not re-address the original task unless the new message explicitly refers back to it.*`;
|
|
6357
|
+
} else {
|
|
6358
|
+
userPart = stripSelfMention(base || task.title, preferType);
|
|
6359
|
+
}
|
|
6346
6360
|
if (attachmentRefs.length) {
|
|
6347
6361
|
const lines = attachmentRefs.map((a) => `- ${a.filename}: ${a.path}`).join(`
|
|
6348
6362
|
`);
|
package/package.json
CHANGED
package/src/index.ts
CHANGED
|
@@ -17,7 +17,7 @@ const LOG_PATH = join(MULTI_DIR, 'logs', 'agent.log');
|
|
|
17
17
|
const SKILLS_DIR = join(MULTI_DIR, 'skills');
|
|
18
18
|
const STOP_PATH = join(MULTI_DIR, 'stop.flag');
|
|
19
19
|
const TASKS_DB_PATH = join(MULTI_DIR, 'tasks.db');
|
|
20
|
-
const VERSION = '0.6.
|
|
20
|
+
const VERSION = '0.6.7';
|
|
21
21
|
|
|
22
22
|
const COMMANDS = {
|
|
23
23
|
setup: 'Register this device with a workspace',
|
|
@@ -623,10 +623,13 @@ async function handleRunTask(apiUrl: string, deviceId: string, task: any, detect
|
|
|
623
623
|
try {
|
|
624
624
|
if (useAcp) {
|
|
625
625
|
const base = `${task.title}\n\n${task.description || ''}`.trim();
|
|
626
|
-
let userPart
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
626
|
+
let userPart: string;
|
|
627
|
+
if (task.followup) {
|
|
628
|
+
const cleanFollowup = stripSelfMention(task.followup, preferType);
|
|
629
|
+
userPart = `# New user message — THIS is the current request\n\n${cleanFollowup}\n\n---\n*Earlier thread (${task.key} "${task.title}") is only background context. Do not re-address the original task unless the new message explicitly refers back to it.*`;
|
|
630
|
+
} else {
|
|
631
|
+
userPart = stripSelfMention(base || task.title, preferType);
|
|
632
|
+
}
|
|
630
633
|
if (attachmentRefs.length) {
|
|
631
634
|
const lines = attachmentRefs.map(a => `- ${a.filename}: ${a.path}`).join('\n');
|
|
632
635
|
userPart += `\n\n---\nAttached input files (read them with your tools if useful):\n${lines}\n\nNote: if (and only if) you produce binary or large artifact outputs (screenshots, data exports, generated source files), write them under ${outDir}. Always put your human-facing reply in the chat response itself — do NOT write your answer as a file.`;
|
|
@@ -697,8 +700,13 @@ async function handleRunTask(apiUrl: string, deviceId: string, task: any, detect
|
|
|
697
700
|
}
|
|
698
701
|
} catch {}
|
|
699
702
|
const base = `${task.title}\n\n${task.description || ''}`.trim();
|
|
700
|
-
let userPart
|
|
701
|
-
|
|
703
|
+
let userPart: string;
|
|
704
|
+
if (task.followup) {
|
|
705
|
+
const cleanFollowup = stripSelfMention(task.followup, preferType);
|
|
706
|
+
userPart = `# New user message — THIS is the current request\n\n${cleanFollowup}\n\n---\n*Earlier thread (${task.key} "${task.title}") is only background context. Do not re-address the original task unless the new message explicitly refers back to it.*`;
|
|
707
|
+
} else {
|
|
708
|
+
userPart = stripSelfMention(base || task.title, preferType);
|
|
709
|
+
}
|
|
702
710
|
if (attachmentRefs.length) {
|
|
703
711
|
const lines = attachmentRefs.map(a => `- ${a.filename}: ${a.path}`).join('\n');
|
|
704
712
|
userPart += `\n\n---\nAttached files:\n${lines}\n\nWrite generated files to: ${outDir}`;
|