TrustLens AI — Project Description
Inspiration
Scam SMS messages, banking impersonations, and package delivery smishing attacks are increasing, causing billions of dollars in losses annually. Non-technical users often struggle to distinguish legitimate communications from fraudulent ones, especially when messages use urgency, impersonation, or suspicious links.
TrustLens AI brings enterprise-grade threat detection into an intuitive, voice-first Alexa+ conversational agent experience. Users can speak or paste suspicious messages to receive immediate risk assessments, transparent evidence breakdowns, and actionable security guidance without navigating complex cybersecurity software.
How We Built It
1. Machine Learning Core
Trained a scikit-learn text classification pipeline on 5,171 deduplicated UCI SMS Spam records. The model preserves security indicators such as __URL__, __CURRENCY__, __PHONE__, and __MULTI_EXCLAMATION__, achieving 98.4% ROC-AUC and 94.7% F1-score.
2. Alexa+ Simulation Layer
Implemented an assistant runtime in app/alexa_simulation/service.py, following Amazon Alexa+ agent specifications and Model Context Protocol (MCP) tool contracts.
3. MCP Security Tools
trustlens_inspect_message: Extracts regex-based indicators and calculates calibrated spam probabilities.trustlens_explain_threat_indicators: Separates factual observations, such as external domains and urgency keywords, from inferred threats, such as credential theft and social engineering.trustlens_get_defensive_guidance: Provides step-by-step incident response recommendations.
4. FastAPI and Privacy Backend
Built asynchronous endpoints for /api/v1/alexa/simulate, /api/v1/alexa/presets, and /api/v1/alexa/tools, incorporating SHA-256 deduplication, sensitive PII redaction, and optional Amazon Bedrock Claude 3 and Titan connectivity.
5. Modern Web Console
Developed a zero-dependency, glassmorphic web interface featuring real-time risk meters, interactive preset scenarios, contextual follow-up suggestions, and an MCP schema inspector.
Challenges We Overcame
Preview API Availability: Live Alexa+ developer endpoints are restricted to select partners. We implemented a high-fidelity simulated experience that executes real backend AI logic, following the hackathon rules permitting simulation.
Evidence Grounding: We designed the system to distinguish observed message characteristics from inferred threats, reducing unsupported security claims and helping users understand why a message is flagged.
Cross-Platform, Zero-Cost Portability: We engineered the inference and simulation pipeline to run locally on a CPU in under 200 ms, without requiring paid API services for core functionality.
Accomplishments We're Proud Of
- Genuine backend integration: No mocked responses, random probabilities, or decorative-only AI features.
- 46 automated tests passing: Coverage includes inference, preprocessing, authentication, and Alexa conversational flows.
- Transparent threat explanations: Clear separation of direct observations from inferred security implications.
- Privacy-conscious processing: Sensitive information redaction and message deduplication.
- Accessible security guidance: Actionable recommendations designed for non-technical users.
What Makes TrustLens AI Different?
TrustLens AI combines machine learning, conversational AI, explainable threat detection, and privacy-conscious engineering in a single accessible experience. Instead of simply labeling a message as spam, it explains the evidence, communicates uncertainty, and guides users toward safer decisions.
Built With
- bedrock
- context
- css
- haiku
- html5
- javascript
- mcp
- modern
- numpy
- protocol
- pytest
- python
- schema
- scikit-learn
- sdk
- sqlalchemy
- sqlite
- text
- titan
- tool
- uvicorn
- vanilla

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