@htilabs/platform-common-models 0.8.12 → 0.8.13
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/dist/constants/index.cjs +133 -287
- package/dist/constants/index.cjs.map +1 -1
- package/dist/constants/index.d.cts +1 -1
- package/dist/constants/index.d.ts +1 -1
- package/dist/constants/index.js +133 -275
- package/dist/constants/index.js.map +1 -1
- package/dist/cvcs/index.cjs +11670 -969
- package/dist/cvcs/index.cjs.map +1 -1
- package/dist/cvcs/index.d.cts +14727 -3020
- package/dist/cvcs/index.d.ts +14727 -3020
- package/dist/cvcs/index.js +11643 -968
- package/dist/cvcs/index.js.map +1 -1
- package/dist/index.cjs +12718 -1360
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1012 -128
- package/dist/index.d.ts +1012 -128
- package/dist/index.js +12671 -1345
- package/dist/index.js.map +1 -1
- package/dist/{platform-auth-BwfZ0bxU.d.cts → platform-auth-BfCMuAlC.d.cts} +2 -74
- package/dist/{platform-auth-BwfZ0bxU.d.ts → platform-auth-BfCMuAlC.d.ts} +2 -74
- package/dist/schemas/index.cjs +0 -152
- package/dist/schemas/index.cjs.map +1 -1
- package/dist/schemas/index.js +0 -152
- package/dist/schemas/index.js.map +1 -1
- package/dist/services/index.cjs +0 -3
- package/dist/services/index.cjs.map +1 -1
- package/dist/services/index.js +0 -3
- package/dist/services/index.js.map +1 -1
- package/dist/types/index.d.cts +2 -2
- package/dist/types/index.d.ts +2 -2
- package/package.json +4 -1
- package/src/__sot__/README.md +56 -0
- package/src/__sot__/coreIndicators.pin.json +215 -0
- package/src/__sot__/cvcIndex.pin.json +268 -0
- package/src/__sot__/scoringEmits.pin.json +176 -0
- package/src/__tests__/__snapshots__/cvc-sot.snap +109 -37
- package/src/__tests__/cvc-136-scoring-invariant.test.ts +323 -0
- package/src/__tests__/cvc-drift-gate.test.ts +596 -0
- package/src/__tests__/cvc-sot-snapshot.test.ts +38 -8
- package/src/__tests__/cvc-structural.test.ts +37 -1
- package/src/constants/ic.ts +184 -333
- package/src/constants/service-catalog.ts +4 -2
- package/src/cvcs/adminRoles.v1.0.0.json +153 -0
- package/src/cvcs/administeringJurisdiction.v1.0.0.json +40 -40
- package/src/cvcs/ageBinReporting.v1.0.0.json +40 -40
- package/src/cvcs/assertionDomain.v1.1.0.json +78 -105
- package/src/cvcs/citizenship.v1.0.0.json +3062 -0
- package/src/cvcs/contactInfoTypes.v1.0.0.json +40 -40
- package/src/cvcs/coreDhState.v1.0.0.json +113 -0
- package/src/cvcs/coreIndicators.v1.0.0.json +2840 -0
- package/src/cvcs/employmentStatus.v1.0.0.json +60 -60
- package/src/cvcs/exploitationType.v1.0.0.json +106 -0
- package/src/cvcs/facilitatorEntityType.v1.0.0.json +40 -40
- package/src/cvcs/highestEducationLevelCompleted.v1.0.0.json +50 -50
- package/src/cvcs/hmisCurrentLivingSituation.v1.0.0.json +409 -0
- package/src/cvcs/homelessStatus.v1.0.0.json +27 -27
- package/src/cvcs/housingSubsidyTypes.v1.0.0.json +26 -24
- package/src/cvcs/incarcerationEpisodeType.v1.0.0.json +106 -0
- package/src/cvcs/incidentInvolvementRoles.v1.0.0.json +40 -40
- package/src/cvcs/incidentParticipationRoles.v1.0.0.json +40 -40
- package/src/cvcs/index.ts +55 -2
- package/src/cvcs/juvenileJusticeEpisodeType.v1.0.0.json +106 -0
- package/src/cvcs/juvenileJusticeInvolvementStatus.v1.0.0.json +32 -32
- package/src/cvcs/militaryBranch.v1.0.0.json +20 -20
- package/src/cvcs/militaryStatus.v1.0.0.json +20 -20
- package/src/cvcs/nameType.v1.0.0.json +40 -40
- package/src/cvcs/offenderStatus.v1.0.0.json +40 -40
- package/src/cvcs/offenderStatusFamily.v1.0.0.json +36 -36
- package/src/cvcs/poPetitionBasis.v1.0.0.json +96 -0
- package/src/cvcs/poStatus.v1.0.0.json +144 -0
- package/src/cvcs/poViolationStatus.v1.0.0.json +76 -0
- package/src/cvcs/radiusBucket.v1.0.0.json +23 -11
- package/src/cvcs/recencyBand.v1.0.0.json +126 -42
- package/src/cvcs/referralEntityCategory.v1.0.0.json +40 -40
- package/src/cvcs/riskSeverityBand.v1.0.0.json +139 -0
- package/src/cvcs/roiScope.v1.0.0.json +111 -3
- package/src/cvcs/roiStatus.v1.0.0.json +18 -10
- package/src/cvcs/romanticRelationshipChangeType.v1.0.0.json +2 -1
- package/src/cvcs/serviceCategories.v1.0.0.json +44 -44
- package/src/cvcs/serviceDeliveryChannel.v1.0.0.json +147 -0
- package/src/cvcs/serviceMechanisms.v1.0.0.json +36 -36
- package/src/cvcs/serviceStates.v1.0.0.json +40 -40
- package/src/cvcs/sessionTemplate.v1.0.0.json +261 -0
- package/src/cvcs/sexProviderSubrole.v1.0.0.json +35 -28
- package/src/cvcs/smtType.v1.0.0.json +40 -40
- package/src/cvcs/sourceCategory.v1.1.0.json +8 -1
- package/src/cvcs/sourceInstrument.v1.0.0.json +458 -0
- package/src/cvcs/sourceSystem.v1.0.0.json +203 -0
- package/src/cvcs/traffickingRelevantRole.v1.0.0.json +104 -0
- package/src/cvcs/userRoles.v1.0.0.json +203 -0
- package/src/cvcs/victimStatusFamily.v1.0.0.json +40 -40
- package/src/cvcs/whyNots.v1.0.0.json +385 -0
- package/src/generated/cvc-enums.ts +1047 -127
- package/src/services/cvcRegistryService.ts +1 -1
- package/src/cvcs/riskBand.v1.0.0.json +0 -98
|
@@ -572,11 +572,13 @@ const SOT_SPECS: readonly SotSpec[] = [
|
|
|
572
572
|
// codes + 1 missingness root + 3 canonical missingness children = 11.
|
|
573
573
|
// CVC number is PROVISIONAL pending codebook-session ratification.
|
|
574
574
|
{ file: "relationshipConcern.v1.0.0.json", domain: "relationship_concern", expectedCount: 11 },
|
|
575
|
-
//
|
|
576
|
-
//
|
|
577
|
-
//
|
|
578
|
-
//
|
|
579
|
-
|
|
575
|
+
// CVC-137 recency_band — the CANONICAL 8-band key system adopted in 0.8.13
|
|
576
|
+
// (w3m, m3_6, m6_12, y1p, y1_3, y3_10, y10p, ylt3 — the lowercase
|
|
577
|
+
// transliterations of W3M/M3_6/M6_12/Y1P/Y1_3/Y3_10/Y10P/YLT3, carried
|
|
578
|
+
// verbatim in `canonicalCode`) + 1 missingness root + 3 canonical missingness
|
|
579
|
+
// children = 12. Replaces the 6 semantic slugs shipped before 0.8.13; all 6
|
|
580
|
+
// map 1:1 onto a canonical band, and y1_3 / ylt3 are net-new.
|
|
581
|
+
{ file: "recencyBand.v1.0.0.json", domain: "recency_band", expectedCount: 12 },
|
|
580
582
|
// PROVISIONAL CVC-233 housing_subsidy_types — 12 HMIS-aligned subsidy types
|
|
581
583
|
// (housing_choice_voucher, public_housing, project_based_rental_assistance,
|
|
582
584
|
// permanent_supportive_housing, rapid_rehousing_assistance,
|
|
@@ -586,7 +588,7 @@ const SOT_SPECS: readonly SotSpec[] = [
|
|
|
586
588
|
// root + 3 canonical missingness children = 16. CVC number is PROVISIONAL
|
|
587
589
|
// pending ratification.
|
|
588
590
|
{ file: "housingSubsidyTypes.v1.0.0.json", domain: "housing_subsidy_types", expectedCount: 16 },
|
|
589
|
-
{ file: "assertionDomain.v1.1.0.json", domain: "assertion_domain", expectedCount:
|
|
591
|
+
{ file: "assertionDomain.v1.1.0.json", domain: "assertion_domain", expectedCount: 68 },
|
|
590
592
|
{ file: "activityType.v1.0.0.json", domain: "activity_type", expectedCount: 14 },
|
|
591
593
|
{ file: "provenanceSourceId.v1.0.0.json", domain: "provenance_source_id", expectedCount: 13 },
|
|
592
594
|
{ file: "radiusBucket.v1.0.0.json", domain: "radius_bucket", expectedCount: 9 },
|
|
@@ -608,7 +610,6 @@ const SOT_SPECS: readonly SotSpec[] = [
|
|
|
608
610
|
// 5 bands (severe/elevated/review/watch/stable — `stable` is the cutoff-less
|
|
609
611
|
// fall-through floor, so the count is 5, NOT the 4 numeric BandCutoffs
|
|
610
612
|
// fields) + 4 missingness = 9
|
|
611
|
-
{ file: "riskBand.v1.0.0.json", domain: "risk_band", expectedCount: 9 },
|
|
612
613
|
// ─── 0.8.12 vocabulary batch ───
|
|
613
614
|
// CANONICAL Notion CVC-133 `core - functions` (verified v1.0): 77 functions
|
|
614
615
|
// + 4 missingness = 81
|
|
@@ -618,12 +619,41 @@ const SOT_SPECS: readonly SotSpec[] = [
|
|
|
618
619
|
{ file: "needsAssessmentChangeType.v1.0.0.json", domain: "needs_assessment_change_type", expectedCount: 13 },
|
|
619
620
|
// 15 ROI scope items (@pave/domain ROI_SCOPE_KEYS — the PAVE-seed-attested
|
|
620
621
|
// subset of the prototype's 27-item UI superset) + 4 = 19
|
|
621
|
-
{ file: "roiScope.v1.0.0.json", domain: "roi_scope", expectedCount:
|
|
622
|
+
{ file: "roiScope.v1.0.0.json", domain: "roi_scope", expectedCount: 31 },
|
|
622
623
|
// 5 stored-ROI lifecycle states (@pave/domain ROI_STATUSES) + 4 = 9
|
|
623
624
|
{ file: "roiStatus.v1.0.0.json", domain: "roi_status", expectedCount: 9 },
|
|
624
625
|
// 2 HMIS FY2026 "P2 Referrals Provided" outcomes (attained / not_attained)
|
|
625
626
|
// + 4 = 6. The not-attained REASON is a separate axis, not folded in here.
|
|
626
627
|
{ file: "coreReferralOutcome.v1.0.0.json", domain: "core_referral_outcome", expectedCount: 6 },
|
|
628
|
+
// ─── 0.8.13 canonical CVC batch ───
|
|
629
|
+
{ file: "coreDhState.v1.0.0.json", domain: "dh_state", expectedCount: 9 },
|
|
630
|
+
{ file: "coreIndicators.v1.0.0.json", domain: "core_indicators", expectedCount: 214 },
|
|
631
|
+
{ file: "riskSeverityBand.v1.0.0.json", domain: "risk_severity_band", expectedCount: 9 },
|
|
632
|
+
{ file: "adminRoles.v1.0.0.json", domain: "admin_roles", expectedCount: 14 },
|
|
633
|
+
{ file: "userRoles.v1.0.0.json", domain: "user_roles", expectedCount: 19 },
|
|
634
|
+
{ file: "hmisCurrentLivingSituation.v1.0.0.json", domain: "hmis_current_living_situation", expectedCount: 33 },
|
|
635
|
+
{ file: "juvenileJusticeEpisodeType.v1.0.0.json", domain: "juvenile_justice_episode_type", expectedCount: 9 },
|
|
636
|
+
{ file: "incarcerationEpisodeType.v1.0.0.json", domain: "incarceration_episode_type", expectedCount: 9 },
|
|
637
|
+
{ file: "exploitationType.v1.0.0.json", domain: "exploitation_type", expectedCount: 9 },
|
|
638
|
+
{ file: "sourceSystem.v1.0.0.json", domain: "source_system", expectedCount: 19 },
|
|
639
|
+
{ file: "sourceInstrument.v1.0.0.json", domain: "source_instrument", expectedCount: 41 },
|
|
640
|
+
{ file: "poPetitionBasis.v1.0.0.json", domain: "po_petition_basis", expectedCount: 8 },
|
|
641
|
+
{ file: "poStatus.v1.0.0.json", domain: "po_status", expectedCount: 12 },
|
|
642
|
+
{ file: "poViolationStatus.v1.0.0.json", domain: "po_violation_status", expectedCount: 6 },
|
|
643
|
+
{ file: "sessionTemplate.v1.0.0.json", domain: "session_template", expectedCount: 23 },
|
|
644
|
+
{ file: "serviceDeliveryChannel.v1.0.0.json", domain: "service_delivery_channel", expectedCount: 11 },
|
|
645
|
+
{ file: "whyNots.v1.0.0.json", domain: "why_nots", expectedCount: 32 },
|
|
646
|
+
// CVC-182 — 249 countries (codes MINTED; upstream Code column is blank) + 1
|
|
647
|
+
// missingness root + 3 canonical missingness children (Unknown / Declined to
|
|
648
|
+
// asnwer / Not collected, carried verbatim from the codebook) = 253.
|
|
649
|
+
{ file: "citizenship.v1.0.0.json", domain: "citizenship", expectedCount: 253 },
|
|
650
|
+
// CVC-235 — 4 L1 trafficking-relevant roles + 1 missingness root + 3 canonical
|
|
651
|
+
// missingness children = 8.
|
|
652
|
+
{
|
|
653
|
+
file: "traffickingRelevantRole.v1.0.0.json",
|
|
654
|
+
domain: "trafficking_relevant_role",
|
|
655
|
+
expectedCount: 8,
|
|
656
|
+
},
|
|
627
657
|
] as const;
|
|
628
658
|
|
|
629
659
|
// ─── Helpers ────────────────────────────────────────────────────────────────
|
|
@@ -179,7 +179,6 @@ const SOT_FILES: readonly SotFile[] = [
|
|
|
179
179
|
{ file: "housingSubsidyTypes.v1.0.0.json", expectedDomain: "housing_subsidy_types" },
|
|
180
180
|
// ─── Risk taxonomy (names-only projection of the @hti/scoring SOT) ───
|
|
181
181
|
{ file: "riskCategory.v1.0.0.json", expectedDomain: "risk_category" },
|
|
182
|
-
{ file: "riskBand.v1.0.0.json", expectedDomain: "risk_band" },
|
|
183
182
|
// ─── 0.8.12 vocabulary batch ───
|
|
184
183
|
{ file: "coreFunctions.v1.0.0.json", expectedDomain: "core_functions" },
|
|
185
184
|
{ file: "needsAssessmentChangeType.v1.0.0.json", expectedDomain: "needs_assessment_change_type" },
|
|
@@ -187,6 +186,43 @@ const SOT_FILES: readonly SotFile[] = [
|
|
|
187
186
|
{ file: "roiStatus.v1.0.0.json", expectedDomain: "roi_status" },
|
|
188
187
|
{ file: "coreReferralOutcome.v1.0.0.json", expectedDomain: "core_referral_outcome" },
|
|
189
188
|
{ file: "assertionDomain.v1.1.0.json", expectedDomain: "assertion_domain" },
|
|
189
|
+
// ─── 0.8.13 canonical CVC batch ───
|
|
190
|
+
{ file: "coreDhState.v1.0.0.json", expectedDomain: "dh_state" },
|
|
191
|
+
{ file: "coreIndicators.v1.0.0.json", expectedDomain: "core_indicators" },
|
|
192
|
+
{ file: "riskSeverityBand.v1.0.0.json", expectedDomain: "risk_severity_band" },
|
|
193
|
+
{ file: "adminRoles.v1.0.0.json", expectedDomain: "admin_roles" },
|
|
194
|
+
{ file: "userRoles.v1.0.0.json", expectedDomain: "user_roles" },
|
|
195
|
+
{ file: "hmisCurrentLivingSituation.v1.0.0.json", expectedDomain: "hmis_current_living_situation" },
|
|
196
|
+
{ file: "juvenileJusticeEpisodeType.v1.0.0.json", expectedDomain: "juvenile_justice_episode_type" },
|
|
197
|
+
{ file: "incarcerationEpisodeType.v1.0.0.json", expectedDomain: "incarceration_episode_type" },
|
|
198
|
+
{ file: "exploitationType.v1.0.0.json", expectedDomain: "exploitation_type" },
|
|
199
|
+
{ file: "sourceSystem.v1.0.0.json", expectedDomain: "source_system" },
|
|
200
|
+
{ file: "sourceInstrument.v1.0.0.json", expectedDomain: "source_instrument" },
|
|
201
|
+
{ file: "poPetitionBasis.v1.0.0.json", expectedDomain: "po_petition_basis" },
|
|
202
|
+
{ file: "poStatus.v1.0.0.json", expectedDomain: "po_status" },
|
|
203
|
+
{ file: "poViolationStatus.v1.0.0.json", expectedDomain: "po_violation_status" },
|
|
204
|
+
{ file: "sessionTemplate.v1.0.0.json", expectedDomain: "session_template" },
|
|
205
|
+
{ file: "serviceDeliveryChannel.v1.0.0.json", expectedDomain: "service_delivery_channel" },
|
|
206
|
+
{ file: "whyNots.v1.0.0.json", expectedDomain: "why_nots" },
|
|
207
|
+
// ─── 0.8.13 held-item resolutions (Job A) ───
|
|
208
|
+
{ file: "citizenship.v1.0.0.json", expectedDomain: "citizenship" },
|
|
209
|
+
{ file: "traffickingRelevantRole.v1.0.0.json", expectedDomain: "trafficking_relevant_role" },
|
|
210
|
+
// ─── Domains the hand-maintained list previously OMITTED (found by the
|
|
211
|
+
// CVC drift gate, which scans the directory instead of a list). ───
|
|
212
|
+
{ file: "activityType.v1.0.0.json", expectedDomain: "activity_type" },
|
|
213
|
+
{ file: "childChangeType.v1.0.0.json", expectedDomain: "child_change_type" },
|
|
214
|
+
{ file: "contactLinkType.v1.0.0.json", expectedDomain: "contact_link_type" },
|
|
215
|
+
{ file: "hivStatus.v1.0.0.json", expectedDomain: "hiv_status" },
|
|
216
|
+
{ file: "immigrationLegalStatusChangeType.v1.0.0.json", expectedDomain: "immigration_legal_status_change_type" },
|
|
217
|
+
{ file: "mentalHealthStatus.v1.0.0.json", expectedDomain: "mental_health_status" },
|
|
218
|
+
{ file: "programEnrollmentChangeType.v1.0.0.json", expectedDomain: "program_enrollment_change_type" },
|
|
219
|
+
{ file: "provenanceSourceId.v1.0.0.json", expectedDomain: "provenance_source_id" },
|
|
220
|
+
{ file: "radiusBucket.v1.0.0.json", expectedDomain: "radius_bucket" },
|
|
221
|
+
{ file: "roiMethod.v1.0.0.json", expectedDomain: "roi_method" },
|
|
222
|
+
{ file: "romanticRelationshipChangeType.v1.0.0.json", expectedDomain: "romantic_relationship_change_type" },
|
|
223
|
+
{ file: "sessionNoteVisibility.v1.0.0.json", expectedDomain: "session_note_visibility" },
|
|
224
|
+
{ file: "specialNeedsDisabilities.v1.0.0.json", expectedDomain: "special_needs_disabilities" },
|
|
225
|
+
{ file: "suggestionSource.v1.0.0.json", expectedDomain: "suggestion_source" },
|
|
190
226
|
] as const;
|
|
191
227
|
|
|
192
228
|
function loadSot(file: string): unknown {
|