How ashwkun/box.lore.android works
1. Repository shape
This is a modular Android app with a clear split between the UI shell, feature modules, and shared core modules. The app code lives in app, while reusable logic is divided into core/model, core/network, core/data, and core/designsystem. Feature-specific Compose UIs live under feature/*.
2. App entry and presentation boundary
BoxLoreApplication and MainActivity are the Android entry points. From there, the app routes into feature screens such as home, explore, player, library, onboarding, briefing, and info. The UI layer is entirely Compose-based and relies on ViewModels for state rather than direct data access.
3. Shared design system
core/designsystem is the visual and interaction layer used across all features. It contains the app theme, expressive Material 3 components, player controls, loaders, image optimization, share sheets, consent dialogs, and navigation bars. This module is the main boundary that keeps feature UIs visually consistent.
4. Feature modules as bounded UI slices
Each feature module owns one part of the user journey:
- feature/home for discovery, recommendations, hero content, and profile
- feature/explore for search and browsing
- feature/player for playback UI, queue, transcript, chapters, and mini/full player states
- feature/library for downloads, history, likes, subscriptions, and smart-download settings
- feature/onboarding for setup and AI/search/import flows
- feature/info for podcast/episode detail and cross-promotion
- feature/briefing for the daily briefing experience
These modules depend on core repositories and shared UI components, but not on each other directly.
5. Domain and data orchestration
core/data is the application’s main business/data layer. It exposes repositories and managers for podcasts, episodes, playback, downloads, queueing, transcripts, user preferences, sharing, subscriptions, chapters, install referrers, and smart downloads. This is where app behavior is coordinated before reaching UI or infrastructure.
6. Local persistence
The app uses a Room database in core/data/database to store podcasts, downloaded episodes, listening history, and queue items. DAOs and entities provide the persistent state for offline library features, resume positions, and queue restoration. This local store is the app’s source of truth for user-owned data.
7. Media and background services
Playback and downloads are handled by dedicated Android services in core/data/service, including BoxLorePlaybackService and MediaDownloadService. The playback stack is centered on Media3/ExoPlayer and MediaSession, with the player UI controlling a long-lived service rather than playing audio directly in the screen layer. Smart download behavior is further managed by SmartDownloadWorker, SmartDownloadManager, and SmartQueueEngine.
8. Network and external content sources
core/network defines the API layer (BoxLoreApi) and remote response models for Podcast Index, iTunes, radio, onboarding, transcripts, and sync data. The README indicates the app aggregates public podcast sources, especially Podcast Index and Apple Podcast Charts. Network responses are converted into shared models in core/model, which keeps API shape separate from app/domain shape.
9. Recommendations, analytics, and personalization
The core/data/analytics, crosspromo, and privacy packages show that the app has an internal personalization layer beyond basic playback. Session aggregation, pending entry points, recommendation logic, cross-promotion detection/resolution, and consent management all sit in this core layer so features can consume curated content without embedding the logic in UI.
10. Backup, sync, and offline resilience
LibraryBackupManager, InstallReferrerManager, ThrottlingDataSource, and the download/history repositories suggest the app is designed to survive app reinstalls and network variability. Offline content, listening history, and queue state are persisted locally, while backup/sync utilities help reconstruct or protect the library state.
11. Operational data pipeline and backend maintenance
The repository also contains a non-Android operational layer: scripts/ plus GitHub workflows for syncing podcast data, vectorizing content, restoring databases, backfilling metadata, and checking new episodes. This indicates a separate ingestion/maintenance pipeline that prepares remote catalog and ranking data for the app and any supporting backend storage.
12. Distribution and web surface
firebase.json, .firebaserc, and the web/ directory provide static hosting for privacy/share pages and app-links verification (assetlinks.json). The Android app also includes an BoxLoreFcmService, so push notifications are part of the supported runtime surface. These pieces are auxiliary to the app itself, but they matter for distribution, linking, and remote messaging.
Main entry points: data Data Layer · network Network API · designsystem Design System · MainActivity.kt Main Activity
Components 19
App shell
Android entry points and runtime services.
- Application · Process-level application setup and dependency wiring.
app/src/main/java/cx/aswin/boxcast/BoxLoreApplication.kt - Main Activity · Host activity that enters the Compose UI and navigation flow.
app/src/main/java/cx/aswin/boxcast/MainActivity.kt - FCM Service · Receives remote notifications for the app.
app/src/main/java/cx/aswin/boxcast/fcm/BoxLoreFcmService.kt
Core stack
Shared model, network, data, and design system modules.
- Design System · Shared theme, controls, dialogs, loaders, and navigation chrome.
core/designsystem/src/main/java/cx/aswin/boxcast/core/designsystem - Models · Shared app-level entities for podcasts, episodes, briefing, and promotion.
core/model/src/main/java/cx/aswin/boxcast/core/model - Network API · API client and remote response models for podcast and sync sources.
core/network/src/main/java/cx/aswin/boxcast/core/network - Data Layer · Repository, manager, and orchestration layer for app behavior.
core/data/src/main/java/cx/aswin/boxcast/core/data - Room DB · Persistent storage for podcasts, downloads, history, and queue state.
core/data/src/main/java/cx/aswin/boxcast/core/data/database - Media Services · Long-lived playback and download services backed by Media3 and background work.
core/data/src/main/java/cx/aswin/boxcast/core/data/service - Personalization · Consent, session aggregation, recommendations, and cross-promotion logic.
core/data/src/main/java/cx/aswin/boxcast/core/data/analytics
Feature UI
Compose feature slices for the main user journeys.
- Home · Discovery, recommendations, hero content, and profile entry points.
feature/home/src/main/java/cx/aswin/boxcast/feature/home - Explore · Search and browse experience for catalog discovery.
feature/explore/src/main/java/cx/aswin/boxcast/feature/explore - Player · Playback UI, queue, transcript, chapters, and mini/full player states.
feature/player/src/main/java/cx/aswin/boxcast/feature/player - Library · Downloads, listening history, likes, subscriptions, and smart downloads settings.
feature/library/src/main/java/cx/aswin/boxcast/feature/library - Onboarding · Setup flows for genres, search, import, and AI-guided suggestions.
feature/onboarding/src/main/java/cx/aswin/boxcast/feature/onboarding - Info · Podcast and episode detail screens plus cross-promotion UI.
feature/info/src/main/java/cx/aswin/boxcast/feature/info - Briefing · Daily briefing experience and its view state.
feature/briefing/src/main/java/cx/aswin/boxcast/feature/briefing
Ops & web
Maintenance scripts, CI workflows, and hosted web assets.
- Pipelines · Operational scripts and GitHub workflows for sync, vectorization, and backfills.
scripts - Web Surface · Hosted privacy/share pages and app-links verification assets.
web
Connections 26
- Application → Data Layer: wires · Application scope initializes shared repositories and app services.
- Main Activity → Home: enters · Main activity hands off into the Compose navigation shell.
- Main Activity → Onboarding: routes · First-run setup can launch onboarding flows.
- Main Activity → Player: opens · Activity hosts the player surface and transitions.
- FCM Service → Personalization: notifications · Push handling connects to app-side session and entry-point logic.
- Home → Data Layer: reads · Home uses repositories for curated content and user state.
- Explore → Network API: searches · Browse/search flows depend on remote catalog access.
- Player → Data Layer: controls · Playback UI coordinates queue, chapters, transcripts, and playback state.
- Library → Data Layer: manages · Library surfaces downloads, history, subscriptions, and settings from data layer.
- Onboarding → Network API: collects · Setup screens pull remote discovery and import suggestions.
- Info → Data Layer: details · Episode and podcast info resolves local/remote content via repositories.
- Briefing → Data Layer: summarizes · Briefing composes a daily package from curated data.
- Home → Design System: shares ui · Feature screens reuse common theme and components.
- Player → Design System: shares ui · Player UI relies on shared controls and visual primitives.
- Library → Design System: shares ui · Library screens use the same shared design language.
- Info → Design System: shares ui · Info screens use shared cards, sheets, and themes.
- Onboarding → Design System: shares ui · Onboarding uses the shared Compose design system.
- Data Layer → Room DB: persists · Repositories store offline state and user-owned library data.
- Data Layer → Media Services: dispatches · Data layer starts and coordinates playback and download services.
- Data Layer → Network API: fetches · Repositories call remote APIs and map responses.
- Network API → Models: maps to · Remote payloads are normalized into shared models.
- Data Layer → Personalization: derives · Recommendations, consent, and cross-promo logic are centralized here.
- Pipelines → Network API: feeds · Sync and vectorization workflows prepare remote content data.
- Pipelines → Room DB: restores · Backfill and restore jobs operate on catalog and local database state.
- Web Surface → Main Activity: supports · Static pages and app-links assets support distribution and linking.
- Web Surface → Pipelines: publishes · Operational outputs can be deployed through hosted web assets.