research consent type and a capability token whose hsi tier is at least research. Without those, lab sessions stay on-device.
What it gives you
- A session scoped to one protocol (e.g. “morning baseline + 5-min stressor”).
- A tree of windows inside the session (e.g. baseline → stressor → recovery), each with a type, label, and free-form values.
- Window-level overrides for state values (used when the experimenter wants to assert a known ground truth for a slice of time).
- Metadata cache for the device + user info that should accompany every session export.
Public API surface (Synheart Core)
Metadata cache
meta_id into every finalized session’s session_metadata.extra_data.metadata_id, so server-side analysis can group sessions by the device/user state at the time they were recorded.
Availability
Lab is gated by a capability flag in the runtime artifact. Hosts should callSynheart.isLabAvailable() before assuming the surface is present:
lab feature, every lab* method returns a “not available” sentinel (false / null) and never throws.
Cloud upload path
WhencloudConfig.lab = true AND research consent is granted, labFinalize enqueues an upload to /ingest/v1/lab/session. The upload is separate from the standard HSI ingest path (/ingest/v1/hsi) so research data is routed and retained under research-tier policies.
See Cloud Protocol for the full ingest surface and Consent System for the research consent flow.
When to use Lab Mode
- You’re running an academic study and need protocol structure alongside the live state stream.
- You’re A/B testing interventions and need windowed ground truth.
- You want to attach experimenter-supplied values (mood scores, intervention IDs, custom labels) to slices of time.