Mobile surface
Byk on iOS
The iOS client shares Byk's Supabase identity and authenticated trading-surface boundary while keeping credentials, session persistence, and native navigation on the device.
Architecture
BykIOSCoreis pure Foundation. It owns Supabase project configuration, GoTrue email-code, OAuth PKCE and Sign in with Apple exchanges, RLS-scoped PostgREST reads, Keychain session persistence, and mobile analytics.BykIOSUIowns SwiftUI authentication and the session-gated root. Once signed in it hosts the trading surface in a WKWebView.- The native session is injected at document start as the Supabase SSR cookie
sb-<project-ref>-auth-token, so the web surface and native shell represent the same signed-in user. Sources/Appis the Xcode-only application entry point. Core and UI remain host-buildable Swift Package targets.
Build and run
git clone https://github.com/wisent-ai/byk-ios.git
cd byk-ios
swift build
xcodegen generate
open Byk.xcodeproj
Requirements are iOS 17 or newer, Swift 6 with Xcode 16 or newer, and XcodeGen. Run the generated project on a simulator or device through Xcode.
Authentication and storage
Email one-time-code, Google/GitHub OAuth PKCE, and native Sign in with Apple all terminate in the same Supabase session shape. The session is stored in Keychain and removed on sign-out. A stable mobile subject is used for first-party analytics and experiment assignment.
Import existing account data
During first use, choose Import existing account data…. Later, open Settings → Account data and use the same action. Both paths send a selected wisent.app.account-data.v1 file through the signed-in account and show the server's atomic imported, unchanged, conflicting, and rejected counts.
Only portfolio and watchlist records plus historical CLOSED or CANCELLED positions are accepted. Active positions, orders, executions, funds, broker connections, live or automatic-live settings, and unsupported references are refused. See Import existing Byk account data for the format, refusal meanings, and equivalent web, macOS, and CLI paths.
Security boundary
Only the publishable Supabase anonymous key ships in the client. The service-role key, database credentials, model-router credentials, and deployment tokens never reach the device. The trading web surface performs model and privileged server work behind its own authenticated server boundary.
Product boundary
Byk iOS owns native identity, session persistence, navigation, analytics, and authenticated hosting. Trading strategy, assistant reasoning, and account administration remain properties of the shared trading web product. Byk remains on commercial hold and has no independent paid entitlement.