Method and device for staff scheduling in area, electronic equipment and storage medium

By obtaining and analyzing employee portraits, combining the demand information of the types of work hours to be allocated and the scheduling constraints, the target scheduling line segment is determined, which solves the problem of uneven employee arrangements in multiple physical areas, and achieves efficient and reasonable employee scheduling.

CN119918823APending Publication Date: 2025-05-02SHENGDOUSHI SHANGHAI SCI & TECH DEV CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311441994.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-10-31
Publication Date
2025-05-02

AI Technical Summary

Technical Problem

In areas of multiple entities, due to different levels of busyness and idleness, some entity employees are insufficient and some entity employees are over-arranged. The existing technology cannot effectively solve this problem.

Method used

By obtaining employee portraits, including the employee's entity, scheduling logos, work skills and proficiency scores, candidate shift scheduling segments are obtained based on employee portraits and preset shift scheduling rules, and the target shift scheduling segments are determined based on the work hours to be allocated and shift scheduling constraints.

Benefits of technology

It realizes the automatic schedule of employee shifts for all entities in the area from a global perspective, improves employee utilization, meets the working hours needs of each entity, and improves the efficiency, rationality and fairness of scheduling.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119918823A_ABST
    Figure CN119918823A_ABST
Patent Text Reader

Abstract

The invention provides a method and a device for staff scheduling in a region, electronic equipment, a storage medium and a computer program product. The method comprises the following steps: acquiring staff portraits of a first type of staff and a second type of staff; obtaining a plurality of candidate scheduling line segments corresponding to each employee in the first type of employees and the second type of employees based on the employee portrait, the to-be-allocated man-hour types of the plurality of entities and a preset scheduling rule; obtaining respective demand information of a plurality of to-be-allocated man-hour types of a plurality of entities; and determining a target scheduling line segment corresponding to each employee in the first type of employees and the second type of employees based on the plurality of candidate scheduling line segments, the respective demand information of the plurality of to-be-allocated man-hour types, and one or more of preset scheduling constraint conditions.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of computer technology, in particular to the field of data processing, and specifically to a method, device, electronic device, computer-readable storage medium, and computer program product for scheduling employees in a region. Background Art

[0002] In the related art, each entity assigns work to its employees through manual scheduling according to its business needs. For the convenience of management, each entity only assigns work to its employees independently. However, for multiple entities in a specified area, since the busyness of multiple entities may be different, there is a problem that in certain time periods, the employees of some entities may be too busy to be used, and the employees of some entities may be too idle to be fully utilized.

[0003] The methods described in this section are not necessarily methods that have been previously conceived or employed. Unless otherwise indicated, it should not be assumed that any method described in this section is considered to be prior art simply because it is included in this section. Similarly, unless otherwise indicated, the issues mentioned in this section should not be considered to have been recognized in any prior art. Summary of the invention

[0004] The present disclosure provides a method, an apparatus, an electronic device, a computer-readable storage medium, and a computer program product for scheduling employees in a region.

[0005] According to one aspect of the present disclosure, a method for scheduling employees in a region is provided, wherein the region includes multiple entities, the multiple entities include a first type of employees and a second type of employees, the first type of employees cannot be scheduled between the multiple entities, and the second type of employees can be scheduled between the multiple entities, the method comprising: obtaining employee portraits of the first type of employees and the second type of employees, the employee portraits including the entity to which the employee belongs, a scheduling identifier, and the employee's work skills and proficiency scores thereof, the scheduling identifier being used to characterize whether the employee can be scheduled between the multiple entities, and the proficiency score being used to characterize the employee's proficiency in the work skills; and multiple The type of working hours to be allocated and the preset scheduling rules respectively obtain multiple candidate scheduling segments corresponding to each employee of the first type of employees and the second type of employees, and one candidate scheduling segment corresponding to each employee includes the entity where the employee works and the type of working hours allocated in each time period of multiple continuous time periods, and the employee's work skills correspond to the multiple types of working hours to be allocated; obtain the demand information of each of the multiple types of working hours to be allocated of the multiple entities; and based on the multiple candidate scheduling segments, the demand information of each of the multiple types of working hours to be allocated, and one or more of the preset scheduling constraints, determine the target scheduling segment corresponding to each employee of the first type of employees and the second type of employees.

[0006] According to another aspect of the present disclosure, a device for scheduling employees in a region is provided, wherein the region includes multiple entities, the multiple entities include a first type of employees and a second type of employees, the first type of employees cannot be scheduled between the multiple entities, and the second type of employees can be scheduled between the multiple entities, and the device includes: a first acquisition unit, configured to acquire employee portraits of the first type of employees and the second type of employees, the employee portraits including the entity to which the employee belongs, a scheduling identifier, and the employee's work skills and proficiency scores thereof, the scheduling identifier being used to characterize whether the employee can be scheduled between the multiple entities, and the proficiency score being used to characterize the employee's proficiency in the work skills; a second acquisition unit, configured to acquire employee portraits of the first type of employees and the second type of employees based on the employee portraits, the multiple entities, and the scheduling identifier; The method comprises the following steps: obtaining a plurality of candidate scheduling segments corresponding to each employee of the first type of employees and the second type of employees based on the types of working hours to be allocated and the preset scheduling rules, wherein the candidate scheduling segment corresponding to each employee includes the entity for which the employee works and the type of working hours allocated in each time period in multiple continuous time periods, and the working skills of the employee correspond to the plurality of types of working hours to be allocated; a third acquisition unit is configured to obtain the respective demand information of the plurality of types of working hours to be allocated of the plurality of entities; and a first selection unit is configured to determine the target scheduling segment corresponding to each employee of the first type of employees and the second type of employees based on the plurality of candidate scheduling segments, the respective demand information of the plurality of types of working hours to be allocated, and one or more of the preset scheduling constraints.

[0007] According to another aspect of the present disclosure, an electronic device is provided, comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the above-mentioned method for employee scheduling.

[0008] According to another aspect of the present disclosure, a computer-readable storage medium storing computer instructions is provided, wherein the computer instructions are used to enable the computer to execute the above-mentioned method for employee scheduling.

[0009] According to another aspect of the present disclosure, a computer program product is provided, including a computer program, wherein the computer program implements the above-mentioned method for employee scheduling when executed by a processor.

[0010] According to one or more embodiments of the present disclosure, the busyness and idleness of multiple entities (e.g., restaurants) in a specified area at different times and the employee human resources situation are considered from a global perspective, and employee shifts for all entities in the specified area are automatically scheduled, thereby improving employee utilization and meeting the various working hours requirements of each entity, ultimately improving the efficiency, rationality and fairness of employee scheduling.

[0011] It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present disclosure, nor is it intended to limit the scope of the present disclosure. Other features of the present disclosure will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS

[0012] The accompanying drawings exemplarily illustrate the embodiments and constitute a part of the specification, and together with the text description of the specification, are used to explain the exemplary implementation of the embodiments. The embodiments shown are for illustrative purposes only and do not limit the scope of the claims. In all drawings, the same reference numerals refer to similar but not necessarily identical elements.

[0013] Figure 1 A flowchart of a method for scheduling employees in a region according to an exemplary embodiment of the present disclosure is shown;

[0014] Figure 2 A flowchart showing the method in step 140 according to some exemplary embodiments of the present disclosure;

[0015] Figure 3 A structural block diagram of a device for scheduling employees in a region according to an exemplary embodiment of the present disclosure is shown;

[0016] Figure 4 A block diagram of an electronic device according to an embodiment of the present disclosure is shown. DETAILED DESCRIPTION

[0017] The following is a description of exemplary embodiments of the present disclosure in conjunction with the accompanying drawings, including various details of the embodiments of the present disclosure to facilitate understanding, which should be considered as merely exemplary. Therefore, it should be recognized by those of ordinary skill in the art that various changes and modifications may be made to the embodiments described herein without departing from the scope of the present disclosure. Similarly, for the sake of clarity and conciseness, the description of well-known functions and structures is omitted in the following description.

[0018] In the present disclosure, unless otherwise specified, the use of the terms "first", "second", etc. to describe various elements is not intended to limit the positional relationship, timing relationship, or importance relationship of these elements, and such terms are only used to distinguish one element from another element. In some examples, the first element and the second element may refer to the same instance of the element, and in some cases, based on the description of the context, they may also refer to different instances.

[0019] The terms used in the description of various examples in this disclosure are only for the purpose of describing specific examples and are not intended to be limiting. Unless the context clearly indicates otherwise, if the number of elements is not specifically limited, the element can be one or more. In addition, the term "and / or" used in this disclosure covers any one of the listed items and all possible combinations.

[0020] In the present disclosure, multiple entities within a region include but are not limited to restaurants, shopping malls, factories and other workplaces. These entities include multiple employees and a variety of different work tasks that employees need to perform. Taking restaurants as an example, when there are multiple restaurants in a designated area, the busyness of each restaurant may be different at different times, resulting in insufficient staff in some restaurants and excessive staff in others. In the related art, employees of multiple restaurants in a region are scheduled manually. Manual scheduling cannot improve the overall manpower utilization rate, so its efficiency and rationality need to be improved. In addition, human factors will also lead to unfair schedule results.

