Skip to content

Latest commit

 

History

History
12 lines (12 loc) · 3.42 KB

ENGINEERING.md

File metadata and controls

12 lines (12 loc) · 3.42 KB

P0 engineering contract

Target: Oppo Reno 10 5G, Dimensity 7050, ColorOS 15, ARM64 Android 15. English only. User values reliability and speed above broad compatibility. Hard RAM budget 500 MB total PSS; aim below 200 MB. No root or mobile data switching. No voice replies/general knowledge.

Phases

  1. Foreground tap-to-test streaming ASR, separate cold model init and endpoint/decoding timing, no real device actions. Baseline Zipformer 20M INT8 on CPU, 2 threads; compare Moonshine v2 Small on identical command recordings only with explicit consent for recording and local deletion. Never store or upload audio by default.
  2. Add separate always-on KWS (English GigaSpeech 3.3M, one thread initially), temporary internal test phrase, single AudioRecord stream, bounded in-memory pre-roll and wake-to-command handoff. No fixed production word until owner approval; no arbitrary wake-word setting. Measure false accepts/rejects against conversation, music, noise and owner speech; test no-pause commands. Add local sensitivity calibration, evaluate speaker verification separately (not authentication).
  3. Native default assistant VoiceInteractionService + session, examine ColorOS screen-off restrictions and audio sharing; resource-worker process separate from system-bound service. Quick Settings off means stop/release mic, unload engines and terminate worker, no automatic resume until manual on. Detect real memory/thermal pressure, game foreground, calls and microphone contention; suspend/resume safely. No polling loops for app activity; no unbounded wake locks.
  4. Typed allowlist executor: app launch via exact unambiguous package mapping, settings, timers, media, flashlight, brightness, volume. No arbitrary intents or accessibility gestures. Native APIs first. Accessible system controls only if strictly needed and separately reviewed. No reading chat contents or sending/drafting in messaging apps in P0. Reject stale callbacks, duplicates, ambiguous numbers, partial results and unknown commands. No confirmation dialog for safe supported commands; distinct activation/success/failure cue, no speech output.
  5. Signed CI release, Obtainium upgrade, pinned signing certificate; no debug installation with differing signer if intended to keep app. Four existing secrets KEYSTORE_BASE64, KEYSTORE_PASSWORD, KEY_ALIAS, KEY_PASSWORD; never print them.

Acceptance gates

Record p50/p95 from end of actual speech to dispatch (goal p95 <= 500ms; measure hardware/app launch separately), wake feedback goal <= 200ms, task exact-match accuracy goal >= 99% on representative owner commands and noise, track false wake rate per hour and missed wake rate, no wrong action in negative corpus. Measure idle and peak PSS, 24h matched baseline battery drain (goal <= 3 percentage points extra), 72h background survival including screen lock, reboot behavior, mic contention with brrBoard/camera/calls and gaming frame pacing. Off tile must release microphone/models. Never interpret CI or synthetic audio alone as physical acceptance.

Current status

Phase 2 development adds the self-contained offline vault, optional background wake preview and calibrated thresholds, semantic readiness, transactional timers, private reminders, supported native controls, original feedback, and encrypted practice transfer. See the Phase 2 directive, audit, and physical acceptance plan. The existing performance numbers remain targets.