ework-daemon 0.4.47 → 0.4.48
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/package.json +1 -1
- package/src/opencode.ts +6 -10
package/package.json
CHANGED
package/src/opencode.ts
CHANGED
|
@@ -817,6 +817,8 @@ export class Engine {
|
|
|
817
817
|
log.info(`engine: session "${session.name}" created for ${k}, workdir=${workdir}`);
|
|
818
818
|
|
|
819
819
|
const instructions = tracker.getTrackerInstructions(ref);
|
|
820
|
+
const payloadClone = this.cloneUrls.get(`${ref.trackerType}:${scopeKey}#${ref.issueId}`);
|
|
821
|
+
if (payloadClone) instructions.clone = `git clone ${payloadClone} .`;
|
|
820
822
|
const prompt = this.buildInitialPrompt(
|
|
821
823
|
session.name, issueData.title,
|
|
822
824
|
this.handleLargeContent(workdir, issueData.body, "issue-body.txt"),
|
|
@@ -911,6 +913,8 @@ export class Engine {
|
|
|
911
913
|
await tracker.createComment(ref, `[system] 🔄 **${session.name}** joined the conversation.`);
|
|
912
914
|
|
|
913
915
|
const instructions = tracker.getTrackerInstructions(ref);
|
|
916
|
+
const payloadClone = this.cloneUrls.get(`${ref.trackerType}:${scopeKey}#${ref.issueId}`);
|
|
917
|
+
if (payloadClone) instructions.clone = `git clone ${payloadClone} .`;
|
|
914
918
|
const prompt = this.buildInitialPrompt(
|
|
915
919
|
session.name, issueData.title,
|
|
916
920
|
this.handleLargeContent(workdir, issueData.body, "issue-body.txt"),
|
|
@@ -1487,26 +1491,18 @@ export class Engine {
|
|
|
1487
1491
|
): string {
|
|
1488
1492
|
return [
|
|
1489
1493
|
`You are ${opName}, an AI development assistant.`,
|
|
1490
|
-
`Your identity is "${opName}" — this name was assigned when you were initialized.`,
|
|
1491
|
-
``,
|
|
1492
1494
|
`A new issue needs your attention:`,
|
|
1493
1495
|
`- Issue: "${title}" (${instructions.issueRef})`,
|
|
1494
1496
|
`- Author: @${author}`,
|
|
1495
|
-
`- Working directory: ${workdir}`,
|
|
1496
1497
|
``,
|
|
1497
1498
|
`### Issue Body`,
|
|
1498
1499
|
body,
|
|
1499
1500
|
``,
|
|
1500
1501
|
`### Repository`,
|
|
1501
1502
|
`Working directory: \`${workdir}\``,
|
|
1502
|
-
`If
|
|
1503
|
-
`\`${instructions.clone}\``,
|
|
1504
|
-
``,
|
|
1505
|
-
`Read the issue, understand what's needed, work on it, and reply to the user.`,
|
|
1503
|
+
`If it's empty, clone the repo: \`${instructions.clone}\``,
|
|
1506
1504
|
``,
|
|
1507
|
-
|
|
1508
|
-
`**IMPORTANT**: Reply as soon as possible, then continue working. Don't make users wait.`,
|
|
1509
|
-
`**IMPORTANT**: Every reply MUST start with \`[bot]\` prefix.`,
|
|
1505
|
+
`Read the issue, work on it, and reply via the \`reply\` tool — every reply starts with \`[bot]\`. Post the reply as soon as possible, then continue working if needed.`,
|
|
1510
1506
|
].filter(Boolean).join("\n");
|
|
1511
1507
|
}
|
|
1512
1508
|
|