👗 TrendMate

AI Market Research Assistant for Malaysian Online Fashion Sellers

Python Claude Sonnet 4.6 Tavily Search Streamlit E-commerce Intelligence

📋 Project Overview & Problem Statement

Challenge: Malaysian online fashion sellers on Shopee, Lazada, and TikTok Shop make most of their product, pricing, and restocking decisions based on gut feel. They have no dedicated analyst, no market research tool built for their scale, and no time to monitor competitors, trends, and platform changes every day.

Solution: TrendMate is an AI-powered market research assistant that gives fashion sellers fast, data-backed answers on what to stock, how to price it, and when to promote — in plain, actionable language that busy sellers can act on immediately.

Key Benefits

🖥️ Application Features

📈 Trend Spotter

Searches TikTok Malaysia, Shopee trending pages, and local fashion media to identify what clothing styles, colours, and silhouettes are gaining momentum this week.

💰 Pricing Intelligence

Checks competitor listings and current market prices on Shopee and Lazada to give sellers a recommended price range for any product category.

🏭 Supplier Research

Finds wholesale sourcing options — both local Malaysian suppliers and China sourcing via Alibaba/1688 — with typical MOQs and landed cost estimates.

📅 Seasonal Planner

Flags upcoming Malaysian sale events (Raya, CNY, 11.11, 12.12) and advises on stocking timelines, top-selling styles, and promotional strategies for each season.

📋 10 Preset Questions

Sidebar includes 10 common seller questions — from trending styles to hashtag strategy to profit margins. One click sends the question with no typing required.

📥 Copy & Download

Every answer has a copy button for quick use. Full conversation can be downloaded as a .txt file — useful for sharing research with business partners.

Platforms & Sources Covered

Shopee Malaysia
Lazada Malaysia
TikTok Shop MY
Alibaba / 1688
Google Trends MY
TikTok Hashtags
Instagram Malaysia
Local Fashion Media

🤖 AI Integration & Intelligence

🧠 Claude Sonnet 4.6 (Anthropic)

The reasoning engine. Claude reads Tavily search results across multiple sources, identifies the most relevant market signals, and synthesises a 3-sentence actionable recommendation with evidence.

🔎 Agentic Search Loop

Claude uses the Anthropic tool-use API in a ReAct loop — it decides what to search, calls Tavily, reads results, and iterates until confident. Typically 1–3 searches per question.

📝 Niche System Prompt

The system prompt restricts Claude to the Malaysian fashion market, enforces the 3-sentence format with evidence + action structure, and requires price ranges to be in RM and platform-specific.

🗓️ Seasonal Awareness

The system prompt is aware of the Malaysian seasonal sales calendar — Hari Raya, Chinese New Year, 11.11, 12.12, school holidays — and flags urgency when a prep window is approaching.

🛠️ Technical Architecture & Implementation

Frontend Stack

Streamlit 1.32+ Custom CSS (Rose + Purple theme) HTML Components

Backend Stack

Python 3.10+ Anthropic SDK Tavily Python SDK python-dotenv

Deployment

Streamlit Community Cloud Local (Windows .bat launcher)

System Architecture

📖 Development Setup & Installation Guide

Prerequisites

Quick Start

# Clone from portfolio git clone https://github.com/lyven81/ai-project.git cd ai-project/projects/trendmate # Install dependencies pip install -r requirements.txt # Set up API keys copy .env.example .env # Edit .env and add your ANTHROPIC_API_KEY and TAVILY_API_KEY # Run web interface streamlit run web_app.py # Or run CLI version python app.py

Environment Configuration

ANTHROPIC_API_KEY=your_anthropic_api_key_here TAVILY_API_KEY=your_tavily_api_key_here

Windows One-Click Launch

🚀 Deployment on Streamlit Community Cloud

# 1. Push project to GitHub # 2. Go to share.streamlit.io and connect your repo # 3. Set main file as: web_app.py # 4. Add secrets in the Streamlit dashboard: # ANTHROPIC_API_KEY = "your_key" # TAVILY_API_KEY = "your_key" # 5. Deploy — live URL generated automatically

Production Notes

📊 Key Metrics

8
Platforms & Sources Covered
10
Preset Questions
3
Sentences Max Per Answer
RM50–150
Target Monthly Price

Business Value