feat: deliver clean avatar home in 0.6.2 UI debug candidate
Keep the avatar mounted while all connection, permission, privacy and diagnostic controls live in a settings sheet. Save the tested continuous-body renderer, safe transition driver and foreground HELLO/permission workflow from this session. Pin runtime03 for the code14 UI-only candidate; mouth deformation remains unresolved. Add source UI contracts, an optional sensor-free device probe, exact asset import and candidate packaging checks. Portrait binaries and diagnostics remain private and untracked.
This commit is contained in:
@@ -0,0 +1,44 @@
|
||||
# 0.6.1-dev / code12 内部工程候选
|
||||
|
||||
本包仅验证真实 MediaCodec 短片解码、五节点调度、TextureView PTS、前台生命周期和自动连接权限 UX。界面显著标注“工程候选:自然度待验”。不是最终自然度产品,也不认证 ≤1s 感知响应;肖像商用权利仍未核实。
|
||||
|
||||
## 素材与技术准入
|
||||
|
||||
只使用 a01-neutral-graph-v1 controlled-01 原始 manifest,SHA256:
|
||||
`e6b6e9a6e555cafb3ca7e0878600c23c4d76f13fb15d98d5f0cd8e5b192a3a09`。
|
||||
原 manifest `safeTransitions.reviewStatus=pending`、`approvedEdges=[]`、`safeExits=[]`、`publishApproval=false` 保持不变。生产 allowlist 仍为空。只有显式 `-PavatarEngineering=true` 的 debug 构建可走 `TECHNICAL_DEBUG` 范围;release 永远关闭此入口。技术字段不能满足生产图的审核范围。
|
||||
|
||||
五段实际离线视频:idle/talk1/talk2 各 12 帧、500ms;opening/end-talk 各 6 帧、250ms,24fps、480×848、H264 Main3.1、yuv420p、无音轨。入口只 frame0;出口只 manifest 指定的 frame11/frame5,CFR PTS 对应 458.333/208.333ms。独立编码边不 pixel identical;端点授权是工程实验准入,不是安全视觉验收。
|
||||
|
||||
图为 idle A→A、opening A→B、talk1/talk2 B→B、end-talk B→A(closing 别名)。保留三 self-loop、八必需转换和 opening→end-talk 反转边;缺边拒绝。窗口错过、目标未 ready、解码异常都不能强行切换。音频不等待视频;实际 PCM 播放头只提交 mouth 意图。口部感知证据不从 authored alpha 伪造,因此 mouth activity / closed-stable 延后诊断保持未知。
|
||||
|
||||
controlled-01 是 A/B 局部嘴层加最多约 0.6px/0.15px 合成身体形变,无眨眼;可能机械、照片感、肤色唇影接缝或 ghost。900ms 只是素材参数预算,不含设备解码、实际显示或用户感知。natural-02 不在本包。
|
||||
|
||||
## 复现
|
||||
|
||||
私密二进制只放 ignored `.runtime`、`app/src/main/assets/avatar`、`artifacts`,不提交 Git。
|
||||
|
||||
```sh
|
||||
python3 scripts/package-avatar-engineering.py --import-only
|
||||
./scripts/check-avatar-regressions.sh
|
||||
/home/ubuntu/miniconda3/envs/gori-speech/bin/python gateway/scripts/check-archive.py --vad-model /home/ubuntu/miniconda3/envs/gori-speech/lib/python3.12/site-packages/silero_vad/data/silero_vad.onnx > logs/avatar-safe-061/gateway-tests.txt 2>&1
|
||||
python3 scripts/package-avatar-engineering.py
|
||||
```
|
||||
|
||||
导入逐项核原 manifest/静态 A/五 MP4 哈希,检查 CFR PTS、帧数及完整解码。打包入口拒绝覆盖已有工程 APK,验证 min26/target34/arm64、同 051/052/060 debug 证书、APK 内素材字节与未压缩 MP4、HTTP APK/sidecar 字节。最终 v061 文件不使用,旧 060/052/051 保留;无提交推送、无后端变更或重启。
|
||||
|
||||
## 协调 Windows ADB 离线验收
|
||||
|
||||
安装保留数据,不加 `-g`,不清数据。先停止旧 Activity,再带 extra 启动新 Activity:
|
||||
|
||||
```sh
|
||||
adb -s 0123456789ABCDEF install -r lan-voice-v061-engineering-arm64-debug.apk
|
||||
adb -s 0123456789ABCDEF shell am force-stop com.gorios.lanvoice
|
||||
adb -s 0123456789ABCDEF shell am start -W -n com.gorios.lanvoice/.MainActivity --ez avatar_offline_preview true
|
||||
```
|
||||
|
||||
离线入口在创建 VoiceSession/音频焦点/相机控制器之前返回;不连接后端,不申请权限,不录音、不分析相机。使用真实播放器,每20s循环合成 idle/talk/stop/100ms反转/resume/abort-new-generation/drained 意图;也可手动 Idle/Talk/Abort/Trace。合成意图不是 PCM 测量。后台释放、前台重新预备 neutral 入口;横屏/平板白底 Fit 不拉伸裁头脚。应检查首帧、末帧转换、loop、黑帧、decoder fallback、后台恢复及设备资源限制;不采集用户视频/脸/音频。
|
||||
|
||||
**正常桌面启动有不同效果:** 自动连接,真实 HELLO 后申请 MIC/CAMERA;如果已授权且实际前台,会直接开启语音和相机分析。face-cue 分享仍独立默认关闭。首次设备验收请使用上面的离线命令;本 agent 不安装、不启动设备传感器。
|
||||
|
||||
JVM 使用真实 driver/codec 控制代码加确定性 Android doubles,不证明硬件解码能力或系统权限弹窗行为。硬件 PTS/双 decoder、首帧及长期资源、感知自然度、嘴活动/闭嘴 ≤1s、摄像头算法均待设备独立验收。
|
||||
@@ -1,5 +1,7 @@
|
||||
# Android 0.6.0 / code11 — neutral avatar candidate MVP
|
||||
|
||||
This describes the retained released APK only. The later user requirement replaces dial/hangup with automatic foreground connection and sequential MIC/CAMERA requests, and replaces seated media with a standing full-body identity under review. That uncommitted development is documented in [AVATAR_UX_NEXT.md](AVATAR_UX_NEXT.md) and [AVATAR_SAFE_TRANSITIONS.md](AVATAR_SAFE_TRANSITIONS.md). It has not changed or replaced this0.6.0 artifact; the default-off camera-request policy below is historical release behavior.
|
||||
|
||||
This release replaces the debug home with a video-call style single page. Before dialing it displays the a01 waiting portrait, title “声伴” and Dial; no listen/start or microphone capture occurs until the user explicitly dials and grants microphone permission. WS/health preparation alone is not a call. Connecting has a cancel action, duplicate dialing is fenced, denial shows guidance. These labels describe an app conversation, not a real person's ringing/answering. The existing hello has no character display field consumed by this client, so no private persona name is embedded.
|
||||
|
||||
During a call the 480×848 portrait fits the available width/height without stretching. Bottom controls hang up, mute the microphone, or explicitly enable the camera. Status is short; actual requested role expression, previous reply, selected neutral asset/fallback, camera presence/cue, interruption and diagnostic upload live in the expandable details. Insets are respected; details have bounded scrolling and portrait shrinks for small/landscape screens. Physical small-screen/tablet rendering remains pending.
|
||||
|
||||
@@ -0,0 +1,48 @@
|
||||
# 0.6.1-natural-dev / code13 自然工程候选
|
||||
|
||||
本阶段授权 continuous body + registered local mouth layer Android 集成。与 code12 controlled01 五 wholeframe clip 的方法不同,仍是工程候选,不认证最终自然度或 ≤1s 感知响应。后端、模型/TTS 参数、相机算法不变;没有新 AI 付费、安装或传感器采集。
|
||||
|
||||
## 精确素材与范围
|
||||
|
||||
runtime-03 manifest SHA256:`87ad2b2ad0e96fe64943692da363c856939ad4aad57073c589d53130c2f2073c`。
|
||||
来源 `.runtime/avatar-imports/a01-neutral-graph-v1/runtime-03/`,导出自 natural03。body SHA `177dbc0ab809e3c9c684899ffbd9cf3a2c357973c7037134f5d79e4e6cdfc762`,97帧、480×848、24fps、4041667us、静音 H264。97张局部嘴 PNG 为 straight RGBA8,注册/tone/空间羽化已离线烘焙,无实时 SSD。
|
||||
|
||||
保留 manifest publishApproval=false、safeTransitions pending、approvedEdges=[]、naturalQuality/deviceTest pending。仅 `-PavatarNatural=true -PnaturalManifestSha=<exact SHA>` debug 构建准入;release 关闭 runtime override,生产图 allowlist 仍为空。旧 controlled01 manifest/素材/code12 APK 保留原哈希,natural02/03 失败或审查视频不作为 runtime 片段打包。
|
||||
|
||||
## 实装路径
|
||||
|
||||
ContinuousBodyRenderer 使用一个 MediaCodec → OES SurfaceTexture → GLES2/EGL window。每次仅释放一个解码输出;updateTexImage 后核 SurfaceTexture timestamp 与 decoder PTS,ContinuousFrameClock 校验0..96连续索引及 wrap。按已消费 index 选 patch,body 和局部嘴层同一 draw/swap 完成,不独立 Compose overlay,不取 MediaPlayer position 猜相位。swap 成功仅表示合成 buffer 提交,不证明物理屏幕/用户感知时刻。
|
||||
|
||||
body 持续前进,嘴相位独立 IDLE→OPENING→TALKING→STOPPING→IDLE;250ms opening/end、500ms talk 单元。持续 talk 在合法曲线端点选择 talk1/2,有另一合法变体时不连续重复;latest generation/revision 覆盖旧请求,abort 立即由既有音频实现停止声音,嘴完成当前短单元和 closing;opening 反转可完成后 closing,stop 中恢复先完成 closing→idle,再 opening。mouth 变化不 flush/seek body。只有完整97帧 wrap 才 flush/seek0、ordinal+1。
|
||||
|
||||
PNG 启动时97张小图解码并缓存 GL texture,总 RGBA 上限8MB(本包约341KB),不每帧解码/分配全身 bitmap。Bitmap getPixels 取得 straight ARGB 后显式 RGBA byte 上传,shader `out=body*(1-g*a)+patchRGB*(g*a)`,g=0 原 body;不二次乘空间 alpha。body 和 patch 使用同一 top-left480×848坐标与白底 Fit,不裁头脚或拉伸。GLES highp 失败、PTS错配、早EOS、超时或 surface问题均回原静态兜底并记录限频 enum,无超时猜 patch、无音频等待。后台释放 decoder/EGL/GL资源并 fence旧callback;前台重新初始 body/neutral mouth。
|
||||
|
||||
## 复现与工程证据
|
||||
|
||||
```sh
|
||||
python3 scripts/package-avatar-natural.py --import-only
|
||||
python3 scripts/check-reply-regressions.py --suite avatar --runtime-manifest .runtime/avatar-imports/a01-neutral-graph-v1/runtime-03/manifest.json > logs/avatar-natural-061/actual-manifest-tests.txt 2>&1
|
||||
./scripts/check-avatar-regressions.sh
|
||||
/home/ubuntu/miniconda3/envs/gori-speech/bin/python gateway/scripts/check-archive.py --vad-model /home/ubuntu/miniconda3/envs/gori-speech/lib/python3.12/site-packages/silero_vad/data/silero_vad.onnx > logs/avatar-safe-061/gateway-tests.txt 2>&1
|
||||
python3 scripts/package-avatar-natural.py
|
||||
```
|
||||
|
||||
导入逐项核97 PNG/body SHA、尺寸/alpha/bounds、所有 body PTS/CFR和完整解码;实际 manifest 另外编译给 production Kotlin parser 验证。独立 CPU 验证97帧 alpha0 恒等及 alpha.5/1 straight/premul source-over代数;不是 GPU 像素认证。保持已有9 JVM entry points+74 gateway,全编译/验签/badging/精确APK素材清单/未压缩 MP4/HTTP SHA。真实 ContinuousBodyRenderer 也在确定性 Android MediaCodec/EGL doubles 下测帧索引、同次draw/swap、loop、停止时body连续、timestamp/swap/size/timeout失败和释放;doubles不证明硬件decoder/GLES兼容。
|
||||
|
||||
源码/素材/交付 checkpoint 与报告见 ignored `logs/avatar-natural-061/`;APK `artifacts/lan-voice-v061-natural-engineering-arm64-debug.apk`,不覆盖 code12/V060/052/051、不提交肖像 Git、不 commit/push final。
|
||||
|
||||
## 设备离线验证
|
||||
|
||||
```sh
|
||||
adb -s 0123456789ABCDEF install -r lan-voice-v061-natural-engineering-arm64-debug.apk
|
||||
adb -s 0123456789ABCDEF shell am force-stop com.gorios.lanvoice
|
||||
adb -s 0123456789ABCDEF shell am start -W -n com.gorios.lanvoice/.MainActivity --ez avatar_offline_preview true
|
||||
```
|
||||
|
||||
extra 保留相同精确名;此入口在 VoiceSession/AudioOutputGate/ExpressionController 构建前返回,完全不连WS、不请求权限、不录音不开相机。20s synthetic intent trace+Idle/Talk/Abort/Trace按钮走真实连续body renderer。观察嘴切换时 body/眼睛是否连续,97frame wrap、贴层上下方向/位置、错帧、首帧/黑帧、后台恢复/旋转/Fit、decoder/GLES错误fallback。
|
||||
|
||||
正常桌面启动仍为 foreground自动连接→真实HELLO→MIC/CAMERA权限;已有权限会直接对话和相机分析,请协调首次使用离线命令。拒相机不阻断音频;face-cue分享独立默认off,无背景服务。
|
||||
|
||||
## 未测边界
|
||||
|
||||
body loop seam 自身、头部旋转/缩放使 translation-only嘴层失配、tone/唇影/纹理接缝、Bitmap premul量化、GPU颜色转换/采样、设备短时/长期资源/温度、权限系统弹窗及硬件物理显示时间均待真机。原素材 registration0撞界不代表贴合全通过。authored alpha125–500ms不是 perceived/device latency;250/500ms曲线参数不构成 ≤1s SLA。用户相机人脸仍独立验收,肖像商业权利unverified。
|
||||
@@ -0,0 +1,41 @@
|
||||
# Fixed neutral graph — asset handoff for 0.6.1
|
||||
|
||||
This replaces the failed raw-talk slicing route. The arms reference is the accepted original SHA256 `36a078ad9e1d2929612e9baa2af524bda90dafceddc4515dd448fc08121d7dd2`. Cleanup and all rejected wide-mouth/sigh-like takes are excluded. The material owner owns `.runtime/avatar-imports/a01-neutral-graph-v1/`; Android work must not write there. Generation is bounded to at most five video calls, estimated total ≤$1.70, with opening/talk1 quality gates first. First/last image constraints are production inputs, not junction approval.
|
||||
|
||||
## Five real nodes and required junctions
|
||||
|
||||
| Node role | Anchors | Runtime operation |
|
||||
|---|---|---|
|
||||
| idle | A→A, closed mouth | independently reviewed loop |
|
||||
| opening | A→B | real opening bridge |
|
||||
| talk1 | B→B | independently reviewed small-articulation loop |
|
||||
| talk2 | B→B | independently reviewed small-articulation loop |
|
||||
| closing | B→A | `end-talk` / `idle-start` are names of this same node/file |
|
||||
|
||||
Required explicit approved transitions: idle→opening; opening→talk1 and →talk2; talk1→talk2 and talk2→talk1; talk1→closing and talk2→closing; closing→idle. In addition, idle, talk1 and talk2 each require their own reviewed self-loop seam. Absence of any junction rejects the complete product graph. Clip IDs can differ from these display names. The role accepts `closing`, `end-talk`, or `idle-start` as aliases; they must not create three different nodes.
|
||||
|
||||
The owner changed the production method after the initial two1s calls (total$0.20) gave opening but insufficient talking articulation. A controlled local mouth layer over common A/B body data is an admissible candidate, not automatic approval. Preserve original AI masters, edited B and B-compositing metadata; disclose the ellipse/feathered mouth mask, mouth/lower-jaw parameters and procedural body-deformation curves per frame. No further paid call or model installation is implied. Zero endpoint velocity is a construction constraint; final pixels and neighboring full-speed motion still need review. Local mouth blending must not conceal whole-face/body cuts or make a static portrait pass as animated idle. Keep semantic small-talk quality and all graph edge/loop gates independent.
|
||||
|
||||
The runtime preselects one legal upcoming talk variant at segment entry and prepares it on the second decoder. Another legal variant is preferred over immediate repetition; only two decoders exist. Stop cancels that hidden continuation and prepares closing. A visible opening may complete through a legal talk entry before closing. Reversal always uses the latest intent and reviewed paths.
|
||||
|
||||
An additional independently reviewed opening→closing B junction is allowed for reversal. It avoids an unnecessary talk node when the latest intention is idle, but does not replace any required junction or loop. Unknown/pending reversal metadata never becomes a shortcut.
|
||||
|
||||
## Delivery fields
|
||||
|
||||
Use `docs/AVATAR_SAFE_TRANSITIONS.md` for the exact safeTransitions v1 schema. Final pack top level: schemaVersion=1, packId=`a01-neutral-graph-v1`, identityId=`a01`, five assets, staticFallbackPath under `frames/`, staticFallbackSha256, source/provenance/rights status. Each asset has id/path/sha256/emotion=`neutral`/intensity=0/hasAudio=false. Runtime paths are `videos/<name>.mp4` or `delivery/<name>.mp4`, never audit-run paths. Keep original source spans and source PTS in separate provenance/review evidence; normalized clips have zero-origin PTS. Never round a candidate into approved metadata.
|
||||
|
||||
Each clip provides durationMs/frameCount/fpsNumerator/fpsDenominator, role, entryAnchors, safeExitWindows, loop/loopSeamReviewStatus/seekReviewStatus/reviewStatus. Intervals use startMs/endMs and startFrame/endFrame, end exclusive. For 24fps preserve exact PTS in evidence and choose integer-ms bounds that actually contain the annotated frame PTS after runtime floor-to-ms conversion. Source and target intervals share a reviewed anchor. This asserts inspected complete-state AND velocity compatibility for all permitted frame pairs, not just matching mouths.
|
||||
|
||||
Also supply `mouthStateWindows` on clips when verified: objects with state=`active` or `closed_stable`, startMs/endMs/startFrame/endFrame/reviewStatus. They record actual small conversational mouth activity and stable mouth closure seen in reviewed frames. They are independent of role/filename/anchor IDs. Missing evidence stays empty and latency stays unknown; transition or loop approval alone cannot manufacture a mouth-completion time. Fields are optional for legacy parsing but required evidence for final graph activation. Do not mark a prolonged open mouth `active` merely to satisfy this field.
|
||||
|
||||
Each junction needs dense face/fullbody/arms/feet-shadow context and full-speed repeats, including self-loops and both talk directions. Check head/eyes/blinks/lips/jaw/body/hands/feet/background/shadow plus motion speed/direction. At least 10s original-speed talk continuation and synthetic cue scenarios must be visually reviewed; no reverse/freeze/retiming/double-face crossfade. Quality and junction approval are separate gates. Until review: safeTransitions pending, approvedEdges=[], safeExits=[]; no invented windows or approved hash.
|
||||
|
||||
## Response budget and acceptance
|
||||
|
||||
Goal ≤1s means intention→observed small mouth activity, and silence/abort→observed stable closed mouth, NOT transition-start time. For natural silence count the actual-playhead detector's 120ms release; abort stops audio immediately and adds no audio wait. Worst-case source-window wait + target preparation (where not already overlapped) + bridge-to-mouth-event + presentation must fit the remaining budget.
|
||||
|
||||
Requested talk 0.4–0.7s and bridges 0.15–0.3s are search preferences, not guarantees. 0.7s wait + 0.3s closing + 0.12s detector =1.12s before decoder/presentation, hence fails. A 0.4–0.55s maximum exit gap plus 0.15–0.2s closing may leave a workable margin; still measure, do not approve from arithmetic alone. Idle exit density is equally necessary. A unique 4s exit fails.
|
||||
|
||||
Trace latest intent time/revision/generation, active source real PTS/frame, approved exit interval, target prepared time, actual reveal, actual mouth event/closed-stable frame, superseded requests and gate-wait reasons. Exercise cue offsets throughout each loop, opening reversal, ongoing talk variant changes, stop/resume, abort, late target, missed windows and background. Unknown/failed endpoints remain null. No PCM, chat, user face images or camera head pose needed.
|
||||
|
||||
Only a coordinator-reviewed exact manifest hash may enter the runtime allowlist. `scripts/import-avatar-graph.py SOURCE --approved-manifest-sha SHA --verify-only` checks bytes without importing; omit verify-only only after the handoff is reviewed. No candidate is currently allowlisted. Original 0.6.0 remains the rollback APK.
|
||||
@@ -0,0 +1,46 @@
|
||||
# Continuous body / registered mouth runtime engineering interface
|
||||
|
||||
仅 debug 自然工程候选,不是五 wholeframe clip graph,不改 pending/final 审核状态。素材 owner 独立导出,Android 不实时 SSD。导出 partial 不算完成;须最后写 manifest,核所有文件 SHA。
|
||||
|
||||
```json
|
||||
{
|
||||
"schemaVersion": 1,
|
||||
"identityId": "a01",
|
||||
"publishApproval": false,
|
||||
"packId": "a01-neutral-graph-v1-runtime-03",
|
||||
"runtimeReady": true,
|
||||
"patchFormat": {"format": "PNG RGBA 8bit", "alphaEncoding": "straight_unassociated"},
|
||||
"body": {
|
||||
"path": "body/body.mp4", "sha256": "<actual SHA256>",
|
||||
"width": 480, "height": 848, "frameCount": 97,
|
||||
"fpsNumerator": 24, "fpsDenominator": 1,
|
||||
"frameDurationUsNumerator": 1000000, "frameDurationUsDenominator": 24,
|
||||
"durationUs": 4041667, "hasAudio": false
|
||||
},
|
||||
"patches": [
|
||||
{"frameIndex": 0, "ptsUs": 0, "path": "patches/f000.png",
|
||||
"sha256": "<actual SHA256>", "x": 210, "y": 111, "width": 42, "height": 24}
|
||||
],
|
||||
"mouthStates": [
|
||||
{"id": "opening", "durationMs": 250, "frameCount": 6,
|
||||
"fpsNumerator": 24, "fpsDenominator": 1,
|
||||
"entryMouthAnchor": "A", "exitMouthAnchor": "B",
|
||||
"globalAlphaByFrame": [0, 0.0954915, 0.3454915, 0.6545085, 0.9045085, 1]}
|
||||
],
|
||||
"stateRouting": {
|
||||
"idle": ["idle", "opening"],
|
||||
"opening": ["talk1", "talk2", "end-talk"],
|
||||
"talk1": ["talk1", "talk2", "end-talk"],
|
||||
"talk2": ["talk1", "talk2", "end-talk"],
|
||||
"end-talk": ["idle"]
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
上面是字段示例,不是可直接导入的真实数据/批准 hash。mouthStates 必须完整五种:idle12个alpha0;opening6个0→1;talk1/talk2各12个1→1且中间min<.5;end-talk6个1→0。对应500/250ms,不伪增安全审核。patches 需要按真实 frameIndex0..96 完整有序列出;ptsUs=floor(index*1000000/24),容差2us。每帧 RGBA patch 可已烘焙亚像素平移、tone 和空间 mask;x/y 是在480×848 top-left 像素空间的摆放位置,不是 UV,允许有限小数。width/height 1..128,总 decoded RGBA <=8MB,每路径必须唯一。颜色按 sRGB encoded 值混合以复现当前离线 NumPy 算法;不是 linear-light 质量认证。
|
||||
|
||||
runtime 没有静态 loopOrdinal 表:ContinuousFrameClock 检查每个实际 decoded PTS/frame 连续顺序;SurfaceTexture updateTexImage 后核 timestamp,合法完成97帧后 flush/seek0 时 ordinal+1。patch 按 latched index 选,不取 MediaPlayer position。共用一个 EGL window、GLES pass 和 Fit,body OES texture 与 patch 2D texture 原子绘制后 swap;最新 mouth 曲线独立于 body loop,不因 intent seek/restart body。
|
||||
|
||||
Android Bitmap PNG 可能内部 premultiply,因此用 getPixels 提取 straight ARGB,再明确写 RGBA ByteBuffer 上传;shader global alpha g 只乘一次空间 alpha a:out=body*(1-g*a)+patchRGB*(g*a),g=0 完全原 body。所有97个小 patch 仅启动时解码/cache/upload,不每帧 allocate 全身图。音频线程不等待 GL;后台关闭 decoder/EGL/texture,旧 generation callbacks 丢弃。
|
||||
|
||||
必须提供真实 body loop 审核范围、preview/source SHA、方法与风险,仍为工程 candidate;稀疏 safe graph 不伪补 approved。runtime03 可以记录 pending,因为 debug 精确 manifest hash 准入代表本次实验授权,不代表 final quality/1sSLA。实际输出字段若不同,先发送真实 manifest 供适配,不需要覆盖既有包。
|
||||
@@ -0,0 +1,66 @@
|
||||
# Android 0.6.1/code12 — safe neutral graph integration
|
||||
|
||||
Development stage, not a released APK. The user resumed complete Android implementation, self-validation and final packaging. Final activation needs the coordinator's actual material/edge review and exact manifest SHA; no additional per-step user approval is required. The owner is producing `a01-neutral-graph-v1` independently, bounded to five video calls (estimated ≤$1.70). Failed old raw/large-mouth/sigh-like clips must never be substituted. At this stage the allowlist is empty and no graph APK has been packaged, committed, pushed or installed.
|
||||
|
||||
Retain `fdd91234b5910ee18e4a75c24c0a49de596cc4fa` and the existing 0.6.0/code11 artifact unchanged: `artifacts/lan-voice-v060-arm64-debug.apk`, SHA256 `37f789820e86ac1656bda546f47ece3e4533ff8fc54614b171fd8a42accaa52e`. 0.5.1/0.5.2 artifacts are retained too. Android may reject a lower version code over a newer installation; no downgrade/data-preservation promise or device data clearing is implied.
|
||||
|
||||
## Implemented behavior
|
||||
|
||||
Foreground entry automatically attempts health→authenticated WS→real server HELLO. Then MIC/CAMERA permission requests are sequential and remembered. No recording before MIC grant and actual foreground. Granted MIC starts voice independently of camera or video readiness; denied camera permits audio. Denied MIC has an explicit authorization/settings action, no automatic prompt loop. Three transport attempts per foreground cycle use 1s/3s backoff, stop on busy and expose manual retry. Transport retry does not generate another LLM reply. Failed voice start is visibly bounded too.
|
||||
|
||||
No dial/hangup or simulated incoming-call UX remains in the screen. Close/background the app to stop. PAUSE stops mic/camera/audio/video and clears face/sharing. A pending system permission may also STOP the Activity: retain only its continuation and fenced socket for at most 30s, never sensors. A genuine STOP disconnects WS; DESTROY releases all resources. Initially muted start is applied before capture; camera-off/denial persists. Explicit camera settings enable intent survives return from settings. Face sharing remains independently default off and clears on camera-off/disconnect/background; camera permission alone never enables sharing or image transmission.
|
||||
|
||||
The single white full-canvas screen uses Fit, preserving complete head/feet and aspect ratio on portrait/landscape/tablets. White system bars and safe insets, a status pill, visible mic/camera status, bounded scrollable controls and expandable details support small screens. Details preserve the real current/previous seven-state reply tags, neutral asset resolution/fallback, face presence/cue, AEC and explicit diagnostics. No happy/sad/etc video is claimed. Existing face model/thresholds/10Hz/TTL/diagnostics are unchanged; face acceptance is separate. Physical layout/font-scale/ROM permission acceptance remains device work.
|
||||
|
||||
## Actual renderer, not just a pure planner
|
||||
|
||||
`SafeTransitionPlanner` consumes only latest generation/revision/turn-scoped desired mouth state. That desired state comes from actual AudioTrack playback-head consumption of 20ms RMS/peak metadata, with the existing bounded 120ms silence/underrun release. Arrival, writes, tts-start and ANSWERING phase never authorize a reveal. Partial writes/cross-block windows/u32 wrap/reset/bounded metadata and drained/abort fences remain. No fixed startup buffer was added; audio never waits for video.
|
||||
|
||||
The fixed five-node contract is idle A→A / opening A→B / talk1 B→B / talk2 B→B / closing B→A. `end-talk` and `idle-start` alias that same closing node/file. The two talk self-loops, both mutual directions, both opening→talk and talk→closing edges, idle→opening and closing→idle must all be reviewed. Missing any required junction rejects complete activation. The planner chooses a legal upcoming variant at segment entry with injectable randomness, preferring the other legal talk over an immediate repeat. Stop cancels its hidden continuation and prepares closing. Opening reversal follows legal short completion/junctions toward the latest idle intent; an old callback cannot restore an old turn's talk. Native audio abort remains immediate.
|
||||
|
||||
`SafeVideoDriver` operates at most two `AnchorVideoPort`s: current clip and one paused upcoming entry. `CodecAnchorVideoPort` uses native MediaExtractor/MediaCodec on a worker looper. It seeks to a preceding sync frame, discards preroll, validates normalized CFR/PTS and renders one output at a time. TextureView's actual latched timestamp must match the submitted codec PTS. The target remains held at its reviewed entry, never an unrelated running phase. A source with another output in flight cannot supply its old texture as a fresh observation.
|
||||
|
||||
A reveal requires the target's verified entry plus a real source displayed frame inside an approved exit, followed by a fresh second source observation and successful planner commit. No timer or expired budget grants a hard cut. Late windows wait for a separately approved loop; ended nonloop clips cannot extend their last-frame window to authorize a late cut. A final-frame hold after a missed nonloop window is an exceptional failed route, not continuous animation or a freeze-based material fix. A loop may wrap only with approved seam metadata. Releasing/restarting epochs fences old source/target/error callbacks. Decode/resource/format/timestamp/timeout failures show a static exception with a retained failure enum and never delay audio. No double-face crossfade, reverse, acceleration or mouth-coordinate camera input is used.
|
||||
|
||||
The controlled local-layer candidate also offers opening→closing for reversal. This optional direct B junction is accepted only if individually reviewed and does not remove any required talk edge. Its shared authored mouth alpha/body deformation and exact raw endpoint pixels are provenance/production constraints, not encoded-edge approval. Authored alpha thresholds alone cannot mark perceived mouthStateWindows approved.
|
||||
|
||||
Prepared targets may require decoder creation repeatedly at short segment boundaries. Two-decoder capacity, TextureView timestamps at PTS0, scheduling/pacing/seek cost, frame drops/black flashes and thermal behavior need actual API31 device validation. Tests with deterministic Android API doubles verify control flow; they cannot certify hardware decoding or seamless motion.
|
||||
|
||||
## Honest response measurements
|
||||
|
||||
Each approved clip may contain reviewed `mouthStateWindows` (`active` / `closed_stable`) with exact frame intervals. Only a displayed frame in those windows completes a measured mouth response. Entering TALK or revealing a clip does not. Missing evidence leaves `mouthActiveLagMs`/`closingLagMs` null and visual wait pending. Logs expose desired/actual clip, requested/selected emotion, finite reason, full pending wait and completed response durations at ≤1Hz, clamped for diagnostic upload. No raw PCM/chat/images/coefficients/error text is added.
|
||||
|
||||
Target ≤1s remains an acceptance goal, not an achieved claim. Natural silence includes 120ms detector release, source-window wait, nonoverlapped preparation, bridge-to-mouth-event and presentation. A 0.7s talk wait +0.3s closing +0.12s release already totals1.12s, so preferred clip ranges alone cannot pass. Opening/closing activity timing, idle exit spacing and full-route latency need actual material traces and device measurement. No exact phoneme/real-person lip sync or 200ms guarantee is claimed.
|
||||
|
||||
## Private asset import and release gate
|
||||
|
||||
Accepted original crossed-arms test reference SHA256: `36a078ad9e1d2929612e9baa2af524bda90dafceddc4515dd448fc08121d7dd2`. Rights remain unverified; test identity approval is not commercial authorization. It is imported separately as static fallback; no failed video was imported. The complete graph source is `.runtime/avatar-imports/a01-neutral-graph-v1/`, manifest SHA **pending coordinator review**. Reference/source lineage, motion quality, edges, loops, preparation and device acceptance are distinct gates.
|
||||
|
||||
`docs/AVATAR_NEUTRAL_GRAPH_INTERFACE.md` defines the exact handoff/evidence/budget. `SafeAvatarManifest` rejects malformed metadata, returns no runnable graph for pending/unannotated/rejected material, and requires an exact approved SHA allowlist. The runtime additionally verifies five neutral/silent file hashes, all graph paths, full contract completeness and static fallback hash. Unknown pack/decoder failure visibly falls back; it cannot activate archived clips. Original imports remain intact; Gradle excludes old seated/arms-down packs from the new APK.
|
||||
|
||||
Reproduce after obtaining authorized private material out of band:
|
||||
|
||||
```bash
|
||||
python3 scripts/import-standing-avatar.py /path/to/original-arms-reference.png --arms-reference
|
||||
# Only after the coordinator approves actual evidence and supplies the exact final hash:
|
||||
python3 scripts/import-avatar-graph.py /path/to/a01-neutral-graph-v1 --approved-manifest-sha SHA --verify-only
|
||||
python3 scripts/import-avatar-graph.py /path/to/a01-neutral-graph-v1 --approved-manifest-sha SHA
|
||||
./scripts/check-avatar-regressions.sh
|
||||
./scripts/build.sh :app:compileDebugKotlin
|
||||
# Requires matching docs/avatar manifest/review text and runtime SHA allowlist:
|
||||
./scripts/package-avatar-safe-release.sh
|
||||
```
|
||||
|
||||
The importer confines paths/size/hashes, preflights existing bytes and refuses unknown overwrites. Private directories/files use0700/0600. Runtime imports, portraits/videos/logs/APKs remain ignored. Git will contain code, tests, docs and exact text manifest/hash/review only. No portrait binary is committed. A source checkout alone cannot reproduce the private visuals.
|
||||
|
||||
`scripts/package-avatar-safe-release.sh` checks tested-source hashes, all nine JVM entry points, full74 gateway regression, exact reviewed/allowlisted manifest and imported bytes; then builds through the isolated toolchain. It validates0.6.1/code12, arm64/min26/target34, apksigner and identical certificate to0.5.1/0.5.2/0.6.0, exact APK asset bytes and uncompressedMP4, and HTTP APK/checksum bytes. It refuses replacing retained APKs or an existing0.6.1. HTTP revalidation can use `--verify-existing` without rebuilding. Final path will be `artifacts/lan-voice-v061-arm64-debug.apk` plus `.apk.sha256`; no such final artifact exists at this stage.
|
||||
|
||||
## Validation and remaining work
|
||||
|
||||
Use `logs/avatar-safe-061/` for current client/expression/gateway/compile evidence and source hashes. Synthetic planner/driver fixtures use20fps made-up intervals; `synthetic-player-trace.json` is a finite control trace, not footage annotations, real PCM or material approval. Tests cover full graph/missing junctions, seeded continuation, entry/texture gating, missed windows/EOS/wrap, cancel/reversal/abort/old-turn/background, decoder errors/watchdogs, two-port bounds, mouth-event evidence/nulls, Fit aspect, sequential permissions/denials/settings and finite reconnect, plus retained native audio/capture/protocol/face regressions. The74 gateway suite runs temporary source copies with a checksum-verified existing Silero artifact, no service calls or live dialogue inference.
|
||||
|
||||
Before final package: receive reviewed new graph, read real quality/edge/loop/PTS evidence and previews, align normalized paths/windows, record exact manifest/review text, enable its hash, rerun affected checks and compile, then package/commit/push. If opening/talk quality or any junction fails, report the specific missing node/bridge instead of shipping a fake full graph. No extra generation beyond the bounded owner batch is initiated here.
|
||||
|
||||
On the coordinator's existing Windows USB ADB (`-s 0123456789ABCDEF`), install the verified final APK with `install -r` and check package version/signature. This agent does not configure USB/wireless/USBIP/SSH, clear data, launch recording or grant permissions. Device acceptance: first entry/granted/denied/permanently denied/revoked permissions and dialog STOP orders; mic mute; independent camera/share; busy/network failure/retry; voice/PCM silence/underrun/drain/abort; all graph junctions, stop/resume/reversal at varied offsets; actual mouth-response times; background/resume; portrait/landscape/small screen/tablet/large fonts; unsupported decoder/static failure. No new device report or face-recovery claim exists.
|
||||
|
||||
Backend/provider/model/TTS voice parameters, ASR/VAD services and container configuration were not changed or restarted.
|
||||
@@ -0,0 +1,64 @@
|
||||
# Safe avatar transition interface — implementation and synthetic tests, not material approval
|
||||
|
||||
PCM native playback activity provides the latest desired mouth mode. It does not change video visibility. `SafeTransitionPlanner` is a pure state machine with no audio/network dependency. Audio abort and capture stop remain immediate; visual closing uses reviewed edges and may lag. No waiting policy delays audio or adds an audio startup buffer. Neither 200ms nor a 4s visual wait is accepted or claimed.
|
||||
|
||||
## Optional manifest extension
|
||||
|
||||
`SafeAvatarManifest.read(Map, actualManifestSha256, approvedManifestHashes)` supports an optional `schemaVersion:1` extension, `safeTransitions.version:1`. No extension gives LEGACY_UNANNOTATED and no runnable graph. Pending/unknown review gives REVIEW_PENDING and no graph even when times are omitted; inventing intervals to make a candidate parse is forbidden. Malformed approved metadata gives INVALID. Approved metadata needs the coordinator-approved **exact SHA256** allowlist too; by default that list is empty. The current AvatarPack loader performs JSON-to-Map conversion, bounded byte/hash validation and fixed neutral graph completeness checks. The target is a01-neutral-graph-v1; its exact manifest hash allowlist is currently empty. See AVATAR_SAFE_061.md and AVATAR_NEUTRAL_GRAPH_INTERFACE.md for the current integration boundary.
|
||||
|
||||
A minimal honest candidate extension, with no synthetic timestamps:
|
||||
|
||||
```json
|
||||
{
|
||||
"version": 1,
|
||||
"reviewStatus": "pending",
|
||||
"anchors": [],
|
||||
"clips": [],
|
||||
"transitions": []
|
||||
}
|
||||
```
|
||||
|
||||
For a reviewed extension the following fields are required:
|
||||
|
||||
| Object | Fields and meaning |
|
||||
|---|---|
|
||||
| Graph | reviewStatus, initialAssetId, initialEntryId, anchors, clips, transitions |
|
||||
| Anchor | id, closedMouth (reviewed entry observation), reviewStatus |
|
||||
| Clip | assetId referencing a declared id/path; role idle/opening/talk/closing/waiting; durationMs, frameCount, fpsNumerator/fpsDenominator; entryAnchors, safeExitWindows; reviewStatus, loop, loopSeamReviewStatus, seekReviewStatus |
|
||||
| Entry/exit interval | id, anchorId, startMs/endMs, startFrame/endFrame, reviewStatus; both ends are **exclusive at end**, frame indices start at0 |
|
||||
| Transition | id, sourceAssetId, sourceWindowId, targetAssetId, targetEntryId, reviewStatus, earliestPolicy=`next_safe_window`, latestPolicy=`next_reviewed_loop` or `hold`, earliestWaitMs, optional latestWaitMs |
|
||||
|
||||
Limits:32 clips,64 anchors,128 edges,32 entries/exits per clip, ≤60s duration and wait budget, ≤3600 frames, bounded safe identifiers and relative paths under videos/frames/delivery. Time/index annotations must agree within frame rounding. Source window and target entry refer to the **same reviewed anchor ID**. A shared ID asserts that **every allowed source/entry frame combination and motion junction** was inspected, not that a single still looked similar. Shorter windows or explicit distinct anchors/edges are necessary if only specific frame pairs match. Frame0 or final frame is not automatically safe. Displayed head/eyes/mouth/body/hands/feet/background/shadow and motion speed/direction all matter.
|
||||
|
||||
Opening and closing are explicit actual clip nodes: idle→opening→talk→closing→idle, only if each junction is approved. No opaque bridgeAssetId shortcut is accepted. An already visible bridge follows a reviewed route for the newest intention; a reversal may require finishing its short path before closing. More poses/idle variations use pre-authored anchor IDs and assets, never the user's camera head pose. No complete emotion/pose cross-product is required. Review state is unknown/pending/approved/rejected; unknowns and rejected edges stay unusable.
|
||||
|
||||
`latestWaitMs` is a **diagnostic budget only**; exceeding it cannot authorize a cut. Clip lengths and budgets are metadata/configuration, never hardcoded4s. `next_reviewed_loop` can retry a missed window only when the source clip and its seam are approved. `hold` refuses to carry the offered edge into another loop. A talk segment cut out of an otherwise continuous source still needs its own approved tail→head loop. Matching first/last stills is insufficient to certify the seam or arbitrary-time transitions.
|
||||
|
||||
## Driver contract
|
||||
|
||||
1. Set a monotonic generation/revision/turn-scoped MouthIntent. Latest valid intent cancels staged old targets/offers. Wrong-turn PCM, old generations/revisions and old callbacks are fenced. Callbacks never write mouth intent. Abort/disconnect/drained desire idle; the legacy hangup planner case desires waiting but the latest UX has no hangup control.
|
||||
2. `tick` consumes fresh actual video positions and actual displayed-frame indices, loop ordinal, serial and continuity status. `ActualClipCursor` only tracks successive actual samples; it requires a separately observed displayedFrame, not a predicted frame. Wrap is recognized only near last/first two frames. Backward jitter, a seek or a gap long enough to miss a loop makes continuity unknown until reset. Position-derived frame estimates alone cannot prove that the target texture is showing that frame.
|
||||
3. On Stage, pause and seek/preload the hidden target at its approved entry. Await **seek completion and a latched displayed texture frame** in the interval. Do not advance an unrelated hidden clip phase. MEDIA_INFO_VIDEO_RENDERING_START alone is inadequate. Actual MediaPlayer/SurfaceTexture seek and texture timestamp behavior, decoder/GOP support, seek cost and target drift must be verified before connecting this contract to production UI.
|
||||
4. An OfferCut is only a proposal. Immediately before revealing, obtain a **second fresh source observation** still inside the same source window/loop and revalidate the paused target. `commit` returning Reveal is the only switch permission. A missed/stale/expired offer yields Hold; do not apply a delayed alpha change or crossfade. Default sample freshness40ms is configurable1–100ms; it is sample validity, not a synchronization SLA.
|
||||
5. A bridge may continue through approved junctions to the latest desired state. No reviewed path means keep the current mode and report NO_REVIEWED_EDGE; no invented closed pose, timeout cut, double-face crossfade or fake loop. An unreviewed loop cannot run forever; the future driver must stop advancing across its seam and report unavailable/hold according to explicit failure UX. Holding a final frame or emergency static fallback is an exception, not a reviewed continuous animation. Background releases immediately and invalidates renderer epochs. Foreground requires a new generation and an explicitly staged, verified neutral startup entry.
|
||||
|
||||
Optional reviewed mouthStateWindows (active/closed_stable with frame/time intervals) measure actual displayed mouth events, independently of role/reveal. Missing events leave completed response latency null; an ongoing wait is never reported as completed closure. Snapshot diagnostics include desired/actual role, generation/revision, finite reason, full pending visual wait, closing-entry lag, pending exit, switch/cancel counts. `TransitionDiagnostics` emits≤1Hz and clamps reported times to60s; snapshots retain full wait for local evaluation. Closing lag measures arrival at a reviewed closed-mouth entry, not a phoneme or every intervening frame. No chat, PCM, images, coefficients or raw error text. Requested reply expression remains separately real; neutral resolved fallback never rewrites it.
|
||||
|
||||
## Current integration boundary and materials
|
||||
|
||||
The planner, strict optional manifest reader, cursor and diagnostics are implemented and tested against **synthetic1s/20fps graph fixtures**, which are not annotations for a01 material. They are now wired to SafeVideoDriver and the native CodecAnchorVideoPort with actual codec PTS/TextureView timestamp gates; deterministic API-double tests cover the adapter, while hardware/device rendering remains pending. The old arbitrary phase-switch renderer has been removed from current code. The latest UI supplies no seated motion pack. No approved safe graph is packaged. Audio/permission UX can therefore be tested independently; visual production completion still requires real reviewed assets and driver/device acceptance.
|
||||
|
||||
a01-v1 original materials and the published0.6.0 APK remain intact. Seated a01-v2, arms-down standing-v3, crossed-arms v2/v3-motion and the single3s raw experiment are archives with no usable approved graph. The latest accepted original crossed-arms reference SHA is36a078ad9e1d2929612e9baa2af524bda90dafceddc4515dd448fc08121d7dd2. The owner is producing a01-neutral-graph-v1 under the bounded five-call budget; quality gates and actual windows are pending. Do not promote first/last constraints, similarity rankings or static identity approval into safe motion approval.
|
||||
|
||||
Necessary material evidence before integration: accepted reference identity; actual decoded frame/time intervals for each entry/exit; approved edges including real opening/closing bridges if needed; approved idle/talk loop seams and ability to stage entry on target device; short dense ±0.5s junction sequences plus full-speed repeated loops and transitions; explicit latency tradeoff approval if safe exits are sparse. The number/cost of candidates is finite and separately agreed; no additional video generation is initiated here.
|
||||
|
||||
Available archived seated candidate previews (not standing materials):
|
||||
|
||||
- `.runtime/avatar-imports/a01-v2/review/switch-boundary-only-candidate.mp4` — complete-cycle candidate,20s.
|
||||
- `.runtime/avatar-imports/a01-v2/review/switch-boundary-only.gif` — convenience240px/12fps reduction, not acceptance at delivery spec.
|
||||
- `.runtime/avatar-imports/a01-v2/review/boundary-idle-to-talk-dense-24.png`
|
||||
- `.runtime/avatar-imports/a01-v2/review/boundary-talk-to-idle-dense-24.png`
|
||||
- `.runtime/avatar-imports/a01-v2/review/idle-loop-5x.mp4`
|
||||
- `.runtime/avatar-imports/a01-v2/review/talk-loop-3x.mp4`
|
||||
|
||||
Coordinator has local copies under `/mnt/d/baji-vc-install/avatar-review/a01-v2/`. Existing NumPy/Pillow interpreter is `/home/ubuntu/miniconda3/bin/python3`; ffmpeg `/home/ubuntu/gori-bin/ffmpeg`. No installation required. Viewing sampled PNGs or decoding frames does not establish full-speed visual or device approval.
|
||||
@@ -0,0 +1,60 @@
|
||||
# 0.6.2-ui-dev / code14 — clean home UI candidate
|
||||
|
||||
This authorized internal debug APK fixes the app UI over code13. Mouth rendering and all portrait asset bytes remain identical to runtime03; the reported mouth deformation is **not fixed** in this version. It is not a final natural-quality release or a certified ≤1s perceived-mouth response. No backend, provider, TTS, voice, camera model/threshold, system toolchain or service change is included.
|
||||
|
||||
## Home and settings
|
||||
|
||||
Normal and offline entry show a white full-screen Fit avatar and one bottom-right settings gear. The touch target is 48dp plus safe drawing insets. No app title, connection/error strip, candidate banner, emotion/face labels, diagnostic text or mic/camera bar covers the home. System permission dialogs and OS privacy indicators remain visible.
|
||||
|
||||
The scrollable settings bottom sheet holds connection/retry/error and permission information, mic pause/resume, camera control, independent face-cue sharing (default off), current/previous requested emotion and selected neutral fallback, diagnostic report action/results, player diagnostics and candidate limitations. Offline Idle/Talk/Abort/Trace controls also live here. The sheet explicitly states that runtime03 mouth deformation remains unresolved.
|
||||
|
||||
The avatar stays in the same composition slot outside the conditional sheet. Opening or closing the sheet neither keys nor recreates the AndroidView/renderer, changes Activity lifecycle, nor calls the connection/session coordinator. Avatar time and conversation continue while settings are open. On short/landscape/tablet screens the sheet scrolls; the body uses one shared Fit transform without stretching or cropping head/feet.
|
||||
|
||||
Foreground still automatically connects, waits for real server HELLO, then sequentially requests MIC/CAMERA as required. Already granted permissions can immediately start recording/camera analysis. Denied camera permits voice, denied mic starts no recording, asked/denied/off choices prevent prompt loops. Permission pauses stop sensors while retaining bounded connection continuation. Genuine background releases capture/audio/camera/video, clears face/share and disconnects. No background service. Settings permissions/control actions retain these guards.
|
||||
|
||||
## Exact assets and mouth investigation boundary
|
||||
|
||||
Runtime manifest SHA256: `87ad2b2ad0e96fe64943692da363c856939ad4aad57073c589d53130c2f2073c`.
|
||||
Body SHA256: `177dbc0ab809e3c9c684899ffbd9cf3a2c357973c7037134f5d79e4e6cdfc762`.
|
||||
Source: `.runtime/avatar-imports/a01-neutral-graph-v1/runtime-03/`.
|
||||
Accepted test static reference SHA256: `36a078ad9e1d2929612e9baa2af524bda90dafceddc4515dd448fc08121d7dd2`.
|
||||
All pending natural/device/rights/publish flags are retained. Debug exact-hash admission grants this experiment only. Production motion hash allowlist remains empty. Portrait images/videos, logs and APKs stay ignored in Git.
|
||||
|
||||
The read-only code audit found no proven double-premultiplication, UV inversion or frame-index bug. Bitmap defaults to premultiplied decode, then getPixels yields straight ARGB for explicit RGBA upload. Fragment output is `body*(1-g*a)+patchRGB*(g*a)`, opaque alpha1; fresh EGL context has fixed-function blending disabled. Patch uses GL_LINEAR. Body transform comes from SurfaceTexture; top-left patch coordinates use the logical480×848 quad. One pending decoded output is latched/timestamp-checked and its corresponding patch is composed in the same GLES draw/swap. Both share Fit. No explicit linear-light or sRGB conversion is applied.
|
||||
|
||||
This source audit and CPU export equality do not validate actual Android GPU color/UV/Bitmap output or rule out asset defects. Intermediate opacity mixes two lip anatomies and can ghost; feather sampling/quantization, color mismatch and translation-only registration under rotation/scale remain possible contributors. Runtime04's proposed per-body-frame aperture-level patches are a different parser/shader contract and are not admitted here. No asset directory is overwritten and no mouth alpha is suppressed to hide the issue.
|
||||
|
||||
## Reproduce without committing portrait binaries
|
||||
|
||||
Use the existing private source packs. Import the accepted original arms PNG with `scripts/import-standing-avatar.py --arms-reference <exact-original-PNG>`. Restore controlled01 using `scripts/package-avatar-engineering.py --import-only`; it preserves pending flags and pins manifest `e6b6e9a6e555cafb3ca7e0878600c23c4d76f13fb15d98d5f0cd8e5b192a3a09`. Import runtime03 using the command below. Missing, drifted or invalid data stops packaging; on-device invalid/missing runtime falls back to the verified still image, and a missing still produces the clean white canvas with gear. No unsafe pack substitution is allowed.
|
||||
|
||||
```sh
|
||||
/home/ubuntu/miniconda3/bin/python3 scripts/package-avatar-ui.py --import-only
|
||||
python3 scripts/check-reply-regressions.py --suite avatar --runtime-manifest .runtime/avatar-imports/a01-neutral-graph-v1/runtime-03/manifest.json > logs/avatar-062/actual-manifest-tests.txt 2>&1
|
||||
./scripts/check-avatar-regressions.sh
|
||||
/home/ubuntu/miniconda3/envs/gori-speech/bin/python gateway/scripts/check-archive.py --vad-model /home/ubuntu/miniconda3/envs/gori-speech/lib/python3.12/site-packages/silero_vad/data/silero_vad.onnx > logs/avatar-safe-061/gateway-tests.txt 2>&1
|
||||
./scripts/build.sh compileDebugKotlin assembleDebugAndroidTest -PavatarNatural=true -PavatarUiCandidate=true -PnaturalManifestSha=87ad2b2ad0e96fe64943692da363c856939ad4aad57073c589d53130c2f2073c > logs/avatar-062/android-test-compile.txt 2>&1
|
||||
/home/ubuntu/miniconda3/bin/python3 scripts/package-avatar-ui.py
|
||||
```
|
||||
|
||||
The packager requires current source regression hashes, actual production Kotlin manifest parsing, unchanged mouth renderer fingerprints, exact body/97patch hashes/full decode, all74 gateway tests, compiled optional UI instrumentation, package/signature/SDK/ABI and ZIP byte checks. It compares all avatar bytes with retained code13, verifies HTTP APK/checksum bytes and refuses to overwrite an existing artifact. Version0.6.2-ui-dev/code14, min26/target34/arm64-v8a, same existing debug certificate. Baseline051/052/060/code12/code13 remain byte-identical. No store/release signing is used.
|
||||
|
||||
## Validation and physical-device boundary
|
||||
|
||||
Executed checks: nine existing JVM entrypoints including production MediaCodec/EGL renderer under deterministic doubles, current permission/background/auto-entry/mute tests and repeated ACTIVE coordinator drives representing settings recomposition; clean-home source contracts; actual runtime03 production parser; complete Kotlin/Android test APK compile; all74 isolated gateway tests. Clean-home source contracts verify only avatar+gear outside the sheet and that sheet state never keys the renderer/session. These are not an executed Compose UI/instrumentation test or a physical screen assertion.
|
||||
|
||||
An optional platform-only instrumentation probe is compiled in `app/src/androidTest/java/com/gorios/lanvoice/AvatarCleanUiInstrumentation.kt`. It explicitly uses offline mode, checks the accessibility home has no app text and only one48dp gear, opens/closes settings three times while verifying the identical avatar View and renderer instance, checks no VoiceSession/ExpressionController is constructed, and backgrounds the Activity to check renderer release. It captures no screenshots/audio/camera data. It has not run here; coordinator must first confirm the device is online. OEM accessibility, keyboard/navigation insets, real permission dialogs, actual decoder/GLES appearance, performance and user-perceived latency remain untested in this build.
|
||||
|
||||
```sh
|
||||
adb -s 0123456789ABCDEF install -r lan-voice-v062-ui-candidate-arm64-debug.apk
|
||||
adb -s 0123456789ABCDEF shell am force-stop com.gorios.lanvoice
|
||||
adb -s 0123456789ABCDEF shell am start -W -n com.gorios.lanvoice/.MainActivity --ez avatar_offline_preview true
|
||||
```
|
||||
|
||||
This exact extra returns before constructing session/audio/camera. Open the gear to find synthetic intent controls. For the optional UI probe, after installing `app/build/outputs/apk/androidTest/debug/app-debug-androidTest.apk` built by the commands above:
|
||||
|
||||
```sh
|
||||
adb -s 0123456789ABCDEF shell am instrument -w com.gorios.lanvoice.test/com.gorios.lanvoice.AvatarCleanUiInstrumentation
|
||||
```
|
||||
|
||||
Normal launcher entry can activate already-granted MIC/CAMERA after HELLO; use the offline command for sensor-free verification. No automatic installation, permission granting, recording or device-network configuration is performed by this task. User camera/face algorithm acceptance remains separate.
|
||||
@@ -0,0 +1,29 @@
|
||||
# Current avatar UX — clean home in 0.6.2 UI candidate
|
||||
|
||||
The user has resumed complete implementation, self-validation and final APK production. This supersedes both the released0.6.0 dial/hangup design and the intervening development pause. Final motion activation still requires coordinator review of actual material/edges and an exact manifest hash; no repeated per-step user permission is required. Current implementation, limitations and release gate: [AVATAR_SAFE_061.md](AVATAR_SAFE_061.md). Material owner interface: [AVATAR_NEUTRAL_GRAPH_INTERFACE.md](AVATAR_NEUTRAL_GRAPH_INTERFACE.md).
|
||||
|
||||
## Foreground conversation
|
||||
|
||||
RESUMED automatically attempts health→authenticated WS→real HELLO. Only after HELLO request microphone and camera sequentially, once unless explicitly retried. Already granted MIC can start voice immediately, independently of camera/video preparation. Denied camera permits audio; denied MIC starts no capture and exposes authorization/settings. Persist asked/denied/mute/camera-off preferences; no repeated automatic permission prompts.
|
||||
|
||||
CONNECTING / AWAITING_PERMISSION / ACTIVE / ERROR are the page states. Transport retry is finite (three attempts,1s/3s backoff), stops on busy and leaves visible manual Retry. It never requests duplicate LLM generation. No dial/hangup, fake ringing, real-person acceptance claim, account or router UI. Users close/background the app to exit.
|
||||
|
||||
PAUSE stops sensors/audio/video and clears face/sharing. Pending system permission can also cause STOP: retain only continuation and a bounded30s fenced socket, never sensors. Genuine STOP disconnects WS; DESTROY releases. Callbacks arriving while paused cannot start capture. A remembered microphone mute applies before starting capture. Explicit camera settings action retains enable intent on return; denied/user-off camera stays off without such an action. Face-cue sharing is separate, default off and cleared on camera-off/disconnect/background. No images transmitted.
|
||||
|
||||
## Screen
|
||||
|
||||
White full canvas with Fit media and white system bars; preserve complete body/head/feet, no stretching or centerCrop. Home contains only the avatar and one bottom-right48dp settings gear with safe insets. All connection/error states, recording/camera controls, permissions, emotions, diagnostics, candidate warnings and offline controls are inside a scrollable settings sheet. Closing it restores the clean home without restarting player/session. System privacy indicators/dialogs remain visible. Requested current/previous seven-state reply tags stay real; selected neutral asset/fallback stays separate. Details include face presence/cue, AEC and explicit diagnostic report action. No camera model/threshold/TTL or10Hz processing change; face acceptance remains separate.
|
||||
|
||||
Title falls back to 声伴; no private persona data is embedded. No server display-name field is currently consumed. Layout, fonts and OEM/system permission behavior still require physical screen acceptance.
|
||||
|
||||
## Materials and continuity
|
||||
|
||||
Current accepted pose is natural crossed arms, original reference SHA25636a078ad9e1d2929612e9baa2af524bda90dafceddc4515dd448fc08121d7dd2. Standing-v2 face revision is lineage, not the latest arms-down animation pose. Cleanup remains unconfirmed and is not the new graph baseline. Static reference approval/test use is separate from rights/commercial use and every animation edge/loop review.
|
||||
|
||||
The only target motion pack is a01-neutral-graph-v1: idle A-A, opening A-B, talk1 B-B, talk2 B-B, end-talk B-A. All required junctions and three self-loops must be reviewed. Failed prior seated/arms-down/arms wide-mouth/raw loops remain archived; never substitute them to ship a video version. Motion graph allowlist is currently empty.
|
||||
|
||||
PCM actual playback-head activity supplies latest mouth intent only. Reviewed source windows and a paused prepared/latching target gate actual reveals. The real codec/driver implementation is tested with Android API doubles; hardware/device acceptance remains pending. Audio never waits for picture. ≤1s mouth activity/closed-stable response needs actual reviewed frame events and full-route measurement, not merely a switch-start timer.
|
||||
|
||||
## Release boundary
|
||||
|
||||
Current UI-only candidate targets0.6.2-ui-dev/code14, retaining runtime03 mouth rendering unchanged; mouth deformation is unresolved. See [AVATAR_UI_062.md](AVATAR_UI_062.md) for exact reproduction and test boundaries. Code12/code13 and retained0.6.0/code11 APK stay byte-identical. Current checks and staged material blockers are recorded in AVATAR_SAFE_061.md and ignored logs/avatar-safe-061/. Final material hash, signature/badging/HTTP checks, commit/push and coordinator Windows USB installation follow actual graph review. No device sensors/install or backend/provider/model/TTS change is performed by this agent.
|
||||
Reference in New Issue
Block a user