[0021] To solve the above problems, the present disclosure provides a method for scheduling employees in a region, which determines the target scheduling segment corresponding to each employee of the first type of employees and the second type of employees based on multiple candidate scheduling segments, the demand information of each of the multiple types of working hours to be allocated, and one or more of the preset scheduling constraints. The method considers the busyness and idleness of multiple entities (e.g., restaurants) in a specified area at different time periods and the employee human resources situation from a global perspective, and automatically schedules the employee schedules of all entities in the specified area, thereby improving the personnel utilization rate of employees, while meeting the needs of various types of working hours of each entity, and ultimately improving the efficiency, rationality and fairness of employee scheduling.

[0022] The embodiments of the present disclosure will be described in detail below with reference to the accompanying drawings.

[0023] Figure 1A flow chart of a method 100 for scheduling employees in a region according to an exemplary embodiment of the present disclosure is shown. The region includes multiple entities (the multiple entities may be, for example, multiple restaurants, multiple shopping malls, multiple factories, etc.), and each of the multiple entities may include a first type of employee and a second type of employee. The first type of employee is configured to be unable to be scheduled between multiple entities, while the second type of employee is configured to be able to be scheduled between multiple entities. Various details of the method 100 are further described below using a restaurant as an example, but it should be understood that the method 100 can also be used in other usage scenarios (e.g., shopping malls, factories, etc.).

[0024] In some embodiments of the present disclosure, multiple entities within a designated area may be shared restaurants that can share employees, and multiple restaurants within the designated area whose distances are less than a threshold distance and whose busyness is complementary may be arranged as shared restaurants. A first type of employee may be a core employee in the restaurant to which they belong, so the first type of employee is configured to work only in the restaurant to which they belong; a second type of employee may be a shared employee in the restaurant to which they belong, so the second type of employee is configured to work both in the restaurant to which they belong and in other shared restaurants within the designated area.

[0025] Continue to refer Figure 1 ,like Figure 1 As shown, the method 100 for scheduling employees in a region may include the following steps:

[0026] Step 110: Obtain employee portraits of the first type of employees and the second type of employees, the employee portraits including the entity to which the employee belongs, the scheduling identifier, and the employee's work skills and proficiency scores. The scheduling identifier is used to indicate whether the employee can be scheduled between multiple entities, and the proficiency score is used to indicate the employee's proficiency in the work skills.

[0027] Step 120: Based on the employee portrait, multiple types of working hours to be allocated of multiple entities and the preset scheduling rules, multiple candidate scheduling segments corresponding to each employee of the first type of employees and the second type of employees are respectively obtained, and a candidate scheduling segment corresponding to each employee includes the entity where the employee works and the type of working hours allocated in each time period of multiple continuous time periods, and the employee's work skills correspond to the multiple types of working hours to be allocated.

[0028] Step 130: Obtain demand information of multiple types of man-hours to be allocated for multiple entities.

[0029] Step 140: Determine a target scheduling segment corresponding to each employee of the first type of employees and the second type of employees based on multiple candidate scheduling segments, demand information of each of multiple types of working hours to be allocated, and one or more of the preset scheduling constraints.

[0030] In some embodiments of the present disclosure, in step 110, the entity to which the employee belongs is uniquely determined, that is, each first-type employee and each second-type employee has a corresponding specific restaurant (for example, registered or enrolled in the specific restaurant).

[0031] In some embodiments of the present disclosure, in step 110, the first type of employee may have a dispatch identification indicating that the employee cannot be shared among multiple restaurants in the region, and the second type of employee may have a dispatch identification indicating that the employee can be shared among multiple restaurants in the region. Therefore, the dispatch identification of the first type of employee is different from the dispatch identification of the second type of employee.

[0032] In some embodiments of the present disclosure, in step 110, when the entity is a restaurant, the employee's work skills may include grilling wings, making pizza, making hamburgers, washing dishes, sweeping the floor, wiping tables, etc. The employee's proficiency score for work skills can be used to characterize the employee's proficiency / work efficiency for different jobs.

[0033] In some embodiments of the present disclosure, in step 110, the input employee portrait may be obtained through a terminal device, or the employee portrait may be read from a memory of the terminal device.

[0034] In some embodiments of the present disclosure, in step 120, multiple types of working hours to be allocated of multiple entities can represent multiple work tasks that employees need to go to work to complete in multiple restaurants, and the multiple types of working hours to be allocated can include one or more of the first working hour type, the second working hour type, the third working hour type, and the fourth working hour type. The first working hour type needs to be completed within a fixed time period and has a specific working hour length; the second working hour type only has a specific working hour length and does not need to be completed within a fixed time period; the third working hour type is associated with a specific employee (for example, only assigned to novice employees) and has a specific working hour length; the fourth working hour type has a specific working hour length and occurs corresponding to the third working hour type. In addition, the fourth working hour type does not need to be associated with a specific employee. It should be understood that the "first", "second", "third", and "fourth" related to the working hour type in the present disclosure are not intended to limit the positional relationship, temporal relationship, or importance relationship of these elements, but are only used to distinguish one working hour type from another working hour type. The attributes and characteristics of these working hour types will be described in more detail below.

[0035] In some embodiments of the present disclosure, in step 120, the scheduling rules may include at least one of the employee's rest time in the entity to which they belong, the rest time across entities, the number of shifts, and the work time type connection rules. The employee's rest time in the entity to which they belong may refer to the employee's rest time between working time periods (i.e., "shifts") when cross-restaurant scheduling does not occur. The rest time can be reasonably configured according to the employee's shift time and work intensity, so that the employee gets a suitable rest time when cross-restaurant scheduling does not occur. The employee's cross-entity rest time may refer to the employee's rest time between working time periods (i.e., "shifts") when cross-restaurant scheduling occurs. In addition to considering the employee's shift time and work intensity, the rest time also needs to consider the employee's commuting time required across restaurants, so that the employee gets a suitable rest time when cross-restaurant scheduling occurs. The number of shifts represents the number of consecutive time periods of the work time type to be assigned. It is necessary to avoid allocating too few or too many shifts to employees, because too few shifts will cause employees to work long hours, while too many shifts will cause employees to take too many breaks, which will adversely affect the continuity of work. The work time type connection rule represents the connection relationship between adjacent work time types. For example, after completing the task of making hamburgers, employees can perform the task of making pizza, but after completing the task of sweeping the floor, employees cannot perform the task of making pizza (due to hygiene and other issues).

[0036] According to some embodiments of the present disclosure, based on scheduling rules including at least one of the employee's rest time in the entity to which they belong, the rest time across entities, the number of shifts, and the working hour type connection rules, the scheduling results obtained by method 100 can ensure that the employees have sufficient rest, improve the work efficiency of the employees, and meet the work task requirements of each restaurant, thereby making the scheduling results more reasonable.

[0037] In some embodiments of the present disclosure, in step 120, the candidate scheduling segments corresponding to the employee may be determined based on the employee's shift time, the employee's work skills, the demand information of each of the multiple types of working hours to be allocated, the scheduling rules, and whether the employee can be scheduled between the multiple entities. The employee's shift time may be provided for each day, for example, but not limited to, that is, the employee's shift time may indicate the time period when the employee can go to work on a certain day (for example, one or more of 7:00 to 12:00, 13:00 to 17:00, and 18:00 to 24:00). For a first type of employee s among multiple first type employees, at least one candidate scheduling segment corresponding to the employee may be obtained based on the employee's employee portrait, the multiple types of working hours to be allocated of the entity to which the employee belongs, and the preset scheduling rules. The steps of generating multiple candidate scheduling segments for the first type of employees are as follows:

[0038] Step 1: According to the shift time of the first type employee s, traverse each unit time period in all available unit time periods W(s) of the first type employee s in turn, and generate possible work tasks for the first type employee s in the unit time period t based on the work time type requirements of the restaurant to which the first type employee s belongs in the unit time period t and the skill set SK(s) of the first type employee s. In one example, the unit time period can be 0.5 hours, so the 24 hours of a day can be evenly divided into 48 unit time periods. It should be understood that the unit time period is not limited to 0.5 hours, for example, it can also be set to 45 minutes, 1 hour, 1.5 hours, 2 hours, etc. As an example, the skills in the skill set SK(s) include but are not limited to grilling wings, making pizza, making hamburgers, washing dishes, sweeping the floor, wiping tables, etc.

[0039] Step 2: After generating the work tasks for unit time period t, in the next available unit time period t+1, based on the working hour type requirements of the restaurant to which the first type employee s belongs in the available unit time period and the skills SK(s) of the first type employee s, and taking into account the working hour type connection rules and the principle of stable continuity of work tasks (i.e. avoiding arranging too many different types of work for employees within a period of time), generate the possible work tasks for the first type employee s in the unit time period t+1.

