refactor(agent): simplify download_asset prompt instruction in prompt builder

This commit is contained in:
yiling
2026-07-29 17:15:12 +08:00
parent db04df88f1
commit 9ba61b3d3e
2 changed files with 2 additions and 3 deletions
@@ -166,7 +166,6 @@ describe('AgentChatPromptBuilder', () => {
const builder = new AgentChatPromptBuilder('a1')
const result = builder.build()
expect(result).toContain("call the 'download_asset' tool with assetId")
expect(result).toContain('remember to delete the temporary downloaded file.')
expect(result).toContain("call the 'download_asset' tool with assetId.")
})
})
@@ -174,7 +174,7 @@ export class AgentChatPromptBuilder {
}
}
instruction += `\n\nIf you need a local file on disk to run bash commands or scripts (e.g. processing or combining assets), call the 'download_asset' tool with assetId. After finishing the job, remember to delete the temporary downloaded file.`
instruction += `\n\nIf you need a local file on disk to run bash commands or scripts (e.g. processing or combining assets), call the 'download_asset' tool with assetId.`
if (this.userInfo) {
instruction += `\n\nUser Info:\nName: ${this.userInfo.name}\nRole: ${this.userInfo.role}`