Hasty Briefsbeta

Bilingual

Adding a feature to a closed-source app

11 hours ago
  • #Android Modding
  • #LLM-Assisted Development
  • #Audiobook Syncing
  • The author uses Audiobookshelf (ABS) for audiobooks and Smart Audiobook Player (SABP) for listening, but they don't sync progress.
  • To add ABS syncing to the closed-source SABP, the author used LLMs (Claude) to decompile the app with apktool and jadx.
  • They found a key function (PlayerService.u0()) to hook into for syncing progress, avoiding writing smali code by using Java.
  • The ABS API was tested manually to understand payloads, revealing an issue with the isFinished flag affecting progress.
  • A separate Java class (AbsSyncClient) was compiled and integrated into the APK using a smali invoke-static call.
  • LLM code review caught bugs like unnecessary reflection and a race condition, but missed syncing logic issues corrected by the author.
  • Configuration was handled via a JSON file in the book directory for server details and book IDs, avoiding UI changes.
  • The app was resigned with a new key, requiring reinstallation, but settings were preserved.
  • The experience highlighted that while LLMs make modding easier, open-source software benefits more from contributions due to accessible source code.
  • The author plans to switch to Lissen, an open-source ABS-compatible app, despite the successful mod.