@the-cascade-protocol/sdk 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +190 -0
- package/README.md +164 -0
- package/dist/consent/consent-filter.d.ts +21 -0
- package/dist/consent/consent-filter.d.ts.map +1 -0
- package/dist/consent/consent-filter.js +71 -0
- package/dist/consent/consent-filter.js.map +1 -0
- package/dist/consent/index.d.ts +2 -0
- package/dist/consent/index.d.ts.map +1 -0
- package/dist/consent/index.js +2 -0
- package/dist/consent/index.js.map +1 -0
- package/dist/deserializer/index.d.ts +7 -0
- package/dist/deserializer/index.d.ts.map +1 -0
- package/dist/deserializer/index.js +7 -0
- package/dist/deserializer/index.js.map +1 -0
- package/dist/deserializer/turtle-parser.d.ts +47 -0
- package/dist/deserializer/turtle-parser.d.ts.map +1 -0
- package/dist/deserializer/turtle-parser.js +840 -0
- package/dist/deserializer/turtle-parser.js.map +1 -0
- package/dist/index.d.ts +42 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +34 -0
- package/dist/index.js.map +1 -0
- package/dist/jsonld/context.d.ts +29 -0
- package/dist/jsonld/context.d.ts.map +1 -0
- package/dist/jsonld/context.js +95 -0
- package/dist/jsonld/context.js.map +1 -0
- package/dist/jsonld/converter.d.ts +50 -0
- package/dist/jsonld/converter.d.ts.map +1 -0
- package/dist/jsonld/converter.js +139 -0
- package/dist/jsonld/converter.js.map +1 -0
- package/dist/jsonld/index.d.ts +8 -0
- package/dist/jsonld/index.d.ts.map +1 -0
- package/dist/jsonld/index.js +8 -0
- package/dist/jsonld/index.js.map +1 -0
- package/dist/models/activity-snapshot.d.ts +49 -0
- package/dist/models/activity-snapshot.d.ts.map +1 -0
- package/dist/models/activity-snapshot.js +13 -0
- package/dist/models/activity-snapshot.js.map +1 -0
- package/dist/models/allergy.d.ts +49 -0
- package/dist/models/allergy.d.ts.map +1 -0
- package/dist/models/allergy.js +13 -0
- package/dist/models/allergy.js.map +1 -0
- package/dist/models/common.d.ts +174 -0
- package/dist/models/common.d.ts.map +1 -0
- package/dist/models/common.js +12 -0
- package/dist/models/common.js.map +1 -0
- package/dist/models/condition.d.ts +59 -0
- package/dist/models/condition.d.ts.map +1 -0
- package/dist/models/condition.js +13 -0
- package/dist/models/condition.js.map +1 -0
- package/dist/models/coverage.d.ts +117 -0
- package/dist/models/coverage.d.ts.map +1 -0
- package/dist/models/coverage.js +16 -0
- package/dist/models/coverage.js.map +1 -0
- package/dist/models/family-history.d.ts +38 -0
- package/dist/models/family-history.d.ts.map +1 -0
- package/dist/models/family-history.js +13 -0
- package/dist/models/family-history.js.map +1 -0
- package/dist/models/health-profile.d.ts +54 -0
- package/dist/models/health-profile.d.ts.map +1 -0
- package/dist/models/health-profile.js +11 -0
- package/dist/models/health-profile.js.map +1 -0
- package/dist/models/immunization.d.ts +78 -0
- package/dist/models/immunization.d.ts.map +1 -0
- package/dist/models/immunization.js +12 -0
- package/dist/models/immunization.js.map +1 -0
- package/dist/models/index.d.ts +20 -0
- package/dist/models/index.d.ts.map +1 -0
- package/dist/models/index.js +7 -0
- package/dist/models/index.js.map +1 -0
- package/dist/models/lab-result.d.ts +83 -0
- package/dist/models/lab-result.d.ts.map +1 -0
- package/dist/models/lab-result.js +12 -0
- package/dist/models/lab-result.js.map +1 -0
- package/dist/models/medication.d.ts +144 -0
- package/dist/models/medication.d.ts.map +1 -0
- package/dist/models/medication.js +13 -0
- package/dist/models/medication.js.map +1 -0
- package/dist/models/patient-profile.d.ts +171 -0
- package/dist/models/patient-profile.d.ts.map +1 -0
- package/dist/models/patient-profile.js +14 -0
- package/dist/models/patient-profile.js.map +1 -0
- package/dist/models/procedure.d.ts +53 -0
- package/dist/models/procedure.d.ts.map +1 -0
- package/dist/models/procedure.js +12 -0
- package/dist/models/procedure.js.map +1 -0
- package/dist/models/sleep-snapshot.d.ts +54 -0
- package/dist/models/sleep-snapshot.d.ts.map +1 -0
- package/dist/models/sleep-snapshot.js +13 -0
- package/dist/models/sleep-snapshot.js.map +1 -0
- package/dist/models/vital-sign.d.ts +74 -0
- package/dist/models/vital-sign.d.ts.map +1 -0
- package/dist/models/vital-sign.js +13 -0
- package/dist/models/vital-sign.js.map +1 -0
- package/dist/pod/index.d.ts +2 -0
- package/dist/pod/index.d.ts.map +1 -0
- package/dist/pod/index.js +2 -0
- package/dist/pod/index.js.map +1 -0
- package/dist/pod/pod-builder.d.ts +63 -0
- package/dist/pod/pod-builder.d.ts.map +1 -0
- package/dist/pod/pod-builder.js +245 -0
- package/dist/pod/pod-builder.js.map +1 -0
- package/dist/serializer/index.d.ts +8 -0
- package/dist/serializer/index.d.ts.map +1 -0
- package/dist/serializer/index.js +8 -0
- package/dist/serializer/index.js.map +1 -0
- package/dist/serializer/turtle-builder.d.ts +93 -0
- package/dist/serializer/turtle-builder.d.ts.map +1 -0
- package/dist/serializer/turtle-builder.js +204 -0
- package/dist/serializer/turtle-builder.js.map +1 -0
- package/dist/serializer/turtle-serializer.d.ts +66 -0
- package/dist/serializer/turtle-serializer.d.ts.map +1 -0
- package/dist/serializer/turtle-serializer.js +404 -0
- package/dist/serializer/turtle-serializer.js.map +1 -0
- package/dist/validator/index.d.ts +2 -0
- package/dist/validator/index.d.ts.map +1 -0
- package/dist/validator/index.js +2 -0
- package/dist/validator/index.js.map +1 -0
- package/dist/validator/validator.d.ts +16 -0
- package/dist/validator/validator.d.ts.map +1 -0
- package/dist/validator/validator.js +295 -0
- package/dist/validator/validator.js.map +1 -0
- package/dist/vocabularies/index.d.ts +8 -0
- package/dist/vocabularies/index.d.ts.map +1 -0
- package/dist/vocabularies/index.js +7 -0
- package/dist/vocabularies/index.js.map +1 -0
- package/dist/vocabularies/namespaces.d.ts +125 -0
- package/dist/vocabularies/namespaces.d.ts.map +1 -0
- package/dist/vocabularies/namespaces.js +361 -0
- package/dist/vocabularies/namespaces.js.map +1 -0
- package/package.json +48 -0
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Immunization data model for the Cascade Protocol.
|
|
3
|
+
*
|
|
4
|
+
* Represents a vaccine administration record, typically from EHR imports.
|
|
5
|
+
*
|
|
6
|
+
* RDF type: `health:ImmunizationRecord`
|
|
7
|
+
* Vocabulary: `https://ns.cascadeprotocol.org/health/v1#`
|
|
8
|
+
*
|
|
9
|
+
* @see https://cascadeprotocol.org/docs/cascade-protocol-schemas
|
|
10
|
+
*/
|
|
11
|
+
export {};
|
|
12
|
+
//# sourceMappingURL=immunization.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"immunization.js","sourceRoot":"","sources":["../../src/models/immunization.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Re-exports all Cascade Protocol data model types.
|
|
3
|
+
*
|
|
4
|
+
* @module models
|
|
5
|
+
*/
|
|
6
|
+
export type { ProvenanceType, ProvenanceClass, ConditionStatus, AllergySeverity, AllergyCategory, LabInterpretation, MedicationClinicalIntent, CourseOfTherapyType, PrescriptionCategory, SourceFhirResourceType, VitalType, VitalInterpretation, ImmunizationStatus, PlanType, CoverageType, SubscriberRelationship, BiologicalSex, AgeGroup, BloodType, ProcedureStatus, CascadeRecord, } from './common.js';
|
|
7
|
+
export type { Medication } from './medication.js';
|
|
8
|
+
export type { Condition } from './condition.js';
|
|
9
|
+
export type { Allergy } from './allergy.js';
|
|
10
|
+
export type { LabResult } from './lab-result.js';
|
|
11
|
+
export type { VitalSign } from './vital-sign.js';
|
|
12
|
+
export type { Immunization } from './immunization.js';
|
|
13
|
+
export type { Procedure } from './procedure.js';
|
|
14
|
+
export type { FamilyHistory } from './family-history.js';
|
|
15
|
+
export type { Coverage } from './coverage.js';
|
|
16
|
+
export type { PatientProfile, EmergencyContact, Address, PharmacyInfo, } from './patient-profile.js';
|
|
17
|
+
export type { ActivitySnapshot } from './activity-snapshot.js';
|
|
18
|
+
export type { SleepSnapshot } from './sleep-snapshot.js';
|
|
19
|
+
export type { HealthProfile } from './health-profile.js';
|
|
20
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/models/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,YAAY,EACV,cAAc,EACd,eAAe,EACf,eAAe,EACf,eAAe,EACf,eAAe,EACf,iBAAiB,EACjB,wBAAwB,EACxB,mBAAmB,EACnB,oBAAoB,EACpB,sBAAsB,EACtB,SAAS,EACT,mBAAmB,EACnB,kBAAkB,EAClB,QAAQ,EACR,YAAY,EACZ,sBAAsB,EACtB,aAAa,EACb,QAAQ,EACR,SAAS,EACT,eAAe,EACf,aAAa,GACd,MAAM,aAAa,CAAC;AAGrB,YAAY,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAClD,YAAY,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAChD,YAAY,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AAC5C,YAAY,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AACjD,YAAY,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AACjD,YAAY,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AACtD,YAAY,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAChD,YAAY,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AACzD,YAAY,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AAG9C,YAAY,EACV,cAAc,EACd,gBAAgB,EAChB,OAAO,EACP,YAAY,GACb,MAAM,sBAAsB,CAAC;AAG9B,YAAY,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC/D,YAAY,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAGzD,YAAY,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/models/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG"}
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Lab result data model for the Cascade Protocol.
|
|
3
|
+
*
|
|
4
|
+
* Represents a laboratory test result, typically sourced from EHR imports.
|
|
5
|
+
*
|
|
6
|
+
* RDF type: `health:LabResultRecord`
|
|
7
|
+
* Vocabulary: `https://ns.cascadeprotocol.org/health/v1#`
|
|
8
|
+
*
|
|
9
|
+
* @see https://cascadeprotocol.org/docs/cascade-protocol-schemas
|
|
10
|
+
*/
|
|
11
|
+
import type { CascadeRecord, LabInterpretation } from './common.js';
|
|
12
|
+
/**
|
|
13
|
+
* A lab result record in the Cascade Protocol.
|
|
14
|
+
*
|
|
15
|
+
* Required fields: `testName`, `dataProvenance`, `schemaVersion`.
|
|
16
|
+
* All date fields use ISO 8601 string format.
|
|
17
|
+
*
|
|
18
|
+
* Serializes as `health:LabResultRecord` in Turtle.
|
|
19
|
+
*/
|
|
20
|
+
export interface LabResult extends CascadeRecord {
|
|
21
|
+
type: 'LabResultRecord';
|
|
22
|
+
/**
|
|
23
|
+
* Name of the laboratory test (e.g., `"Hemoglobin A1c"`).
|
|
24
|
+
* Maps to `health:testName` in Turtle serialization.
|
|
25
|
+
*/
|
|
26
|
+
testName: string;
|
|
27
|
+
/**
|
|
28
|
+
* Numeric or string result value (e.g., `"7.2"`, `"112"`).
|
|
29
|
+
* Maps to `health:resultValue` in Turtle serialization.
|
|
30
|
+
*/
|
|
31
|
+
resultValue?: string;
|
|
32
|
+
/**
|
|
33
|
+
* Unit of the result value (e.g., `"%"`, `"mg/dL"`, `"mEq/L"`).
|
|
34
|
+
* Maps to `health:resultUnit` in Turtle serialization.
|
|
35
|
+
*/
|
|
36
|
+
resultUnit?: string;
|
|
37
|
+
/**
|
|
38
|
+
* Reference range for normal values (e.g., `"4.0 - 5.6"`, `"< 100"`).
|
|
39
|
+
* Maps to `health:referenceRange` in Turtle serialization.
|
|
40
|
+
*/
|
|
41
|
+
referenceRange?: string;
|
|
42
|
+
/**
|
|
43
|
+
* Clinical interpretation of the result.
|
|
44
|
+
* Maps to `health:interpretation` in Turtle serialization.
|
|
45
|
+
*/
|
|
46
|
+
interpretation?: LabInterpretation;
|
|
47
|
+
/**
|
|
48
|
+
* Date and time the test was performed (ISO 8601).
|
|
49
|
+
* Maps to `health:performedDate` in Turtle serialization.
|
|
50
|
+
*/
|
|
51
|
+
performedDate?: string;
|
|
52
|
+
/**
|
|
53
|
+
* LOINC code URI for this test.
|
|
54
|
+
* Maps to `health:testCode` in Turtle serialization as a URI reference.
|
|
55
|
+
*/
|
|
56
|
+
testCode?: string;
|
|
57
|
+
/**
|
|
58
|
+
* Laboratory category (e.g., `"Chemistry"`, `"Hematology"`).
|
|
59
|
+
* Maps to `health:labCategory` in Turtle serialization.
|
|
60
|
+
*/
|
|
61
|
+
labCategory?: string;
|
|
62
|
+
/**
|
|
63
|
+
* Type of specimen collected (e.g., `"Whole Blood"`, `"Serum"`).
|
|
64
|
+
* Maps to `health:specimenType` in Turtle serialization.
|
|
65
|
+
*/
|
|
66
|
+
specimenType?: string;
|
|
67
|
+
/**
|
|
68
|
+
* Date and time the result was reported (ISO 8601).
|
|
69
|
+
* Maps to `health:reportedDate` in Turtle serialization.
|
|
70
|
+
*/
|
|
71
|
+
reportedDate?: string;
|
|
72
|
+
/**
|
|
73
|
+
* Name of the clinician who ordered the test.
|
|
74
|
+
* Maps to `health:orderingProvider` in Turtle serialization.
|
|
75
|
+
*/
|
|
76
|
+
orderingProvider?: string;
|
|
77
|
+
/**
|
|
78
|
+
* Name of the laboratory that performed the test.
|
|
79
|
+
* Maps to `health:performingLab` in Turtle serialization.
|
|
80
|
+
*/
|
|
81
|
+
performingLab?: string;
|
|
82
|
+
}
|
|
83
|
+
//# sourceMappingURL=lab-result.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lab-result.d.ts","sourceRoot":"","sources":["../../src/models/lab-result.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,KAAK,EAAE,aAAa,EAAE,iBAAiB,EAAE,MAAM,aAAa,CAAC;AAEpE;;;;;;;GAOG;AACH,MAAM,WAAW,SAAU,SAAQ,aAAa;IAC9C,IAAI,EAAE,iBAAiB,CAAC;IAExB;;;OAGG;IACH,QAAQ,EAAE,MAAM,CAAC;IAEjB;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB;;;OAGG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;IAExB;;;OAGG;IACH,cAAc,CAAC,EAAE,iBAAiB,CAAC;IAEnC;;;OAGG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;IAEvB;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;;OAGG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB;;;OAGG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB;;;OAGG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAE1B;;;OAGG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Lab result data model for the Cascade Protocol.
|
|
3
|
+
*
|
|
4
|
+
* Represents a laboratory test result, typically sourced from EHR imports.
|
|
5
|
+
*
|
|
6
|
+
* RDF type: `health:LabResultRecord`
|
|
7
|
+
* Vocabulary: `https://ns.cascadeprotocol.org/health/v1#`
|
|
8
|
+
*
|
|
9
|
+
* @see https://cascadeprotocol.org/docs/cascade-protocol-schemas
|
|
10
|
+
*/
|
|
11
|
+
export {};
|
|
12
|
+
//# sourceMappingURL=lab-result.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lab-result.js","sourceRoot":"","sources":["../../src/models/lab-result.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG"}
|
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Medication data model for the Cascade Protocol.
|
|
3
|
+
*
|
|
4
|
+
* Represents a medication record with fields sourced from EHR imports,
|
|
5
|
+
* FHIR MedicationRequest/MedicationStatement resources, or self-reported data.
|
|
6
|
+
*
|
|
7
|
+
* RDF type: `health:MedicationRecord`
|
|
8
|
+
* Vocabulary: `https://ns.cascadeprotocol.org/health/v1#`
|
|
9
|
+
*
|
|
10
|
+
* @see https://cascadeprotocol.org/docs/cascade-protocol-schemas
|
|
11
|
+
*/
|
|
12
|
+
import type { CascadeRecord, MedicationClinicalIntent, CourseOfTherapyType, PrescriptionCategory, ProvenanceClass, SourceFhirResourceType } from './common.js';
|
|
13
|
+
/**
|
|
14
|
+
* A medication record in the Cascade Protocol.
|
|
15
|
+
*
|
|
16
|
+
* Required fields: `medicationName`, `isActive`, `dataProvenance`, `schemaVersion`.
|
|
17
|
+
* All date fields use ISO 8601 string format.
|
|
18
|
+
*
|
|
19
|
+
* Serializes as `health:MedicationRecord` in Turtle.
|
|
20
|
+
*/
|
|
21
|
+
export interface Medication extends CascadeRecord {
|
|
22
|
+
type: 'MedicationRecord';
|
|
23
|
+
/**
|
|
24
|
+
* Name of the medication.
|
|
25
|
+
* Maps to `health:medicationName` in Turtle serialization.
|
|
26
|
+
*/
|
|
27
|
+
medicationName: string;
|
|
28
|
+
/**
|
|
29
|
+
* Whether the medication is currently active.
|
|
30
|
+
* Maps to `health:isActive` in Turtle serialization.
|
|
31
|
+
*/
|
|
32
|
+
isActive: boolean;
|
|
33
|
+
/**
|
|
34
|
+
* Prescribed dose (e.g., `"20 mg"`, `"90 mcg/actuation"`).
|
|
35
|
+
* Maps to `health:dose` in Turtle serialization.
|
|
36
|
+
*/
|
|
37
|
+
dose?: string;
|
|
38
|
+
/**
|
|
39
|
+
* Dosing frequency (e.g., `"once daily"`, `"twice daily"`, `"as needed"`).
|
|
40
|
+
* Maps to `health:frequency` in Turtle serialization.
|
|
41
|
+
*/
|
|
42
|
+
frequency?: string;
|
|
43
|
+
/**
|
|
44
|
+
* Route of administration (e.g., `"oral"`, `"inhalation"`).
|
|
45
|
+
* Maps to `health:route` in Turtle serialization.
|
|
46
|
+
*/
|
|
47
|
+
route?: string;
|
|
48
|
+
/**
|
|
49
|
+
* Name of the prescribing clinician.
|
|
50
|
+
* Maps to `health:prescriber` in Turtle serialization.
|
|
51
|
+
*/
|
|
52
|
+
prescriber?: string;
|
|
53
|
+
/**
|
|
54
|
+
* Date when the medication was started (ISO 8601).
|
|
55
|
+
* Maps to `health:startDate` in Turtle serialization.
|
|
56
|
+
*/
|
|
57
|
+
startDate?: string;
|
|
58
|
+
/**
|
|
59
|
+
* Date when the medication was discontinued (ISO 8601).
|
|
60
|
+
* Maps to `health:endDate` in Turtle serialization.
|
|
61
|
+
*/
|
|
62
|
+
endDate?: string;
|
|
63
|
+
/**
|
|
64
|
+
* RxNorm concept URI for this medication.
|
|
65
|
+
* Maps to `health:rxNormCode` in Turtle serialization as a URI reference.
|
|
66
|
+
*/
|
|
67
|
+
rxNormCode?: string;
|
|
68
|
+
/**
|
|
69
|
+
* Array of drug code URIs from multiple coding systems (RxNorm, SNOMED CT, etc.).
|
|
70
|
+
* Maps to `clinical:drugCode` in Turtle serialization (repeated predicate).
|
|
71
|
+
*/
|
|
72
|
+
drugCodes?: string[];
|
|
73
|
+
/**
|
|
74
|
+
* Provenance class indicating the import mechanism.
|
|
75
|
+
* Maps to `clinical:provenanceClass` in Turtle serialization.
|
|
76
|
+
*/
|
|
77
|
+
provenanceClass?: ProvenanceClass | string;
|
|
78
|
+
/**
|
|
79
|
+
* The FHIR resource type from which this record was sourced.
|
|
80
|
+
* Maps to `clinical:sourceFhirResourceType` in Turtle serialization.
|
|
81
|
+
*/
|
|
82
|
+
sourceFhirResourceType?: SourceFhirResourceType | string;
|
|
83
|
+
/**
|
|
84
|
+
* Clinical intent for this medication.
|
|
85
|
+
* Maps to `clinical:clinicalIntent` in Turtle serialization.
|
|
86
|
+
*/
|
|
87
|
+
clinicalIntent?: MedicationClinicalIntent | string;
|
|
88
|
+
/**
|
|
89
|
+
* Clinical indication for prescribing this medication.
|
|
90
|
+
* Maps to `clinical:indication` in Turtle serialization.
|
|
91
|
+
*/
|
|
92
|
+
indication?: string;
|
|
93
|
+
/**
|
|
94
|
+
* Course of therapy type.
|
|
95
|
+
* Maps to `clinical:courseOfTherapyType` in Turtle serialization.
|
|
96
|
+
*/
|
|
97
|
+
courseOfTherapyType?: CourseOfTherapyType | string;
|
|
98
|
+
/**
|
|
99
|
+
* Whether this medication is taken on an as-needed (PRN) basis.
|
|
100
|
+
* Maps to `clinical:asNeeded` in Turtle serialization.
|
|
101
|
+
*/
|
|
102
|
+
asNeeded?: boolean;
|
|
103
|
+
/**
|
|
104
|
+
* Physical form of the medication (e.g., `"tablet"`, `"inhaler"`).
|
|
105
|
+
* Maps to `clinical:medicationForm` in Turtle serialization.
|
|
106
|
+
*/
|
|
107
|
+
medicationForm?: string;
|
|
108
|
+
/**
|
|
109
|
+
* Active pharmaceutical ingredient.
|
|
110
|
+
* Maps to `clinical:activeIngredient` in Turtle serialization.
|
|
111
|
+
*/
|
|
112
|
+
activeIngredient?: string;
|
|
113
|
+
/**
|
|
114
|
+
* Strength of the active ingredient (e.g., `"1000 mg"`).
|
|
115
|
+
* Maps to `clinical:ingredientStrength` in Turtle serialization.
|
|
116
|
+
*/
|
|
117
|
+
ingredientStrength?: string;
|
|
118
|
+
/**
|
|
119
|
+
* Number of refills allowed on the prescription.
|
|
120
|
+
* Maps to `clinical:refillsAllowed` in Turtle serialization.
|
|
121
|
+
*/
|
|
122
|
+
refillsAllowed?: number;
|
|
123
|
+
/**
|
|
124
|
+
* Number of days of medication supply per fill.
|
|
125
|
+
* Maps to `clinical:supplyDurationDays` in Turtle serialization.
|
|
126
|
+
*/
|
|
127
|
+
supplyDurationDays?: number;
|
|
128
|
+
/**
|
|
129
|
+
* Prescription category (e.g., `"community"`, `"inpatient"`).
|
|
130
|
+
* Maps to `clinical:prescriptionCategory` in Turtle serialization.
|
|
131
|
+
*/
|
|
132
|
+
prescriptionCategory?: PrescriptionCategory | string;
|
|
133
|
+
/**
|
|
134
|
+
* Therapeutic class of the medication (e.g., `"bronchodilator"`, `"antihypertensive"`).
|
|
135
|
+
* Maps to `health:medicationClass` in Turtle serialization.
|
|
136
|
+
*/
|
|
137
|
+
medicationClass?: string;
|
|
138
|
+
/**
|
|
139
|
+
* List of vital sign types that this medication may affect.
|
|
140
|
+
* Maps to `health:affectsVitalSigns` as an RDF list in Turtle serialization.
|
|
141
|
+
*/
|
|
142
|
+
affectsVitalSigns?: string[];
|
|
143
|
+
}
|
|
144
|
+
//# sourceMappingURL=medication.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"medication.d.ts","sourceRoot":"","sources":["../../src/models/medication.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,KAAK,EACV,aAAa,EACb,wBAAwB,EACxB,mBAAmB,EACnB,oBAAoB,EACpB,eAAe,EACf,sBAAsB,EACvB,MAAM,aAAa,CAAC;AAErB;;;;;;;GAOG;AACH,MAAM,WAAW,UAAW,SAAQ,aAAa;IAC/C,IAAI,EAAE,kBAAkB,CAAC;IAEzB;;;OAGG;IACH,cAAc,EAAE,MAAM,CAAC;IAEvB;;;OAGG;IACH,QAAQ,EAAE,OAAO,CAAC;IAElB;;;OAGG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;OAGG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IAEf;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;OAGG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,EAAE,CAAC;IAErB;;;OAGG;IACH,eAAe,CAAC,EAAE,eAAe,GAAG,MAAM,CAAC;IAE3C;;;OAGG;IACH,sBAAsB,CAAC,EAAE,sBAAsB,GAAG,MAAM,CAAC;IAEzD;;;OAGG;IACH,cAAc,CAAC,EAAE,wBAAwB,GAAG,MAAM,CAAC;IAEnD;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB;;;OAGG;IACH,mBAAmB,CAAC,EAAE,mBAAmB,GAAG,MAAM,CAAC;IAEnD;;;OAGG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IAEnB;;;OAGG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;IAExB;;;OAGG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAE1B;;;OAGG;IACH,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAE5B;;;OAGG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;IAExB;;;OAGG;IACH,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAE5B;;;OAGG;IACH,oBAAoB,CAAC,EAAE,oBAAoB,GAAG,MAAM,CAAC;IAErD;;;OAGG;IACH,eAAe,CAAC,EAAE,MAAM,CAAC;IAEzB;;;OAGG;IACH,iBAAiB,CAAC,EAAE,MAAM,EAAE,CAAC;CAC9B"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Medication data model for the Cascade Protocol.
|
|
3
|
+
*
|
|
4
|
+
* Represents a medication record with fields sourced from EHR imports,
|
|
5
|
+
* FHIR MedicationRequest/MedicationStatement resources, or self-reported data.
|
|
6
|
+
*
|
|
7
|
+
* RDF type: `health:MedicationRecord`
|
|
8
|
+
* Vocabulary: `https://ns.cascadeprotocol.org/health/v1#`
|
|
9
|
+
*
|
|
10
|
+
* @see https://cascadeprotocol.org/docs/cascade-protocol-schemas
|
|
11
|
+
*/
|
|
12
|
+
export {};
|
|
13
|
+
//# sourceMappingURL=medication.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"medication.js","sourceRoot":"","sources":["../../src/models/medication.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG"}
|
|
@@ -0,0 +1,171 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Patient profile data model for the Cascade Protocol.
|
|
3
|
+
*
|
|
4
|
+
* Represents the core demographic and identification data for a patient,
|
|
5
|
+
* including optional nested structures for emergency contact, address,
|
|
6
|
+
* and preferred pharmacy.
|
|
7
|
+
*
|
|
8
|
+
* RDF type: `cascade:PatientProfile`
|
|
9
|
+
* Vocabulary: `https://ns.cascadeprotocol.org/core/v1#`
|
|
10
|
+
*
|
|
11
|
+
* @see https://cascadeprotocol.org/docs/cascade-protocol-schemas
|
|
12
|
+
*/
|
|
13
|
+
import type { CascadeRecord, BiologicalSex, AgeGroup, BloodType } from './common.js';
|
|
14
|
+
/**
|
|
15
|
+
* Emergency contact information for a patient.
|
|
16
|
+
*
|
|
17
|
+
* Serializes as a blank node of type `cascade:EmergencyContact` in Turtle.
|
|
18
|
+
*/
|
|
19
|
+
export interface EmergencyContact {
|
|
20
|
+
/**
|
|
21
|
+
* Name of the emergency contact.
|
|
22
|
+
* Maps to `cascade:contactName` in Turtle serialization.
|
|
23
|
+
*/
|
|
24
|
+
contactName: string;
|
|
25
|
+
/**
|
|
26
|
+
* Relationship of the contact to the patient (e.g., `"spouse"`, `"parent"`).
|
|
27
|
+
* Maps to `cascade:contactRelationship` in Turtle serialization.
|
|
28
|
+
*/
|
|
29
|
+
contactRelationship?: string;
|
|
30
|
+
/**
|
|
31
|
+
* Phone number of the emergency contact.
|
|
32
|
+
* Maps to `cascade:contactPhone` in Turtle serialization.
|
|
33
|
+
*/
|
|
34
|
+
contactPhone?: string;
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* Postal address for a patient.
|
|
38
|
+
*
|
|
39
|
+
* Serializes as a blank node of type `cascade:Address` in Turtle.
|
|
40
|
+
*/
|
|
41
|
+
export interface Address {
|
|
42
|
+
/**
|
|
43
|
+
* Street address line.
|
|
44
|
+
* Maps to `cascade:addressLine` in Turtle serialization.
|
|
45
|
+
*/
|
|
46
|
+
addressLine?: string;
|
|
47
|
+
/**
|
|
48
|
+
* City name.
|
|
49
|
+
* Maps to `cascade:addressCity` in Turtle serialization.
|
|
50
|
+
*/
|
|
51
|
+
addressCity?: string;
|
|
52
|
+
/**
|
|
53
|
+
* State or province code.
|
|
54
|
+
* Maps to `cascade:addressState` in Turtle serialization.
|
|
55
|
+
*/
|
|
56
|
+
addressState?: string;
|
|
57
|
+
/**
|
|
58
|
+
* Postal / ZIP code.
|
|
59
|
+
* Maps to `cascade:addressPostalCode` in Turtle serialization.
|
|
60
|
+
*/
|
|
61
|
+
addressPostalCode?: string;
|
|
62
|
+
/**
|
|
63
|
+
* Country code (e.g., `"US"`).
|
|
64
|
+
* Maps to `cascade:addressCountry` in Turtle serialization.
|
|
65
|
+
*/
|
|
66
|
+
addressCountry?: string;
|
|
67
|
+
/**
|
|
68
|
+
* Address use type (e.g., `"home"`, `"work"`).
|
|
69
|
+
* Maps to `cascade:addressUse` in Turtle serialization.
|
|
70
|
+
*/
|
|
71
|
+
addressUse?: string;
|
|
72
|
+
}
|
|
73
|
+
/**
|
|
74
|
+
* Preferred pharmacy information for a patient.
|
|
75
|
+
*
|
|
76
|
+
* Serializes as a blank node of type `cascade:PharmacyInfo` in Turtle.
|
|
77
|
+
*/
|
|
78
|
+
export interface PharmacyInfo {
|
|
79
|
+
/**
|
|
80
|
+
* Name of the pharmacy.
|
|
81
|
+
* Maps to `cascade:pharmacyName` in Turtle serialization.
|
|
82
|
+
*/
|
|
83
|
+
pharmacyName: string;
|
|
84
|
+
/**
|
|
85
|
+
* Full address of the pharmacy.
|
|
86
|
+
* Maps to `cascade:pharmacyAddress` in Turtle serialization.
|
|
87
|
+
*/
|
|
88
|
+
pharmacyAddress?: string;
|
|
89
|
+
/**
|
|
90
|
+
* Phone number of the pharmacy.
|
|
91
|
+
* Maps to `cascade:pharmacyPhone` in Turtle serialization.
|
|
92
|
+
*/
|
|
93
|
+
pharmacyPhone?: string;
|
|
94
|
+
}
|
|
95
|
+
/**
|
|
96
|
+
* A patient profile record in the Cascade Protocol.
|
|
97
|
+
*
|
|
98
|
+
* Required fields: `dateOfBirth`, `biologicalSex`, `dataProvenance`, `schemaVersion`.
|
|
99
|
+
* Date of birth uses ISO 8601 date format (YYYY-MM-DD).
|
|
100
|
+
*
|
|
101
|
+
* Serializes as `cascade:PatientProfile` in Turtle.
|
|
102
|
+
*/
|
|
103
|
+
export interface PatientProfile extends CascadeRecord {
|
|
104
|
+
type: 'PatientProfile';
|
|
105
|
+
/**
|
|
106
|
+
* Date of birth (ISO 8601 date: `YYYY-MM-DD`).
|
|
107
|
+
* Maps to `cascade:dateOfBirth` in Turtle serialization.
|
|
108
|
+
*/
|
|
109
|
+
dateOfBirth: string;
|
|
110
|
+
/**
|
|
111
|
+
* Biological sex for clinical calculations.
|
|
112
|
+
* Maps to `cascade:biologicalSex` in Turtle serialization.
|
|
113
|
+
*/
|
|
114
|
+
biologicalSex: BiologicalSex;
|
|
115
|
+
/**
|
|
116
|
+
* Computed age in years based on date of birth.
|
|
117
|
+
* Maps to `cascade:computedAge` in Turtle serialization.
|
|
118
|
+
*/
|
|
119
|
+
computedAge?: number;
|
|
120
|
+
/**
|
|
121
|
+
* Age group classification.
|
|
122
|
+
* Maps to `cascade:ageGroup` in Turtle serialization.
|
|
123
|
+
*/
|
|
124
|
+
ageGroup?: AgeGroup;
|
|
125
|
+
/**
|
|
126
|
+
* Full display name of the patient.
|
|
127
|
+
* Maps to `foaf:name` in Turtle serialization.
|
|
128
|
+
*/
|
|
129
|
+
name?: string;
|
|
130
|
+
/**
|
|
131
|
+
* Given (first) name of the patient.
|
|
132
|
+
* Maps to `foaf:givenName` in Turtle serialization.
|
|
133
|
+
*/
|
|
134
|
+
givenName?: string;
|
|
135
|
+
/**
|
|
136
|
+
* Family (last) name of the patient.
|
|
137
|
+
* Maps to `foaf:familyName` in Turtle serialization.
|
|
138
|
+
*/
|
|
139
|
+
familyName?: string;
|
|
140
|
+
/**
|
|
141
|
+
* Blood type classification.
|
|
142
|
+
* Maps to `health:bloodType` in Turtle serialization.
|
|
143
|
+
*/
|
|
144
|
+
bloodType?: BloodType;
|
|
145
|
+
/**
|
|
146
|
+
* Gender identity as self-reported by the patient.
|
|
147
|
+
* Maps to `cascade:genderIdentity` in Turtle serialization.
|
|
148
|
+
*/
|
|
149
|
+
genderIdentity?: string;
|
|
150
|
+
/**
|
|
151
|
+
* Unique profile identifier (typically a UUID).
|
|
152
|
+
* Maps to `cascade:profileId` in Turtle serialization.
|
|
153
|
+
*/
|
|
154
|
+
profileId?: string;
|
|
155
|
+
/**
|
|
156
|
+
* Emergency contact information.
|
|
157
|
+
* Maps to `cascade:emergencyContact` as a blank node in Turtle serialization.
|
|
158
|
+
*/
|
|
159
|
+
emergencyContact?: EmergencyContact;
|
|
160
|
+
/**
|
|
161
|
+
* Patient address.
|
|
162
|
+
* Maps to `cascade:address` as a blank node in Turtle serialization.
|
|
163
|
+
*/
|
|
164
|
+
address?: Address;
|
|
165
|
+
/**
|
|
166
|
+
* Preferred pharmacy information.
|
|
167
|
+
* Maps to `cascade:preferredPharmacy` as a blank node in Turtle serialization.
|
|
168
|
+
*/
|
|
169
|
+
preferredPharmacy?: PharmacyInfo;
|
|
170
|
+
}
|
|
171
|
+
//# sourceMappingURL=patient-profile.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"patient-profile.d.ts","sourceRoot":"","sources":["../../src/models/patient-profile.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,KAAK,EAAE,aAAa,EAAE,aAAa,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAErF;;;;GAIG;AACH,MAAM,WAAW,gBAAgB;IAC/B;;;OAGG;IACH,WAAW,EAAE,MAAM,CAAC;IAEpB;;;OAGG;IACH,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAE7B;;;OAGG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED;;;;GAIG;AACH,MAAM,WAAW,OAAO;IACtB;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;;OAGG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB;;;OAGG;IACH,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAE3B;;;OAGG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;IAExB;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED;;;;GAIG;AACH,MAAM,WAAW,YAAY;IAC3B;;;OAGG;IACH,YAAY,EAAE,MAAM,CAAC;IAErB;;;OAGG;IACH,eAAe,CAAC,EAAE,MAAM,CAAC;IAEzB;;;OAGG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAED;;;;;;;GAOG;AACH,MAAM,WAAW,cAAe,SAAQ,aAAa;IACnD,IAAI,EAAE,gBAAgB,CAAC;IAEvB;;;OAGG;IACH,WAAW,EAAE,MAAM,CAAC;IAEpB;;;OAGG;IACH,aAAa,EAAE,aAAa,CAAC;IAE7B;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;;OAGG;IACH,QAAQ,CAAC,EAAE,QAAQ,CAAC;IAEpB;;;OAGG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB;;;OAGG;IACH,SAAS,CAAC,EAAE,SAAS,CAAC;IAEtB;;;OAGG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;IAExB;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;OAGG;IACH,gBAAgB,CAAC,EAAE,gBAAgB,CAAC;IAEpC;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAElB;;;OAGG;IACH,iBAAiB,CAAC,EAAE,YAAY,CAAC;CAClC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Patient profile data model for the Cascade Protocol.
|
|
3
|
+
*
|
|
4
|
+
* Represents the core demographic and identification data for a patient,
|
|
5
|
+
* including optional nested structures for emergency contact, address,
|
|
6
|
+
* and preferred pharmacy.
|
|
7
|
+
*
|
|
8
|
+
* RDF type: `cascade:PatientProfile`
|
|
9
|
+
* Vocabulary: `https://ns.cascadeprotocol.org/core/v1#`
|
|
10
|
+
*
|
|
11
|
+
* @see https://cascadeprotocol.org/docs/cascade-protocol-schemas
|
|
12
|
+
*/
|
|
13
|
+
export {};
|
|
14
|
+
//# sourceMappingURL=patient-profile.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"patient-profile.js","sourceRoot":"","sources":["../../src/models/patient-profile.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG"}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Procedure data model for the Cascade Protocol.
|
|
3
|
+
*
|
|
4
|
+
* Represents a clinical procedure record.
|
|
5
|
+
*
|
|
6
|
+
* RDF type: `health:ProcedureRecord`
|
|
7
|
+
* Vocabulary: `https://ns.cascadeprotocol.org/health/v1#`
|
|
8
|
+
*
|
|
9
|
+
* @see https://cascadeprotocol.org/docs/cascade-protocol-schemas
|
|
10
|
+
*/
|
|
11
|
+
import type { CascadeRecord, ProcedureStatus } from './common.js';
|
|
12
|
+
/**
|
|
13
|
+
* A procedure record in the Cascade Protocol.
|
|
14
|
+
*
|
|
15
|
+
* Required fields: `procedureName`, `dataProvenance`, `schemaVersion`.
|
|
16
|
+
* All date fields use ISO 8601 string format.
|
|
17
|
+
*
|
|
18
|
+
* Serializes as `health:ProcedureRecord` in Turtle.
|
|
19
|
+
*/
|
|
20
|
+
export interface Procedure extends CascadeRecord {
|
|
21
|
+
type: 'ProcedureRecord';
|
|
22
|
+
/**
|
|
23
|
+
* Name of the procedure.
|
|
24
|
+
* Maps to `health:procedureName` in Turtle serialization.
|
|
25
|
+
*/
|
|
26
|
+
procedureName: string;
|
|
27
|
+
/**
|
|
28
|
+
* Date and time the procedure was performed (ISO 8601).
|
|
29
|
+
* Maps to `health:performedDate` in Turtle serialization.
|
|
30
|
+
*/
|
|
31
|
+
performedDate?: string;
|
|
32
|
+
/**
|
|
33
|
+
* Current status of the procedure.
|
|
34
|
+
* Maps to `health:status` in Turtle serialization.
|
|
35
|
+
*/
|
|
36
|
+
status?: ProcedureStatus;
|
|
37
|
+
/**
|
|
38
|
+
* SNOMED CT code URI for this procedure.
|
|
39
|
+
* Maps to `health:snomedCode` in Turtle serialization as a URI reference.
|
|
40
|
+
*/
|
|
41
|
+
snomedCode?: string;
|
|
42
|
+
/**
|
|
43
|
+
* Name of the clinician who performed the procedure.
|
|
44
|
+
* Maps to `health:performer` in Turtle serialization.
|
|
45
|
+
*/
|
|
46
|
+
performer?: string;
|
|
47
|
+
/**
|
|
48
|
+
* Location where the procedure was performed.
|
|
49
|
+
* Maps to `health:location` in Turtle serialization.
|
|
50
|
+
*/
|
|
51
|
+
location?: string;
|
|
52
|
+
}
|
|
53
|
+
//# sourceMappingURL=procedure.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"procedure.d.ts","sourceRoot":"","sources":["../../src/models/procedure.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,KAAK,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AAElE;;;;;;;GAOG;AACH,MAAM,WAAW,SAAU,SAAQ,aAAa;IAC9C,IAAI,EAAE,iBAAiB,CAAC;IAExB;;;OAGG;IACH,aAAa,EAAE,MAAM,CAAC;IAEtB;;;OAGG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;IAEvB;;;OAGG;IACH,MAAM,CAAC,EAAE,eAAe,CAAC;IAEzB;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Procedure data model for the Cascade Protocol.
|
|
3
|
+
*
|
|
4
|
+
* Represents a clinical procedure record.
|
|
5
|
+
*
|
|
6
|
+
* RDF type: `health:ProcedureRecord`
|
|
7
|
+
* Vocabulary: `https://ns.cascadeprotocol.org/health/v1#`
|
|
8
|
+
*
|
|
9
|
+
* @see https://cascadeprotocol.org/docs/cascade-protocol-schemas
|
|
10
|
+
*/
|
|
11
|
+
export {};
|
|
12
|
+
//# sourceMappingURL=procedure.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"procedure.js","sourceRoot":"","sources":["../../src/models/procedure.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG"}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Sleep snapshot data model for the Cascade Protocol.
|
|
3
|
+
*
|
|
4
|
+
* Represents a nightly sleep summary typically sourced from wearable
|
|
5
|
+
* devices or HealthKit data.
|
|
6
|
+
*
|
|
7
|
+
* RDF type: `health:SleepSnapshot`
|
|
8
|
+
* Vocabulary: `https://ns.cascadeprotocol.org/health/v1#`
|
|
9
|
+
*
|
|
10
|
+
* @see https://cascadeprotocol.org/docs/cascade-protocol-schemas
|
|
11
|
+
*/
|
|
12
|
+
import type { CascadeRecord } from './common.js';
|
|
13
|
+
/**
|
|
14
|
+
* A nightly sleep snapshot in the Cascade Protocol.
|
|
15
|
+
*
|
|
16
|
+
* Required fields: `date`, `dataProvenance`, `schemaVersion`.
|
|
17
|
+
* The `date` field uses ISO 8601 date format (YYYY-MM-DD).
|
|
18
|
+
*
|
|
19
|
+
* Serializes as `health:SleepSnapshot` in Turtle.
|
|
20
|
+
*/
|
|
21
|
+
export interface SleepSnapshot extends CascadeRecord {
|
|
22
|
+
type: 'SleepSnapshot';
|
|
23
|
+
/**
|
|
24
|
+
* Date of the sleep session (ISO 8601 date: `YYYY-MM-DD`).
|
|
25
|
+
* Maps to `health:date` in Turtle serialization.
|
|
26
|
+
*/
|
|
27
|
+
date: string;
|
|
28
|
+
/**
|
|
29
|
+
* Total sleep duration in minutes.
|
|
30
|
+
* Maps to `health:totalSleepMinutes` in Turtle serialization.
|
|
31
|
+
*/
|
|
32
|
+
totalSleepMinutes?: number;
|
|
33
|
+
/**
|
|
34
|
+
* Deep sleep duration in minutes.
|
|
35
|
+
* Maps to `health:deepSleepMinutes` in Turtle serialization.
|
|
36
|
+
*/
|
|
37
|
+
deepSleepMinutes?: number;
|
|
38
|
+
/**
|
|
39
|
+
* REM sleep duration in minutes.
|
|
40
|
+
* Maps to `health:remSleepMinutes` in Turtle serialization.
|
|
41
|
+
*/
|
|
42
|
+
remSleepMinutes?: number;
|
|
43
|
+
/**
|
|
44
|
+
* Light sleep duration in minutes.
|
|
45
|
+
* Maps to `health:lightSleepMinutes` in Turtle serialization.
|
|
46
|
+
*/
|
|
47
|
+
lightSleepMinutes?: number;
|
|
48
|
+
/**
|
|
49
|
+
* Number of awakenings during the sleep session.
|
|
50
|
+
* Maps to `health:awakenings` in Turtle serialization.
|
|
51
|
+
*/
|
|
52
|
+
awakenings?: number;
|
|
53
|
+
}
|
|
54
|
+
//# sourceMappingURL=sleep-snapshot.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sleep-snapshot.d.ts","sourceRoot":"","sources":["../../src/models/sleep-snapshot.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAEjD;;;;;;;GAOG;AACH,MAAM,WAAW,aAAc,SAAQ,aAAa;IAClD,IAAI,EAAE,eAAe,CAAC;IAEtB;;;OAGG;IACH,IAAI,EAAE,MAAM,CAAC;IAEb;;;OAGG;IACH,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAE3B;;;OAGG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAE1B;;;OAGG;IACH,eAAe,CAAC,EAAE,MAAM,CAAC;IAEzB;;;OAGG;IACH,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAE3B;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Sleep snapshot data model for the Cascade Protocol.
|
|
3
|
+
*
|
|
4
|
+
* Represents a nightly sleep summary typically sourced from wearable
|
|
5
|
+
* devices or HealthKit data.
|
|
6
|
+
*
|
|
7
|
+
* RDF type: `health:SleepSnapshot`
|
|
8
|
+
* Vocabulary: `https://ns.cascadeprotocol.org/health/v1#`
|
|
9
|
+
*
|
|
10
|
+
* @see https://cascadeprotocol.org/docs/cascade-protocol-schemas
|
|
11
|
+
*/
|
|
12
|
+
export {};
|
|
13
|
+
//# sourceMappingURL=sleep-snapshot.js.map
|