@htilabs/platform-common-models 0.5.2-beta.3 → 0.6.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.
Files changed (71) hide show
  1. package/dist/{cvcEntry-wqktWfzE.d.cts → cvcEntry-BCj1OWqL.d.cts} +8 -8
  2. package/dist/{cvcEntry-wqktWfzE.d.ts → cvcEntry-BCj1OWqL.d.ts} +8 -8
  3. package/dist/cvcs/index.cjs +8673 -2
  4. package/dist/cvcs/index.cjs.map +1 -1
  5. package/dist/cvcs/index.d.cts +9511 -56
  6. package/dist/cvcs/index.d.ts +9511 -56
  7. package/dist/cvcs/index.js +8634 -1
  8. package/dist/cvcs/index.js.map +1 -1
  9. package/dist/{index--NCIPluF.d.cts → index-CoVr1jIV.d.cts} +1 -1
  10. package/dist/{index-CFOrHA8l.d.ts → index-I-DiX9eQ.d.ts} +1 -1
  11. package/dist/index.cjs +9637 -0
  12. package/dist/index.cjs.map +1 -1
  13. package/dist/index.d.cts +1118 -4
  14. package/dist/index.d.ts +1118 -4
  15. package/dist/index.js +9561 -0
  16. package/dist/index.js.map +1 -1
  17. package/dist/models/index.d.cts +2 -2
  18. package/dist/models/index.d.ts +2 -2
  19. package/dist/schemas/index.d.cts +1 -1
  20. package/dist/schemas/index.d.ts +1 -1
  21. package/dist/validation/index.cjs +6 -0
  22. package/dist/validation/index.cjs.map +1 -1
  23. package/dist/validation/index.d.cts +47 -1
  24. package/dist/validation/index.d.ts +47 -1
  25. package/dist/validation/index.js +5 -0
  26. package/dist/validation/index.js.map +1 -1
  27. package/package.json +1 -1
  28. package/src/__tests__/__snapshots__/cvc-sot.snap +152 -0
  29. package/src/__tests__/cvc-sot-snapshot.test.ts +303 -0
  30. package/src/__tests__/cvc-structural.test.ts +51 -0
  31. package/src/cvcs/administeringJurisdiction.v1.0.0.json +105 -0
  32. package/src/cvcs/ageBinReporting.v1.0.0.json +114 -0
  33. package/src/cvcs/contactInfoTypes.v1.0.0.json +250 -0
  34. package/src/cvcs/contactSafetyStatus.v1.0.0.json +69 -0
  35. package/src/cvcs/employmentStatus.v1.0.0.json +302 -0
  36. package/src/cvcs/enrollmentApplicationStatus.v1.0.0.json +123 -0
  37. package/src/cvcs/eyeColor.v1.0.0.json +114 -0
  38. package/src/cvcs/facilitatorEntityType.v1.0.0.json +141 -0
  39. package/src/cvcs/facilitatorLabelUsedInSource.v1.0.0.json +159 -0
  40. package/src/cvcs/facilitatorSubrole.v1.0.0.json +381 -0
  41. package/src/cvcs/frequencyCadence.v1.0.0.json +114 -0
  42. package/src/cvcs/genderIdentity.v1.0.0.json +128 -0
  43. package/src/cvcs/hairColor.v1.0.0.json +105 -0
  44. package/src/cvcs/hasTattoos.v1.0.0.json +69 -0
  45. package/src/cvcs/highestEducationLevelCompleted.v1.0.0.json +124 -0
  46. package/src/cvcs/homelessStatus.v1.0.0.json +98 -0
  47. package/src/cvcs/incomeBenefitsSources.v1.0.0.json +392 -0
  48. package/src/cvcs/index.ts +76 -0
  49. package/src/cvcs/juvenileJusticeInvolvementStatus.v1.0.0.json +78 -0
  50. package/src/cvcs/locationType.v1.0.0.json +168 -0
  51. package/src/cvcs/maritalStatusLegal.v1.0.0.json +96 -0
  52. package/src/cvcs/militaryBranch.v1.0.0.json +85 -0
  53. package/src/cvcs/militaryStatus.v1.0.0.json +67 -0
  54. package/src/cvcs/nameType.v1.0.0.json +123 -0
  55. package/src/cvcs/offenderStatus.v1.0.0.json +96 -0
  56. package/src/cvcs/offenderStatusFamily.v1.0.0.json +87 -0
  57. package/src/cvcs/orientationIdentity.v1.0.0.json +97 -0
  58. package/src/cvcs/personRelationships.v1.0.0.json +924 -0
  59. package/src/cvcs/preferredContactMethod.v1.0.0.json +46 -0
  60. package/src/cvcs/primaryLanguage.v1.0.0.json +2116 -0
  61. package/src/cvcs/pronouns.v1.0.0.json +87 -0
  62. package/src/cvcs/referralEntityCategory.v1.0.0.json +439 -0
  63. package/src/cvcs/relationshipStatusCurrent.v1.0.0.json +69 -0
  64. package/src/cvcs/relationshipTies.v1.0.0.json +291 -0
  65. package/src/cvcs/sexProviderSubrole.v1.0.0.json +78 -0
  66. package/src/cvcs/sharePurpose.v1.0.0.json +82 -0
  67. package/src/cvcs/smtType.v1.0.0.json +114 -0
  68. package/src/cvcs/tribes.v1.0.0.json +492 -0
  69. package/src/cvcs/victimStatusFamily.v1.0.0.json +96 -0
  70. package/src/generated/cvc-enums.ts +1190 -0
  71. package/src/validation/cvc.ts +17 -0
