fix(insights): add chart tokens for v1.25 clinical measurement types

The PHQ-9 / GAD-7 screener totals and the physical clinical measures
(grip strength, pain NRS, waist circumference, waist-to-height) are
continuous numeric series. Register their metric:<TYPE> tokens so the
chart-token drift guard passes and the AI insight prose can reference
them through the generic chart renderer.
This commit is contained in:
Marc-André Bombeck committed 2026-06-28 16:15:48 +02:00
1 parent 8b1cccbfce
commit 2563690e4b
1 file changed
+10
+10
View File
@@ -127,6 +127,16 @@ export const ALLOWED_CHART_TOKENS = [
// v1.19.0 — Oura resilience. A continuous daily ordinal series (1–5), so it
// carries a `metric:<TYPE>` token and renders through the generic chart.
"metric:RESILIENCE",
// v1.25.0 — clinical signals. Mental-health screener totals (PHQ-9 0–27,
// GAD-7 0–21) and the physical clinical measures are continuous numeric
// series, so each carries a `metric:<TYPE>` token and renders through the
// generic chart.
"metric:PHQ9_SCORE",
"metric:GAD7_SCORE",
"metric:GRIP_STRENGTH",
"metric:PAIN_NRS",
"metric:WAIST_CIRCUMFERENCE",
"metric:WAIST_TO_HEIGHT",
] as const;
export type ChartToken = (typeof ALLOWED_CHART_TOKENS)[number];