Inspiration
A small e-commerce owner shared her frustration: she had thousands of customers and tons of sales data, but no way to analyze it or figure out what products each customer would actually want. She couldn't identify patterns, segment customers by behavior, or create personalized recommendations—those capabilities were locked behind expensive enterprise analytics platforms and data science teams. Even if she could somehow generate recommendations, writing personalized messages for thousands of customers would take weeks. I realized small businesses are drowning in data they can't use, while enterprise competitors leverage AI teams for sophisticated personalization. When AWS Bedrock made advanced reasoning accessible, I saw an opportunity to build an autonomous AI agent that democratizes these capabilities—making customer analysis, product recommendations, and personalized communication available to businesses of any size.
What it does
SmartSales AI is an autonomous AI agent powered by AWS Bedrock that transforms raw sales data into personalized customer experiences at scale. Users upload data, and the agent independently analyzes purchase patterns using collaborative filtering, segments customers with RFM analysis, and generates genuinely human-sounding messages. The agent autonomously decides when queries are needed, writes and executes SQL code on-the-fly, and interprets results in natural language—delivering dramatically faster personalization at a fraction of the cost.
How we built it
We built it using hybrid intelligence: AWS Bedrock Runtime API for autonomous reasoning and SQL generation, scikit-learn for collaborative filtering recommendations, DuckDB for fast SQL queries, and Streamlit for the web interface. The agent follows a multi-stage workflow—intent recognition → code generation → execution → interpretation → messaging—with aggressive caching and sparse matrix optimizations to handle massive transaction volumes efficiently.
Challenges we ran into
The biggest challenge was preventing LLM hallucinations in SQL generation—Bedrock initially generated invalid queries. We solved this with schema-aware prompting that explicitly lists available columns and syntax rules, dramatically improving reliability.
Accomplishments that we're proud of
We are proud of building truly autonomous intelligence that independently decides, codes, executes, and interprets. The agent achieves dramatic time savings, significant cost reduction, and exponential scalability, making enterprise-level personalization accessible to small businesses. We successfully combined ML collaborative filtering, AWS Bedrock reasoning, and natural language generation into a production-ready system that solves a real problem.
What we learned
We learned that LLM reasoning opens new paradigms—the agent actively reasons about data, generates executable code, and adapts messaging contextually. Domain-specific ML algorithms still outperform pure LLM for certain tasks. Most surprisingly, combining multiple intelligences (ML precision + LLM creativity) creates synergies neither achieves alone.
What's next for SmartSales AI
Next evolution includes multi-agent collaboration with specialized agents for inventory, pricing, and coordination. We plan real-time e-commerce integration for automated campaigns triggered by customer behavior patterns, plus voice interface for natural conversation. The ultimate vision is expanding beyond retail to healthcare, financial advisory, and B2B sales—making SmartSales AI a universal personalization platform powered by autonomous agents.
Built With
- bedrock
- duckdb
- html/css/javascript
- openai
- python
- rfm
- scikit-learn
- scipy
- sql
- streamlit
Log in or sign up for Devpost to join the conversation.