Laundry AI Conversational Assistant
Fine-Tuned FLAN-T5 NLP Model and Flask REST Microservice for Conversational Campus Laundry Customer Support

System Context & Value Proposition
The Laundry AI Conversational Assistant is an NLP-powered microservice built to handle 24/7 student laundry inquiries within the campus Laundry App ecosystem. Powered by a fine-tuned Google FLAN-T5 sequence-to-sequence model served through Flask, the assistant provides immediate contextual guidance on garment washing temperatures, fabric care instructions, stain diagnosis remedies, cycle turnaround times, and refund inquiries.
Hostel laundry support staff are overwhelmed by repetitive daily student questions regarding order delays, delicate garment rules, and pricing policies.
System Architecture & Execution Flow
Flutter Mobile Client
↓ (HTTP POST via connect.dart)
ngrok / Cloud Gateway
↓
Flask API Server (/get-response)
↓
Prompt Formatting & Tokenizer
↓
FLAN-T5 Base Transformer (PyTorch Weights)
↓
Response Decoding & Safety Guardrails
↓
JSON Response Streamed to Mobile Chat UIMulti-Tier Architectural Layers
Flutter, Dart (connect.dart)
Custom chat UI with quick-prompt chips, message bubble animations, and JSON HTTP POST client communicating with the Flask backend.
Python, Flask, CORS
Lightweight REST endpoint (/get-response) managing request parsing, rate limiting, and output serialization.
HuggingFace, PyTorch, FLAN-T5 Base
Sequence-to-sequence instruction-tuned model conditioned on garment care taxonomies, pricing matrices, and hostel service guidelines.
Core Engineering Modules & Workflows
Provides step-by-step chemical and temperature remedies for coffee, ink, grease, and oil stains across cottons, wools, and synthetics.
Instantly quotes accurate laundry charges, turn-around timelines, weight limits, and delivery schedules.
Dart client module (connect.dart) enabling seamless embedding of chat assistant within the mobile laundry client.
Mitigates hallucinations by bounding model generation within verified laundry care and chemical safety boundaries.
Persistence Schemas & Execution Contracts
Database Schema & Entity Structure
Datasets: ├── Datasets/laundry_dataset.json (Domain QA pairs) └── Datasets/laundry_faq_500_basic.json (FAQ dialogue corpus) Trained Checkpoints: └── flan_laundry_bot1_8_lr5e-05.pth (PyTorch Model via Git LFS)
Key Endpoints & Query Interfaces
Engineering Challenges & Specifications
Technical Obstacles Solved
Resolution: Quantized FLAN-T5 weights and implemented query response caching for top-50 high-frequency student questions.
Technology Stack Matrix
| Category | Tooling & Frameworks |
|---|---|
| NLP Model | Google FLAN-T5 Base |
| Deep Learning Library | HuggingFace Transformers, PyTorch |
| Web Server | Python Flask |
| Mobile Connector | Flutter Dart (connect.dart) |
| Tunneling Protocol | ngrok Reverse Proxy |