[0040] Step 3: Repeat step 2 for the remaining available unit time periods of the first type employee s until a candidate scheduling line segment that meets the length requirement is generated, that is, all available unit time periods of the first type employee s have been traversed. Among them, the rest task of the first type employee s can be generated in the appropriate available unit time period. In addition, for the first type employee s, any subset of the available unit time periods in his available unit time period W(s) that meets the shortest working time must have a task line segment generated, that is, the working time of the first type employee s needs to be greater than or equal to the shortest working time, so as to avoid waste of human resources.

[0041] Finally, a candidate scheduling line segment for the first type of employee s can be represented as a list of length T. When the unit time period is 0.5 hours, the length T of the list is 48. The following shows a part of the exemplary list in this case (including only part of the unit time period), [......0, 0, 0, j 1 , j 1 , j 1 , j 2 , j 2 , j 2 , j 2 , j 2 , j 2 ,0,0,j 2 , j 2 , j2 , j 2 , j 2 , j 2 , j 2 , j 2 , j 2 , j 2 , 0, 0, ...] where 0 represents rest, j 1 、j 2 represents the task type generated in the corresponding unit time period, J = {j 1 , j 2 , ...} represents the set of tasks required by the restaurant described by the employee, and is also the set of skills that the employee possesses. It can be seen that part of the exemplary list includes two shifts (i.e., two consecutive working time periods), and the first shift includes a task type of j. 1 and j 2 The next shift includes tasks of type j. 2 For work of 1 hour, the rest period between two shifts is 1 hour.

[0042] Since the first type of employee s may have multiple skills and the restaurant to which the first type of employee s belongs may have multiple work hours requirements in different time periods, multiple candidate scheduling segments for the first type of employee s can be obtained by repeating the above steps. The number of the multiple candidate scheduling segments is not limited and can be hundreds or thousands.

[0043] After performing similar operations on other first-type employees of the restaurant, a plurality of candidate shift scheduling segments specific to each of the other first-type employees can be obtained similarly.

[0044] For the second type of employees, since the second type of employees are configured to be dispatched between multiple shared restaurants in the area, it is necessary to consider the task requirements of multiple shared restaurants in the area when generating multiple candidate scheduling segments for the second type of employees (rather than only considering the task requirements of the restaurant to which the second type of employees belongs). * , generating the second type of employee s * The steps of finding multiple candidate scheduling segments are as follows:

[0045] Step 1: According to the second type of employees * The shift time of the second type of employees s * Each unit time period in all available unit time periods W(s) is based on the working time type requirements of multiple shared restaurants in the region in unit time period t and the second type of employees s * Skills SK(s * ), generate the second type of employees s* Possible work tasks in unit time period t. Second type of employee s * The unit time period and skill set SK(s*) can be similar to that of the first type of employee s.

[0046] Step 2: After generating the work tasks for the unit time period t, in the next available unit time period t+1, based on the work time type requirements of multiple shared restaurants in the area in the available unit time period and the second type of employees s * Skills SK(s * ), and considering the working time type connection rules and the principle of stable continuity of work tasks (i.e. avoiding assigning too many different types of work to employees within a period of time), the second type of employees s * Possible work tasks in unit time period t+1. When generating cross-restaurant tasks, due to the commuting consumption, it is necessary to * Allow adequate rest time.

[0047] Step 3: For the second type of employees * Repeat step 2 for the remaining available unit time periods until a candidate scheduling line segment that meets the length requirement is generated, i.e., the second type of employee s * All available unit time periods have been traversed. Among them, the second type of employees s can be generated in the appropriate available unit time period * In addition, for the second type of employees s * , any subset of his available unit time period W(s) that meets the shortest working time must have a task line segment generated, that is, the second type of employee s * The working hours need to be greater than or equal to the minimum working hours to avoid waste of human resources.

[0048] Finally, Type 2 employees * A candidate scheduling line segment can be represented as a list of length T. When the unit time period is 0.5 hours, the length T of the list is 48. The following shows a part of the exemplary list in this case (only part of the unit time period is included).

[0049] [......0,0,0,j 1,r1 , j 2,r1 , j 2,r1 , j 2,r1 ,0,0,j 2,r2 , j 2,r2 , j 2,r2 , j 2,r2 , j 2,r2 ,0,0,,......]

[0050] Where 0 represents rest, j 1 、j 2 Represents the type of tasks generated in the corresponding unit time period, r 1 、r 2 represents different restaurants in a specified area that can share employees, R = {r 1 , r 2 , ...} represents a set of shared restaurants in the region. It can be seen that part of the exemplary list contains two shifts (i.e., two consecutive working time periods), and the first shift is arranged in restaurant r 1 , and includes task type j 1 and j 2 The next shift was arranged in the restaurant. 2 , and includes task type j 2 The rest time between two shifts is 1 hour, which can still guarantee the employees' rest time after deducting the employees' commuting time.

[0051] Since the second type of employees * The second type of employees may have multiple skills and take into account that multiple shared restaurants in a designated area may have different work hours requirements at different time periods. * The number of candidate scheduling segments of may exceed the number of candidate scheduling segments of the first type of employees s.

[0052] After performing similar operations on other second-type employees of the restaurant, a plurality of candidate shift scheduling segments specific to each of the other second-type employees can be obtained similarly.

[0053] According to some embodiments of the present disclosure, based on the employee's shift time, the employee's work skills, the demand information of each of the multiple types of work hours to be allocated, the scheduling rules, and whether the employee can be scheduled between the multiple entities, the multiple candidate scheduling segments determined are more reasonable and diverse, thereby providing a basis for the subsequent determination of the target scheduling segments. In addition, multiple candidate scheduling segments corresponding to each employee of the first type of employees and the second type of employees are generated in different ways, thereby improving the utilization rate of the first type of employees and the second type of employees, so that human resources can flow efficiently in multiple shared restaurants.

[0054] In some embodiments of the present disclosure, in step 130, the requirement information of each of the multiple types of work time to be allocated may include the required work time length and / or preset working time period of the type of work time to be allocated. The preset time period indicates that a certain type of work time must be completed within a certain time period.

[0055] Figure 2A flowchart of the method in step 140 according to some exemplary embodiments of the present disclosure is shown.

[0056] In some embodiments of the present disclosure, step 140, based on multiple candidate scheduling segments, demand information of each of multiple types of working hours to be allocated, and one or more of the preset scheduling constraints, determining the target scheduling segment corresponding to each of the first type of employees and the second type of employees may include the following steps:

[0057] Step 142: construct an integer programming model based on the input information, the integer programming model including a planning objective, a decision variable, and a preset scheduling constraint. The input information includes a plurality of candidate scheduling segments and demand information of a plurality of types of working hours to be allocated. The planning objective is used to indicate the conditions that need to be met for allocating a target scheduling segment to each employee of the first type of employees and the second type of employees. The decision variable includes a first decision variable for indicating whether each candidate scheduling segment of at least one candidate scheduling segment corresponding to each employee is selected.

[0058] Step 144: Solve the integer programming model based on the planning objectives and the preset scheduling constraints to obtain the distribution value of the first decision variable. The target scheduling line segment corresponding to each employee of the first type of employees and the second type of employees is determined based on the distribution value of the first decision variable.

[0059] In some embodiments of the present disclosure, integer programming refers to that the variables (all or part) in the programming are restricted to integers. A special case thereof is 0-1 programming, that is, the decision variables can only take values ​​of 0 or 1.

[0060] By solving the integer programming model based on the planning objectives and preset scheduling constraints, the corresponding target scheduling segments for each employee of the first type of employees and the second type of employees are obtained, and automatic personnel scheduling can be achieved, thereby improving the efficiency and rationality of working hour type arrangement and personnel arrangement while meeting the different working hour type requirements of each restaurant.

[0061] In some embodiments of the present disclosure, step 110, respectively obtaining multiple candidate scheduling segments corresponding to each employee of the first type of employees and the second type of employees based on the employee portrait, multiple types of working hours to be allocated of the multiple entities, and the preset scheduling rules may include: for each employee of the first type of employees and the second type of employees, respectively obtaining at least one candidate scheduling segment corresponding to the employee based on the employee portrait of the employee, multiple types of working hours to be allocated, and the preset scheduling rules. The method for generating multiple candidate scheduling segments for the first type of employees and the second type of employees may refer to the method described above. In addition, the preset scheduling constraint may include, for each employee of the first type of employees and the second type of employees, selecting at most one candidate scheduling segment from at least one candidate scheduling segment corresponding to the employee as the target scheduling segment corresponding to the employee. The preset scheduling constraint may be expressed by the following formula (1):

[0062]

