# description
JSON Schema for compiled WPL (Wellness Plan Language) output.

# $defs.AthleteThresholds.description
Optional reference values for the target athlete that resolve relative-intensity targets (HR zones, %FTP, %1RM) into absolute numbers downstream.

# $defs.MuscleGroup.description
Controlled vocabulary for muscle groups. Lets analytics tools compute weekly sets per muscle (Schoenfeld-style volume tracking) without an out-of-band exercise→muscle map.

# $defs.MovementPattern.description
Functional movement-pattern taxonomy. Useful for balanced-program checks (e.g. push:pull ratio).

# $defs.Contraindication.properties.condition.description
Free-form condition tag. For clinical use, prefer a recognized prefix so consumers can match deterministically:
  • 'icd10:<code>' — ICD-10-CM (e.g. 'icd10:O09' = supervision of high-risk pregnancy)
  • 'snomed:<concept-id>' — SNOMED CT (e.g. 'snomed:248152002' = low back pain)
  • 'acsm:<category>' — ACSM Guidelines (e.g. 'acsm:cardiac_rehab_phase_2')
  • 'acog:<id>' — ACOG opinions (e.g. 'acog:pregnancy_t2')
Unprefixed strings are allowed for non-clinical content (e.g. 'lower_back_injury') but cannot be deterministically matched.

# $defs.Contraindication.properties.severity.description
Optional clinical-risk tier (mirrors the ACSM low/moderate/high stratification). Lets consumers triage required actions: 'low' may proceed with standard plan, 'moderate' may require modification, 'high' typically requires medical clearance before exercise.

# $defs.Contraindication.properties.action.description
What to do when this contraindication applies.
  • 'exclude' — drop the affected activities from the compiled plan.
  • 'modify' — replace or down-regulate the affected activities (consumer policy).
  • 'require_clearance' — gate plan execution on documented medical clearance (consumer is expected to surface a clearance prompt and check 'user.clearance_obtained' before progressing).

# $defs.PersonalizationInput.properties.source.description
Where this input value comes from. Recognized prefixes:
  • user.* — static profile fields (user.age, user.experience_level, user.injuries, user.equipment.barbell)
  • wellness.* — daily/recent telemetry (wellness.sleep_hours_last_night, wellness.hrv_rmssd_morning, wellness.session_rpe_yesterday, wellness.subjective_readiness, wellness.menstrual_phase)
  • device.* — wearable-derived metrics (device.steps_today, device.battery_drain_24h)
  • plan.* — plan-state queries (plan.current_phase_type, plan.day_index_in_phase)
Unrecognized prefixes are allowed but consumers may ignore them.

# $defs.PhaseType.description
Optional periodization role of a phase. Lets consuming tools surface where in a cycle the user is (e.g. 'Deload week' badges, fatigue plots).

# $defs.Week.properties.is_deload.description
Optional flag marking a deload week. Independent of Phase.type so individual deload weeks can be tagged inside any phase.

# $defs.SubPlanActivity.description
Activity that includes another plan by reference. Lets a workout reuse a 'warmup plan' or compose larger sessions from smaller plans. Resolution is the consumer's responsibility (validators emit CYCLIC_SUBPLAN if a self-reference or known cycle is detected).

# $defs.SubPlanActivity.properties.sub_plan_ref.description
Identifier of another WPL plan. Resolution is performed by the consumer; validators only check it's a non-empty string and that the reference is not the containing plan's own id (CYCLIC_SUBPLAN).

# $defs.ExercisePrescription.properties.to_failure.description
When true, the prescription is performed to momentary muscular failure. Mutually informative with target_rir=0; consumers should treat them as equivalent stop criteria.

# $defs.Reps.properties.amrap.description
When true, the set is performed as 'as many reps as possible' to a stop criterion (target_rir, target_rpe, or to_failure). target/min/max may be omitted or used as guidance.

# $defs.Tempo.description
Lifting tempo. Either the conventional 4-digit string (e.g. "3-1-1-0" or "30X1" where X = explosive) for human authoring, or a structured object that tools can compute time-under-tension from. Phases are eccentric (lowering), pause at bottom, concentric (lifting), pause at top — all in seconds.

# $defs.Tempo.oneOf[].properties.explosive_concentric.description
When true, concentric is intent-maximal regardless of the numeric value (corresponds to the 'X' character in 4-digit notation).

