Inspiration In large-scale enterprise environments, C-level executives and Data Analysts are wasting hours every day on traditional Business Intelligence (BI) or CRM systems. These systems have two fatal weaknesses:
Passivity: They only display historical data. When a revenue chart plummets, they cannot answer the question "WHY?"
Blindness (Isolation): They analyze internal data exclusively and are completely "blind" to the outside world (e.g., competitor pricing, weather anomalies, macroeconomic news).
We asked ourselves: "What if a data analysis system wasn't just a static dashboard, but an intelligence agent capable of hearing, speaking, reasoning, and automatically scouting the market?" That is exactly why SIA (Sales Intelligence Agent) was born.
What it does SIA is a real-time Autonomous Analytics Platform that provides 3 core values:
Multi-modal UI: Executives don't need to type. They can just press the microphone and say: "How are sun protection jackets selling this month?" The system instantly streams data to the screen as dynamic charts (Generative UI) and uses an expressive AI voice (ElevenLabs) to deliver a summary report.
Market-Aware Alarm Engine: Running 24/7 in the background. When it detects a >15% drop in a product's revenue, SIA automatically triggers TinyFish (AgentQL) to scrape competitor prices on e-commerce platforms and simultaneously calls Exa Neural Search to scan market news (e.g., a prolonged severe storm). It then synthesizes the root causes and fires a red alert via SendGrid Email.
Hybrid Predictive Analytics: Instead of relying solely on Machine Learning (Prophet) for static numerical predictions, SIA integrates RAG via Zilliz Vector DB to capture the semantic context of upcoming marketing campaigns, thereby providing highly accurate strategic recommendations.
How we built it Instead of building a simple API wrapper, we engineered a true Enterprise-grade Microservices Architecture:
Frontend: Built with Next.js 14, using Zustand for state management. We utilized Server-Sent Events (SSE) to stream text tokens and chart JSON payloads to the Client, allowing Recharts to render dynamically with near-zero latency. Integrated Web Speech API for voice recognition.
Backend: Developed with FastAPI (Python) supporting full asynchronous operations (asyncpg). We used APScheduler to manage background Cron jobs for alarm monitoring.
Data Foundation (Zero Data Lake): Optimized resources by using a single Supabase (PostgreSQL) instance for both raw staging and the Data Warehouse. Employed dbt (Data Build Tool) to automatically run at midnight every day for data transformation and cleansing.
AI Orchestration: Used Dify as the coordinating brain (Router). Dify autonomously decides when to write internal SQL queries, when to call TinyFish for quantitative market data, and when to call Exa for qualitative news.
Challenges we ran into LLM Hallucinations in SQL generation: Initially, the AI frequently generated incorrect SQL queries or dangerously attempted DROP/DELETE commands. We mitigated this by setting up a Database Proxy (strict Read-only access) and injecting the database schema into Zilliz Vector DB to act as a "semantic layer" guiding the LLM.
Environment Breakage when Deploying TinyFish: Running AgentQL requires a Headless Playwright browser. When deployed to a Docker Cloud environment, the system crashed continuously due to missing core C++ libraries. We had to redesign the Dockerfile (Multi-stage build) to successfully integrate the embedded browser.
The Timeout Dilemma: Market scanning tasks via Exa and TinyFish take 5-15 seconds. If synchronous (Sync) flows were used, HTTP requests would time out. Our solution was to transition the entire pipeline to an asynchronous (Async) architecture, enabling partial results to be delivered seamlessly via SSE Stream.
Accomplishments that we're proud of We are incredibly proud of the system's Hybrid Intent Routing capability. It intelligently determines whether a user wants internal metrics (triggering SQL) or external market insights (triggering TinyFish/Exa) without manual intervention.
Creating a fully closed autonomous loop: Self-scraping data -> Self-cleansing (dbt) -> Self-monitoring -> Self-analyzing root causes (Exa) -> Self-briefing via audio (ElevenLabs).
What we learned LLMs are just brains; they need hands and eyes. No matter how powerful an AI model is, it's useless without Tools. Thanks to Exa and TinyFish, we learned how to engineer "market awareness" into an AI system.
Data Engineering is the foundation: No AI can provide correct insights if fed garbage data. Applying an ELT architecture with dbt and PostgreSQL ensured our data strictly met Data Quality standards before reaching the AI semantic layer.
What's next for SIA Integrate JigsawStack Vision: Allowing sales reps to snap photos of physical invoices or competitor flyers and push the data directly into the database using OCR.
Autonomous Action: Upgrading SIA from "just sending reports" to taking decisive actions. For example, when a revenue drop is detected due to a competitor's Flash Sale, SIA will autonomously call Facebook/Google Ads APIs to adjust the ad budget and compete directly.
Native Integrations: Connecting seamlessly with major CRM platforms like Salesforce or HubSpot to deploy SIA as a comprehensive B2B SaaS model.
Built With
- agentql
- dbt
- dify
- docker
- elevenlabs
- exa
- fastapi
- next.js
- postgresql
- prophet
- python
- recharts
- sendgrid
- supabase
- tinyfish
- typescript
- zilliz
- zustand

Log in or sign up for Devpost to join the conversation.