[0063] Among them, L s represents the set of candidate scheduling segments generated by employee s, which includes multiple candidate scheduling segments corresponding to employee s. l represents the set of candidate scheduling segments of employee s L s A candidate scheduling line segment in . ls The first decision variable representing the candidate scheduling line segment l corresponding to employee s, whose value is 0 or 1. ls When the value of is 0, it means that a candidate scheduling line segment l generated by employee s is not selected. ls When the value of is 1, it means that the candidate scheduling line segment l generated by employee s is selected. When the summation term on the left side of the formula is equal to 1, it means that a candidate scheduling line segment of employee s is selected, and the employee needs to go to work on that day. When the summation term on the left side of the formula is equal to 0, it means that all candidate scheduling lines of employee s are not selected, and the employee does not need to go to work on that day.

[0064] According to some embodiments of the present disclosure, by selecting at most one candidate scheduling segment for each employee from at least one candidate scheduling segment corresponding to the employee as the target scheduling segment corresponding to the employee, the work assigned to the employee on that day will not conflict, and the same employee will not be scheduled to work in different restaurants at the same time, thereby improving the accuracy and efficiency of scheduling.

[0065] In some embodiments of the present disclosure, the type of working hours to be allocated may include rest working hours (as shown by "0" in the aforementioned list of length T). In method 100, the input information may also include quality scores of multiple candidate scheduling segments. The quality score is used to characterize the unreasonableness of the candidate scheduling segment. The quality score is related to at least one of the working hours of the employee in the candidate scheduling segment, the rest time in the entity to which it belongs, the rest time across entities, the relationship between the employee and the entity, the number of times the employee crosses entities, and the matching degree between the employee and the candidate scheduling segment. The matching degree between the employee and the candidate scheduling segment is at least related to the proficiency score of the employee corresponding to the type of working hours allocated to multiple consecutive time periods in the candidate scheduling segment and the relationship between the employee and the entity. Among them, the proficiency score of the employee for work skills includes a first proficiency score when working in the entity to which it belongs and a second proficiency score when not working in the entity. Since the employee is more familiar with the entity to which it belongs, the first proficiency score is configured to be greater than the second proficiency score. The higher the proficiency score, the higher the matching degree between the employee and the candidate scheduling segment.

[0066] In the case where the entity is a restaurant, the quality score of the scheduling line segment can be determined by the following logic: Taking employee s as an example, first, each candidate scheduling line segment of employee s has a basic score b 0 If the employee's working hours exceed the predetermined maximum working hours, the penalty value increases by p 1 If the employee's rest time exceeds the maximum rest time, the penalty value increases by p 2 If the employee's inter-restaurant rest time exceeds the scheduled maximum inter-restaurant rest time, the penalty value increases by p 3 ; If all the work tasks in the candidate scheduling line segment are arranged in the restaurant to which employee s belongs, the penalty value is reduced by q 1 (i.e., avoid unnecessary cross-restaurant scheduling to save employees’ time and energy); if the number of cross-restaurants of an employee exceeds the maximum number of cross-restaurants, the penalty value increases by p 4 ; If the work tasks in the candidate scheduling line segment are assigned to employees with high task proficiency, the penalty value is reduced by q 2 , you can use f srj To represent the proficiency score of employee s for job skill j in restaurant r, the proficiency of the same employee s for the same task j in different restaurants may be different (for example, the proficiency score in the restaurant to which the employee belongs may be higher than that in other restaurants). Therefore, the quality score c of the candidate scheduling line segment l of employee s is ls It can be expressed by the following formula (2):

[0067] c ls =b 0 +p 1 +p 2 +p 3 -q1 +p 4 -q 2 (2)

[0068] Quality fraction c ls The higher the value, the higher the penalty value of the candidate scheduling segment l, and the more unreasonable the candidate scheduling segment l is. Therefore, when selecting the target scheduling segment, we should consider the overall situation (considering both different employees and different candidate scheduling segments for the same employee), and try to avoid selecting candidate scheduling segments with high quality scores.

[0069] In this embodiment of the present disclosure, under the premise that the preset scheduling constraint condition is to select at most one candidate scheduling segment for each employee from at least one candidate scheduling segment corresponding to the employee as the target scheduling segment corresponding to the employee, the planning goal includes reducing the quality score of the target scheduling segment corresponding to each employee of the first type of employees and the second type of employees. The planning goal can be expressed by the following formula (3):

[0070]

[0071] Among them, S r represents the set of employees of restaurant r, U r S r represents the set of employees of all restaurants in the specified area (where U represents the union operation), and s represents the set U r S r Specific employees in s, L s represents the set of candidate scheduling segments generated by employee s, and l represents the set of candidate scheduling segments of employee s. s A candidate scheduling line segment in ls represents the first decision variable of the candidate scheduling line segment l corresponding to employee s, c ls Represents the quality score of the candidate scheduling segment l of employee s.

[0072] According to some embodiments of the present disclosure, by reducing the quality score of the target scheduling segment corresponding to each employee of the first type of employees and the second type of employees, the quality score of the target scheduling segment of all employees can be minimized globally, thereby eliminating unreasonable candidate scheduling segments.

[0073] In some embodiments of the present disclosure, for each of the multiple entities, the work time type to be allocated may include a first work time type, and the demand information of the first work time type may include a first preset time period corresponding to the first work time type and a required first preset work time duration. In some examples, taking restaurant r as an example, the first work time type A may be expressed as A={a 1r , a 2r , ..}, a itrUsed to indicate the specific working hours type a in restaurant r ir The quantity demanded in time period t, a itr ≥0 and a itr ∈Z (Z represents an integer). Based on the restaurant’s product sales estimate, a itr As an example, the first work hour type A may include specific work hour types such as making hamburgers and making pizza. Taking making hamburgers as an example, based on the sales volume of hamburgers of restaurant r on that day, restaurant r needs to complete the workload of making hamburgers of a preset work hour length (in the example where the preset time period is 7:00 to 9:00, the preset work hour length is 2 hours) within a preset time period (e.g., 7:00 to 9:00).

[0074] In this embodiment of the present disclosure, the input information may also include a first penalty parameter p1 when the first work time type is not assigned in the restaurant r. i The decision variables may include a second decision variable z1 for indicating the length of the working hours of the first working hour type that are not assigned in the restaurant r. itr , the second decision variable z1 itr Indicates the specific working time type a ir The unscheduled working time in time period t, z1 itr ≥0 and z1 itr ∈Z. At this time, the preset scheduling constraint condition may include that the first preset working hours required for the first working hours type in restaurant r is equal to the sum of the working hours of the unallocated first working hours type and the working hours of the allocated first working hours type, and the working hours of the allocated first working hours type can be obtained based on the target scheduling line segment. The preset scheduling constraint condition can be expressed by the following formula (4):

[0075]

[0076] Among them, z1 itr represents the second decision variable, S r represents the set of employees of restaurant r, U r S r represents the set of employees of all restaurants in the specified area (where U represents the union operation), and s represents the set U r S r Specific employees in s, L s represents the set of candidate scheduling segments generated by employee s, and l represents the set of candidate scheduling segments of employee s. s A candidate scheduling line segment in itr Indicates the specific working time type a ir The demand in time period t, M1 = (M1 litr) is a three-dimensional coefficient matrix. The elements in this high-dimensional matrix are composed of 0 and 1, which indicates the relationship between the candidate scheduling line segment and the first working time type A. The elements in the matrix represent:

[0077]

[0078] At this time, the planning goal may include reducing the product of the first penalty parameter and the assigned value of the second decision variable. The planning goal may be expressed by the following formula (5):

[0079]

[0080] Where A represents the first working time type (which may include multiple specific working time types a ir ), a ir represents a specific working time type in set A in restaurant r, t represents the preset time period, T represents the total working time period, R represents the set of shared restaurants in the region, p1 i represents the first penalty parameter, z1 itr represents the second decision variable.

[0081] According to some embodiments of the present disclosure, by reducing the product of the first penalty parameter and the assigned value of the second decision variable, the demand for the first working hour type can be met as much as possible from a global perspective, thereby reducing the adverse impact of insufficient workload of the first working hour type.

[0082] In some embodiments of the present disclosure, for each of the multiple entities, the work time type to be allocated may include a second work time type, and the demand information of the second work time type includes a second preset work time length required for the second work time type. In some examples, taking restaurant r as an example, the second work time type B can be expressed as B={b 1r , b 2r , ..}, b ir Used to indicate specific working time type b ir The demand, b ir ≥0 and b ir ∈Z. It should be noted that, unlike the first work time type with a first preset time period and a required first preset working time length, the second work time type does not need to be completed within the preset time period, so there is no t in the subscript of the relevant parameters of the second work time type. As an example, the second work time type B may include specific work time types such as washing dishes, sweeping the floor, and wiping the table. Taking washing dishes as an example, the work of washing dishes does not need to be completed within the preset time period, but only needs to be done by the employee in the time outside the first work time type.

