IVR Task SequenceTask Sequence
Overview
A task sequence provides a mechanism to specify a particular sequence of tasks on a vehicle. The sequence may be used either as a pure evaluation (to identify points of infeasibility in a model) or to provide a starting point to the solver (if the task sequence is feasible). The solve request should be set in the mode corresponding to the desired usage (ReOptimise or Evaluate).
Applicable models
- IVR7
ivr7-kt461v8eoaif - IVR8
ivr8-yni1c9k2swof
Task Sequence
The task sequence defines a sequence of tasks to be performed by a particular vehicle. In the case of the IVR8 model, a sequence of compartment assignments for each task may be provided. Any tasks or compartments not defined within the model will result in an invalid payload response.
A list of task sequences are provided to the model corresponding to each vehicle. Vehicles which are not used in the desired evaluation (evaluate) or warm start (reoptimise) can either be provided with an empty task sequence or omitted entirely. An empty task sequence with an evaluate request corresponds to the solution cost of leaving all tasks unperformed.
Schema definition
message TaskSequence {
required string vehicleId = 1;
repeated string taskId = 2;
repeated string compartmentId = 3; // IVR 8 only.
}Fields
- vehicleId
- The identifier of the vehicle to which this task sequence pertains. An error is returned if the vehicle is not defined in the model.
- taskId
- The sequence of tasks which should be performed by the vehicle. In the case of an Evalute request, any infeasibilities incurred by the vehicle on the route are returned as part of the infeasibilities output structures along with the node and edge evaluations corresponding to the sequence. This allows users to verify which constraints are being broken in a particular model, and to what degree. In the case of a ReOptimise request, if the starting point is feasible, it is added to the candidate solution pool and the remainder of the optimisation routines are then applied. If the task sequence provided is feasible, the returned solution will be no greater than the input solution provided.
- compartmentId
- The compartment assignment corresponding to the sequence of tasks provided. If the compartmentId length is non-zero and not equal in length to the
taskIdlist, an error is returned. In an IVR8 model, a task sequence can be provided without a compartment sequence. In this instance, a search is conducted for a feasible compartment assignment given the task sequence (if the tasks can all be performed feasibly ignoring compartment constraints). If there is a feasible incumbent for the compartments given the task sequence, the compartment assignments will be returned as part of the solution response. If no feasible assignment of compartments exists within the prescribed task sequence, an infeasible response is returned (without identifying the point of infeasibility). If a compartment sequence consistent with the each task in thetaskIdlist is provided, then the points of infeasibility (if any) are returned as part of the standard infeasibilities response.
Examples
This example illustrates a task sequence for vehicle v-1 where it performs two pickups and two dropoffs (in the prescribed order). The pickup and dropoff names correspond to the task id’s within the model. As an example, it may be that there are two jobs in this example model, each with a single pickup and dropoff task.
vehicleId: "v-1"
taskId: "pickup-1"
taskId: "pickup-2"
taskId: "dropoff-1"
taskId: "dropoff-2"