A compassionate mobile app empowering dementia patients, caregivers, and admins
โจ Features โข ๐ธ Screenshots โข ๐ Database โข ๐ API โข ๐ Getting Started โข ๐ Demo
DVMA (Dementia Virtual Memory Assistant) is an innovative mobile application crafted to support individuals with dementia in navigating daily life, cherishing memories, and fostering connections with loved ones and caregivers. With intuitive role-based access for Patients, Caretakers, and Admins, DVMA delivers real-time notifications, AI-driven chat support, and advanced face recognition to uplift the well-being of dementia patients and their support networks.
| Category | Highlights |
|---|---|
| ๐ค Patient Features | - ๐
Task Management: Create, edit, and track daily/recurring tasks with reminders - ๐ค AI Chat Assistant: Gemini-powered prompts for memory and tasks - ๐ธ Memory Album: Add photos and notes to relive moments - ๐จโ๐ฉโ๐งโ๐ฆ Family Management: Add contacts and set emergency numbers - ๐ Location Sharing: Secure sharing with caretakers - ๐ Personal Diary: Private daily reflections with auto-save - ๐ Smart Notifications: Alerts for tasks and connections - ๐ญ Face Recognition: AI-based family identification |
| ๐งโโ๏ธ Caretaker Features | - ๐ Connection Management: Handle patient requests and links - ๐ค Patient Monitoring: View tasks, location, and albums - ๐ Direct Communication: Calls and messages to patients - ๐ธ Advanced Scanner: On-the-go family recognition - ๐ Task Oversight: Remote supervision of tasks - ๐ Reporting System: Submit well-being or feedback reports - ๐ Live Tracking: Real-time patient location |
| ๐จโ๐ผ Admin Features | - ๐ฅ User Management: Edit, ban/unban users and caretakers - ๐ Global Notifications: Broadcast or targeted alerts - ๐ Reports Dashboard: Review and resolve reports - โ๏ธ System Settings: Customize APIs and support - ๐ค Account Control: Manage admin permissions - ๐ Analytics: Track engagement and usage patterns |
| Patient Interface | ||
|---|---|---|
![]() |
![]() |
![]() |
![]() |
| Caretaker Interface | ||
|---|---|---|
![]() |
![]() |
![]() |
| Admin Interface | ||
|---|---|---|
![]() |
![]() |
![]() |
The Firestore structure uses normalized singular collection names for scalability and real-time sync.
| Collection | Purpose | Key Features |
|---|---|---|
user |
Patient profiles and data | Tasks, diary, family, location, notifications |
caretaker |
Caretaker profiles | Credentials, approvals, connections, notifications |
admin |
Admin accounts | System access control |
connections |
Userโcaretaker links | Status tracking, request/confirm actors, timestamps |
reports |
User-submitted reports | Issue tracking, moderation workflow |
api |
System configuration | URLs, support contacts |
Purpose: Stores patient profiles and related data.
Example Document:
{
"uid": "abc123def",
"fullName": "John Doe",
"username": "johndoe2025",
"email": "john@example.com",
"phoneNo": "+1234567890",
"dob": "1950-05-15",
"gender": "male",
"bio": "Loves gardening and music",
"locality": "Springfield",
"city": "Los Angeles",
"state": "California",
"profileImageUrl": "https://example.com/profile.jpg",
"isConnected": true,
"currentConnectionId": "conn789",
"emergencyContacts": [
{ "name": "Jane Doe", "relation": "Spouse", "number": "+1234567891" }
],
"playerIds": ["oneSignalId123"],
"isBanned": false
}Subcollections:
to_dos:{ "task": "Take medicine", "completed": false, "dueDate": "2025-11-02T10:00:00Z" }recurring_tasks:{ "task": "Morning walk", "dailyDueTime": {"hour": 8, "min": 0} }family_members:{ "name": "Mary Doe", "relation": "Daughter", "phone": "+1234567892", "imageUrl": "https://..." }album:{ "title": "Birthday 2025", "imageUrl": "https://example.com/photo.jpg" }diary: (Doc ID = date){ "content": "Had a good day today...", "createdAt": "2025-11-02T20:00:00Z" }notifications:{ "type": "connection_request", "message": "New request", "isRead": false, "createdAt": "2025-11-02T10:00:00Z" }
Purpose: Manages caretaker profiles and credentials.
Example Document:
{
"uid": "xyz789abc",
"fullName": "Sarah Smith",
"username": "sarahsmith",
"email": "sarah@example.com",
"phoneNo": "+0987654321",
"profileImageUrl": "https://example.com/caretaker.jpg",
"caregiverType": "nurse",
"relation": "",
"experienceYears": 5,
"experienceBio": "5 years of elderly care experience",
"graduationOnNursing": "BSN from UCLA",
"graduationCertificateUrl": "https://example.com/cert.pdf",
"isApprove": true,
"isConnected": true,
"currentConnectionId": "conn789",
"playerIds": ["oneSignalId456"],
"isBanned": false
}Subcollections:
notifications:{ "type": "unbind_request", "message": "Patient wants to unbind", "isRead": false, "createdAt": "2025-11-02T12:00:00Z" }
| Field | Type | Description | Example |
|---|---|---|---|
user_uid |
String | Patient UID | "abc123def" |
caretaker_uid |
String | Caretaker UID | "xyz789abc" |
status |
String | Connection status | "accepted" |
timestamp |
Timestamp | Request time | "2025-11-02T10:00:00Z" |
confirmedBy |
String | Who confirmed | "xyz789abc" |
requestedBy |
String | Who requested | "abc123def" |
| Field | Type | Description | Example |
|---|---|---|---|
sender_uid |
String | Reporter UID | "abc123def" |
sender_role |
String | Reporter role | "user" |
reported_uid |
String | Reported UID | "xyz789abc" |
reported_role |
String | Reported role | "caretaker" |
title |
String | Report title | "Inappropriate behavior during visit" |
description |
String | Report details | "The caretaker was unresponsive..." |
status |
String | Review status | "pending" |
createdAt |
Timestamp | Submission time | "2025-11-02T14:00:00Z" |
Example Document:
{
"geminiApiUrl": "https://generativelanguage.googleapis.com/v1beta/models/gemini-pro:generateContent",
"supportEmail": "support@dvma.app",
"supportPhone": "+1-800-DVMA-HELP",
"version": "1.0.0",
"lastUpdated": "2025-11-02T00:00:00Z"
}DVMA uses Firebase for auth and data, Gemini for AI, and OneSignal for notifications. Endpoints are loaded dynamically from the api collection.
- Sign Up/Login: Firebase Auth (
createUserWithEmailAndPassword/signInWithEmailAndPassword) - Role Assignment: Post-signup role selection and profile completion.
- User Tasks:
user/{uid}/to_dos(CRUD via SDK) - Connections:
connections(add/update for requests/approvals) - Notifications: OneSignal push + subcollection storage
- Face Recognition: Client-side ML Kit or Cloud Vision API
- Chat Assistant: POST to Gemini with prompt:
"As a compassionate assistant for dementia patients, respond to: {user_input}"
For details: Firebase Docs | Gemini API
- Flutter SDK (v3.10+)
- Firebase project
- OneSignal account
- Gemini API key
-
Clone the Repo:
git clone https://github.com/ajmal-uk/dementia-virtual-memory.git cd dementia-virtual-memory -
Install Dependencies:
flutter pub get
-
Configure Firebase:
- Add
google-services.json(Android) /GoogleService-Info.plist(iOS)
- Add
-
Set Environment Vars:
- Update
lib/config/app_config.dartwith API keys
- Update
-
Run the App:
flutter run
- Patient Flow: Test tasks and AI in simulator
- Caretaker: Use Firestore emulator for connections
- Admin: Enable elevated privileges for bans/notifications
Contributions welcomeโprioritize accessibility and privacy!
Download the APK for a hands-on experience. (Replace with actual link for production.)