[0083] In this embodiment of the present disclosure, the input information may also include a second penalty parameter p2 when the second work time type is not assigned. iThe decision variables include a third decision variable z2 for indicating the length of the working hours of the second working hours type that is not allocated ir , the third decision variable z2 ir Indicates the specific working time type b ir The unscheduled working hours for the day, z2 ir ≥0 and z2 ir ∈Z. At this time, the preset scheduling constraint condition may include that the second preset working hours required for the second working hours type is equal to the sum of the working hours of the unallocated second working hours type and the working hours of the allocated second working hours type. The working hours of the allocated second working hours type can be obtained based on the target scheduling line segment. The preset scheduling constraint condition can be expressed by the following formula (6):

[0084]

[0085] Among them, z2 ir represents the third decision variable, S r represents the set of employees of restaurant r, U r S r represents the set of employees of all restaurants in the specified area (where U represents the union operation), and s represents the set U r S r Specific employees in s, L s represents the set of candidate scheduling segments generated by employee s, and l represents the set of candidate scheduling segments of employee s. s A candidate scheduling line segment in ls represents the first decision variable of the candidate scheduling line segment l corresponding to employee s, b ir Indicates the specific working time type b ir The demand on that day, CV = (CV lir ) is a two-dimensional coefficient matrix, and the elements CV in the matrix lir Represents the specific working hours type b of restaurant r arranged in line segment l ir Working hours, CV lir ≥0 and CV lir ∈Z.

[0086] At this time, the planning goal may include reducing the product of the second penalty parameter and the assigned value of the third decision variable. The planning goal may be expressed by the following formula (7):

[0087]

[0088] Wherein, B represents the second working time type (which may include multiple specific working time types b ir ), b ir represents a specific working time type in set B, R represents the set of shared restaurants in the region, p2 irepresents the second penalty parameter, z2 ir represents the third decision variable.

[0089] According to some embodiments of the present disclosure, by reducing the product of the second penalty parameter and the assigned value of the third decision variable, the demand for the second working hour type can be met as much as possible from a global perspective, thereby reducing the adverse impact of insufficient workload of the second working hour type.

[0090] In some embodiments of the present disclosure, for each of the multiple entities, the working hours type to be allocated may also include a third working hours type and a fourth working hours type. The third working hours type is associated with a specific employee. For example, the third working hours type is obtained based on a given configuration, which may be the training hours for trainee employees (e.g., new employees who are unfamiliar with the business). Therefore, the third working hours type needs to be specifically allocated to trainee employees who are not proficient in work skills. The demand information for the third working hours type may include the second preset time period corresponding to the third working hours type and the required third preset working hours duration. In some examples, taking restaurant r as an example, the third working hours type D can be expressed as D={d 1r , d 2r , ..}, Used to indicate employees in training 0 For specific working time types i The amount of demand (e.g., training duration), and That is to say, trained employees 0 Need to go through After the workload training, the employees can master the skills they have been trained for. It should be noted that the third working hours type does not need to be completed within a preset time period, but only needs to be carried out for specific employees (i.e., trained employees). Therefore, the subscripts of the relevant parameters of the third working hours type only have i and s. 0 And there is no t. As an example, the third working hour type may include but is not limited to specific work tasks such as grilling wings, making pizza, making hamburgers, washing dishes, sweeping the floor, and wiping tables. The fourth working hour type is associated with the third working hour type. For example, the fourth working hour type is obtained based on a given configuration. It can be a training task for training employees (such as old employees who are familiar with the business). The training employee can be any one of multiple employees who are familiar with the work skills. The demand information of the fourth working hour type may include the third preset time period corresponding to the fourth working hour type and the required fourth preset working hour duration. In some examples, the fourth working hour type E can be expressed as E={e 1r , e 2r ,..},e s′i It is used to indicate the demand for training hours of trainee s′ (corresponding to the number of hours of training hours of trainee s 0 For specific working time types ir Quantity demanded), e s′i≥0 and e s′i ∈Z. It should be noted that the fourth working time type does not need to be completed within a preset time period, but only needs to be completed within the time period of the trainee s 0 The training time window is completed, so the subscripts of the relevant parameters of the fourth working hour type only have i and s' but no t. As an example, the fourth working hour type may include but is not limited to specific work tasks such as grilling wings, making pizza, making hamburgers, washing dishes, sweeping the floor, and wiping tables.

[0091] In this embodiment of the present disclosure, the input information may further include a third penalty parameter p3 when the third work time type is not assigned. i and the fourth penalty parameter p4 when the fourth working time type is not assigned i The decision variables may include a fourth decision variable for indicating the duration of the unallocated third work-hour type. and a fifth decision variable z4 for indicating the working time length of the fourth working time type that is not allocated s′ir The fourth decision variable Indicates employees 0 Training hours ir During the unscheduled training time of the day, and The fifth decision variable z4 s′ir represents the training hours e of employee s′ i (corresponding to the trained employees 0 Training hours ir ) The unscheduled training time on that day, z4 s′ir ≥0 and z4 s′ir ∈Z. At this time, the preset scheduling constraints may also include the following items:

[0092] The preset scheduling constraint condition for the third working hour type, that is, the preset working hours required for the third working hour type is equal to the sum of the working hours of the third working hour type that have not been allocated and the working hours of the third working hour type that have been allocated, can be expressed by the following formula (8):

[0093]

[0094] in, represents the fourth decision variable, s 0 Indicates specific trained employees 0 , l represents employee s 0 The set L of candidate scheduling segments s A candidate scheduling line segment in ls represents the first decision variable of the candidate scheduling line segment l corresponding to employee s, Indicates employees 0 For specific working time types irThe demand, subscript i is used to distinguish different work tasks of the third working time type, subscript r is used to distinguish different restaurants in a specified area, CE = (CE lir ) is a two-dimensional coefficient matrix, and the elements CE lir Represents the specific working hours type d of restaurant r arranged in line segment l ir or e ir Working hours, CE lir ≥0 and CE lir ∈Z.

[0095] The preset scheduling constraint condition for the fourth working hour type, that is, the preset working hours required for the fourth working hour type is equal to the sum of the working hours of the unallocated fourth working hour type and the working hours of the allocated fourth working hour type, can be expressed by the following formula (9):

[0096]

[0097] Among them, z4 s′ir represents the fifth decision variable, s′ represents the employee s′ under training, and l represents the set L of candidate scheduling segments for employee s′ s A candidate scheduling line segment in ls represents the first decision variable of the candidate scheduling line segment l corresponding to employee s, e s′ir It is used to represent the training hours required for the training employee s′. The subscript i is used to distinguish different work tasks in the fourth working hour type. The subscript r is used to distinguish different restaurants in a specified area. CE=(CE lir ) is a two-dimensional coefficient matrix, and the elements CE lir Represents the specific working hours type d of restaurant r arranged in line segment l ir or e ir Working hours, CE lir ≥0 and CE lir ∈Z.

[0098] The preset scheduling constraint condition for the correspondence between the third working hour type and the fourth working hour type, that is, the second preset time period corresponds to the third preset time period, so that the trainee can receive guidance from the trainer on the trained skills within the training time window.

[0099] In this embodiment of the present disclosure, employees corresponding to the fourth working hour type can be pre-assigned, or employees corresponding to the fourth working hour type can be determined based on the target scheduling line segment. Taking restaurant r as an example, when a fixed employee corresponding to the fourth working hour type (i.e., a trainee employee) is assigned to a trainee, the constraint condition for the correspondence between the third working hour type and the fourth working hour type can be further expressed by the following formula (10):

[0100]

[0101] The left side of formula (10) represents the working hours of the trainee, and the right side of formula (10) represents the working hours of the trainee. ltir ) is a three-dimensional coefficient matrix, which identifies the relationship between the candidate scheduling line segment and the third working hour type D or the fourth working hour type E. The elements in the matrix represent:

[0102]

[0103] Formula (10) means that if the fourth working hour type E specifies trainee employees, for the trainee s 0 and its corresponding D-type working hours d ir , and train employees 1 and its corresponding E-type working hours e ir If you train employees 1 Working hours e are scheduled in time period t ir , then there must be an employee s in time period t 0 Arranged working hours ir That is to say, the fourth working hour type and the third working hour type have a one-to-one correspondence. 1 No need to instruct trainees in real time 0 Therefore, train employees 1 The working hours of the trainee can be less than or equal to 0 Length of working hours.

[0104] When no fixed employee corresponding to the fourth working hour type (i.e., the trainee) is assigned to the trainee, the employee corresponding to the fourth working hour type can be determined based on the target scheduling line segment. Taking restaurant r as an example, the constraint condition for the correspondence between the third working hour type and the fourth working hour type can be further expressed by the following formula (11):

[0105]

[0106] Where TA(i) represents the working time d ir The collection of other working hours in the same area. The meaning of formula (10) is: If the fourth working hour type E does not specify a trainee, for the trainee s 0 , if D-type working hours d are arranged in time period t ir , then you need to do the work d in time period t ir In the same area, employees who work the first working hours type A or the second working hours type B except for trainees 0 To select suitable employees from other employees other than , then there must be a time period t with working hours d irThe first working time type A or the second working time type B working time in the same area is allocated to employees other than trainees. 0 Other employees other than

