Data Model
The HDS data model defines all health data items, their types, streams, and relationships.
Structure
Section titled “Structure”- Items — individual data points (body-weight, body-height, bleeding, medication, treatment, procedure, etc.)
- Streams — hierarchical categories (body, fertility, medication, treatment, procedure, profile, …)
- Event types — Pryv event type definitions with JSON schemas
- Datasources — external data sources (medication, treatment, procedure databases)
Item Types
Section titled “Item Types”number— numeric values with optional unit variations (kg/lb, m/ft)select— single choice from optionscheckbox— boolean (activity/plain events)text— free textdate— date valuescomposite— nested object fieldsdatasource-search— search external datasources (medications, treatments, procedures)
Context-via-substream (D3 mechanic)
Section titled “Context-via-substream (D3 mechanic)”Items registered at a parent stream (e.g. treatment-coded at treatment) can be reused under a descendant stream (treatment-fertility) by passing a context to the form section. forEvent() walks parent streams to resolve the original itemDef, keeping a single coded surface across multiple medical subdomains. See data-model/documentation/TREATMENT-PROCEDURE.md.
Published
Section titled “Published”The compiled model is served at model.datasafe.dev.