fix(android): retain action layer and idle rotation across turns

This commit is contained in:
zenord
2026-10-13 09:36:29 +08:00
parent 24ec3ab044
commit a68988e0ba
21 changed files with 554 additions and 58 deletions
+95
View File
@@ -0,0 +1,95 @@
# Android 0.7.1 runtime trigger repair
This Android-only repair starts from clean/pushed
`24ec3ab0449f198408239a8ed9830c0ff70da776`. It fixes two defects reproduced
with production Kotlin callbacks over the published code18 assets. It does not
establish which build/mode the user's phone ran or explain every reported symptom.
The last audit report query returned zero entries at 2026-10-13 09:12:48 Shanghai.
## Confirmed defects and changes
- In code18, `ConversationMediaDriver.prepare` unconditionally revealed the held
conversation body. The continuous compositor posts held presentations every20ms.
After the music's first-frame reveal, a body callback hid music within21ms even
though the player remained started. ACTION now owns the layer from music start
through actual end/release and presentation of the reviewed return frame. Held
body callbacks cannot reveal, relabel, advance or schedule conversation. Music
ready/first-frame/end/error callbacks check their epoch and instance; duplicate
completion cannot initiate another return. Delayed activation checks ownership.
The stable View changes alpha only when the selected layer changes.
- `beginTurn` previously cleared the idle rotation target/cycle count and retained
the displayed neutral variant as the selected model goal. That variant then
remained stranded for30s. Model goal and displayed neutral variant are now
separate: new turns retain the rotation target and completed cycle count;
a neutral variant can always schedule its reviewed return. New reply expression
takes priority, and cycle cadence resets at actual bridge-to-body transitions,
rather than on every new turn/TALK update. No body seek/hardcut was added.
`emotion.prepare` still only preloads. Final happy/sad tags and selected slight
visuals remain separate; intensity2 never enlarges the expression or mouth.
The emotion path passed production loader/request/bridge/render callback replay;
actual user labels, human visibility and phone GPU remain unmeasured.
## Frozen media and backend
The reviewed index remains exactly
`987e125a7d7a2cde99121b5f5246c82f4dbe36c4899d3d49eaffd1a68bafb887`.
All3222 referenced runtime files must match code18 byte-for-byte. Five bodies,
eight own-mouth transitions, thirteen edges and two music dances are unchanged;
mouth gap remains1.1 source pixels. `--runtime-fix` packaging rejects any changed,
missing or extra avatar file, changed index pin or code18 rollback hash.
Code18/17/16 artifacts remain available. Build0.7.1/code19 uses the existing debug
certificate, `com.gorios.lanvoice`, arm64, min26/target34.
No gateway deployment/restart or server-clock/provider/TTS/model setting change.
Gateway0.8 and its exact action allowlist remain the code18 configuration. Gateway
regression runs in a temporary remote source stage, with `applied=false`.
This repair makes no LLM/ASR/TTS/paid asset calls and performs no device install.
Asset ledger is unchanged:21 submitted, known video$4.16; image/rate fees unknown.
## Verification and evidence boundaries
- Nine existing JVM/UI entry suites passed. Production View/renderer/music callback
checks now contain1288 assertions, including five10-second/241-frame scenarios
with interleaved held compositor ticks, delayed first frame, duplicate readiness,
cancellation/error/background/new turn, return A and retired callbacks.
- Existing289 bridge TALK assertions,27 idle assertions,17 full graph assertions,
and2367 dynamic frame/level/parser checks pass. New actual-APK replay exercises
both neutral idle variants through repeated new turns, preload/final mismatch,
short TALK/end, legal return and another rotation over30s.
- Production APK loader and own happy/sad routes pass with the actual frozen file
bytes, PNG dimensions, N/PTS and own patch bindings. Both dances retain music
alpha1/body alpha0 at21ms and all241 sampled frames; code18 was alpha0/body1 at21ms.
- Packaging safety has29 passing tests; five body shader runs total200 offline
software EGL/GLES goldens. Gateway98 total:97 pass and1 existing skip
(`Silero artifact excluded from source archive`). The skip is not a pass.
- Android app and instrumentation compile. Instrumentation execution, real codec/
GPU/surface visibility, AudioRecord state, actual music tail, human listening,
naturalness and perceptual latency remain **not_run**. Host replay doubles those
Android/device boundaries and recording confirmation; elapsed time alone never
causes action completion.
Reproduce source regression with `scripts/check-avatar-regressions.sh`; use
`scripts/check-avatar-apk-runtime.py --apk <APK> --sha256 <exact APK SHA>` for finite
production loader/View callback replay. Ignored evidence lives under
`logs/action-emotion/runtime-fix-071/`; audit evidence remains untouched under
`logs/action-emotion/runtime-trigger-audit-01/`. No evidence logs/media enter Git.
## Next user diagnostic
The main screen remains fullscreen avatar plus the settings gear. Settings show
versionName, **versionCode**, pin prefix, admission and current runtime state.
Sending a diagnostic explicitly includes normal/offline mode, expected pin,
loader admission/reject stage, owner/epoch/turn/seq, model request versus displayed
package/queued edge, source frame/PTS/loop, idle rotation/cycles and ignored
callbacks. HELLO reports offered pin and negotiated accepted/unavailable/unknown;
a missing plan is not asserted to be model `action:none`. Fixed events identify
prepare/receive, plan/pre-TTS-drain, actual capture-stop confirmation, first music
frame, audio release and restored A/completion. Render state changes and monotonic
10s summaries use the existing500-entry ring, without per-frame log churn.
No raw reply/prompt, credentials, audio, images or user face values are added.
A later normal-mode report can distinguish capability rejection, absent model
request, queued exit and rendering failure. Offline preview has no VoiceSession
and cannot trigger a server dance. Expression exits may still wait2–4s plus an
approximately1s bridge; this repair does not claim expression arrival within1s.