[0107] At this time, the planning goal may include reducing the product of the third penalty parameter and the assigned value of the third decision variable and reducing the product of the fourth penalty parameter and the assigned value of the fourth decision variable. The planning goal can be expressed by the following formula (12):

[0108]

[0109] Wherein, D represents the third working time type (which may include multiple specific working time types d ir ), d ir represents a training time in set D, p3 i represents the third penalty parameter, represents the fourth decision variable; E represents the fourth working time type (which may include multiple specific working time types e ir ), e ir represents the corresponding training hours in set E, p4 i represents the fourth penalty parameter, z4 s′ir represents the fifth decision variable.

[0110] According to some embodiments of the present disclosure, by reducing the product of the third penalty parameter and the assigned value of the third decision variable and reducing the product of the fourth penalty parameter and the assigned value of the fourth decision variable, the demand for the third working hour type and the demand for the fourth working hour type can be met as much as possible from a global perspective, thereby reducing the adverse effects of insufficient workload of the third working hour type and the fourth working hour type.

[0111] In summary, the objective function can be designed as:

[0112]

[0113] It will be understood that the values ​​of the various penalty parameters in formula (13) can be adjusted according to different actual needs, thereby changing the contribution of each part of the objective function to the objective function. In some embodiments, the objective function f(x) can be optimized based on the following multiple constraints so that the value of the objective function f(x) is minimized (i.e., minf(x)).

[0114]

[0115]

[0116]

[0117]

[0118]

[0119]

[0120]

[0121]

[0122]

[0123] Among them, either formula (10) or formula (11) is used. When the trainee of the fourth working hour type is specified, formula (10) is used; when the trainee of the fourth working hour type is not specified, formula (11) is used.

[0124] The meaning of the preset scheduling constraint represented by formula (13) is: taking the first working hour type as an example, the first type of employees can only work in the restaurant to which they belong, and cannot work in other restaurants. In this formula, e(s) represents the restaurant to which the first type of employee s belongs, R\e(s) represents other restaurants in the specified area except the restaurant to which the first type of employee s belongs, T = {t 1 , t 2 , ...} represents the set of time periods divided into the whole day, S r represents the set of all employees of restaurant r, represents the set of the second type of employees (i.e., shareable employees) of restaurant r, represents the set of first-type employees (i.e., non-shareable employees) of restaurant r.

[0125] The meaning of the preset scheduling constraint represented by formula (14) is to make the second type of employees work in their respective restaurants first, thereby reducing the waste of human resources caused by unnecessary scheduling. For example, when a certain type of work-hour task is required in restaurant r, employees who can perform the task in the restaurant are given priority, rather than employees from other restaurants. In formula (14), represents the set of the second type of employees in all restaurants, where U represents the union operation.

[0126] When the objective function f{x) satisfies the above constraints and reaches the minimum value, according to y ls The value of can determine the employees to be scheduled and the target scheduling line segments of these employees. For example, if y ls =1, the candidate scheduling line segment l of employee s is selected, and then the candidate scheduling line segment l of employee s is arranged in the schedule; if y ls = 0, the candidate scheduling line segment l of employee s is not selected. Among all employees, take all y values ​​​​1 lsThe corresponding target scheduling line segments can obtain the automatically generated shift schedule, and the employee sets corresponding to these target scheduling line segments are the employees who need to go to work.

[0127] According to some embodiments of the present disclosure, by constructing a mixed linear integer programming model, employee shifts are automatically generated, which can meet the restaurant's working hour needs as much as possible while fully utilizing the employees' shifts, skills, productivity, etc., making working hour arrangements and personnel arrangements more reasonable and efficient.

[0128] According to another aspect of the present disclosure, a device for scheduling employees in a region is also provided. Figure 3 FIG. 3 shows a structural block diagram of an apparatus 300 for employee scheduling according to an exemplary embodiment of the present disclosure. Figure 3 As shown, the device 300 for scheduling employees in a region may include: a first acquisition unit 310, configured to acquire employee portraits of first-type employees and second-type employees of multiple entities, the employee portraits including the entity to which the employee belongs, a scheduling identifier, and the employee's work skills and proficiency scores, the scheduling identifier is used to indicate whether the employee can be scheduled between multiple entities, and the proficiency score is used to indicate the employee's proficiency in work skills; a second acquisition unit 320, configured to acquire multiple candidate hours corresponding to each employee of the first-type employee and the second-type employee based on the employee portrait, multiple types of work hours to be allocated by multiple entities, and a preset scheduling rule. Select a scheduling segment, a candidate scheduling segment corresponding to each employee includes the entity where the employee works and the assigned working time type in each time period of multiple continuous time periods, and the employee's work skills correspond to the multiple working time types to be assigned; a third acquisition unit 330 is configured to obtain the demand information of multiple working time types to be assigned of multiple entities; and a first determination unit 340 is configured to determine the target scheduling segment corresponding to each employee of the first type of employees and the second type of employees based on the multiple candidate scheduling segments, the demand information of the multiple working time types to be assigned, and one or more of the preset scheduling constraints.

[0129] According to some embodiments of the present disclosure, the device 300 for scheduling employees in a region may further include: a construction unit, configured to construct an integer programming model based on input information, the integer programming model including a planning objective, a decision variable and a preset scheduling constraint, the input information including demand information of multiple candidate scheduling segments and multiple types of working hours to be assigned, the planning objective being used to indicate the conditions that need to be met for assigning a target scheduling segment to each of the first type of employees and the second type of employees, the decision variable including a first decision variable for indicating whether each candidate scheduling segment in at least one candidate scheduling segment corresponding to each employee is selected; and a solving unit, configured to solve the integer programming model based on the planning objective and the preset scheduling constraint to obtain an assigned value of the first decision variable, the target scheduling segment corresponding to each of the first type of employees and the second type of employees being determined based on the assigned value of the first decision variable.

[0130] According to some embodiments of the present disclosure, the device 300 for employee scheduling may further include: a fourth acquisition unit, configured to obtain, for each employee of the first type of employees and the second type of employees, at least one candidate scheduling segment corresponding to the employee based on the employee portrait of the employee, multiple types of working hours to be allocated and preset scheduling rules, wherein the preset scheduling constraints include, for each employee, selecting at most one candidate scheduling segment from the at least one candidate scheduling segment corresponding to the employee as the target scheduling segment corresponding to the employee.

[0131] According to some embodiments of the present disclosure, the device 300 for employee scheduling may further include: a fifth acquisition unit, configured to obtain, for each employee of the first type of employees, at least one candidate scheduling segment corresponding to the employee based on the employee portrait of the employee, multiple types of working hours to be allocated of the entity to which the employee belongs, and preset scheduling rules.

[0132] According to some embodiments of the present disclosure, the type of working hours to be allocated includes rest working hours, wherein the input information also includes quality scores of multiple candidate scheduling segments, the quality scores are used to characterize the degree of unreasonableness of the candidate scheduling segments, and the quality scores are related to at least one of the working hours of employees in the candidate scheduling segments, the rest hours in the affiliated entities, the rest hours across entities, the affiliation of the employees and the entities, the number of times the employees cross entities, and the matching degree between the employees and the candidate scheduling segments, and the planning goals include reducing the quality scores of the target scheduling segments corresponding to each employee of the first type of employees and the second type of employees.

[0133] According to some embodiments of the present disclosure, for each of the multiple entities, the working time type to be allocated includes a first working time type, and the demand information of the first working time type includes a first preset time period corresponding to the first working time type and a required first preset working time duration, wherein the input information also includes a first penalty parameter when the first working time type is not allocated, and the decision variable includes a second decision variable for indicating the working time duration of the unallocated first working time type, wherein the planning goal includes reducing the product of the first penalty parameter and the assigned value of the second decision variable, and the preset scheduling constraint includes that the first preset working time duration required for the first working time type is equal to the sum of the working time duration of the unallocated first working time type and the working time duration of the allocated first working time type, and the working time duration of the allocated first working time type is obtained based on the target scheduling segment.

[0134] According to some embodiments of the present disclosure, for each of the multiple entities, the working time type to be allocated includes a second working time type, and the demand information of the second working time type includes a second preset working time length required for the second working time type, wherein the input information also includes a second penalty parameter when the second working time type is not allocated, and the decision variable includes a third decision variable for indicating the working time length of the unallocated second working time type, wherein the planning goal includes reducing the product of the second penalty parameter and the assigned value of the third decision variable, and the preset scheduling constraint includes that the second preset working time length required for the second working time type is equal to the sum of the working time length of the unallocated second working time type and the working time length of the allocated second working time type, and the working time length of the allocated second working time type is obtained based on the target scheduling segment.

