Skip to content

Commit f5ce19c

Browse files
committed
update to new use type
1 parent 6cc661b commit f5ce19c

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

app/src/utils/agentTemplateManager.ts

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ appendMemory(agentId, \`\\n[\${timestamp}] \${response}\`);
3030
return `
3131
// --- SMS TOOL ---
3232
// Sends the model's response as an SMS to the specified number.
33-
sendSms(response, ${phoneNumber});
33+
sendSms(${phoneNumber}, response);
3434
`;
3535
},
3636
whatsapp: (data: ToolData) => {
@@ -39,39 +39,39 @@ sendSms(response, ${phoneNumber});
3939
// --- WHATSAPP TOOL ---
4040
// Sends a pre-approved WhatsApp notification. The content is static for now.
4141
// IMPORTANT: The 'response' variable is currently ignored for anti-spam reasons.
42-
sendWhatsapp(response, ${phoneNumber});
42+
sendWhatsapp(${phoneNumber}, response);
4343
`;
4444
},
4545
email: (data: ToolData) => {
4646
const emailAddr = data.emailAddress ? JSON.stringify(data.emailAddress) : '""';
4747
return `
4848
// --- EMAIL TOOL ---
4949
// Sends the model's response as an email to the specified address.
50-
sendEmail(response, ${emailAddr});
50+
sendEmail(${emailAddr}, response);
5151
`;
5252
},
5353
pushover: (data: ToolData) => {
5454
const userKey = data.pushoverUserKey ? JSON.stringify(data.pushoverUserKey) : '""';
5555
return `
5656
// --- PUSHOVER TOOL ---
5757
// Sends the model's response as a Pushover notification.
58-
sendPushover(response, ${userKey});
58+
sendPushover(${userKey}, response);
5959
`;
6060
},
6161
discord: (data: ToolData) => {
6262
const webhookUrl = data.discordWebhookUrl ? JSON.stringify(data.discordWebhookUrl) : '""';
6363
return `
6464
// --- DISCORD TOOL ---
6565
// Sends the model's response to a Discord channel via a webhook.
66-
sendDiscordBot(response, ${webhookUrl});
66+
sendDiscord(${webhookUrl}, response);
6767
`;
6868
},
6969
telegram: (data: ToolData) => {
7070
const chatId = data.telegramChatId ? JSON.stringify(data.telegramChatId) : '""';
7171
return `
7272
// --- TELEGRAM TOOL ---
7373
// Sends the model's response to a Telegram chat.
74-
sendTelegram(response, ${chatId});
74+
sendTelegram(${chatId}, response);
7575
`;
7676
},
7777
start_clip: () => `
@@ -94,7 +94,7 @@ ask(response);
9494
system_notify: () => `
9595
// --- SYSTEM NOTIFICATION TOOL ---
9696
// Shows a native system notification.
97-
systemNotify(response);
97+
system_notify(response, "Observer AI");
9898
`,
9999
message: () => `
100100
// --- MESSAGE TOOL ---

0 commit comments

Comments
 (0)