feat: validate per-body mouth timelines and reviewed conversation routes
This commit is contained in:
@@ -22,18 +22,18 @@ Adjacent spoken assistant rows merge in provider context to preserve role orderi
|
||||
Android implements capture cleanup acknowledgement, action state/port, settings
|
||||
cancel, background cancellation, no-repeat variants, stale callbacks/frames fences,
|
||||
and expression preload callback separate from displayed expression. V2 metadata
|
||||
parser and visual selector bind each own body-mouth SHA/97 PTS and slight-only
|
||||
parser and visual selector bind each own body-mouth SHA/actual per-body PTS and slight-only
|
||||
visual intensity, requiring complete fallback packages and reviewed bridge graph.
|
||||
See [asset contract](AVATAR_PACK_V2_CONTRACT.md).
|
||||
|
||||
Pending: asset owner's mouth amplitude choice, happy/sad TALK packages and their
|
||||
Pending: happy/sad TALK packages and their
|
||||
own mouths/bridges, Pi exact manifest review, idle variants, two real music dances,
|
||||
asset file/decode import gate and actual v2 bridge/media renderer integration.
|
||||
No new asset is admitted in this APK; default action capability remains absent.
|
||||
Existing neutral runtime04 bytes are preserved. No naturalness approval is inferred
|
||||
from hashes, tests or fixtures. Real device/GPU/music tail/≤1s perception: **not_run**.
|
||||
|
||||
Validation: full nine client JVM entry points + expression/UI source contracts;
|
||||
Validation: nine JVM entry points (five client + four expression), UI source contracts;
|
||||
production parser on actual runtime04 97×5 metadata; 40 offline EGL/GLES pixel cases.
|
||||
95 gateway tests pass in remote staging, including existing Silero; local archive
|
||||
also passes with that excluded-model test skipped. Android assemble and device-test
|
||||
@@ -65,7 +65,8 @@ Detailed numeric evidence (ignored, no raw replies/keys/user audio/face reports)
|
||||
`logs/action-emotion/{schema-probe.json,delivery.json,shader-golden/}`, client
|
||||
`logs/avatar-safe-061/`, gateway `logs/voice-investigation/gateway-emotion-staged.json`.
|
||||
Live gateway0.8.0 deployed from `e91354c9e8bd3a671bb8b02b3ff94c252559355d`.
|
||||
Exact deployed hashes are in `gateway/SOURCE_MANIFEST.json`; before restart, source
|
||||
Deployed runtime-module hashes are in `gateway/SOURCE_MANIFEST.json`; followup
|
||||
test-file hashes describe the newer local tests, not a new deployment. Before restart, source
|
||||
and busy fences passed. Private environment and unit loading stayed hash-identical.
|
||||
Only `lan-voice-gateway.service` restarted. Backup:
|
||||
`/home/gorios-spark-2/lan-voice/.runtime/backups/voice-gateway-20261013-004204`.
|
||||
@@ -80,8 +81,59 @@ protocol evidence, not proof of a person hearing playback. Numeric result:
|
||||
schema calls + this one pipeline call; paid/cloud calls by code owner: zero.
|
||||
|
||||
Asset-owner update: P1 free amplitude previews completed in its own
|
||||
`.runtime/avatar-imports/a01-expression-action-v1/p1-amplitude-01/`; Pi original-speed
|
||||
selection remains pending. Nearest-level/opacity1/zero-bypass rendering stays intact.
|
||||
P4a report: four generation calls (two expression edits + two 4s body videos),
|
||||
known video fee $0.68, image fee unknown. Bodies/own-mouth/bridges are not admitted;
|
||||
`.runtime/avatar-imports/a01-expression-action-v1/p1-amplitude-01/`; Pi selected1.1
|
||||
source pixels for candidate production based on fixed comparisons. Dynamic visual
|
||||
review remains pending. Nearest-level/opacity1/zero-bypass rendering stays intact.
|
||||
Latest coordinator ledger snapshot: **6 submitted**, known video fee **$0.96**,
|
||||
image fee unknown (supersedes earlier4/$0.68 and5/$0.86 snapshots, not an all-time total).
|
||||
sad001 idle rejected for visible opening/strong expression; sad0022s inspection
|
||||
continues in `p4a-sad-revision-02`. Happy own mouth uses1.1 sourcepx and actual97
|
||||
source PTS; dynamic12s review pending. First real frame0-to-frame0 entry bridge
|
||||
is in `bridge-review/neutral-happy-enter-001`; its gate determines later bridges.
|
||||
Bodies/own-mouth/bridges are not admitted;
|
||||
this cost is the separate asset ledger, not code-owner paid usage. No P4b/P5 activation.
|
||||
|
||||
Preparation semantics: four fixed probe rows record complete valid ordered header
|
||||
availability before full response, and agreement with strict final parsing on those
|
||||
four outputs. They cannot guarantee all future finals. `reply.emotion.prepare` is
|
||||
**preload-only**, turn/seq scoped; it must not select visible expression or start
|
||||
speech. The final `reply.emotion` event is authoritative. Duplicate/mismatched/
|
||||
truncated/extra-field finals cancel preparation; after_action emotion is excluded
|
||||
from prefix preparation and is displayed only in its later speech turn. Current
|
||||
MainActivity has no approved multi-pack preload implementation wired to this hook;
|
||||
the protocol hook and deterministic planner are tested separately, not claimed as
|
||||
actual new expression pixels on code16. The code16 APK remains unchanged/rollback.
|
||||
|
||||
Post-code16 source milestone starts from clean/pushed
|
||||
`4358fc9cae27bcad01b0098690c4a77fa4767d13`. New schema2 per-body parser, frame
|
||||
presenter/renderer and mouth curves use actual N/PTS/fps/duration. Independent
|
||||
97/121/49 and rational61-frame fixtures retain N×5 levels, exact own-body SHA and
|
||||
frame binding. Runtime RGBA≤8MB, index≤32MB, N≤720; oversize numeric narrowing,
|
||||
duplicate paths, malformed curves and invalid timelines fail admission. Only
|
||||
legacy neutral schema1 keeps97@24; current happy/sad001 also happen to be97.
|
||||
|
||||
New multi-package planner keeps prepare separate from final selection and actual
|
||||
visible package. Sad→neutral→happy executes only reviewed source frames/bridges;
|
||||
serial/turn fences reject stale/repeated presentation, and missing own mouth
|
||||
falls back as a whole package. Index retains bridge clip metadata for its future
|
||||
driver. It remains unwired to MainActivity until asset/bridge admission is complete.
|
||||
|
||||
Followup validation: 2,361 dynamic frame/level/rejection checks, 15 invalid graph/
|
||||
cache cases; all nine JVM entries + UI checks; 40 offline real EGL/GLES goldens;
|
||||
Android debug/application-instrumentation Kotlin compilation passed, no new APK
|
||||
published. Local gateway archive98 tests:97 passed,1 existing Silero model test
|
||||
skipped (no model artifact provided); three added tests cover actual generate/
|
||||
synthesize/drain/action cancel/failure/new-turn abort and prepare-final cancellation.
|
||||
Mock action normal completion still proves1 LLM/2 TTS across two speech turns,
|
||||
after speech history only upon drain, with no model/TTS provider changes.
|
||||
|
||||
Read-only Gate1 on retained neutral runtime04 verified486 files,97 body PTS,
|
||||
485 RGBA patches,1,646,400 cache bytes, full decode and actual production parser.
|
||||
Current unapproved happy draft was rejected with nonzero exit for old schema;
|
||||
owner files/previews were not changed. Evidence:
|
||||
`logs/action-emotion/dynamic-n/{avatar-tests.txt,neutral-gate.json,happy-draft-rejection.json,shader-golden/}`,
|
||||
`logs/avatar-safe-061/`; gateway98-test and compile summaries are in the same
|
||||
dynamic-n evidence directory. No new live probes, paid calls, deployments,
|
||||
service restarts or code16 replacement in this milestone. Whole visual/action
|
||||
release remains pending approved own-mouth/bridges/index and media integration;
|
||||
device/AudioRecord/GPU/perceptual≤1s remain not_run.
|
||||
|
||||
@@ -14,15 +14,18 @@ Self-authored approved/status fields never enable runtime capabilities.
|
||||
|
||||
Each conversation package: unique `id`, `emotion:neutral|happy|sad`,
|
||||
`visualIntensity:0|1`, `mouthBodySha256`, `runtimeManifest:{path,sha256}` referencing runtime04 format
|
||||
(continuous body + own 97 PTS registered frames × five RGBA aperture levels,
|
||||
(continuous body + own actual N PTS registered frames × five RGBA aperture levels,
|
||||
own curves/anchors/coordinates). Body SHA, frame count and decoded PTS bind every
|
||||
mouth track to that exact body; no cross-body patches/masks/coordinates reuse.
|
||||
Happy/sad are slightly only, including model intensity2. Body is silent.
|
||||
No layer means whole-package fallback, never a neutral mouth over another body.
|
||||
Provide 0.9/1.1/1.2 aperture previews; Pi chooses before import.
|
||||
Pi selected **1.1 source pixels for the candidate**, based on fixed comparisons;
|
||||
dynamic naturalness review is still pending. Do not treat a numeric gap as approval.
|
||||
|
||||
Edges: `id`, `from`, `to`, `fromAnchor`, `toAnchor`, `fromFrame`, `toFrame`,
|
||||
`clip:{path,sha256,width,height,frameCount,ptsUs,durationUs,hasAudio:false}`.
|
||||
`clip:{path,sha256,width,height,frameCount,ptsUs,durationUs,fpsNumerator,fpsDenominator,hasAudio:false}`.
|
||||
Edges also bind `fromPtsUs` and `toPtsUs` to the exact source/target body frame;
|
||||
`fromFrame` must be in that source package's `legalExitFrames`.
|
||||
Each package declares `entryAnchor`, `exitAnchor`, `legalExitFrames`, `loopEdge`.
|
||||
Frame indices/PTS are actual decoded values. Every changed body phase requires a
|
||||
reviewed edge, no arbitrary alpha cut. Supply dense seam frames, real-speed loops
|
||||
@@ -58,6 +61,44 @@ camera cues are independent and never select these role packages. Production
|
||||
runtime04 parser: `app/src/main/java/com/gorios/lanvoice/avatar/ContinuousAvatarManifest.kt`;
|
||||
v2 index parser: `app/src/main/java/com/gorios/lanvoice/avatar/EmotionActionManifest.kt`.
|
||||
Each package should use `packId:a01-expression-action-v1-<packageId>-runtime-04`;
|
||||
runtime04 body/patchFormat/patches/mouthStates/stateRouting field shapes stay intact.
|
||||
New per-package runtime manifests use **schemaVersion:2**; only the old neutral
|
||||
runtime03/04 schemaVersion1 retains its fixed97@24 constraints. Each new body's
|
||||
`frameCount:N`, `durationUs`, `fpsNumerator/fpsDenominator`, **`ptsUs:[actual decoded
|
||||
presentation timestamps]`** are mandatory. No truncation/padding to97, no neutral
|
||||
track reuse. Counts121/49 and rational frame rates are supported independently.
|
||||
Current GLES shape remains480×848 (new shapes require renderer extension).
|
||||
N is bounded2..720, fps1..60, duration0.1..30s; body PTS starts0, strictly increases,
|
||||
remains below duration and agrees with measured duration/nominal fps within one
|
||||
nominal frame. Nonuniform actual PTS is accepted within two nominal frame intervals.
|
||||
Machine gate must compare decoded PTS/duration to declarations, not infer PTS.
|
||||
`patchFormat.bodySha256` must equal `body.sha256`; `patches` has exactlyN entries,
|
||||
each `frameIndex:i`, `ptsUs:body.ptsUs[i]`, own coordinates/mask and five independent
|
||||
level paths/hashes. Patch format remains straight RGBA8, [0,.25,.5,.75,1]; nearest
|
||||
level, nonzero opacity1, zero bypass. Each patch≤128×128, totalRGBA≤8MB/runtime;
|
||||
all packages combined≤32MB, ≤12packages. These are admission bounds, not GPU proof.
|
||||
Each of the five mouth states supplies own actual `ptsUs`, `frameCount`, fps ratio,
|
||||
`durationMs` (100..1000), alpha values and A/B anchors; curve timing no longer
|
||||
assumes24fps. Runtime04 mouthStates/stateRouting names and anchor rules stay intact.
|
||||
Entry/return bridges carry actual decoded frame PTS; `audioEndUs` records measured
|
||||
last audio timestamp, completion also waits actual media stop and restored A.
|
||||
|
||||
Current asset snapshot: happy/sad001 sources each actually97 frames; sad002 must
|
||||
be measured independently. 121/49 are compatibility test counts, not a claim about
|
||||
those files. The happy-01 draft hash
|
||||
`518865589fcff36259b864226cdc9651f742d6f56f3b58eeb98f241ef03d48e3`
|
||||
still used schema1/`a01-slight-happy-01`/`body.framePTSUs` at the read-only check;
|
||||
it is rejected, not silently relabeled or modified. Export schema2, packId
|
||||
`a01-expression-action-v1-happy-01-runtime-04`, `body.ptsUs`,
|
||||
`patchFormat.bodySha256`, and each mouth state's `ptsUs`. Use the same format for
|
||||
sad/neutral, independently measured. A frame0 enter bridge is legal only when
|
||||
its source declares frame0 in `legalExitFrames`; do not inherit old last-frame exits.
|
||||
|
||||
Read-only handoff check (new evidence file, does not import/activate):
|
||||
`python3 scripts/check-avatar-runtime.py --manifest <runtime>/manifest.json --sha256 <exact-candidate-sha> --output logs/action-emotion/<new-evidence>.json`.
|
||||
It checks file hashes, complete video decode, actual PTS/duration/fps, PNG RGBA
|
||||
shape/cache and production Kotlin admission. It rejects concurrent file drift.
|
||||
Deliver corrected runtime paths/hashes plus complete index hash, reviewed loop/
|
||||
enter/return clip paths/hashes, timed seam previews and Pi's external exact pin.
|
||||
Conversation planning retains clip metadata and assigns each bridge execution a
|
||||
unique serial; stale completion cannot authorize a later bridge with the same id.
|
||||
Playback driver integration and capability activation remain separate work.
|
||||
|
||||
Reference in New Issue
Block a user