// Type used to communicate the problem to be optimized to the serveur export type Skill = { id: number; name: string; isTeachable: boolean; isPreference: boolean; }; export type AssignementPair = { slotId: string; volonteerId: number; isFixed?: boolean; }; export type TimeslotRaw = { id: string; startTime: string; endTime: string; skillsId: Array; minAttendee: number; maxAttendee: number; }; export type VolonteerRaw = { id: number; skillsId: Array; }; export type MealSlot = { id: string; startTime: string; endTime: string; maxAttendee: number; }; export type SolverInput = { constraints: Array; mealAssignements: Array; volonteerList: Array; mealSlots: Array; timeslots: Array; assignements: Array; }; export type SolverOutput = { assignements: Array; message: string; score: string; explanation: string; }; export type JustificationObject = { type: "Assignement" | "MealAssignement" | "MealSlot"; slotId: string; volonteerId: number; }; export type HardConstraint = | "Meal not initialized" | "Timeslot not initialized" | "Volonteer conflict" | "Volonteer Meal conflict" | "Competence conflict" | "Meal max attendee"; export type ScoreExplanation = { [constraintName in HardConstraint]: Array>; };