# 运控算法输出参数模板。
# 算法工程师在完成求解后复制本文件，填写真实参数和质量结论。

schema_version: 1
session_id: replace_with_session_id
vehicle_id: replace_with_real_vehicle_id
chassis_type: ackermann
control_axis: combined
controller_algorithm: mpc
control_role: path_tracking_outer_loop
parameter_version: replace_with_control_parameter_version

estimated_params:
  # 单个 PID 回路。使用 PID 时必须明确 loop_name 和 control_axis。
  # loop_name 示例：speed / acceleration / heading / yaw_rate / steering_angle。
  pid:
    control_axis: longitudinal_control
    control_role: speed_loop
    loop_name: speed
    kp: 0.0
    ki: 0.0
    kd: 0.0
    has_integral_limit: false
    integral_limit: 0.0
    has_output_limit: false
    output_limit: 0.0
  # 如果 controller_algorithm=pid 且 control_axis=combined，应使用这个列表分别描述每个 PID 回路。
  pid_loops:
    - control_axis: longitudinal_control
      control_role: speed_loop
      loop_name: speed
      kp: 0.0
      ki: 0.0
      kd: 0.0
    - control_axis: lateral_control
      control_role: heading_loop
      loop_name: heading
      kp: 0.0
      ki: 0.0
      kd: 0.0
  lateral_mpc:
    prediction_horizon: 10
    control_horizon: 3
    model_dt_s: 0.05
    q_lateral: 1.0
    q_heading: 1.0
    r_steering: 1.0
    r_steering_rate: 1.0
    has_steering_limit_deg: false
    steering_limit_deg: 0.0
  longitudinal_mpc:
    prediction_horizon: 10
    control_horizon: 3
    model_dt_s: 0.05
    q_speed: 1.0
    q_accel: 1.0
    r_throttle: 1.0
    r_brake: 1.0
    r_jerk: 1.0
    has_throttle_limit: false
    throttle_limit: 0.0
    has_brake_limit: false
    brake_limit: 0.0
  lqr:
    q_state_weights:
      - 1.0
      - 1.0
    r_input_weights:
      - 1.0
    has_preview_time_s: false
    preview_time_s: 0.0
  pure_pursuit:
    lookahead_m: 1.0
    has_min_lookahead_m: false
    min_lookahead_m: 0.0
    has_max_lookahead_m: false
    max_lookahead_m: 0.0
    has_curvature_gain: false
    curvature_gain: 0.0
    has_steering_limit_deg: false
    steering_limit_deg: 0.0

quality:
  data_quality_passed: false
  suitable_for_commit: false
  auto_acceptance_passed: false
  validation_summary:
    rms_lateral_error_m: 0.0
    rms_heading_error_rad: 0.0
    rms_speed_error_ms: 0.0
    overshoot_ratio: 0.0
    settle_time_sec: 0.0
    stop_position_error_m: 0.0
    max_jerk: 0.0
    saturation_ratio: 0.0
  notes: replace_with_algorithm_notes
