twin-verify

Verify Godot digital-twin viewers with frame-budget, data-binding, join-coverage, and playback gates.

Updated Jul 8, 2026
One-click install
npx skills add https://github.com/arthur0n/xenodot-twin --skill twin-verify-arthur0n
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: twin-verify
Source: https://github.com/arthur0n/xenodot-twin/tree/main/plugin/skills/twin-verify
Command: npx skills add https://github.com/arthur0n/xenodot-twin --skill twin-verify-arthur0n

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? A digital-twin viewer can render beautifully yet silently miss its frame budget, paint no live data, lose its GlobalId join keys, or play back recordings non-deterministically — and a generic engine smoke test will never catch any of it. This Skill layers twin-specific verification gates on top of the base Godot verification floor so a viewer is only called done when it provably works. ## Core Features & Use Cases - Frame-budget gate: Benchmarks the scene against the architect's stated frame budget (via viewer.cfg or TWIN_FRAME_BUDGET_MS) using a windowed bench, with loud SKIP semantics when no display or budget exists. - Data-binding smoke: Drives the real viewer shell headlessly with a seeded sim (seed 42) and asserts stream health, full binding resolution, and visible node-state changes. - GlobalId join coverage: Checks that model elements join to sidecar properties at ~100% coverage, counting both named MeshInstance3D nodes and twin_globalids metadata on optimized MultiMesh batches. - Playback determinism and browser evidence: Runs a two-leg playback-hash comparison for determinism and captures CDP screenshots plus console logs for web builds. - Use Case: After optimizing a plant model scene, run tools/verify_twin.sh to confirm the frame budget holds, bindings still drive colors, the join stayed at 100%, and playback remains deterministic before reporting the optimization win. ## Quick Start Run the composed gate with rtk tools/verify_twin.sh from the project root after any scene, binding, import, or playback change and report each gate's PASS, FAIL, or explicit SKIP verdict.

Frequently Asked Questions about twin-verify

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I verify a Godot digital-twin viewer actually works?

Run tools/verify_twin.sh from the project root after any .tscn or .gd change. It composes the base Godot verification layers with twin-specific gates for frame budget, data binding, join coverage, and playback determinism, printing a PASS, FAIL, or explicit SKIP per gate.

How do I test live data binding in a headless Godot scene?

Start the seeded sim with node tools/sim/server.js --seed 42 --port 8899, then run tools/smoke_binding.gd headlessly with your binding map. It asserts stream health, full binding resolution, and that at least one node target's material color changes between samples.

Why does the frame-budget gate skip instead of passing?

The bench needs a real window to measure frames drawn, so under a headless renderer the gate skips loudly with the exact windowed command to run. Set TWIN_BENCH=1 with a display available, and ensure a budget is stated via TWIN_FRAME_BUDGET_MS or viewer.cfg.

Can MultiMesh instance colors be asserted in headless Godot?

No. Under the headless dummy renderer, get_instance_color and the MultiMesh buffer read black regardless of set_instance_color, so the smoke only asserts the write path is wired and marks it WINDOWED-ONLY. Confirm actual colors in a windowed render.

What does the GlobalId join coverage gate check after a model import?

It compares GlobalIds from named MeshInstance3D nodes and twin_globalids metadata arrays against the property sidecar, requiring roughly 100 percent matched at a default 0.95 threshold. A double-digit miss rate indicates a broken IFC conversion that must be fixed before binding work.

How is playback determinism tested for recorded telemetry?

The gate synthesizes a byte-reproducible fixture with tools/sim/record.js, then runs tools/check_playback.gd twice over the same fixture and seeks. The two PLAYBACK-HASH lines must be identical, proving the player emits frames deterministically.