[0135] According to some embodiments of the present disclosure, for each of the multiple entities, the working hours type to be allocated also includes a third working hours type and a fourth working hours type, the third working hours type is associated with a specific employee, the demand information of the third working hours type includes a second preset time period corresponding to the third working hours type and a required third preset working hours duration, the fourth working hours type is associated with the third working hours type, the demand information of the fourth working hours type includes a third preset time period corresponding to the fourth working hours type and a required fourth preset working hours duration, wherein the input information also includes a third penalty parameter when the third working hours type is not allocated and a fourth penalty parameter when the fourth working hours type is not allocated, wherein the decision variable includes a parameter for indicating that the third working hours type is not allocated. The fourth decision variable for indicating the working hours of the fourth working hour type that are not allocated and the fifth decision variable for indicating the working hours of the fourth working hour type that are not allocated, and wherein the planning goal includes reducing the product of the third penalty parameter and the allocated value of the fourth decision variable and reducing the product of the fourth penalty parameter and the allocated value of the fifth decision variable, wherein the preset scheduling constraints also include: the preset working hours required for the third working hour type is equal to the sum of the working hours of the unallocated third working hour type and the working hours of the allocated third working hour type, the preset working hours required for the fourth working hour type is equal to the sum of the working hours of the unallocated fourth working hour type and the working hours of the allocated fourth working hour type, and the second preset time period corresponds to the third preset time period.

[0136] According to some embodiments of the present disclosure, employees corresponding to the fourth working hour type are pre-assigned, or employees corresponding to the fourth working hour type are determined based on a target scheduling line segment.

[0137] According to some embodiments of the present disclosure, the candidate scheduling line segments are determined based on the employee's shift time, the employee's work skills, the demand information of multiple types of working hours to be allocated, the scheduling rules, and whether the employee can be scheduled between multiple entities.

[0138] According to some embodiments of the present disclosure, the scheduling rules include at least one of the employee's rest time in the entity to which they belong, the rest time across entities, the number of shifts, and the work time type connection rules, wherein the number of shifts represents the number of consecutive time periods to which the work time types are to be assigned, and the work time type connection rules represent the connection relationship between adjacent work time types.

[0139] According to some embodiments of the present disclosure, the preset scheduling constraint condition further includes: the first type of employees only work in the affiliated entity; and the first proficiency score of the second type of employees for the work skills when working in the affiliated entity is greater than the second proficiency score of the second type of employees for the work skills when not working in the affiliated entity. In other words, the second type of employees have priority to work in the affiliated entity.

[0140] It should be understood that Figure 3 The various units 310 to 340 of the device 300 shown in FIG. 3 can be compared with the reference Figure 1 The various steps 110 to 140 of the method 100 described, refer to Figure 2 The steps 142 to 144 in the described method 140 correspond to each other. Therefore, the operations, features and advantages described above for the methods 100 and 140 are also applicable to the apparatus 300 and the units included therein. For the sake of brevity, some operations, features and advantages are not described in detail here.

[0141] According to another aspect of the present disclosure, an electronic device is also provided, comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the above-mentioned method for employee scheduling.

[0142] According to another aspect of the present disclosure, a computer-readable storage medium storing computer instructions is further provided, wherein the computer instructions are used to enable a computer to execute the above-mentioned method for employee scheduling.

[0143] According to another aspect of the present disclosure, a computer program product is also provided, including a computer program, wherein the computer program implements the above-mentioned method for employee scheduling when executed by a processor.

[0144] See also Figure 4 , a block diagram of an electronic device 400 that can be used as the present disclosure will now be described, which is an example of a hardware device that can be applied to various aspects of the present disclosure. The electronic device can be a computer device of different types, such as a laptop computer, a desktop computer, a workbench, a personal digital assistant, a server, a blade server, a mainframe computer, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present disclosure described and / or required herein.

[0145] Figure 4 1 shows a block diagram of an electronic device according to an embodiment of the present disclosure. Figure 4 As shown, the electronic device 400 may include at least one processor 401 , a working memory 402 , an I / O device 404 , a display device 405 , a storage device 406 , and a communication interface 407 that can communicate with each other via a system bus 403 .

[0146] Processor 401 may be a single processing unit or multiple processing units, all of which may include a single or multiple computing units or multiple cores. Processor 401 may be implemented as one or more microprocessors, microcomputers, microcontrollers, digital signal processors, central processing units, state machines, logic circuits, and / or any device that manipulates signals based on operating instructions. Processor 401 may be configured to obtain and execute computer-readable instructions stored in working memory 402, storage device 406, or other computer-readable media, such as program codes of operating system 402a, program codes of application programs 402b, and the like.

[0147] Working memory 402 and storage device 406 are examples of computer-readable storage media for storing instructions, which are executed by processor 401 to implement the various functions described above. Working memory 402 may include both volatile memory and non-volatile memory (e.g., RAM, ROM, etc.). In addition, storage device 406 may include a hard disk drive, a solid-state drive, a removable medium, including external and removable drives, memory cards, flash memory, a floppy disk, an optical disk (e.g., CD, DVD), a storage array, a network attached storage, a storage area network, etc. Working memory 402 and storage device 406 may all be collectively referred to herein as memory or computer-readable storage media, and may be a non-transitory medium capable of storing computer-readable, processor-executable program instructions as computer program code, which may be executed by processor 401 as a specific machine configured to implement the operations and functions described in the examples herein.

[0148] The I / O device 404 may include an input device and / or an output device. The input device may be any type of device capable of inputting information to the electronic device 400, and may include but is not limited to a mouse, a keyboard, a touch screen, a track pad, a track ball, a joystick, a microphone, and / or a remote controller. The output device may be any type of device capable of presenting information, and may include but is not limited to a video / audio output terminal, a vibrator, and / or a printer.

[0149] The communication interface 407 allows the electronic device 400 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks, and may include but is not limited to a modem, a network card, an infrared communication device, a wireless communication transceiver and / or a chipset, such as a Bluetooth™ device, an 802.11 device, a WiFi device, a WiMax device, a cellular communication device and / or the like.

[0150] The application 402b in the working register 402 can be loaded to execute the various methods and processes described above, such as Figure 1In some embodiments, part or all of the computer program may be loaded and / or installed on the electronic device 400 via the storage device 406 and / or the communication interface 407. When the computer program is loaded and executed by the processor 401, one or more steps of the method for employee scheduling described above may be performed.

[0151] Various implementations of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various implementations may include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.

[0152] The program code for implementing the method of the present disclosure may be written in any combination of one or more programming languages. These program codes may be provided to a processor or controller of a general-purpose computer, a special-purpose computer, or other programmable data processing device, so that the program code, when executed by the processor or controller, enables the functions / operations specified in the flow chart and / or block diagram to be implemented. The program code may be executed entirely on the machine, partially on the machine, partially on the machine and partially on a remote machine as a stand-alone software package, or entirely on a remote machine or server.

[0153] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0154] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user can provide input to the computer. Other types of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).

[0155] The systems and techniques described herein may be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such back-end components, middleware components, or front-end components. The components of the system may be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), and the Internet.

[0156] A computing system may include clients and servers. Clients and servers are generally remote from each other and usually interact through a communication network. The relationship of client and server is generated by computer programs running on respective computers and having a client-server relationship to each other.

[0157] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps recorded in this disclosure can be performed in parallel, sequentially or in a different order, as long as the desired results of the technical solutions disclosed in this disclosure can be achieved, and this document is not limited here.

[0158] Although the embodiments or examples of the present disclosure have been described with reference to the accompanying drawings, it should be understood that the above-mentioned methods, systems and devices are merely exemplary embodiments or examples, and the scope of the present invention is not limited by these embodiments or examples, but only by the claims after authorization and their equivalent scope. Various elements in the embodiments or examples can be omitted or replaced by their equivalent elements. In addition, each step can be performed in an order different from that described in the present disclosure. Further, the various elements in the embodiments or examples can be combined in various ways. It is important that with the evolution of technology, many elements described herein can be replaced by equivalent elements that appear after the present disclosure.

Claims

1. A method for scheduling employees in a region, wherein the region includes a plurality of entities, the plurality of entities include a first type of employees and a second type of employees, the first type of employees cannot be scheduled between the plurality of entities, and the second type of employees can be scheduled between the plurality of entities, the method comprising: Obtaining employee portraits of the first type of employees and the second type of employees, the employee portraits including the entity to which the employee belongs, a scheduling identifier, and the employee's work skills and proficiency scores, the scheduling identifier being used to indicate whether the employee can be scheduled between multiple entities, and the proficiency score being used to indicate the employee's proficiency in the work skills; Based on the employee portrait, the multiple types of working hours to be allocated of the multiple entities and the preset scheduling rules, a plurality of candidate scheduling segments corresponding to each employee of the first type of employees and the second type of employees are respectively obtained, wherein one candidate scheduling segment corresponding to each employee includes the entity worked by the employee and the type of working hours allocated in each time period of multiple continuous time periods, and the work skills of the employee correspond to the multiple types of working hours to be allocated; Obtaining demand information of each of the multiple types of man-hours to be allocated of the multiple entities; as well as Based on the multiple candidate scheduling segments, the demand information of the multiple types of man-hours to be allocated, and one or more of the preset scheduling constraints, a target scheduling segment corresponding to each of the first type of employees and the second type of employees is determined.

