Skip to content

Lenscowboy/lcbe-layout-schema

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LCBE Layout Schema

Canonical JSON Schema for the LCBE_LAYOUT payload by Lenscowboy.

LCBE_LAYOUT carries spatial and temporal scene information (camera, proxies, world) between LCBE-ecosystem ComfyUI nodes — typically from PAL (producer) to LCBE (consumer or backend store) — and lets PAL's spatial intelligence flow into Comfy graphs without backend round-trips.

This repository is the single source of truth for the schema. Both comfyui-lenscowboy-pal and comfyui-lenscowboy-lcbe vendor a pinned copy via sync-schema.sh and a CI check that fails on drift.

Versions

Version Status Spec Schema
v1.0 Locked schemas/v1.0/README.md schemas/v1.0/lcbe_layout.schema.json

Conventions (v1.0, LOCKED)

The wire format does not negotiate coordinate conventions. v1.0 pins:

  • Handedness: Right-handed
  • Up axis: Y
  • World units: Metres
  • Angle units: Radians
  • Camera FOV: Vertical FOV
  • Rotation: Quaternion [x, y, z, w] (Three.js convention)
  • Translation: [x, y, z] arrays in metres
  • Time: Seconds
  • Frame indexing: Zero-indexed

Consumers needing different conventions (Z-up for Blender, degrees for legacy tools) convert at their boundary. The contract is locked for the lifetime of v1.

Layout

schemas/v1.0/
  ├── lcbe_layout.schema.json   # JSON Schema draft-2020-12, authoritative for validation
  └── README.md                 # human-readable spec, authoritative for intent
examples/v1.0/
  ├── minimal.json              # single static camera, no proxies
  ├── full_with_proxies.json    # animated camera + capsule, box, and mesh_ref proxies
  └── multi_camera.json         # wide + close-up cameras

Validation

pip install jsonschema
python3 -c "
import json
from jsonschema import Draft202012Validator
schema = json.load(open('schemas/v1.0/lcbe_layout.schema.json'))
payload = json.load(open('examples/v1.0/minimal.json'))
Draft202012Validator(schema).validate(payload)
print('OK')
"

CI validates every example in examples/v1.0/ against the schema on every push.

Versioning policy

  • Patch (v1.0.x): clarifications, non-normative metadata, no wire-format change.
  • Minor (v1.x): additive optional fields only. Consumers pinned to 1.0 MUST ignore unknown fields gracefully (additionalProperties: true is set on every subobject).
  • Major (v2.0): breaking changes. New socket type (LCBE_LAYOUT_V2), new endpoint path, 12-month deprecation window for v1.

Consumers

Repo Role
comfyui-lenscowboy-pal Producer — emits LCBE_LAYOUT from PAL's Three.js scene state
comfyui-lenscowboy-lcbe Consumer + producer — reads LCBE_LAYOUT from the LCBE backend, also passes through on save

License

MIT — see LICENSE.

About

Canonical JSON Schema for LCBE_LAYOUT — spatial scene data passed between PAL and LCBE ComfyUI nodes.

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors