Skip to content

Implementation

Technology selection (10 min)

Core frameworks

  • Programming language: Swift 6
  • UI framework: SwiftUI
  • Data persistence: SwiftData

Development toolchain

  • IDE: Xcode 16
  • Version control: Git
  • Database testing tool: DB Browser for SQLite
  • Icon / UI design: Figma
  • Mockups: Shots
  • Documentation: Material for MkDocs
  • Text editors: VSCode, Sublime Text
  • Code hosting: GitHub
  • Model hosting: Hugging Face
  • Website deployment: Vercel / Cloudflare
  • DNS management: Cloudflare
  • AI-assisted development: ChatGPT

Key app technologies & components

System features

  • Notification scheduling: UNUserNotificationCenter
  • App ratings: StoreKit
  • File handling: FileManager
  • Web integration: Safari Services

Data & storage

  • Network requests / downloads: URLSession
  • JSON parsing: JSONDecoder
  • Preference storage: AppStorage
  • Data encryption / validation: CryptoKit

UI & interaction

  • Sharing: ShareLink, UIActivityViewController
  • Image rendering: ImageRenderer
  • Tips: TipKit
  • Haptic feedback: UIImpactFeedbackGenerator

Architecture & code design

  • Architecture: Data-driven UI (MVVM)
  • State management: @State / @StateObject / @Environment / @EnvironmentObject
  • Asynchronous calls: Swift Concurrency (MainActor / Task / async/await)
  • Event observation: NotificationCenter
  • UIKit integration: UIViewControllerRepresentable
  • UI component reuse: Custom ViewModifier

Inference models

  • LLMs: Foundation Models / Qwen3
  • Inference engine: llama.cpp

Note: The technologies above reflect the current version; their individual introduction versions are not listed.


MVP implementation (90 min)

  1. Create a new iOS project
  2. Create MainView and integrate TabView to manage the Check-in, Review, and Settings screens
  3. Create models for challenges, habits, and records

  4. Build the Start screen to start a new challenge or return to the current challenge
  5. Build the Check-in screen using a List to display seven habits and implement check-ins
  6. Build the Review screen using a Grid to display all check-in records for 50 days × 7 habits
  7. Build the Settings screen with external links to Support and Privacy Policy pages

  8. Implement challenge archiving and build the Challenge History and Challenge Details screens
  9. Build the Start screen shown after a challenge is completed and the flow for starting another challenge

Completed features (v1.1–)

  • Change the date to fill in missed entries ✅
  • Add check-in notes ✅
  • Calculate consecutive check-in days ✅
  • Customize habits ✅
  • Customize the challenge duration ✅
  • Check-in reminders ✅
  • Share challenge results ✅
  • UI/UX improvements ✅
  • Challenge data import/export ✅
  • Bulk deletion of archived challenges ✅
  • Introduction and startup flow improvements ✅
  • Daily summaries with local AI ✅
  • Daily summary import/export ✅
  • Foundation Models as the preferred model ✅

Planned features / possible extensions

  • Edit the start date
  • Rewards (unlock badges when conditions are met)
  • Multilingual support (English and Japanese)

Testing (30 min)

MVP-stage tests

  1. Test the main feature flow: Start -> Check-in / Review / Settings -> End -> Start again
  2. Test the challenge lifecycle
ID Test action Expected result Notes
1-1 Open the app for the first time The Start screen is displayed
1-2 Tap Start Challenge Navigate to the Check-in screen Day 1 and seven habits are displayed
1-3 Tap the tab bar Switch freely between Check-in, Review, and Settings
1-4 Tap several habits The habits are marked as completed Tap again to undo completion
1-5 Switch to the Review screen Check-in statuses are displayed correctly Shows Day 1/50 and seven habit groups, each with 50 records
1-6 Switch to the Settings screen The settings menu is displayed
1-7 Tap the challenge list The current challenge is displayed in the list
1-8 Tap the current challenge Navigate to the Challenge Details screen Challenge data is displayed correctly
1-9 Return to Settings and end the current challenge Return to the Start screen
1-10 Tap Start Challenge again A new challenge starts The challenge list shows both the previous, ended challenge and the new, current challenge
1-11 Edit a check-in record, close the app, and reopen it The updated data is still displayed correctly
2-1 Use a database tool to manually set the current challenge's start date to 50 days ago The Start screen for a completed challenge is displayed
2-2 Tap Start Challenge again A new challenge starts The challenge list shows both the previous, ended challenge and the new, current challenge

Additional tests [v1.3]

    3. Automatic date rollover tests
ID Preconditions Test action Expected result
3-1 It is the second-to-last day of the challenge Display the Check-in screen and keep the app in the foreground until midnight The date automatically advances to the next day
3-2 Same as above Display a past date and keep the app in the foreground until midnight The displayed date remains unchanged
3-3 Same as above Display today, switch to Review, and keep the app in the foreground until midnight The displayed day count updates automatically
3-4 Same as above Display a past date, switch to Review, and keep the app in the foreground until midnight The displayed day count updates automatically
3-5 Same as above Display today, put the app in the background, and reopen it after midnight The date automatically advances to the next day
3-6 Same as above Display a past date, put the app in the background, and reopen it after midnight The displayed date remains unchanged
3-7 Same as above Display today, switch to Review, put the app in the background, and reopen it after midnight The displayed day count updates automatically
3-8 Same as above Display a past date, switch to Review, put the app in the background, and reopen it after midnight The displayed day count updates automatically
3-9 It is the last day of the challenge Display the Check-in screen and keep the app in the foreground until midnight Automatically navigate to the challenge end screen
3-10 Same as above Display a past date and keep the app in the foreground until midnight Automatically navigate to the challenge end screen
3-11 Same as above Display today, switch to Review, and keep the app in the foreground until midnight Automatically navigate to the challenge end screen
3-12 Same as above Display a past date, switch to Review, and keep the app in the foreground until midnight Automatically navigate to the challenge end screen
3-13 Same as above Display today, put the app in the background, and reopen it after midnight Automatically navigate to the challenge end screen
3-14 Same as above Display a past date, put the app in the background, and reopen it after midnight Automatically navigate to the challenge end screen
3-15 Same as above Display today, switch to Review, put the app in the background, and reopen it after midnight Automatically navigate to the challenge end screen
3-16 Same as above Display a past date, switch to Review, put the app in the background, and reopen it after midnight Automatically navigate to the challenge end screen