@htilabs/platform-common-models 0.13.1 → 0.14.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 (45) hide show
  1. package/dist/constants/index.cjs +33 -0
  2. package/dist/constants/index.cjs.map +1 -1
  3. package/dist/constants/index.d.cts +1 -1
  4. package/dist/constants/index.d.ts +1 -1
  5. package/dist/constants/index.js +29 -0
  6. package/dist/constants/index.js.map +1 -1
  7. package/dist/cvcs/index.cjs +96 -13
  8. package/dist/cvcs/index.cjs.map +1 -1
  9. package/dist/cvcs/index.d.cts +101 -12
  10. package/dist/cvcs/index.d.ts +101 -12
  11. package/dist/cvcs/index.js +96 -13
  12. package/dist/cvcs/index.js.map +1 -1
  13. package/dist/enums/index.cjs +7 -1
  14. package/dist/enums/index.cjs.map +1 -1
  15. package/dist/enums/index.d.cts +8 -2
  16. package/dist/enums/index.d.ts +8 -2
  17. package/dist/enums/index.js +7 -1
  18. package/dist/enums/index.js.map +1 -1
  19. package/dist/index.cjs +136 -14
  20. package/dist/index.cjs.map +1 -1
  21. package/dist/index.d.cts +1 -1
  22. package/dist/index.d.ts +1 -1
  23. package/dist/index.js +132 -14
  24. package/dist/index.js.map +1 -1
  25. package/dist/{platform-auth-64U8jjuw.d.cts → platform-auth-CrF5U_JH.d.cts} +43 -2
  26. package/dist/{platform-auth-64U8jjuw.d.ts → platform-auth-CrF5U_JH.d.ts} +43 -2
  27. package/dist/schemas/index.cjs +234 -0
  28. package/dist/schemas/index.cjs.map +1 -1
  29. package/dist/schemas/index.js +234 -0
  30. package/dist/schemas/index.js.map +1 -1
  31. package/dist/types/index.d.cts +2 -2
  32. package/dist/types/index.d.ts +2 -2
  33. package/package.json +1 -1
  34. package/src/__sot__/coreIndicatorFields.ts +4 -4
  35. package/src/__sot__/coreIndicators.pin.json +62 -2
  36. package/src/__sot__/scoringEmits.pin.json +9 -4
  37. package/src/__tests__/__snapshots__/cvc-sot.snap +2 -2
  38. package/src/__tests__/cvc-136-scoring-invariant.test.ts +89 -28
  39. package/src/__tests__/cvc-drift-gate.test.ts +149 -27
  40. package/src/__tests__/cvc-sot-snapshot.test.ts +3 -1
  41. package/src/__tests__/cvc-structural.test.ts +1 -1
  42. package/src/constants/ic.ts +163 -3
  43. package/src/cvcs/{coreIndicators.v1.0.0.json → coreIndicators.v1.1.0.json} +93 -10
  44. package/src/cvcs/index.ts +1 -1
  45. package/src/generated/cvc-enums.ts +8 -2
