{
  "$defs": {
    "AssessmentStatus": {
      "enum": [
        "pass",
        "warn",
        "fail",
        "not_assessed"
      ],
      "title": "AssessmentStatus",
      "type": "string"
    },
    "CandidateDecision": {
      "additionalProperties": false,
      "properties": {
        "actor_id": {
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
          "title": "Actor Id",
          "type": "string"
        },
        "candidate_id": {
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
          "title": "Candidate Id",
          "type": "string"
        },
        "decided_at_utc": {
          "maxLength": 40,
          "minLength": 20,
          "title": "Decided At Utc",
          "type": "string"
        },
        "decision_id": {
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
          "title": "Decision Id",
          "type": "string"
        },
        "evaluation_selection": {
          "anyOf": [
            {
              "$ref": "#/$defs/EvaluationSelectionReceipt"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "rationale": {
          "maxLength": 2000,
          "minLength": 1,
          "title": "Rationale",
          "type": "string"
        },
        "sequence": {
          "minimum": 1,
          "title": "Sequence",
          "type": "integer"
        },
        "status": {
          "$ref": "#/$defs/DecisionStatus"
        }
      },
      "required": [
        "decision_id",
        "sequence",
        "candidate_id",
        "status",
        "actor_id",
        "decided_at_utc",
        "rationale"
      ],
      "title": "CandidateDecision",
      "type": "object"
    },
    "CandidateDelta": {
      "additionalProperties": false,
      "properties": {
        "field_path": {
          "maxLength": 512,
          "minLength": 1,
          "pattern": "^[a-z][a-z0-9_]*(?:\\.[a-z0-9_]+|\\[[0-9]+\\])*$",
          "title": "Field Path",
          "type": "string"
        },
        "value": {
          "anyOf": [
            {
              "type": "boolean"
            },
            {
              "type": "integer"
            },
            {
              "type": "number"
            },
            {
              "type": "string"
            }
          ],
          "title": "Value"
        }
      },
      "required": [
        "field_path",
        "value"
      ],
      "title": "CandidateDelta",
      "type": "object"
    },
    "CandidateLedger": {
      "additionalProperties": false,
      "properties": {
        "candidates": {
          "default": [],
          "items": {
            "$ref": "#/$defs/CandidateRecord"
          },
          "title": "Candidates",
          "type": "array"
        },
        "contract_suite": {
          "const": "sindri.contracts",
          "default": "sindri.contracts",
          "title": "Contract Suite",
          "type": "string"
        },
        "contract_version": {
          "const": "1.0.0",
          "default": "1.0.0",
          "title": "Contract Version",
          "type": "string"
        },
        "decisions": {
          "default": [],
          "items": {
            "$ref": "#/$defs/CandidateDecision"
          },
          "title": "Decisions",
          "type": "array"
        },
        "evaluation_scope": {
          "anyOf": [
            {
              "$ref": "#/$defs/EvaluationDecisionScope"
            },
            {
              "$ref": "#/$defs/StudyDecisionScope"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Evaluation Scope"
        },
        "ledger_id": {
          "default": "ledger.design-candidates",
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
          "title": "Ledger Id",
          "type": "string"
        },
        "schema_kind": {
          "const": "candidate_ledger",
          "default": "candidate_ledger",
          "title": "Schema Kind",
          "type": "string"
        },
        "study_id": {
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
          "title": "Study Id",
          "type": "string"
        },
        "transitions": {
          "default": [],
          "items": {
            "$ref": "#/$defs/CandidateTransition"
          },
          "title": "Transitions",
          "type": "array"
        }
      },
      "required": [
        "study_id"
      ],
      "title": "CandidateLedger",
      "type": "object"
    },
    "CandidateLifecycle": {
      "enum": [
        "defined",
        "generated",
        "evaluated",
        "rejected",
        "eligible",
        "ranked",
        "proposed",
        "selected",
        "approved"
      ],
      "title": "CandidateLifecycle",
      "type": "string"
    },
    "CandidateRecord": {
      "additionalProperties": false,
      "properties": {
        "candidate_id": {
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
          "title": "Candidate Id",
          "type": "string"
        },
        "changes": {
          "default": [],
          "items": {
            "$ref": "#/$defs/CandidateDelta"
          },
          "title": "Changes",
          "type": "array"
        },
        "evaluation_binding": {
          "anyOf": [
            {
              "$ref": "#/$defs/EvaluationCandidateBinding"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "feasibility": {
          "$ref": "#/$defs/AssessmentStatus",
          "default": "not_assessed"
        },
        "issues": {
          "default": [],
          "items": {
            "$ref": "#/$defs/IssueRecord"
          },
          "title": "Issues",
          "type": "array"
        },
        "lifecycle": {
          "$ref": "#/$defs/CandidateLifecycle"
        },
        "objective_values": {
          "default": [],
          "items": {
            "$ref": "#/$defs/ObjectiveValue"
          },
          "title": "Objective Values",
          "type": "array"
        },
        "parent_candidate_id": {
          "anyOf": [
            {
              "maxLength": 128,
              "minLength": 1,
              "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Parent Candidate Id"
        },
        "rank": {
          "anyOf": [
            {
              "minimum": 1,
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Rank"
        },
        "result_ids": {
          "default": [],
          "items": {
            "maxLength": 128,
            "minLength": 1,
            "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
            "type": "string"
          },
          "title": "Result Ids",
          "type": "array"
        }
      },
      "required": [
        "candidate_id",
        "lifecycle"
      ],
      "title": "CandidateRecord",
      "type": "object"
    },
    "CandidateTransition": {
      "additionalProperties": false,
      "properties": {
        "actor_id": {
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
          "title": "Actor Id",
          "type": "string"
        },
        "candidate_id": {
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
          "title": "Candidate Id",
          "type": "string"
        },
        "from_lifecycle": {
          "$ref": "#/$defs/CandidateLifecycle"
        },
        "occurred_at_utc": {
          "maxLength": 40,
          "minLength": 20,
          "title": "Occurred At Utc",
          "type": "string"
        },
        "rationale": {
          "maxLength": 2000,
          "minLength": 1,
          "title": "Rationale",
          "type": "string"
        },
        "sequence": {
          "minimum": 1,
          "title": "Sequence",
          "type": "integer"
        },
        "to_lifecycle": {
          "$ref": "#/$defs/CandidateLifecycle"
        },
        "transition_id": {
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
          "title": "Transition Id",
          "type": "string"
        }
      },
      "required": [
        "transition_id",
        "sequence",
        "candidate_id",
        "from_lifecycle",
        "to_lifecycle",
        "actor_id",
        "occurred_at_utc",
        "rationale"
      ],
      "title": "CandidateTransition",
      "type": "object"
    },
    "DecisionStatus": {
      "enum": [
        "proposed",
        "selected",
        "approved",
        "rejected"
      ],
      "title": "DecisionStatus",
      "type": "string"
    },
    "EvaluationCandidateBinding": {
      "additionalProperties": false,
      "properties": {
        "assessment_sha256": {
          "pattern": "^[0-9a-f]{64}$",
          "title": "Assessment Sha256",
          "type": "string"
        },
        "selectable": {
          "title": "Selectable",
          "type": "boolean"
        },
        "source": {
          "$ref": "#/$defs/EvaluationSource"
        },
        "warning_check_ids": {
          "default": [],
          "items": {
            "maxLength": 128,
            "minLength": 1,
            "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
            "type": "string"
          },
          "title": "Warning Check Ids",
          "type": "array"
        }
      },
      "required": [
        "source",
        "assessment_sha256",
        "selectable"
      ],
      "title": "EvaluationCandidateBinding",
      "type": "object"
    },
    "EvaluationDecisionScope": {
      "additionalProperties": false,
      "properties": {
        "candidate_ids": {
          "items": {
            "maxLength": 128,
            "minLength": 1,
            "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
            "type": "string"
          },
          "maxItems": 100,
          "minItems": 1,
          "title": "Candidate Ids",
          "type": "array"
        },
        "comparison_sha256": {
          "pattern": "^[0-9a-f]{64}$",
          "title": "Comparison Sha256",
          "type": "string"
        },
        "context_sha256": {
          "pattern": "^[0-9a-f]{64}$",
          "title": "Context Sha256",
          "type": "string"
        },
        "evaluation_id": {
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
          "title": "Evaluation Id",
          "type": "string"
        },
        "manifest_sha256": {
          "pattern": "^[0-9a-f]{64}$",
          "title": "Manifest Sha256",
          "type": "string"
        },
        "policy_sha256": {
          "pattern": "^[0-9a-f]{64}$",
          "title": "Policy Sha256",
          "type": "string"
        },
        "recommended_candidate_ids": {
          "default": [],
          "items": {
            "maxLength": 128,
            "minLength": 1,
            "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
            "type": "string"
          },
          "title": "Recommended Candidate Ids",
          "type": "array"
        }
      },
      "required": [
        "evaluation_id",
        "manifest_sha256",
        "comparison_sha256",
        "policy_sha256",
        "context_sha256",
        "candidate_ids"
      ],
      "title": "EvaluationDecisionScope",
      "type": "object"
    },
    "EvaluationSelectionReceipt": {
      "additionalProperties": false,
      "properties": {
        "accepted_warning_check_ids": {
          "default": [],
          "items": {
            "maxLength": 128,
            "minLength": 1,
            "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
            "type": "string"
          },
          "title": "Accepted Warning Check Ids",
          "type": "array"
        },
        "expected_ledger_sha256": {
          "pattern": "^[0-9a-f]{64}$",
          "title": "Expected Ledger Sha256",
          "type": "string"
        },
        "request_id": {
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
          "title": "Request Id",
          "type": "string"
        }
      },
      "required": [
        "request_id",
        "expected_ledger_sha256"
      ],
      "title": "EvaluationSelectionReceipt",
      "type": "object"
    },
    "EvaluationSource": {
      "additionalProperties": false,
      "properties": {
        "artifact_index_sha256": {
          "pattern": "^[0-9a-f]{64}$",
          "title": "Artifact Index Sha256",
          "type": "string"
        },
        "candidate_id": {
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
          "title": "Candidate Id",
          "type": "string"
        },
        "contract_version": {
          "const": "1.0.0",
          "default": "1.0.0",
          "title": "Contract Version",
          "type": "string"
        },
        "input_snapshot_sha256": {
          "pattern": "^[0-9a-f]{64}$",
          "title": "Input Snapshot Sha256",
          "type": "string"
        },
        "manifest_sha256": {
          "pattern": "^[0-9a-f]{64}$",
          "title": "Manifest Sha256",
          "type": "string"
        },
        "result_index_sha256": {
          "pattern": "^[0-9a-f]{64}$",
          "title": "Result Index Sha256",
          "type": "string"
        },
        "run_id": {
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
          "title": "Run Id",
          "type": "string"
        }
      },
      "required": [
        "candidate_id",
        "run_id",
        "manifest_sha256",
        "input_snapshot_sha256",
        "result_index_sha256",
        "artifact_index_sha256"
      ],
      "title": "EvaluationSource",
      "type": "object"
    },
    "IssueRecord": {
      "additionalProperties": false,
      "properties": {
        "action_hint": {
          "anyOf": [
            {
              "maxLength": 1000,
              "minLength": 1,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Action Hint"
        },
        "code": {
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
          "title": "Code",
          "type": "string"
        },
        "issue_id": {
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
          "title": "Issue Id",
          "type": "string"
        },
        "message": {
          "maxLength": 2000,
          "minLength": 1,
          "title": "Message",
          "type": "string"
        },
        "severity": {
          "$ref": "#/$defs/IssueSeverity"
        },
        "source_path": {
          "anyOf": [
            {
              "maxLength": 512,
              "minLength": 1,
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Source Path"
        },
        "statement_ids": {
          "default": [],
          "items": {
            "maxLength": 128,
            "minLength": 1,
            "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
            "type": "string"
          },
          "title": "Statement Ids",
          "type": "array"
        }
      },
      "required": [
        "issue_id",
        "code",
        "severity",
        "message"
      ],
      "title": "IssueRecord",
      "type": "object"
    },
    "IssueSeverity": {
      "enum": [
        "info",
        "warning",
        "error"
      ],
      "title": "IssueSeverity",
      "type": "string"
    },
    "ObjectiveValue": {
      "additionalProperties": false,
      "properties": {
        "direction": {
          "enum": [
            "minimize",
            "maximize"
          ],
          "title": "Direction",
          "type": "string"
        },
        "metric_id": {
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
          "title": "Metric Id",
          "type": "string"
        },
        "normalized_score": {
          "anyOf": [
            {
              "maximum": 1.0,
              "minimum": 0.0,
              "type": "number"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Normalized Score"
        },
        "value": {
          "title": "Value",
          "type": "number"
        }
      },
      "required": [
        "metric_id",
        "value",
        "direction"
      ],
      "title": "ObjectiveValue",
      "type": "object"
    },
    "PlacementDiagnostics": {
      "additionalProperties": false,
      "properties": {
        "collision_pairs": {
          "default": [],
          "items": {
            "maxItems": 2,
            "minItems": 2,
            "prefixItems": [
              {
                "type": "string"
              },
              {
                "type": "string"
              }
            ],
            "type": "array"
          },
          "title": "Collision Pairs",
          "type": "array"
        },
        "face_occupancy_mass_kg": {
          "additionalProperties": {
            "type": "number"
          },
          "title": "Face Occupancy Mass Kg",
          "type": "object"
        },
        "rejected_candidates": {
          "default": [],
          "items": {
            "$ref": "#/$defs/PlacementRejectedCandidate"
          },
          "title": "Rejected Candidates",
          "type": "array"
        },
        "unplaced_components": {
          "default": [],
          "items": {
            "type": "string"
          },
          "title": "Unplaced Components",
          "type": "array"
        },
        "violated_constraints": {
          "default": [],
          "items": {
            "type": "string"
          },
          "title": "Violated Constraints",
          "type": "array"
        },
        "zone_occupancy": {
          "additionalProperties": {
            "additionalProperties": {
              "type": "integer"
            },
            "type": "object"
          },
          "title": "Zone Occupancy",
          "type": "object"
        }
      },
      "title": "PlacementDiagnostics",
      "type": "object"
    },
    "PlacementFaceScore": {
      "additionalProperties": false,
      "properties": {
        "nadir_penalty_cost": {
          "title": "Nadir Penalty Cost",
          "type": "number"
        },
        "pair_penalty": {
          "title": "Pair Penalty",
          "type": "number"
        },
        "sun_preference_cost": {
          "title": "Sun Preference Cost",
          "type": "number"
        },
        "total": {
          "title": "Total",
          "type": "number"
        }
      },
      "required": [
        "sun_preference_cost",
        "nadir_penalty_cost",
        "pair_penalty",
        "total"
      ],
      "title": "PlacementFaceScore",
      "type": "object"
    },
    "PlacementRecord": {
      "additionalProperties": false,
      "description": "Selected component placement in the spacecraft body frame.",
      "properties": {
        "aabb_size_m": {
          "anyOf": [
            {
              "maxItems": 3,
              "minItems": 3,
              "prefixItems": [
                {
                  "type": "number"
                },
                {
                  "type": "number"
                },
                {
                  "type": "number"
                }
              ],
              "type": "array"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Aabb Size M"
        },
        "adcs_wheel_cluster": {
          "anyOf": [
            {
              "type": "boolean"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Adcs Wheel Cluster"
        },
        "architecture_node_source": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Architecture Node Source"
        },
        "base_mass_kg": {
          "minimum": 0.0,
          "title": "Base Mass Kg",
          "type": "number"
        },
        "bracket_mass_kg": {
          "minimum": 0.0,
          "title": "Bracket Mass Kg",
          "type": "number"
        },
        "candidate_id": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Candidate Id"
        },
        "center_m": {
          "anyOf": [
            {
              "maxItems": 3,
              "minItems": 3,
              "prefixItems": [
                {
                  "type": "number"
                },
                {
                  "type": "number"
                },
                {
                  "type": "number"
                }
              ],
              "type": "array"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Center M"
        },
        "class_key": {
          "minLength": 1,
          "title": "Class Key",
          "type": "string"
        },
        "component": {
          "minLength": 1,
          "title": "Component",
          "type": "string"
        },
        "distribution_model": {
          "anyOf": [
            {
              "const": "bus_uniform_box",
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Distribution Model"
        },
        "emit_internal_records": {
          "anyOf": [
            {
              "type": "boolean"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Emit Internal Records"
        },
        "face": {
          "anyOf": [
            {
              "enum": [
                "+X",
                "-X",
                "+Y",
                "-Y",
                "+Z",
                "-Z",
                "DISTRIBUTED"
              ],
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Face"
        },
        "face_exposure_scores": {
          "anyOf": [
            {
              "additionalProperties": {
                "type": "number"
              },
              "type": "object"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Face Exposure Scores"
        },
        "fixed_panel_face_score": {
          "anyOf": [
            {
              "$ref": "#/$defs/PlacementFaceScore"
            },
            {
              "type": "null"
            }
          ],
          "default": null
        },
        "internal_wheel_axes_body": {
          "default": [],
          "items": {
            "maxItems": 3,
            "minItems": 3,
            "prefixItems": [
              {
                "type": "number"
              },
              {
                "type": "number"
              },
              {
                "type": "number"
              }
            ],
            "type": "array"
          },
          "title": "Internal Wheel Axes Body",
          "type": "array"
        },
        "internal_wheel_count": {
          "anyOf": [
            {
              "minimum": 1,
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Internal Wheel Count"
        },
        "internal_wheel_layout_mode": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Internal Wheel Layout Mode"
        },
        "mass_kg": {
          "minimum": 0.0,
          "title": "Mass Kg",
          "type": "number"
        },
        "mass_rule": {
          "minLength": 1,
          "title": "Mass Rule",
          "type": "string"
        },
        "mass_source": {
          "minLength": 1,
          "title": "Mass Source",
          "type": "string"
        },
        "mount_angle_deg": {
          "default": 0,
          "title": "Mount Angle Deg",
          "type": "integer"
        },
        "mount_id": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Mount Id"
        },
        "mount_role": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Mount Role"
        },
        "nominal_dims_m": {
          "anyOf": [
            {
              "maxItems": 3,
              "minItems": 3,
              "prefixItems": [
                {
                  "type": "number"
                },
                {
                  "type": "number"
                },
                {
                  "type": "number"
                }
              ],
              "type": "array"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Nominal Dims M"
        },
        "orthogonality_group": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Orthogonality Group"
        },
        "orthogonality_policy": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Orthogonality Policy"
        },
        "parent_component": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Parent Component"
        },
        "placement_tags": {
          "default": [],
          "items": {
            "type": "string"
          },
          "title": "Placement Tags",
          "type": "array"
        },
        "reason": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Reason"
        },
        "resolved_panel_area_fraction": {
          "anyOf": [
            {
              "minimum": 0.0,
              "type": "number"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Resolved Panel Area Fraction"
        },
        "resolved_panel_area_m2": {
          "anyOf": [
            {
              "minimum": 0.0,
              "type": "number"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Resolved Panel Area M2"
        },
        "resolved_panel_area_source": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Resolved Panel Area Source"
        },
        "resolved_panel_aspect_ratio": {
          "anyOf": [
            {
              "exclusiveMinimum": 0.0,
              "type": "number"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Resolved Panel Aspect Ratio"
        },
        "resolved_panel_aspect_ratio_candidates": {
          "default": [],
          "items": {
            "type": "number"
          },
          "title": "Resolved Panel Aspect Ratio Candidates",
          "type": "array"
        },
        "resolved_panel_aspect_ratio_source": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Resolved Panel Aspect Ratio Source"
        },
        "resolved_panel_candidate_count": {
          "anyOf": [
            {
              "minimum": 0,
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Resolved Panel Candidate Count"
        },
        "resolved_panel_candidate_index": {
          "anyOf": [
            {
              "minimum": 0,
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Resolved Panel Candidate Index"
        },
        "resolved_panel_size_source": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Resolved Panel Size Source"
        },
        "resolved_total_solar_array_area_m2": {
          "anyOf": [
            {
              "minimum": 0.0,
              "type": "number"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Resolved Total Solar Array Area M2"
        },
        "rotation_deg": {
          "anyOf": [
            {
              "maxItems": 3,
              "minItems": 3,
              "prefixItems": [
                {
                  "type": "number"
                },
                {
                  "type": "number"
                },
                {
                  "type": "number"
                }
              ],
              "type": "array"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Rotation Deg"
        },
        "score": {
          "anyOf": [
            {
              "type": "number"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Score"
        },
        "search_repair": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Search Repair"
        },
        "shape_type": {
          "minLength": 1,
          "title": "Shape Type",
          "type": "string"
        },
        "size_fallback_model": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Size Fallback Model"
        },
        "size_m": {
          "anyOf": [
            {
              "maxItems": 3,
              "minItems": 3,
              "prefixItems": [
                {
                  "type": "number"
                },
                {
                  "type": "number"
                },
                {
                  "type": "number"
                }
              ],
              "type": "array"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Size M"
        },
        "size_rule": {
          "minLength": 1,
          "title": "Size Rule",
          "type": "string"
        },
        "size_source": {
          "minLength": 1,
          "title": "Size Source",
          "type": "string"
        },
        "stage_order": {
          "minimum": 0,
          "title": "Stage Order",
          "type": "integer"
        },
        "status": {
          "enum": [
            "placed",
            "unplaced",
            "distributed"
          ],
          "title": "Status",
          "type": "string"
        },
        "subsystem_key": {
          "minLength": 1,
          "title": "Subsystem Key",
          "type": "string"
        },
        "template_source": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Template Source"
        },
        "zone_id": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Zone Id"
        }
      },
      "required": [
        "component",
        "class_key",
        "subsystem_key",
        "stage_order",
        "mass_kg",
        "base_mass_kg",
        "bracket_mass_kg",
        "status",
        "mass_source",
        "mass_rule",
        "size_rule",
        "size_source",
        "shape_type"
      ],
      "title": "PlacementRecord",
      "type": "object"
    },
    "PlacementRejectedCandidate": {
      "additionalProperties": false,
      "properties": {
        "candidate_id": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Candidate Id"
        },
        "component": {
          "minLength": 1,
          "title": "Component",
          "type": "string"
        },
        "face": {
          "enum": [
            "+X",
            "-X",
            "+Y",
            "-Y",
            "+Z",
            "-Z"
          ],
          "title": "Face",
          "type": "string"
        },
        "mount_angle_deg": {
          "anyOf": [
            {
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Mount Angle Deg"
        },
        "mount_id": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Mount Id"
        },
        "reasons": {
          "items": {
            "type": "string"
          },
          "minItems": 1,
          "title": "Reasons",
          "type": "array"
        },
        "size_candidate_aspect_ratio": {
          "anyOf": [
            {
              "exclusiveMinimum": 0.0,
              "type": "number"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "title": "Size Candidate Aspect Ratio"
        },
        "size_candidate_index": {
          "minimum": 0,
          "title": "Size Candidate Index",
          "type": "integer"
        },
        "zone_id": {
          "minLength": 1,
          "title": "Zone Id",
          "type": "string"
        }
      },
      "required": [
        "component",
        "zone_id",
        "face",
        "size_candidate_index",
        "reasons"
      ],
      "title": "PlacementRejectedCandidate",
      "type": "object"
    },
    "PlacementSearchStats": {
      "additionalProperties": false,
      "properties": {
        "branch_pruned": {
          "minimum": 0,
          "title": "Branch Pruned",
          "type": "integer"
        },
        "fallback_used": {
          "title": "Fallback Used",
          "type": "boolean"
        },
        "nodes_evaluated": {
          "minimum": 0,
          "title": "Nodes Evaluated",
          "type": "integer"
        }
      },
      "required": [
        "nodes_evaluated",
        "fallback_used",
        "branch_pruned"
      ],
      "title": "PlacementSearchStats",
      "type": "object"
    },
    "StudyDecisionScope": {
      "additionalProperties": false,
      "properties": {
        "candidate_ids": {
          "items": {
            "maxLength": 128,
            "minLength": 1,
            "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
            "type": "string"
          },
          "maxItems": 1024,
          "minItems": 1,
          "title": "Candidate Ids",
          "type": "array"
        },
        "comparison_sha256": {
          "pattern": "^[0-9a-f]{64}$",
          "title": "Comparison Sha256",
          "type": "string"
        },
        "context_sha256": {
          "pattern": "^[0-9a-f]{64}$",
          "title": "Context Sha256",
          "type": "string"
        },
        "evaluation_id": {
          "maxLength": 128,
          "minLength": 1,
          "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
          "title": "Evaluation Id",
          "type": "string"
        },
        "manifest_sha256": {
          "pattern": "^[0-9a-f]{64}$",
          "title": "Manifest Sha256",
          "type": "string"
        },
        "policy_sha256": {
          "pattern": "^[0-9a-f]{64}$",
          "title": "Policy Sha256",
          "type": "string"
        },
        "recommended_candidate_ids": {
          "default": [],
          "items": {
            "maxLength": 128,
            "minLength": 1,
            "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
            "type": "string"
          },
          "title": "Recommended Candidate Ids",
          "type": "array"
        },
        "scope_kind": {
          "const": "study",
          "default": "study",
          "title": "Scope Kind",
          "type": "string"
        },
        "shortlist_candidate_ids": {
          "items": {
            "maxLength": 128,
            "minLength": 1,
            "pattern": "^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$",
            "type": "string"
          },
          "maxItems": 4,
          "minItems": 1,
          "title": "Shortlist Candidate Ids",
          "type": "array"
        }
      },
      "required": [
        "evaluation_id",
        "manifest_sha256",
        "comparison_sha256",
        "policy_sha256",
        "context_sha256",
        "candidate_ids",
        "shortlist_candidate_ids"
      ],
      "title": "StudyDecisionScope",
      "type": "object"
    }
  },
  "$id": "urn:sindri:contracts:1.0.0:placement-result",
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "additionalProperties": false,
  "description": "Canonical placement outcome; solver search state remains private.",
  "properties": {
    "available_volume_m3": {
      "exclusiveMinimum": 0.0,
      "title": "Available Volume M3",
      "type": "number"
    },
    "bus_dimensions_m": {
      "maxItems": 3,
      "minItems": 3,
      "prefixItems": [
        {
          "type": "number"
        },
        {
          "type": "number"
        },
        {
          "type": "number"
        }
      ],
      "title": "Bus Dimensions M",
      "type": "array"
    },
    "candidate_ledgers": {
      "default": [],
      "items": {
        "$ref": "#/$defs/CandidateLedger"
      },
      "title": "Candidate Ledgers",
      "type": "array"
    },
    "cg_body_m": {
      "maxItems": 3,
      "minItems": 3,
      "prefixItems": [
        {
          "type": "number"
        },
        {
          "type": "number"
        },
        {
          "type": "number"
        }
      ],
      "title": "Cg Body M",
      "type": "array"
    },
    "coordinate_frame": {
      "const": "spacecraft_body",
      "default": "spacecraft_body",
      "title": "Coordinate Frame",
      "type": "string"
    },
    "deployment_state": {
      "const": "stowed",
      "default": "stowed",
      "title": "Deployment State",
      "type": "string"
    },
    "diagnostics": {
      "$ref": "#/$defs/PlacementDiagnostics"
    },
    "inertia_about_cg_body_kg_m2": {
      "maxItems": 3,
      "minItems": 3,
      "prefixItems": [
        {
          "maxItems": 3,
          "minItems": 3,
          "prefixItems": [
            {
              "type": "number"
            },
            {
              "type": "number"
            },
            {
              "type": "number"
            }
          ],
          "type": "array"
        },
        {
          "maxItems": 3,
          "minItems": 3,
          "prefixItems": [
            {
              "type": "number"
            },
            {
              "type": "number"
            },
            {
              "type": "number"
            }
          ],
          "type": "array"
        },
        {
          "maxItems": 3,
          "minItems": 3,
          "prefixItems": [
            {
              "type": "number"
            },
            {
              "type": "number"
            },
            {
              "type": "number"
            }
          ],
          "type": "array"
        }
      ],
      "title": "Inertia About Cg Body Kg M2",
      "type": "array"
    },
    "packaging_margin_m3": {
      "title": "Packaging Margin M3",
      "type": "number"
    },
    "passed": {
      "title": "Passed",
      "type": "boolean"
    },
    "payload_kind": {
      "const": "placement",
      "default": "placement",
      "title": "Payload Kind",
      "type": "string"
    },
    "payload_version": {
      "const": "1.0.0",
      "default": "1.0.0",
      "title": "Payload Version",
      "type": "string"
    },
    "records": {
      "items": {
        "$ref": "#/$defs/PlacementRecord"
      },
      "title": "Records",
      "type": "array"
    },
    "search_mode_used": {
      "enum": [
        "greedy",
        "lookahead"
      ],
      "title": "Search Mode Used",
      "type": "string"
    },
    "search_stats": {
      "$ref": "#/$defs/PlacementSearchStats"
    },
    "selected_topology_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Selected Topology Id"
    },
    "topology_candidate_ledger": {
      "anyOf": [
        {
          "$ref": "#/$defs/CandidateLedger"
        },
        {
          "type": "null"
        }
      ],
      "default": null
    },
    "used_volume_m3": {
      "minimum": 0.0,
      "title": "Used Volume M3",
      "type": "number"
    }
  },
  "required": [
    "records",
    "diagnostics",
    "cg_body_m",
    "inertia_about_cg_body_kg_m2",
    "bus_dimensions_m",
    "used_volume_m3",
    "available_volume_m3",
    "packaging_margin_m3",
    "passed",
    "search_mode_used",
    "search_stats"
  ],
  "title": "PlacementResultPayload",
  "type": "object",
  "x-sindri-contract-suite": "sindri.contracts",
  "x-sindri-contract-version": "1.0.0"
}
