From c848385ebb3ac2e57a80bde57c636e5dd28b0a00 Mon Sep 17 00:00:00 2001 From: Deep Koluguri Date: Sun, 28 Jun 2026 14:40:11 -0400 Subject: [PATCH] Remove hardcoded scraper command to let LLM orchestrator handle it --- whatsapp-gateway/server.js | 20 +------------------- 1 file changed, 1 insertion(+), 19 deletions(-) diff --git a/whatsapp-gateway/server.js b/whatsapp-gateway/server.js index 0e1fb8c..83eb417 100644 --- a/whatsapp-gateway/server.js +++ b/whatsapp-gateway/server.js @@ -110,25 +110,7 @@ client.on('message_create', async msg => { // Target Jid is where the bot should reply. const targetJid = msg.fromMe ? msg.to : msg.from; - // Custom command for utility scraper - if (text.toLowerCase().includes('run scraper') || text.toLowerCase().includes('check utility')) { - client.sendMessage(targetJid, '⚡ Triggering utility scraper in background... You will receive the report shortly!'); - try { - const http = require('http'); - const req = http.request({ - hostname: 'utility-agent.ai-agents.svc.cluster.local', - port: 5005, - path: '/api/run', - method: 'POST' - }); - req.on('error', err => console.error('[WhatsApp Bot] Failed to trigger scraper:', err)); - req.end(); - } catch (err) { - console.error(err); - } - return; - } - + // Forward the message to the new LangChain/Gemini orchestrator try { const data = JSON.stringify({ text: text,