{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "urn:animsmith:schema:foot-cycle-member-evidence:1",
  "title": "AnimSmith foot-cycle member evidence V1",
  "type": "object",
  "additionalProperties": false,
  "required": ["schema", "schema_version", "tool", "command", "member_index", "member_id", "paths", "manifest_input", "parameterization_input", "source", "output", "operation", "proof_policy", "proof", "resources"],
  "properties": {
    "schema": {"const": "urn:animsmith:schema:foot-cycle-member-evidence:1"},
    "schema_version": {"const": 1},
    "tool": {"$ref": "#/$defs/tool"},
    "command": {"const": "collection-transform-foot-cycle"},
    "member_index": {"type": "integer", "minimum": 0, "maximum": 4095},
    "member_id": {"type": "string", "minLength": 1, "maxLength": 255},
    "paths": {"$ref": "#/$defs/paths"},
    "manifest_input": {"$ref": "#/$defs/identity"},
    "parameterization_input": {"$ref": "#/$defs/identity"},
    "source": {"$ref": "#/$defs/source"},
    "output": {"$ref": "#/$defs/output"},
    "operation": {"$ref": "#/$defs/identity"},
    "proof_policy": {"$ref": "#/$defs/policy"},
    "proof": {"$ref": "#/$defs/proof"},
    "resources": {"$ref": "#/$defs/resources"}
  },
  "$defs": {
    "identity": {"type": "object", "additionalProperties": false, "required": ["sha256", "bytes"], "properties": {"sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}, "bytes": {"type": "integer", "minimum": 0, "maximum": 9007199254740991}}},
    "tool": {"type": "object", "additionalProperties": false, "required": ["name", "version", "source"], "properties": {"name": {"const": "animsmith"}, "version": {"type": "string", "minLength": 1}, "source": {"type": "object", "additionalProperties": false, "required": ["revision", "dirty"], "properties": {"revision": {"type": ["string", "null"], "pattern": "^[0-9a-fA-F]{40}$"}, "dirty": {"type": ["boolean", "null"]}}}}},
    "paths": {"type": "object", "additionalProperties": false, "required": ["artifact", "contact_fragment", "evidence"], "properties": {"artifact": {"type": "string", "pattern": "^members/[0-9]{6}/artifact\\.glb$"}, "contact_fragment": {"type": "string", "pattern": "^members/[0-9]{6}/contact-fragment\\.json$"}, "evidence": {"type": "string", "pattern": "^members/[0-9]{6}/evidence\\.json$"}}},
    "source": {"type": "object", "additionalProperties": false, "required": ["source_key", "artifact", "dependency_closure_identity"], "properties": {"source_key": {"type": "string", "minLength": 1, "maxLength": 4096}, "artifact": {"$ref": "#/$defs/identity"}, "dependency_closure_identity": {"$ref": "#/$defs/identity"}, "config": {"$ref": "#/$defs/identity"}}},
    "output": {"type": "object", "additionalProperties": false, "required": ["artifact", "dependency_closure_identity", "contact_fragment", "independently_detected_contact_fragment"], "properties": {"artifact": {"$ref": "#/$defs/identity"}, "dependency_closure_identity": {"$ref": "#/$defs/identity"}, "contact_fragment": {"$ref": "#/$defs/identity"}, "independently_detected_contact_fragment": {"$ref": "#/$defs/identity"}}},
    "policy": {"type": "object", "additionalProperties": false, "required": ["max_gait_phase_spread", "min_lr_amplitude_m", "max_contact_boundary_phase_error"], "properties": {"max_gait_phase_spread": {"type": "number", "minimum": 0, "maximum": 0.5}, "min_lr_amplitude_m": {"type": "number", "minimum": 0}, "max_contact_boundary_phase_error": {"type": "number", "minimum": 0, "maximum": 0.5}}},
    "proof": {"type": "object", "additionalProperties": false, "required": ["duration_s", "gait_phase", "lr_amplitude_m", "max_contact_boundary_phase_error", "root_endpoint_displacement_x_m", "root_endpoint_displacement_z_m", "root_accumulated_yaw_deg", "max_loop_position_delta_m", "max_loop_rotation_delta_deg", "max_loop_velocity_delta_mps", "max_loop_angular_velocity_delta_degps"], "properties": {"duration_s": {"type": "number", "exclusiveMinimum": 0}, "gait_phase": {"type": "number", "minimum": 0, "maximum": 1}, "lr_amplitude_m": {"type": "number", "minimum": 0}, "max_contact_boundary_phase_error": {"type": "number", "minimum": 0, "maximum": 0.5}, "root_endpoint_displacement_x_m": {"type": "number"}, "root_endpoint_displacement_z_m": {"type": "number"}, "root_accumulated_yaw_deg": {"type": "number"}, "max_loop_position_delta_m": {"type": "number", "minimum": 0}, "max_loop_rotation_delta_deg": {"type": "number", "minimum": 0}, "max_loop_velocity_delta_mps": {"type": "number", "minimum": 0}, "max_loop_angular_velocity_delta_degps": {"type": "number", "minimum": 0}}},
    "resources": {"type": "object", "additionalProperties": false, "required": ["artifact_bytes", "contact_fragment_bytes"], "properties": {"artifact_bytes": {"type": "integer", "minimum": 1, "maximum": 268435456}, "contact_fragment_bytes": {"type": "integer", "minimum": 1, "maximum": 8388608}}}
  }
}