@@ -0,0 +1,105 @@
1
+ {
2
+ "domain": "hair_color",
3
+ "name": "Core Hair Color",
4
+ "version": "1.0.0",
5
+ "levels": {
6
+ "0": "Unknown or Missing",
7
+ "1": "Hair color"
8
+ },
9
+ "entries": [
10
+ {
11
+ "code": "151-000-000-000-000-000-000",
12
+ "key": "missingness_root",
13
+ "title": "Unknown, Redacted, or Missing",
14
+ "selectable": false,
15
+ "parentCode": null,
16
+ "childCodes": [
17
+ "151-000-000-000-000-000-001",
18
+ "151-000-000-000-000-000-002",
19
+ "151-000-000-000-000-000-003"
20
+ ],
21
+ "definition": "Root group for values indicating absent, withheld, or uncollected data. No prefer_not_to_answer variant — hair color is typically observed/recorded from CJ or media, not self-reported, so the decline option is not applicable per Notion guidance."
22
+ },
23
+ {
24
+ "code": "151-000-000-000-000-000-001",
25
+ "key": "unknown",
26
+ "title": "Unknown",
27
+ "selectable": true,
28
+ "parentCode": "151-000-000-000-000-000-000",
29
+ "childCodes": [],
30
+ "definition": "Value is unknown at time of entry."
31
+ },
32
+ {
33
+ "code": "151-000-000-000-000-000-002",
34
+ "key": "anonymous",
35
+ "title": "Anonymous",
36
+ "selectable": true,
37
+ "parentCode": "151-000-000-000-000-000-000",
38
+ "childCodes": [],
39
+ "definition": "Value is intentionally withheld or redacted."
40
+ },
41
+ {
42
+ "code": "151-000-000-000-000-000-003",
43
+ "key": "data_not_collected",
44
+ "title": "Data not collected",
45
+ "selectable": true,
46
+ "parentCode": "151-000-000-000-000-000-000",
47
+ "childCodes": [],
48
+ "definition": "No attempt was made to collect the value."
49
+ },
50
+ {
51
+ "code": "151-001-000-000-000-000-000",
52
+ "key": "black",
53
+ "title": "Black",
54
+ "selectable": true,
55
+ "parentCode": null,
56
+ "childCodes": [],
57
+ "definition": "Observed hair color is black."
58
+ },
59
+ {
60
+ "code": "151-002-000-000-000-000-000",
61
+ "key": "blonde",
62
+ "title": "Blonde",
63
+ "selectable": true,
64
+ "parentCode": null,
65
+ "childCodes": [],
66
+ "definition": "Observed hair color is blonde."
67
+ },
68
+ {
69
+ "code": "151-003-000-000-000-000-000",
70
+ "key": "brown",
71
+ "title": "Brown",
72
+ "selectable": true,
73
+ "parentCode": null,
74
+ "childCodes": [],
75
+ "definition": "Observed hair color is brown."
76
+ },
77
+ {
78
+ "code": "151-004-000-000-000-000-000",
79
+ "key": "gray_white",
80
+ "title": "Gray/White",
81
+ "selectable": true,
82
+ "parentCode": null,
83
+ "childCodes": [],
84
+ "definition": "Observed hair color is gray or white. Per Notion guidance these are collapsed into a single NCIC-style code (GRY)."
85
+ },
86
+ {
87
+ "code": "151-005-000-000-000-000-000",
88
+ "key": "red",
89
+ "title": "Red",
90
+ "selectable": true,
91
+ "parentCode": null,
92
+ "childCodes": [],
93
+ "definition": "Observed hair color is red."
94
+ },
95
+ {
96
+ "code": "151-006-000-000-000-000-000",
97
+ "key": "other",
98
+ "title": "Other",
99
+ "selectable": true,
100
+ "parentCode": null,
101
+ "childCodes": [],
102
+ "definition": "Observed hair color does not match any of the canonical categories; preserve the raw source value in the consumer's notes if available. Not a missingness marker."
103
+ }
104
+ ]
105
+ }
@@ -0,0 +1,69 @@
1
+ {
2
+ "domain": "has_tattoos",
3
+ "name": "Core Has Tattoos",
4
+ "version": "1.0.0",
5
+ "levels": {
6
+ "0": "Unknown or Missing",
7
+ "1": "Presence"
8
+ },
9
+ "entries": [
10
+ {
11
+ "code": "152-000-000-000-000-000-000",
12
+ "key": "missingness_root",
13
+ "title": "Unknown, Redacted, or Missing",
14
+ "selectable": false,
15
+ "parentCode": null,
16
+ "childCodes": [
17
+ "152-000-000-000-000-000-001",
18
+ "152-000-000-000-000-000-002",
19
+ "152-000-000-000-000-000-003"
20
+ ],
21
+ "definition": "Root group for values indicating absent, withheld, or uncollected data. No prefer_not_to_answer variant — Notion guidance explicitly lists only UNK/ANON/DNC for has_tattoos, and the codebook directs forms offering 'Don't remember' to map to Unknown rather than introducing a separate decline code."
22
+ },
23
+ {
24
+ "code": "152-000-000-000-000-000-001",
25
+ "key": "unknown",
26
+ "title": "Unknown",
27
+ "selectable": true,
28
+ "parentCode": "152-000-000-000-000-000-000",
29
+ "childCodes": [],
30
+ "definition": "Value cannot be determined from the available information. Source workflows that offer a 'Don't remember' option map here. Do not treat as a neutral safe-default in derived current status — prefer excluding from training labels and triggering follow-up prompts over persisting as a long-term state."
31
+ },
32
+ {
33
+ "code": "152-000-000-000-000-000-002",
34
+ "key": "anonymous",
35
+ "title": "Anonymous",
36
+ "selectable": true,
37
+ "parentCode": "152-000-000-000-000-000-000",
38
+ "childCodes": [],
39
+ "definition": "Value is intentionally withheld or redacted, including client preference not to answer and redaction contexts used to reduce re-identification."
40
+ },
41
+ {
42
+ "code": "152-000-000-000-000-000-003",
43
+ "key": "data_not_collected",
44
+ "title": "Data not collected",
45
+ "selectable": true,
46
+ "parentCode": "152-000-000-000-000-000-000",
47
+ "childCodes": [],
48
+ "definition": "No attempt was made to collect the value; the field was not asked or not captured in the source workflow. Primary signal for 'not collected'."
49
+ },
50
+ {
51
+ "code": "152-001-000-000-000-000-000",
52
+ "key": "yes",
53
+ "title": "Yes",
54
+ "selectable": true,
55
+ "parentCode": null,
56
+ "childCodes": [],
57
+ "definition": "Tattoos are known or reported to be present. Pair with the associated tattoo description free-text field and/or SMT log entries when available. If a source implies tattoos via narrative (e.g., 'tattoo on left forearm') without an explicit yes/no answer, prefer creating SMT log entries and leaving this field as unknown unless a deterministic rule is defined."
58
+ },
59
+ {
60
+ "code": "152-002-000-000-000-000-000",
61
+ "key": "no",
62
+ "title": "No",
63
+ "selectable": true,
64
+ "parentCode": null,
65
+ "childCodes": [],
66
+ "definition": "Tattoos are known or reported to be absent. Use only when the source explicitly states no tattoos or the collector marked No; do not infer No from missing tattoo detail fields."
67
+ }
68
+ ]
69
+ }
@@ -0,0 +1,124 @@
1
+ {
2
+ "domain": "highest_education_level_completed",
3
+ "name": "Core Highest Education Level Completed",
4
+ "version": "1.0.0",
5
+ "levels": {
6
+ "0": "Unknown or Missing",
7
+ "1": "Education level"
8
+ },
9
+ "entries": [
10
+ {
11
+ "code": "180-001-000-000-000-000-000",
12
+ "key": "less_than_high_school",
13
+ "title": "Less than high school",
14
+ "selectable": true,
15
+ "parentCode": null,
16
+ "childCodes": [],
17
+ "definition": "No high school diploma or equivalency credential. Aligns with Census/ACS 'Less than high school graduate'."
18
+ },
19
+ {
20
+ "code": "180-002-000-000-000-000-000",
21
+ "key": "high_school_diploma",
22
+ "title": "High school diploma",
23
+ "selectable": true,
24
+ "parentCode": null,
25
+ "childCodes": [],
26
+ "definition": "Completed high school with a standard diploma. Aligns with Census/ACS 'High school graduate (includes equivalency)' diploma branch."
27
+ },
28
+ {
29
+ "code": "180-003-000-000-000-000-000",
30
+ "key": "ged",
31
+ "title": "GED or equivalency credential",
32
+ "selectable": true,
33
+ "parentCode": null,
34
+ "childCodes": [],
35
+ "definition": "Earned a GED or other high school equivalency credential in lieu of a standard diploma. Tracked separately from 'high_school_diploma' for analytic parity with HMIS and workforce reporting."
36
+ },
37
+ {
38
+ "code": "180-004-000-000-000-000-000",
39
+ "key": "some_college",
40
+ "title": "Some college, no degree",
41
+ "selectable": true,
42
+ "parentCode": null,
43
+ "childCodes": [],
44
+ "definition": "Attended college or postsecondary coursework but did not complete a degree. Aligns with Census/ACS 'Some college, no degree'."
45
+ },
46
+ {
47
+ "code": "180-005-000-000-000-000-000",
48
+ "key": "associates",
49
+ "title": "Associate's degree",
50
+ "selectable": true,
51
+ "parentCode": null,
52
+ "childCodes": [],
53
+ "definition": "Completed an associate's degree (AA, AS, AAS, or equivalent). Aligns with Census/ACS 'Associate's degree'."
54
+ },
55
+ {
56
+ "code": "180-006-000-000-000-000-000",
57
+ "key": "bachelors",
58
+ "title": "Bachelor's degree",
59
+ "selectable": true,
60
+ "parentCode": null,
61
+ "childCodes": [],
62
+ "definition": "Completed a bachelor's degree (BA, BS, or equivalent). Aligns with Census/ACS 'Bachelor's degree'."
63
+ },
64
+ {
65
+ "code": "180-007-000-000-000-000-000",
66
+ "key": "graduate_professional",
67
+ "title": "Graduate or professional degree",
68
+ "selectable": true,
69
+ "parentCode": null,
70
+ "childCodes": [],
71
+ "definition": "Completed a master's, doctoral, or professional degree (MA, MS, MBA, JD, MD, PhD, or equivalent). Aligns with Census/ACS 'Graduate or professional degree'."
72
+ },
73
+ {
74
+ "code": "180-000-000-000-000-000-000",
75
+ "key": "missingness_root",
76
+ "title": "Unknown, Redacted, or Missing",
77
+ "selectable": false,
78
+ "parentCode": null,
79
+ "childCodes": [
80
+ "180-000-000-000-000-000-001",
81
+ "180-000-000-000-000-000-002",
82
+ "180-000-000-000-000-000-003",
83
+ "180-000-000-000-000-000-004"
84
+ ],
85
+ "definition": "Root group for values indicating absent, withheld, or uncollected data."
86
+ },
87
+ {
88
+ "code": "180-000-000-000-000-000-001",
89
+ "key": "unknown",
90
+ "title": "Unknown",
91
+ "selectable": true,
92
+ "parentCode": "180-000-000-000-000-000-000",
93
+ "childCodes": [],
94
+ "definition": "Value is unknown at time of entry."
95
+ },
96
+ {
97
+ "code": "180-000-000-000-000-000-002",
98
+ "key": "anonymous",
99
+ "title": "Anonymous",
100
+ "selectable": true,
101
+ "parentCode": "180-000-000-000-000-000-000",
102
+ "childCodes": [],
103
+ "definition": "Value is intentionally withheld or redacted."
104
+ },
105
+ {
106
+ "code": "180-000-000-000-000-000-003",
107
+ "key": "data_not_collected",
108
+ "title": "Data not collected",
109
+ "selectable": true,
110
+ "parentCode": "180-000-000-000-000-000-000",
111
+ "childCodes": [],
112
+ "definition": "No attempt was made to collect the value."
113
+ },
114
+ {
115
+ "code": "180-000-000-000-000-000-004",
116
+ "key": "prefer_not_to_answer",
117
+ "title": "Client prefers not to answer",
118
+ "selectable": true,
119
+ "parentCode": "180-000-000-000-000-000-000",
120
+ "childCodes": [],
121
+ "definition": "Client was offered the opportunity to self-identify and explicitly declined to provide the value. Preserves the legacy 'Declined to answer' semantic from the pre-v2 CVC_180 constant."
122
+ }
123
+ ]
124
+ }
@@ -0,0 +1,98 @@
1
+ {
2
+ "domain": "homeless_status",
3
+ "name": "Core Homeless Status",
4
+ "version": "1.0.0",
5
+ "levels": {
6
+ "0": "Unknown or Missing",
7
+ "1": "Homeless status"
8
+ },
9
+ "entries": [
10
+ {
11
+ "code": "096-001-000-000-000-000-000",
12
+ "key": "current",
13
+ "title": "Current",
14
+ "selectable": true,
15
+ "parentCode": null,
16
+ "childCodes": [],
17
+ "definition": "Client is currently experiencing homelessness per HUD literal-homelessness criteria (living in a place not meant for human habitation, an emergency shelter, transitional housing, or exiting an institution where they resided for ≤90 days after entering from homelessness). Derived from the HMIS Current Living Situation data stream."
18
+ },
19
+ {
20
+ "code": "096-002-000-000-000-000-000",
21
+ "key": "former",
22
+ "title": "Former",
23
+ "selectable": true,
24
+ "parentCode": null,
25
+ "childCodes": [],
26
+ "definition": "Client has previously experienced homelessness under HUD literal-homelessness criteria but is not currently homeless."
27
+ },
28
+ {
29
+ "code": "096-003-000-000-000-000-000",
30
+ "key": "never",
31
+ "title": "Never",
32
+ "selectable": true,
33
+ "parentCode": null,
34
+ "childCodes": [],
35
+ "definition": "Client has never experienced homelessness under HUD literal-homelessness criteria."
36
+ },
37
+ {
38
+ "code": "096-000-000-000-000-000-000",
39
+ "key": "missingness_root",
40
+ "title": "Unknown, Redacted, or Missing",
41
+ "selectable": false,
42
+ "parentCode": null,
43
+ "childCodes": [
44
+ "096-000-000-000-000-000-001",
45
+ "096-000-000-000-000-000-002",
46
+ "096-000-000-000-000-000-003",
47
+ "096-000-000-000-000-000-004",
48
+ "096-000-000-000-000-000-005"
49
+ ],
50
+ "definition": "Root group for values indicating absent, withheld, or uncollected homeless-status data. Expands to the full HMIS 5-state missingness set (unknown, anonymous, data_not_collected, client_doesnt_know, client_refused) per HMIS R-series response semantics."
51
+ },
52
+ {
53
+ "code": "096-000-000-000-000-000-001",
54
+ "key": "unknown",
55
+ "title": "Unknown",
56
+ "selectable": true,
57
+ "parentCode": "096-000-000-000-000-000-000",
58
+ "childCodes": [],
59
+ "definition": "Homeless status is unknown at time of entry."
60
+ },
61
+ {
62
+ "code": "096-000-000-000-000-000-002",
63
+ "key": "anonymous",
64
+ "title": "Anonymous",
65
+ "selectable": true,
66
+ "parentCode": "096-000-000-000-000-000-000",
67
+ "childCodes": [],
68
+ "definition": "Homeless status is intentionally withheld or redacted."
69
+ },
70
+ {
71
+ "code": "096-000-000-000-000-000-003",
72
+ "key": "data_not_collected",
73
+ "title": "Data not collected",
74
+ "selectable": true,
75
+ "parentCode": "096-000-000-000-000-000-000",
76
+ "childCodes": [],
77
+ "definition": "No attempt was made to collect the homeless-status value."
78
+ },
79
+ {
80
+ "code": "096-000-000-000-000-000-004",
81
+ "key": "client_doesnt_know",
82
+ "title": "Client doesn't know",
83
+ "selectable": true,
84
+ "parentCode": "096-000-000-000-000-000-000",
85
+ "childCodes": [],
86
+ "definition": "Client was asked about homeless status but does not know the answer. HMIS R-series canonical response."
87
+ },
88
+ {
89
+ "code": "096-000-000-000-000-000-005",
90
+ "key": "client_refused",
91
+ "title": "Client refused",
92
+ "selectable": true,
93
+ "parentCode": "096-000-000-000-000-000-000",
94
+ "childCodes": [],
95
+ "definition": "Client was asked about homeless status and refused to answer. HMIS R-series canonical response."
96
+ }
97
+ ]
98
+ }