@@ -47,7 +47,7 @@ __export(cvcs_exports, {
47
47
  contactSafetyStatusSot: () => contactSafetyStatus_v1_0_0_default,
48
48
  coreDhStateSot: () => coreDhState_v1_0_0_default,
49
49
  coreFunctionsSot: () => coreFunctions_v1_0_0_default,
50
- coreIndicatorsSot: () => coreIndicators_v1_0_0_default,
50
+ coreIndicatorsSot: () => coreIndicators_v1_1_0_default,
51
51
  coreInformationScopeSot: () => coreInformationScope_v1_0_0_default,
52
52
  coreReferralOutcomeSot: () => coreReferralOutcome_v1_0_0_default,
53
53
  countriesSot: () => countries_v1_0_0_default,
@@ -29161,13 +29161,13 @@ var coreReferralOutcome_v1_0_0_default = {
29161
29161
  ]
29162
29162
  };
29163
29163
 
29164
- // src/cvcs/coreIndicators.v1.0.0.json
29165
- var coreIndicators_v1_0_0_default = {
29164
+ // src/cvcs/coreIndicators.v1.1.0.json
29165
+ var coreIndicators_v1_1_0_default = {
29166
29166
  domain: "core_indicators",
29167
29167
  name: "Core Indicators (CVC-136)",
29168
- version: "1.0.0",
29169
- _status: "CANONICAL \u2014 re-sourced from the live canonical catalog `data/core_indicators.yaml` @ prototype HEAD 622410b (214 codes; +1 vs the 0.8.14 pin 84a1b67, 0 withdrawn, plus the projected-field revisions on 136-007 / 136-094 the same delta carried), plus 2 codes that @hti/scoring (`weights/risk.weights.json` @ 9b5d654, `emits_by_code`) emits but the codebook has not yet adopted (`coercive_debt_pressure_youth`, `debt_terms_deceptive_youth`), each flagged `pendingUpstreamAdoption: true`. 216 substantive + the missingness quadruplet = 220 entries. New codes are APPENDED at 216 so every previously issued positional code stays stable.",
29170
- _source: "htilabstech/prototype@622410b data/core_indicators.yaml + htilabstech/hti-scoring@9b5d654 weights/risk.weights.json (emits_by_code)",
29168
+ version: "1.1.0",
29169
+ _status: "CANONICAL \u2014 re-sourced from the live canonical catalog `data/core_indicators.yaml` @ prototype HEAD c53378f (220 codes; +6 vs the 0.8.17 pin 622410b, 0 withdrawn upstream, plus the projected-field revision on 136-061 `exploitative_pricing_tier_low` the same delta carried), reconciled against @hti/scoring (`weights/risk.weights.json` @ 9c209cf, `emits_by_code`, 174 codes). VERSION 1.0.0 -> 1.1.0 (2026-10-06): this refresh removes `selectable` from two rows and redefines a third, so it is NOT additive and cannot reuse the published 1.0.0 content hash \u2014 the seeder's \xA79.1.2 ContentDriftError guard (scripts/seed-cvc.ts) would refuse to re-seed 1.0.0 with different content (the #188/#190 precedent; `incidentParticipationRoles` 1.1.0 is the shape). The 2 former scoring-ahead codes (`coercive_debt_pressure_youth` 136-033, `debt_terms_deceptive_youth` 136-050, formerly `pendingUpstreamAdoption: true`) are DEPRECATED, NOT REMOVED: `selectable: false`, `deprecated: true`, `supersededBy` their canonical rows `coercive_debt_pressure` (136-032) / `debt_terms_deceptive` (136-049), which upstream carries as `legacy_aliases`. hti-scoring 9c209cf no longer emits them, but PAVE 2.0 `develop` @ 07f3ccd still WRITES both from the IDA (`IDA-syn-missing_care-4i`/`4ii`, packages/api-core/src/rules/assessments/ida/emits.ts) and scores them from its 2026-07-17 vendored weights, so a stored assertion under either key must keep resolving in this SOT. Thread `develop` @ 28580ab has no writer. Their positional codes are HELD by the deprecated rows and are never reissued to another key. 220 selectable + 2 deprecated + the missingness quadruplet = 226 entries. New codes are APPENDED at 217\u2013222 so every previously issued positional code stays stable.",
29170
+ _source: "htilabstech/prototype@c53378f data/core_indicators.yaml + htilabstech/hti-scoring@9c209cf weights/risk.weights.json (emits_by_code)",
29171
29171
  levels: {
29172
29172
  "0": "Unknown or Missing",
29173
29173
  "1": "Indicator"
@@ -29644,11 +29644,12 @@ var coreIndicators_v1_0_0_default = {
29644
29644
  code: "136-033-000-000-000-000-000",
29645
29645
  key: "coercive_debt_pressure_youth",
29646
29646
  title: "Pressured to do things to pay off debt (youth missing-from-care)",
29647
- selectable: true,
29647
+ selectable: false,
29648
29648
  parentCode: null,
29649
29649
  childCodes: [],
29650
- definition: "Indication that a youth who is missing from care was pressured or coerced into doing things in order to pay off a debt. Youth-specific sibling of `coercive_debt_pressure`. PENDING UPSTREAM ADOPTION: this code is NOT yet present in the canonical `data/core_indicators.yaml` at prototype HEAD a596eb9. It is retained because @hti/scoring (the declared scoring SOT, weights/risk.weights.json @ 9b5d654) EMITS it via `emits_by_code` \u2014 scoring is ahead of the codebook here. Withdrawing it would break the scoring contract. File upstream for adoption into core_indicators.yaml.",
29651
- pendingUpstreamAdoption: true
29650
+ definition: "DEPRECATED 2026-10-06 \u2014 superseded by `coercive_debt_pressure` (136-032); the canonical catalog carries this key as a `legacy_alias` of that row and @hti/scoring 9c209cf no longer emits it. Retained read-only because PAVE 2.0 `develop` (IDA `IDA-syn-missing_care-4i`, emits.ts) still writes it and assertions stored under this key must keep resolving. Original meaning: indication that a youth who is missing from care was pressured or coerced into doing things in order to pay off a debt. Youth-specific sibling of `coercive_debt_pressure`. Do not offer for new writes; bind the canonical key.",
29651
+ deprecated: true,
29652
+ supersededBy: "coercive_debt_pressure"
29652
29653
  },
29653
29654
  {
29654
29655
  code: "136-034-000-000-000-000-000",
@@ -29866,11 +29867,12 @@ var coreIndicators_v1_0_0_default = {
29866
29867
  code: "136-050-000-000-000-000-000",
29867
29868
  key: "debt_terms_deceptive_youth",
29868
29869
  title: "Debt repayment terms differed from what was expected (youth missing-from-care)",
29869
- selectable: true,
29870
+ selectable: false,
29870
29871
  parentCode: null,
29871
29872
  childCodes: [],
29872
- definition: "Indication that, for a youth missing from care, the terms of a debt or its repayment differed from what was represented or expected. Youth-specific sibling of `debt_terms_deceptive`. PENDING UPSTREAM ADOPTION: this code is NOT yet present in the canonical `data/core_indicators.yaml` at prototype HEAD a596eb9. It is retained because @hti/scoring (the declared scoring SOT, weights/risk.weights.json @ 9b5d654) EMITS it via `emits_by_code` \u2014 scoring is ahead of the codebook here. Withdrawing it would break the scoring contract. File upstream for adoption into core_indicators.yaml.",
29873
- pendingUpstreamAdoption: true
29873
+ definition: "DEPRECATED 2026-10-06 \u2014 superseded by `debt_terms_deceptive` (136-049); the canonical catalog carries this key as a `legacy_alias` of that row and @hti/scoring 9c209cf no longer emits it. Retained read-only because PAVE 2.0 `develop` (IDA `IDA-syn-missing_care-4ii`, emits.ts) still writes it and assertions stored under this key must keep resolving. Original meaning: indication that, for a youth missing from care, the terms of a debt or its repayment differed from what was represented or expected. Youth-specific sibling of `debt_terms_deceptive`. Do not offer for new writes; bind the canonical key.",
29874
+ deprecated: true,
29875
+ supersededBy: "debt_terms_deceptive"
29874
29876
  },
29875
29877
  {
29876
29878
  code: "136-051-000-000-000-000-000",
@@ -30013,7 +30015,7 @@ var coreIndicators_v1_0_0_default = {
30013
30015
  selectable: true,
30014
30016
  parentCode: null,
30015
30017
  childCodes: [],
30016
- definition: "Ad-derived pricing tier indicates unusually low hourly price relative to local median, potentially signaling economic duress and vulnerability.",
30018
+ definition: `Ad-derived pricing tier is LOW-dominant \u2014 the person's parsed hourly rates fall under $50/hr against the pooled ad population (CVC-277 core-CS_price_tier_band; Sarah 2026-07-22 pooled baseline, about the bottom quartile) \u2014 potentially signaling economic duress and vulnerability. The SRS design framed this as "relative to the local median"; a per-market baseline is the refinement on record, not built.`,
30017
30019
  family: "unfamilied",
30018
30020
  polarity: "depends",
30019
30021
  severity: "informational",
@@ -32081,6 +32083,87 @@ TRA Phase 3 Batch B apply per recs doc \xA7 4.2 + Crysta Q-3 sign-off.`,
32081
32083
  polarity: "depends",
32082
32084
  severity: "caution",
32083
32085
  isAlert: "none"
32086
+ },
32087
+ {
32088
+ code: "136-217-000-000-000-000-000",
32089
+ key: "disclosed_fear_at_intake",
32090
+ title: "Disclosed fear of a specific person",
32091
+ selectable: true,
32092
+ parentCode: null,
32093
+ childCodes: [],
32094
+ definition: "The person has told a worker they are afraid of a named or identifiable individual \u2014 commonly a former or current partner. Distinct from concerning_mannerisms_anxious_fearful_depressed, which is affect a worker observes rather than something the person said, and from threats_of_harm, which requires a threat to have been made; fear can be current and well-founded with no fresh threat.",
32095
+ family: "lethality_dv",
32096
+ polarity: "increases_risk",
32097
+ severity: "elevated",
32098
+ isAlert: "thread_pave",
32099
+ alertWhen: "current_only"
32100
+ },
32101
+ {
32102
+ code: "136-218-000-000-000-000-000",
32103
+ key: "does_not_control_housing",
32104
+ title: "Limited independence: does not control where they live",
32105
+ selectable: true,
32106
+ parentCode: null,
32107
+ childCodes: [],
32108
+ definition: "Indication that an employer, partner, or other person decides where the person lives \u2014 housing is assigned or controlled by someone else, rather than chosen by the person.",
32109
+ family: "mechanism_control",
32110
+ polarity: "increases_risk",
32111
+ severity: "elevated",
32112
+ isAlert: "none"
32113
+ },
32114
+ {
32115
+ code: "136-219-000-000-000-000-000",
32116
+ key: "oppressive_home_life",
32117
+ title: "Oppressive, unsafe, or unstable home life",
32118
+ selectable: true,
32119
+ parentCode: null,
32120
+ childCodes: [],
32121
+ definition: "Indication that the person's current home life is oppressive, unsafe, or unstable \u2014 a present-condition vulnerability, distinct from the childhood household challenges history (VIII-B).",
32122
+ family: "vulnerability_context",
32123
+ polarity: "increases_risk",
32124
+ severity: "elevated",
32125
+ isAlert: "none"
32126
+ },
32127
+ {
32128
+ code: "136-220-000-000-000-000-000",
32129
+ key: "recent_separation",
32130
+ title: "Recent separation from abusive partner",
32131
+ selectable: true,
32132
+ parentCode: null,
32133
+ childCodes: [],
32134
+ definition: "Indication that the person has recently left or separated from an abusive partner. Campbell's Danger Assessment treats the period following separation as the highest-risk window for intimate-partner homicide \u2014 the signal is about having got out, not about current cohabitation.",
32135
+ family: "lethality_dv",
32136
+ polarity: "depends",
32137
+ severity: "elevated",
32138
+ isAlert: "thread_pave",
32139
+ alertWhen: "recency_under_year"
32140
+ },
32141
+ {
32142
+ code: "136-221-000-000-000-000-000",
32143
+ key: "survival_sex",
32144
+ title: "Survival sex (sex exchanged to meet basic needs)",
32145
+ selectable: true,
32146
+ parentCode: null,
32147
+ childCodes: [],
32148
+ definition: "Indication that the person exchanges sex acts to meet basic survival needs \u2014 housing, food, drugs, protection, or money for essentials \u2014 rather than as an income choice. A standalone activity signal that can coexist with, or exist entirely without, a trafficking determination; it asserts the circumstance of the exchange, never the determination.",
32149
+ family: "cs_industry_context",
32150
+ polarity: "depends",
32151
+ severity: "elevated",
32152
+ isAlert: "none"
32153
+ },
32154
+ {
32155
+ code: "136-222-000-000-000-000-000",
32156
+ key: "unable_to_speak_freely",
32157
+ title: "Unable to speak freely",
32158
+ selectable: true,
32159
+ parentCode: null,
32160
+ childCodes: [],
32161
+ definition: "Indication that the person is not able to speak for themselves \u2014 a third party insists on being present, answers on their behalf, or interprets for them, or the person is never encountered alone. Distinct from inability_to_account_for_self, which is about the person's own account being scripted or confused; this is about another party controlling the conversation.",
32162
+ family: "mechanism_control",
32163
+ polarity: "depends",
32164
+ severity: "elevated",
32165
+ isAlert: "thread_pave",
32166
+ alertWhen: "current_only"
32084
32167
  }
32085
32168
  ]
32086
32169
  };