Technical Architecture

A deep dive into Spender's on-device ML pipeline.

System Requirements

  • iOS Version: iOS 18.0+ (Main App), iOS 26.0+ (Smart SMS Analyzer)
  • Device: iPhone 13 or newer (requires advanced Neural Engine support)
  • Storage: ~600MB for the ML model (downloaded via On-Demand Resources)

How SMS Parsing Works

Spender utilizes a highly optimized, on-device machine learning engine to understand transaction messages. By leveraging the iOS Neural Engine, we perform complex Natural Language Processing (NLP) tasks directly on your phone, ensuring your data never leaves the device.

The Pipeline

1

Ingestion (iOS Shortcuts)

An iOS Automation Shortcut triggers when you receive an SMS. It filters for known bank senders and securely passes the raw text to Spender for analysis.

2

Intelligent Analysis

The app uses advanced tokenization and a custom-trained Transformer model to understand the context of the message. This allows it to distinguish between amounts, merchants, dates, and payment methods with high precision.

3

Offline Inference

All processing happens offline. The inference engine is optimized for mobile performance, delivering results in milliseconds without draining your battery.

4

Entity Extraction

The engine extracts key financial data points (Amount, Merchant, Date, Bank Name, Transaction Type) and structures them into a clean transaction record.

Data Architecture

Unified Data Core

We use a reactive data architecture to manage state. All UI components observe this unified core, ensuring that when a transaction is added via SMS or manual entry, the Dashboard and Charts update instantly without reload.

Double-Entry Ledger

Unlike simple expense lists, Spender implements a full double-entry bookkeeping system. Every transaction creates immutable ledger entries, ensuring your calculated balance mathematically matches your actual bank balance.

Security Model

Spender operates on a "Zero Trust" architecture regarding external networks.

  • No API Calls: The app functions 100% offline.
  • Sandboxed Storage: Data is stored in the iOS App Sandbox (`UserDefaults` and private file storage).
  • Encrypted Backups: iCloud Sync uses your private CloudKit container, encrypted with your Apple ID keys.