2. The method according to claim 1, wherein: Based on the multiple candidate scheduling segments, the demand information of the multiple types of work hours to be allocated, and one or more of the preset scheduling constraints, determining a target scheduling segment corresponding to each of the first type of employees and the second type of employees includes: constructing an integer programming model based on input information, the integer programming model including a planning objective, a decision variable, and the preset scheduling constraint condition, the input information including the demand information of the plurality of candidate scheduling segments and the plurality of types of working hours to be allocated, the planning objective being used to indicate the conditions to be satisfied for allocating a target scheduling segment to each of the first type of employees and the second type of employees, the decision variable comprising a first decision variable for indicating whether each candidate scheduling segment of at least one candidate scheduling segment corresponding to each employee is selected; and The integer programming model is solved based on the planning objectives and the preset scheduling constraints to obtain the assigned value of the first decision variable, and the target scheduling line segment corresponding to each employee of the first type of employees and the second type of employees is determined based on the assigned value of the first decision variable.

3. The method according to claim 1, wherein: Based on the employee portrait, the multiple types of working hours to be allocated of the multiple entities and the preset scheduling rules, respectively obtaining multiple candidate scheduling line segments corresponding to each employee of the first type of employees and the second type of employees includes: For each employee of the first type of employees and the second type of employees, at least one candidate scheduling line segment corresponding to the employee is obtained based on the employee portrait of the employee, the multiple types of working hours to be allocated, and the preset scheduling rules. The preset scheduling constraint condition includes selecting, for each employee, at most one candidate scheduling segment from at least one candidate scheduling segment corresponding to the employee as the target scheduling segment corresponding to the employee.

4. The method according to claim 3, wherein: For each employee of the first type of employees and the second type of employees, obtaining at least one candidate scheduling segment corresponding to the employee based on the employee portrait of the employee, the multiple types of working hours to be allocated, and the preset scheduling rule includes: For each employee of the first type of employees, at least one candidate scheduling segment corresponding to the employee is obtained based on the employee portrait of the employee, multiple types of working hours to be allocated of the entity to which the employee belongs, and the preset scheduling rule.

5. The method according to claim 2, wherein: The types of working hours to be allocated include rest working hours, and wherein, The input information also includes quality scores of the plurality of candidate scheduling segments, the quality scores are used to characterize the unreasonableness of the candidate scheduling segments, and the quality scores are related to at least one of the employee's working hours, rest time in the entity to which he belongs, rest time across entities, the relationship between the employee and the entity, the number of times the employee crosses entities, and the matching degree between the employee and the candidate scheduling segment. The planning goal includes reducing the quality score of the target scheduling line segment corresponding to each of the first type of employees and the second type of employees.

6. The method according to claim 2, wherein: For each of the multiple entities, the type of working hours to be allocated includes a first working hour type, and the requirement information of the first working hour type includes a first preset time period corresponding to the first working hour type and a required first preset working hour duration. The input information further includes a first penalty parameter when the first work time type is not allocated, and the decision variable includes a second decision variable for indicating the work time length of the first work time type that is not allocated. Among them, the planning goal includes reducing the product of the first penalty parameter and the assigned value of the second decision variable, and the preset scheduling constraint includes that the first preset working hours required for the first working hour type is equal to the sum of the working hours of the unassigned first working hour type and the working hours of the allocated first working hour type, and the working hours of the allocated first working hour type are obtained based on the target scheduling segment.

7. The method according to claim 2, wherein: For each of the multiple entities, the type of working hours to be allocated includes a second working hour type, and the requirement information of the second working hour type includes a second preset working hour duration required for the second working hour type. The input information further includes a second penalty parameter when the second working time type is not allocated, and the decision variable includes a third decision variable for indicating the working time length of the unallocated second working time type. Among them, the planning goal includes reducing the product of the second penalty parameter and the assigned value of the third decision variable, the preset scheduling constraints include that the second preset working hours required for the second working hour type is equal to the sum of the working hours of the unallocated second working hour type and the working hours of the allocated second working hour type, and the working hours of the allocated second working hour type are obtained based on the target scheduling segment.

8. The method according to claim 2, wherein: For each of the multiple entities, the working time type to be allocated further includes a third working time type and a fourth working time type, the third working time type is associated with a specific employee, the demand information of the third working time type includes a second preset time period corresponding to the third working time type and a required third preset working time duration, the fourth working time type is associated with the third working time type, and the demand information of the fourth working time type includes a third preset time period corresponding to the fourth working time type and a required fourth preset working time duration, The input information further includes a third penalty parameter when the third work hour type is not assigned and a fourth penalty parameter when the fourth work hour type is not assigned. The decision variables include a fourth decision variable for indicating the working time duration of the third working time type that is not allocated and a fifth decision variable for indicating the working time duration of the fourth working time type that is not allocated, and The planning objectives include reducing the product of the third penalty parameter and the assigned value of the fourth decision variable and reducing the product of the fourth penalty parameter and the assigned value of the fifth decision variable. The preset scheduling constraints also include: The preset working hours required for the third working hour type is equal to the sum of the working hours of the unallocated third working hour type and the working hours of the allocated third working hour type; The preset working hours required for the fourth working hour type is equal to the sum of the working hours of the unallocated fourth working hour type and the working hours of the allocated fourth working hour type; and The second preset time period corresponds to the third preset time period.

9. The method according to claim 7, wherein: Employees corresponding to the fourth working hour type are pre-assigned, or employees corresponding to the fourth working hour type are determined based on the target scheduling line segment.

10. The method according to any one of claims 1 to 9, wherein: The candidate scheduling line segment is determined based on the employee's shift time, the employee's work skills, the demand information of the multiple types of working hours to be allocated, the scheduling rules, and whether the employee can be scheduled between the multiple entities.

11. The method according to any one of claims 1 to 9, wherein: The scheduling rules include at least one of the employee's rest time in the entity to which they belong, the rest time across entities, the number of shifts, and the work time type connection rules. The number of shifts represents the number of continuous time periods to be assigned work time types, and the work time type connection rules represent the connection relationship between adjacent work time types.

12. The method according to any one of claims 2 to 9, wherein: The preset scheduling constraints also include: The first type of employee works only for the entity; and A first proficiency score of the second type of employees for the work skills when they work at their entity is greater than a second proficiency score of the second type of employees for the work skills when they do not work at their entity.

13. A device for scheduling employees in a region, the region comprising a plurality of entities, the plurality of entities comprising a first type of employees and a second type of employees, the first type of employees cannot be scheduled between the plurality of entities, and the second type of employees can be scheduled between the plurality of entities, the device comprising: A first acquisition unit is configured to acquire employee portraits of the first type of employees and the second type of employees, wherein the employee portraits include the entity to which the employee belongs, a scheduling identifier, and the employee's work skills and proficiency scores thereof, wherein the scheduling identifier is used to indicate whether the employee can be scheduled between multiple entities, and the proficiency score is used to indicate the employee's proficiency in the work skills; A second acquisition unit is configured to respectively acquire a plurality of candidate scheduling segments corresponding to each employee of the first type of employees and the second type of employees based on the employee portrait, the plurality of types of working hours to be allocated of the plurality of entities, and a preset scheduling rule, wherein one candidate scheduling segment corresponding to each employee includes an entity where the employee works and the type of working hours allocated in each time period of a plurality of continuous time periods, and the employee's work skills correspond to the plurality of types of working hours to be allocated; A third acquisition unit is configured to acquire demand information of each of the multiple types of man-hours to be allocated of the multiple entities; and The first selection unit is configured to determine a target scheduling segment corresponding to each employee of the first type of employees and the second type of employees based on the multiple candidate scheduling segments, the demand information of each of the multiple types of working hours to be allocated, and one or more of the preset scheduling constraints.

14. The device according to claim 13, wherein: The first selection unit comprises: a construction unit configured to construct an integer programming model based on input information, the integer programming model comprising a planning objective, a decision variable and the preset scheduling constraint condition, the input information comprising the plurality of candidate scheduling segments and the respective demand information of the plurality of types of working hours to be allocated, the planning objective being used to indicate a condition to be satisfied for allocating a target scheduling segment to each of the first type of employees and the second type of employees, the decision variable comprising a first decision variable for indicating whether each candidate scheduling segment of at least one candidate scheduling segment corresponding to each employee is selected; and A solving unit is configured to solve the integer programming model based on the planning objectives and the preset scheduling constraints to obtain an assigned value of the first decision variable, wherein the target scheduling segment corresponding to each employee of the first type of employees and the second type of employees is determined based on the assigned value of the first decision variable.

15. An electronic device, comprising: at least one processor; as well as a memory communicatively coupled to the at least one processor; The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the method according to any one of claims 1 to 12.

16. A computer-readable storage medium storing computer instructions, wherein: The computer instructions are used to cause the computer to execute the method according to any one of claims 1-12.

17. A computer program product comprising a computer program, wherein: The computer program implements the method according to any one of claims 1 to 12 when executed by a processor.