# $defs.Weight.oneOf[].properties.metric.description
Reference metric for percentage_1rm. '1RM' = tested 1-rep max, 'e1RM' = estimated 1RM (formula or velocity-derived), 'training_max' = % of 1RM commonly used as program ceiling (e.g. 90% in 5/3/1), 'daily_max' = today's auto-regulated max. Ignored when type is 'absolute' or 'percentage_bodyweight'.

# $defs.CardioPrescription.properties.intensity.properties.target.description
Intensity target. Recognized fields by intensity.type:
  • heart_rate_zone: { zone: integer } or { min_bpm, max_bpm }
  • bpm: { min_bpm, max_bpm }
  • power: { zone: integer } or { min_watts, max_watts }
  • pace: { value: number, unit: 'min_per_km' | 'min_per_mi' | 'm_per_s' | 'sec_per_100m' }
  • rpe: { min: number, max: number } on the scale matched by zone_model (rpe_borg_10 or rpe_borg_20)

# $defs.CardioPrescription.properties.intensity.properties.zone_model.description
Disambiguates which zone numbering system the target uses. Recommended whenever type is heart_rate_zone, power, or pace.

# $defs.CardioPrescription.properties.intervals.properties.work.oneOf[].properties.duration.description
Work-bout duration in seconds. Deprecated bare-number form — prefer the {value, unit} object for consistency with the rest of the schema.

# $defs.CardioPrescription.properties.intervals.properties.rest.oneOf[].properties.duration.description
Rest-bout duration in seconds. Deprecated bare-number form — prefer the {value, unit} object.

# $defs.NutritionPrescription.properties.calories.properties.unit.description
Optional unit qualifier. Defaults to absolute kcal. 'kcal_per_kg' scales by body weight; 'multiplier_of_tdee' lets a plan say 'eat 0.8–1.0× TDEE' independent of athlete-specific TDEE.

# $defs.MacroRange.description
Macronutrient range. 'g' = absolute grams; 'g_per_kg' = grams per kg of body weight (preferred for evidence-based prescriptions, e.g. 1.6–2.2 g/kg/day protein per Morton 2018).

# $defs.RecoveryExercise.properties.modality.description
Recovery technique. 'static_stretch' = passive hold; 'dynamic_stretch' = active ROM; 'pnf' = proprioceptive neuromuscular facilitation (use the 'pnf' block); 'smr_foam_roll' / 'smr_ball' = self-myofascial release; 'breathwork' = breathing protocol; 'mobility_drill' = active mobility.

# $defs.RecoveryExercise.properties.intensity_rpe.description
Subjective stretch/work intensity on the 1–10 RPE-style scale. Useful for static_stretch (target ~6–7 for ROM gains) and SMR (target ~5–7).

# $defs.RecoveryExercise.properties.pnf.description
PNF contract-relax parameters. Required when modality='pnf'.

# $defs.RecoveryExercise.properties.body_part.description
Free-text body region (e.g. 'thoracic_spine', 'piriformis'). Use MuscleGroup values where applicable.

# $defs.Progress.properties.streaks.description
Streak tracking config; shape TBD in v1.x.

# $defs.Checkpoint.properties.measurements.description
What to measure at this checkpoint. Items can be a free string (back-compat with 1.0–1.5 plans) or a typed MeasurementSpec for analytics-grade comparability.

# $defs.MeasurementSpec.properties.unit.description
Optional unit override. Each MeasurementMetric carries an implied canonical unit (see enum description); set this only to override or disambiguate.

# $defs.MeasurementMetric.description
Standardized measurement vocabulary. Canonical units in parentheses.
  • body_weight_kg (kg) • waist_cm (cm) • hip_cm (cm) • body_fat_pct (%) • lean_mass_kg (kg)
  • resting_hr_bpm (bpm) • hrv_rmssd_ms (ms) • blood_pressure_systolic_mmhg (mmHg) • blood_pressure_diastolic_mmhg (mmHg)
  • vo2max_ml_kg_min (mL/kg/min) • six_min_walk_m (m) • cooper_test_m (m)
  • one_rm_kg (kg, requires exercise_ref via note) • grip_strength_kg (kg) • vertical_jump_cm (cm)
  • sit_and_reach_cm (cm) • shoulder_flexion_deg (deg)
  • sleep_hours_avg (h) • session_rpe_avg (1-10)
  • questionnaire_score (numeric, paired with the 'questionnaire' field)
  • photo (string ref) • free_text (free)

# $defs.Questionnaire.description
Validated self-report instrument when metric is 'questionnaire_score'. Consumers pair the resulting numeric score with this enum to interpret cutoffs.