Schedule adjustment program, method, and apparatus
The scheduling program addresses the computational intensity of work shift adjustments by focusing on similar cases from a database to identify a limited range for optimization, thereby reducing calculation time and improving efficiency in obtaining optimal solutions.
Patent Information
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- FUJITSU LTD
- Filing Date
- 2022-09-06
- Publication Date
- 2026-07-08
AI Technical Summary
Existing methods for adjusting work shifts in response to change requests are computationally intensive and require significant time, especially when narrowing the range of optimization calculations, making it difficult to obtain optimal solutions.
A scheduling program and method that extracts similar change cases from a database to identify a limited range of assignment slots for optimization, reducing the calculation time by focusing on these slots for work shift adjustments.
Reduces the time required for calculating work shift adjustments by optimizing the assignment of work patterns within a restricted range, increasing the likelihood of obtaining an optimal solution efficiently.
Smart Images

Figure 0007886528000003 
Figure 0007886528000004 
Figure 0007886528000005
Abstract
Description
Technical Field
[0001] The present invention relates to a schedule adjustment program, method, and apparatus.
Background Art
[0002] In workplaces with a shift work system such as hospitals, work shifts are created under certain constraints. When creating a work shift that meets the constraints manually, the workload of the creation work is large. On the other hand, by using mathematical optimization calculations, it becomes possible to automatically create a work shift that meets the constraints. Also, for example, when there is a change request to change the work mode for a certain allocation frame in an existing work shift, the work shift can be automatically corrected by mathematical optimization calculations.
[0003] Here, regarding the correction of work shifts, the following technologies have been proposed. For example, a work management system has been proposed that, when receiving a designation of a work part for which a change is desired from a worker who wishes to change shifts, repeatedly selects candidates to be assigned to that work part while gradually relaxing the constraint conditions until a predetermined end condition is satisfied. Also, a work schedule creation system has been proposed that, when receiving a correction instruction for work schedule data, selects a daily shift work pattern from a storage unit so that the change in the staff allocation set for each day is minimized, and corrects the work schedule data using the selected daily work pattern.
Prior Art Documents
Patent Documents
[0004]
Patent Document 1
Patent Document 2
Summary of the Invention
Problems to be Solved by the Invention
[0005] By the way, as mentioned above, when modifying work shifts in response to requests for changes in work patterns within a certain allocation, the time required for the calculation can be reduced by narrowing the range of allocations targeted for optimization calculations as much as possible. On the other hand, the narrower the range, the more difficult it becomes to obtain the optimal solution.
[0006] In one aspect, the present invention aims to provide a schedule adjustment program, method, and apparatus that can reduce the calculation time required for adjusting work shifts. [Means for solving the problem]
[0007] One proposal provides a scheduling adjustment program that allows a computer to receive a request to change the work style for a first work shift, where work styles are assigned to each of several time slots and each of several workers within a predetermined period. The program then extracts similar change cases from a database containing multiple past change cases for work shifts, where the requested change in work style is similar to the change made by the request. In these similar change cases, the program identifies one or more second work slots from the allocation slots included in the original second work shift where the work style has been changed by an allocation adjustment in response to the change request. The program then performs an optimization calculation to optimize the work style assignment in the first work shift, using the range of one or more second work slots within the allocation slots included in the first work shift as the range within which the work style assignment can be changed.
[0008] Furthermore, one proposal provides a scheduling method in which a computer performs processing similar to that based on the scheduling program described above. Furthermore, one proposal provides a scheduling device that performs processing similar to that based on the scheduling program described above. [Effects of the Invention]
[0009] One aspect of this is that it can reduce the time required to calculate work shift adjustments. [Brief explanation of the drawing]
[0010] [Figure 1] This figure shows an example of the configuration and processing of a schedule adjustment device according to the first embodiment. [Figure 2] This figure shows an example configuration of the work management system according to the second embodiment. [Figure 3] This figure shows an example of the hardware configuration of the management server. [Figure 4] This diagram shows an example of a nurse's work shift. [Figure 5] This is a diagram to explain the formalization. [Figure 6] This figure shows an example configuration of the processing functions provided by the management server. [Figure 7] This figure shows example data structures for the pre-change shift database, the post-change shift database, and the adjusted shift database. [Figure 8] This is an example flowchart showing the entire process of changing work shifts by the management server. [Figure 9] This diagram illustrates the calculation of differences and distances in a work shift schedule. [Figure 10] This diagram illustrates the processing performed by the change request receiving unit and the change content determination unit. [Figure 11] This is an example flowchart showing the procedure for determining the content of assignment changes. [Figure 12] This diagram illustrates the process of extracting similar work shifts by the impact area calculation unit. [Figure 13] This is a diagram illustrating the process of identifying the scope of impact. [Figure 14] This is an example flowchart showing the procedure for identifying the scope of impact. [Figure 15] This diagram illustrates the initial processing performed by the reallocation processing unit. [Figure 16] The first figure shows the initial value change patterns. [Figure 17]It is a second diagram showing an initial value change pattern. [Figure 18] It is a third diagram showing an initial value change pattern. [Figure 19] It is an example of a flowchart showing the procedure of the assignment adjustment process for work patterns. [Figure 20] It is an example of a flowchart showing the procedure of the output process for adjustment results.
Embodiments for Carrying Out the Invention
[0011] Hereinafter, embodiments of the present invention will be described with reference to the drawings. 〔First Embodiment〕 FIG. 1 is a diagram showing a configuration example and a processing example of a schedule adjustment device according to the first embodiment. The schedule adjustment device A schedule adjustment device 1 shown in FIG. 1 includes a processing unit 2. The processing unit 2 is, for example, a processor.
[0012] When the processing unit 2 receives a change request for an existing work shift, it corrects this work shift by an optimization calculation. The work shift includes assignment frames corresponding to each of a plurality of time zones in a predetermined period and each of a plurality of workers, and a work pattern is assigned to each assignment frame. The work pattern indicates the content of work, working hours, etc. For example, work patterns regarding working hours include day shift, night shift, rest, etc.
[0013] In the example of FIG. 1, it is assumed that the processing unit 2 has received a change request 12 for the work shift 11. In the work shift 11, for each of the workers A 1 to A 4, one of the work patterns B 1 to B 4 is assigned to the assignment frame corresponding to each day of the week in a week. Also, one or more constraints regarding the work patterns B 1 to B 4 are associated with the work shift 11, and the work shift 11 is created so as to satisfy these one or more constraints as much as possible. Also, it is assumed that the change request 12 requests to change the work pattern of the assignment frame on Wednesday of the worker A 2 from the work pattern B 1 to the work pattern B 4.
[0014] When processing unit 2 receives such a change request 12, it modifies the work shift 11 while referring to database 3. Database 3 contains multiple past change examples for work shifts. Change examples are registered as information that shows, for example, the work shift before the change, the content of the change request for that work shift, and how the work shift before the change was modified in response to the change request.
[0015] When the processing unit 2 receives a change request 12, it extracts similar change cases from the database 3 where the content of the work schedule change request is similar to the content of the change request 12. In the example in Figure 1, it is assumed that a change request 22 was extracted as a similar change case in which, for the work shift 21 before the change, the work schedule of employee A6's assigned slot on Wednesday was changed from work schedule B1 to work schedule B4.
[0016] Work shift 21 has a different workforce than work shift 11, but the number of workforces is the same. Also, change request 22 is the same as change request 12 in that it changes the work style of the second workforce's Wednesday assignment slot from work style B1 to work style B4. For this reason, the above change examples have been extracted as similar change examples.
[0017] Processing Unit 2 identifies one or more assignment slots (referred to as "changed assignment slots") from among the assignment slots included in the original work shift 21 in the extracted similar change cases, where the work style has been changed by assignment adjustments in response to the change request 22. Here, it is assumed that in the extracted similar change cases, work shift 23 was ultimately created by assignment adjustments in response to the change request 22. In work shift 23, the work style assignments have been changed in the assignment slots for worker A5 from Wednesday to Saturday, the assignment slots for worker A6 from Thursday to Sunday, and the assignment slots for worker A7 on Thursday, Saturday, and Sunday, from the original work shift 21. Therefore, these assignment slots are identified as changed assignment slots. In Figure 1, these assignment slots are represented by thick solid lines.
[0018] Processing Unit 2 performs an optimization calculation to optimize the assignment of work patterns in work shift 11, using the range of the changeable assignment slots within the assignment slots included in work shift 11 as the changeable range for work pattern assignment. Figure 1 illustrates work shift 13 in which work pattern B4 is assigned to the assignment slot to be changed by the change request 12, and the assignment slots corresponding to the changeable assignment slots (i.e., the changeable range) are left blank. Work patterns are reassigned to each assignment slot corresponding to the changeable assignment slot based on the results of the optimization calculation, thereby creating a work shift modified in accordance with the change request 12.
[0019] Here, work shift 23 is an arrangement of work patterns adjusted in response to change request 22. Therefore, if the optimization calculation is performed using only the range of changeable assignments in work shift 23 from work shift 11 as the range of changeable assignments, there is a high probability that an optimal solution that satisfies the constraints will be obtained. In other words, the above process makes it possible to perform the optimization calculation using the minimum necessary assignment range that has a high probability of obtaining the optimal solution as the range of changeable assignments. Therefore, the time required for optimization calculations to modify work shifts can be reduced.
[0020] [Second Embodiment] Figure 2 shows an example configuration of a work management system according to the second embodiment. The work management system shown in Figure 2 includes a management server 100 and user terminals 200a, 200b, 200c, ...
[0021] The management server 100 is an example of the schedule adjustment device 1 shown in Figure 1, and is a server computer that manages the work schedules of employees. In this embodiment, the management server 100 specifically manages the work shifts of multiple employees over a predetermined period. For example, the management server 100 automatically creates the work shifts of the above-mentioned multiple employees to satisfy predetermined constraints regarding work through mathematical optimization, and stores a work shift table containing the details of the work shifts. The management server 100 can also display the work shift table on a display device and accept changes to work shifts in response to user operations on user terminals 200a, 200b, 200c, etc.
[0022] User terminals 200a, 200b, 200c, ... are terminal devices operated by users. Users can be, for example, administrators who manage employee work schedules, or the employees themselves.
[0023] In the following explanation, when referring to user terminals 200a, 200b, 200c, etc. without making any particular distinction, they may be written as "user terminal 200". Figure 3 shows an example of the hardware configuration of the management server. The management server 100 is implemented as a computer, for example, as shown in Figure 3. The management server 100 shown in Figure 3 has a processor 101, RAM (Random Access Memory) 102, HDD (Hard Disk Drive) 103, GPU (Graphics Processing Unit) 104, input interface (I / F) 105, read device 106, and communication interface (I / F) 107.
[0024] The processor 101 provides comprehensive control over the entire management server 100. The processor 101 may be, for example, a CPU (Central Processing Unit), an MPU (Micro Processing Unit), a DSP (Digital Signal Processor), an ASIC (Application Specific Integrated Circuit), or a PLD (Programmable Logic Device). Alternatively, the processor 101 may be a combination of two or more elements from among the CPU, MPU, DSP, ASIC, and PLD.
[0025] RAM 102 is used as the main memory of the management server 100. At least a portion of the OS (Operating System) program and application programs to be executed by the processor 101 are temporarily stored in RAM 102. Additionally, various data necessary for processing by the processor 101 are stored in RAM 102.
[0026] HDD103 is used as auxiliary storage for the management server 100. The OS program, application programs, and various data are stored on HDD103. Other types of non-volatile storage devices, such as SSDs (Solid State Drives), can also be used as auxiliary storage.
[0027] A display device 104a is connected to the GPU 104. The GPU 104 displays images on the display device 104a according to instructions from the processor 101. The display device 104a can be an LCD display, an OLED (Electroluminescent) display, or the like.
[0028] An input device 105a is connected to the input interface 105. The input interface 105 transmits the signals output from the input device 105a to the processor 101. The input device 105a can be a keyboard, a pointing device, or the like. The pointing device can be a mouse, touch panel, tablet, touchpad, trackball, or the like.
[0029] A portable recording medium 106a is attached to and detached from the reading device 106. The reading device 106 reads the data recorded on the portable recording medium 106a and transmits it to the processor 101. The portable recording medium 106a can be an optical disc, a semiconductor memory, or the like.
[0030] The communication interface 107 transmits and receives data with other devices such as user terminals 200a, 200b, 200c, etc., via the network 107a. The processing functions of the management server 100 can be realized with the hardware configuration described above.
[0031] Next, we will illustrate the work shifts managed by the management server 100 with an example of nurses' work shifts in a hospital. In this case, the management server 100 is, for example, integrated into an information processing system installed in the hospital. Furthermore, the processing functions of the management server 100 may be implemented not only on a server computer but also, for example, on a personal computer.
[0032] Figure 4 shows an example of a nurse's work shift. The work shift table 131 shown in Figure 4 is a table showing the weekly work shifts of seven nurses N1 to N7. The columns of the work shift table 131 contain the day of the week (or date), and the records contain the nurse's identification information. In addition, each field of the work shift table 131 contains the work type for each nurse on the corresponding day of the week. In this embodiment, four types of work types are applied: "day shift," "night shift," "after night shift," and "day off." The work types are stored in the management server 100 together with the work shift table 131, for example, as a work type table 132 shown in Figure 4.
[0033] Furthermore, in this embodiment, as an example, the following four constraints C1 to C4 exist regarding the determination of work shifts. (Constraint C1) There must be at least three daytime workers on each day of the week.
[0034] (Constraint C2) The day following a night shift is considered a day off from night shift work. (Constraint C3) The day following a night shift shall be a day off. (However, this does not apply if a night shift or the day after a night shift falls on a weekend.) (Constraint C4) At least one person is required to work the night shift on each day of the week.
[0035] For example, if a manager, such as a head nurse, manually creates work shifts that satisfy constraints C1 to C4, there is a problem of a heavy workload. In reality, managers must create work shifts considering not only the constraints but also the nurses' preferences, making the workload extremely heavy. Furthermore, managers must revise the work shifts every time there are sudden changes in schedules such as surgeries or changes in nurses' preferences, further increasing the workload.
[0036] In response to this, the management server 100 can automatically create work shifts that satisfy the above constraints C1 to C4 through mathematical optimization. In mathematical optimization, the objective (requirements) and constraints are formalized, and the optimal solution that satisfies the objective and constraints is calculated.
[0037] Figure 5 is a diagram illustrating the formulation. In the work shift schedule 131 above, only one work schedule can be assigned to each field. Therefore, as shown in Figure 5, four additional columns corresponding to four different work schedules are added to each day of the week in the work shift schedule 131. Then, x is defined as the work schedule of nurse n on a given day of the week being m. n,m This is expressed as follows. The goal is to satisfy constraints C1 to C4 while reducing the number of night shifts for each nurse.
[0038] If N={1,2,3,...,7}, D={1,2,3,...,28}, S0={4i|i=0,1,2,...,6}, S1={4i+1|i=0,1,2,...,6}, S2={4i+2|i=0,1,2,...,6}, S3={4i+3|i=0,1,2,...,6}, then constraints C1~C4 are expressed by equations (1-1)~(1-6) below, and the objective function is expressed by equation (2).
[0039]
number
[0040] The management server 100 calculates the optimal solution that minimizes the objective function in equation (2). However, if an initial value exists, that initial value (0 or 1) is added as a constraint. The management server 100 can also calculate the optimal solution for the remaining allocation slots (fields) while considering a nurse's preferred work schedule for a particular day of the week (i.e., fixing the work schedule in a certain field). By enabling the automatic creation of work shifts in this way, the workload of administrators can be reduced.
[0041] In actual workplaces, work shifts that satisfy the constraints are not always adopted, and the shift content may be adjusted at the discretion of the manager. The management server 100 can accept adjustment operations from the manager regarding the work shift output as the optimal solution, and can also store the adjusted work shift.
[0042] Next, let's discuss changes to work shifts. For example, there may be cases where you want to change the work schedule of a particular nurse on a specific day of the week in an existing work shift. The assignment slot to be changed is referred to as the "requested change slot." In this case, the management server 100 changes the work schedule for the requested change slot and calculates the optimal solution within the range of readjustment for the remaining assignment slots.
[0043] This calculation should ideally be performed with a limited scope of readjustment, so as not to alter existing work assignments as much as possible. This is for operational reasons, such as minimizing schedule changes and avoiding disruption, as well as for technical reasons: a larger scope of readjustment increases the computational load and the time required to find the optimal solution. Because the optimization calculation is computationally intensive, if the scope of readjustment is too broad, it may not be possible to obtain the optimal solution within a practical timeframe.
[0044] However, there are challenges in determining the appropriate range for readjustment. For example, a wider range of readjustment increases computation time, as described above, but makes it easier to obtain a solution that satisfies the constraints. On the other hand, narrowing the range of readjustment reduces the number of available work slots that can be modified, making it more difficult to obtain a solution that satisfies all constraints. Therefore, determining an appropriate range for readjustment is challenging.
[0045] Therefore, in this embodiment, the management server 100 extracts work shifts with the same requested change slot from a database that records past work shift changes. Then, the management server 100 determines the range of readjustment in the current work shift schedule based on the readjusted shift content for the extracted work shifts. By determining the range of new readjustment from previously readjusted content, the range of readjustment is minimized, and the optimal solution is calculated in a short calculation time.
[0046] Figure 6 shows an example of the configuration of the processing functions provided by the management server. As shown in Figure 6, the management server 100 includes a storage unit 110, a change request receiving unit 121, a change content determination unit 122, an impact range calculation unit 123, a reallocation processing unit 124, and an adjustment result output unit 125.
[0047] The storage unit 110 is a storage area reserved in the storage device provided by the management server 100, such as RAM 102 and HDD 103. The storage unit 110 stores shift setting information 111, the pre-change shift database (DB) 112, the post-change shift database (DB) 113, and the adjusted shift database (DB) 114.
[0048] Shift setting information 111 stores information about currently set work shifts. For example, shift setting information 111 stores one or more work shift schedules showing the work shifts of specific nurses for a predetermined period. In addition, shift setting information 111 stores data indicating constraints associated with each work shift schedule.
[0049] The pre-change shift database 112, the post-change shift database 113, and the adjusted shift database 114 contain information indicating past change cases where work shifts were modified. These databases will be explained using Figure 7 below.
[0050] Figure 7 shows an example of the data structure of the pre-change shift database, post-change shift database, and adjusted shift database. The pre-change shift database 112 contains one or more past pre-change shifts 112a. The post-change shift database 113 contains past post-change shifts 113a that correspond to any of the past pre-change shifts 112a registered in the pre-change shift database 112. The adjusted shift database 114 contains past adjusted shifts 114a that correspond to any of the past post-change shifts 113a registered in the post-change shift database 113.
[0051] The previous pre-change shift 112a shows the work shift schedule before the change was requested in the past. The previous post-change shift 113a shows the work shift schedule in which only the work style of the requested change slots (fields) of the corresponding previous pre-change shift 112a has been changed to the new work style. The previous adjusted shift 114a shows the work shift schedule in which the work style assignments for the allocation slots other than the requested change slots have been readjusted compared to the corresponding previous post-change shift 113a.
[0052] Note that past adjusted shifts 114a represent the final work shift schedule, regardless of whether the readjustment of assignments in response to change requests was performed by optimization calculations or by administrator input. Therefore, past adjusted shifts 114a do not necessarily satisfy all essential constraints and may have been created based on the administrator's discretion or experience, for example.
[0053] Returning to Figure 6, the processing of the change request receiving unit 121, the change content determination unit 122, the impact scope calculation unit 123, the reallocation processing unit 124, and the adjustment result output unit 125 is realized, for example, by the processor 101 executing a predetermined application program. The processing of these processing blocks will be explained using Figure 8 below.
[0054] Figure 8 is an example flowchart showing the entire process of changing work shifts by the management server. [Step S11] The change request receiving unit 121 receives a request from the user terminal 200 to change the work schedule assignment. At this time, the change request receiving unit 121 obtains the pre-change shift, which shows the existing work shift schedule to be changed, and the post-change shift, which shows the work shift schedule in which only the work schedule for the requested change slot has been changed from the pre-change shift.
[0055] [Step S12] The change content determination unit 122 obtains the pre-change shift and post-change shift from the change request reception unit 121, and determines the assignment change content by taking the difference between them. [Step S13] The impact scope calculation unit 123 refers to the pre-change shift database 112, the post-change shift database 113, and the adjusted shift database 114 to identify past change cases with similar change requests for the work shift schedule. Then, based on the past adjusted shifts corresponding to the identified change cases, the impact scope calculation unit 123 identifies the allocation slots whose work patterns were changed by the readjustment of assignments in response to the change request as the "impact scope," which indicates the allocation slots affected by the readjustment.
[0056] [Step S14] The reassignment processing unit 124 adjusts the assignment of work patterns within the affected range from the modified shifts obtained in step S11. [Step S15] The adjustment result output unit 125 outputs the adjusted work shifts, in which the work patterns have been assigned, to the user terminal 200 as the adjustment result.
[0057] Figure 9 is a diagram illustrating the calculation of differences and distances in work shift schedules. In steps S12 and S13 of Figure 8, differences and similarities in work shift schedules are calculated. In this embodiment, in order to perform these calculations, the work pattern information registered in each assignment slot (field) of the work shift schedule is one-hot encoded.
[0058] Specifically, a row for work patterns is added to the work shift schedule, and the column corresponding to each day of the week is split into four columns, each corresponding to one of the four work patterns. Then, in the field corresponding to each of the split columns, "1" is set if the corresponding work pattern is set, and "0" is set if it is not set. In this way, the information in each field of the original work shift schedule is converted into a four-digit bit string. For a particular nurse, only one of the four work patterns is set in the field corresponding to a particular day of the week, so only one digit of the four-digit bit string will be "1".
[0059] Figure 9 illustrates two work shift schedules for comparison: Schedule 141, in which a row for work type has been added to one of the work shift schedules; and Schedule 142, in which a row for work type has been added to the other work shift schedule. However, it is assumed that the number of nurses is the same in Schedule 141 and 142.
[0060] In work shift schedule 141, if nurse N11 is assigned a day shift on Monday, the information in the corresponding field in the original work shift schedule is converted to a bit string [1,0,0,0] by one-hot encoding. In this way, the information for one week's worth of records for nurse N11 is converted to a 4x7 bit string Bp1. Similarly, the information for one week's worth of records for nurse N12 is converted to a bit string Bp2, the information for one week's worth of records for nurse N13 is converted to a bit string Bp3, and the information for one week's worth of records for nurse N14 is converted to a bit string Bp4. Then, by combining the bit strings corresponding to each nurse, the work assignment information in work shift schedule 141 is converted to a bit string p.
[0061] Similarly, in the work shift schedule 142, the information for one week's worth of records for nurse N21 is converted into bit string Bq1, and the information for one week's worth of records for nurse N22 is converted into bit string Bq2. Furthermore, the information for one week's worth of records for nurse N23 is converted into bit string Bq3, and the information for one week's worth of records for nurse N24 is converted into bit string Bq4. Then, by combining the bit strings corresponding to each nurse, the work assignment information in the work shift schedule 142 is converted into bit string q.
[0062] The difference between work shift schedules is obtained by calculating the difference between the bit strings corresponding to each work shift schedule. Specifically, bit values of the same digit are compared between the bit strings, and a bit string showing the difference is calculated, where "1" is used if the bit values are different and "0" is used if the bit values are the same. From this calculation result, the position information of the assignment slots with different work patterns is obtained from the original work shifts being compared.
[0063] Furthermore, the similarity between work shifts can be obtained by calculating the Euclidean distance between the bit strings corresponding to each work shift schedule. For example, the bit values of bit string p from the beginning are p1, p2, ..., p n Let the bit values of the bit string q be q1, q2, ..., q from the beginning. n Therefore, the Euclidean distance d(p,q) between each corresponding work shift is calculated using the following equation (3).
[0064]
number
[0065] Next, we will explain in detail the process shown in Figure 8. Figure 10 is a diagram illustrating the processing of the change request receiving unit and the change content determination unit.
[0066] In step S11 of Figure 8, the change request receiving unit 121 receives a request from the user terminal 200 to change the work schedule assignment. Here, as an example, let's assume that the change request receiving unit 121 obtains the pre-change shift 151 and post-change shift 152 as shown in Figure 10 in response to the assignment change request. The pre-change shift 151 is the existing work shift schedule for one week for nurses N1 to N7. For example, the change request receiving unit 121 receives a specification of an existing work shift schedule from the user terminal 200, creates the specified work shift schedule based on the shift setting information 111, and obtains it as the pre-change shift 151.
[0067] Furthermore, the modified shift 152 is a work shift schedule in which one or more of the assignment slots (fields) of the original shift 151 have been changed. The change request receiving unit 121 receives an operation to modify the original shift 151 from, for example, the user terminal 200, and obtains the modified original shift 151 as the modified shift 152. In Figure 10, as an example, it is assumed that a change request has been received to change the work schedule of nurse N4 on Tuesday from night shift to day off.
[0068] The change determination unit 122 converts the information in each field of the pre-change shift 151 into a bit string by one-hot encoding, and converts the information in each field of the post-change shift 152 into a bit string by one-hot encoding. Then, the change determination unit 122 determines the change in the work assignment for the pre-change shift 151 by calculating the difference between each bit string.
[0069] In the example in Figure 10, Nurse N4's Tuesday work schedule has been changed from night shift to day off. In this case, the position corresponding to "Tuesday" and "Nurse N4" is identified as the change position in the field in the modified shift 152, and change position information 153 indicating this position is output. Change position information 153 is written in JSON (JavaScript Object Notation, JavaScript is a trademark) format, for example.
[0070] As another example, the change request receiving unit 121 may receive information from the user terminal 200 indicating the change position and content in the pre-change shift 151. In this case, the change request receiving unit 121 creates the post-change shift 152 based on the pre-change shift 151 and the information indicating the change position and content. The change position information 153 can be created based on the information indicating the change position and content received from the user terminal 200.
[0071] Figure 11 is an example flowchart showing the procedure for determining the contents of the assignment change. The process in Figure 11 corresponds to the process in step S12 of Figure 8. [Step S21] The change determination unit 122 obtains the shift before change 151 and the shift after change 152.
[0072] [Step S22] The change determination unit 122 converts the information of each field of the pre-change shift 151 into a bit string by one-hot encoding, and converts the information of each field of the post-change shift 152 into a bit string by one-hot encoding. The change determination unit 122 calculates the difference between each bit string.
[0073] [Step S23] The change determination unit 122 creates change location information indicating the location of the field where the work schedule has been changed, based on the difference calculation result. The change determination unit 122 outputs the created change location information to the impact range calculation unit 123 along with data indicating the pre-change shift 151 and the post-change shift 152.
[0074] Figure 12 is a diagram illustrating the process by which the impact scope calculation unit extracts similar work shifts. In step S13 of Figure 8, the impact scope calculation unit 123 refers to the pre-change shift database 112, the post-change shift database 113, and the adjusted shift database 114 to identify past change cases with similar change requests for the work shift schedule.
[0075] Specifically, the impact range calculation unit 123 first searches the pre-change shift database 112 for past pre-change shifts similar to the pre-change shift 151. In this similarity search, the impact range calculation unit 123 converts both the pre-change shift 151 and the past pre-change shifts in the pre-change shift database 112 into bit strings using one-hot encoding. Then, the impact range calculation unit 123 calculates the Euclidean distance between the bit string corresponding to the pre-change shift 151 and the bit string of the past pre-change shift using the aforementioned equation (3), and calculates the reciprocal of the Euclidean distance as the similarity score.
[0076] The impact scope calculation unit 123 extracts past pre-change shifts from the pre-change shift database 112 whose similarity to the pre-change shift 151 is above a predetermined threshold. Alternatively, the impact scope calculation unit 123 extracts a predetermined number of past pre-change shifts from the pre-change shift database 112 in descending order of similarity to the pre-change shift 151. In Figure 12, it is assumed that past pre-change shifts 161a to 161c have been extracted by this similarity search.
[0077] Here, the pre-change shift database 112 also registers past pre-change shifts where, for example, the number of nurses included in the work shift or the constraints for creating the work shift differ from the pre-change shift 151. Through the similarity search described above, it becomes possible to extract past pre-change shifts from the pre-change shift database 112 that are highly likely to have the same number of nurses and constraints as the pre-change shift 151.
[0078] Next, the impact range calculation unit 123 extracts the past post-change shifts 162a to 162c corresponding to each of the extracted past pre-change shifts 161a to 161c from the post-change shift database 113. Then, the impact range calculation unit 123 searches for past post-change shifts similar to post-change shift 152 from among the extracted past post-change shifts 162a to 162c. In this similarity search, the impact range calculation unit 123 converts post-change shift 152 and each of the past post-change shifts 162a to 162c into bit strings using one-hot encoding. Then, the impact range calculation unit 123 calculates the Euclidean distance between the bit string corresponding to post-change shift 152 and the bit strings corresponding to each of the past post-change shifts 162a to 162c using equation (3), and calculates the reciprocal of the Euclidean distance as the similarity score.
[0079] The impact scope calculation unit 123 extracts the past modified shifts 162a to 162c that have the highest degree of similarity to the modified shift 152. This allows the extraction of past modified shifts where the original work shift schedule before the change was similar to the pre-change shift 151, and where the position of the requested assignment slot is likely to be the same as the position of the requested slot in the modified shift 152. In Figure 12, as an example, it is assumed that past modified shift 162a was extracted as such a past modified shift.
[0080] Next, the impact scope calculation unit 123 extracts the past adjusted shift 163a corresponding to the extracted past modified shift 162a from the adjusted shift database 114. Through this process, combinations of past pre-change shift 161a, past modified shift 162a, and past adjusted shift 163a are extracted as past change cases with similar change requests.
[0081] Figure 13 is a diagram illustrating the process of identifying the scope of influence. The influence scope calculation unit 123 then calculates the difference between the extracted past modified shift 162a and the extracted past adjusted shift 163a. The difference is calculated by taking the bitwise difference between the bit sequence obtained by converting the past modified shift 162a using one-hot encoding and the bit sequence obtained by converting the past adjusted shift 163a using one-hot encoding.
[0082] The impact range calculation unit 123 calculates the difference and identifies the allocation slots from the past adjusted shift 163a that have a different work schedule allocation than the past modified shift 162a. The allocation slots identified by this process are those whose work schedule allocation has been adjusted (the allocation has been changed) in response to the change in Nurse N4's Tuesday schedule. The impact range calculation unit 123 uses the range of the identified allocation slots as the impact range and creates location information 164 for that range.
[0083] In the example in Figure 13, the allocation slots included in the affected area are shown with thick lines. In Figure 13, it is assumed that the allocation slots for nurse N5 on Tuesday, the allocation slots for nurses N4 and N5 on Wednesday, the allocation slots for nurses N4 and N5 on Thursday, the allocation slots for nurses N4 and N5 on Saturday, and the allocation slots for nurses N4 and N5 on Sunday have been identified as the affected area. In addition, in the example in Figure 13, location information 164 includes not only the location information of the allocation slots included in the affected area, but also the location information of the slot to be changed (nurse N4's allocation slot on Tuesday). Note that, similar to the change location information 153 mentioned above, the location information 164 of the affected area is described in JSON format, for example.
[0084] The scope of impact identified in this way represents the range where the change requests are similar and where the allocation has been changed and finalized in response to the change requests. Therefore, it is considered highly likely that the optimal solution can be obtained in a short time by performing the optimization calculation limited to the same scope of impact in the post-change shift 152.
[0085] Figure 14 is an example flowchart showing the procedure for identifying the scope of impact. The process in Figure 14 corresponds to step S13 in Figure 8. [Step S31] The influence range calculation unit 123 searches the pre-change shift database 112 for past pre-change shifts similar to the pre-change shift 151. In this process, for example, one or more past pre-change shifts whose similarity (reciprocal of the Euclidean distance) to the pre-change shift 151 is greater than or equal to a predetermined threshold are found in the pre-change shift database 112. Alternatively, a predetermined number of past pre-change shifts are found in the pre-change shift database 112 in descending order of similarity to the pre-change shift 151.
[0086] [Step S32] The impact scope calculation unit 123 extracts the past post-change shifts corresponding to each of the past pre-change shifts found in step S31 from the post-change shift database 113.
[0087] [Step S33] The influence range calculation unit 123 extracts past modified shifts from the past modified shifts extracted in step S32 that are similar to the modified shift 152 corresponding to the pre-modified shift 151. In this process, the past modified shift with the highest similarity is extracted from among the past modified shifts whose similarity (reciprocal of the Euclidean distance) to the modified shift 152 is equal to or greater than a predetermined threshold.
[0088] However, if there are no past modified shifts with a similarity above a threshold, it becomes impossible to automatically correct the work shift using past modification cases. In this case, for example, the reassignment processing unit 124 performs an optimization calculation using all assignment slots other than the requested change slot in the modified shift 152 as the adjustment range. For example, if an optimal solution is obtained within a predetermined time, the adjustment result based on the optimal solution is displayed on the user terminal 200, and if an optimal solution is not obtained within a predetermined time, information indicating that no adjustment result was obtained is displayed on the user terminal 200.
[0089] [Step S34] The impact range calculation unit 123 extracts past adjusted shifts corresponding to the past modified shifts extracted in step S33 from the adjusted shift database 114.
[0090] [Step S35] The impact scope calculation unit 123 identifies the impact scope of the changes to the work schedule assignment in response to the assignment change request, based on the difference between the past modified shifts extracted in step S33 and the past adjusted shifts extracted in step S34.
[0091] Figure 15 is a diagram illustrating the initial processing by the reassignment processing unit. The reassignment processing unit 124 first applies the work patterns assigned to each assignment slot within the same affected range identified from the past adjusted shift 163a to each assignment slot within the same affected range in the modified shift 152. For example, the work pattern that the 5th nurse (Nurse N5) was assigned to on Tuesday in the past adjusted shift 163a is assigned to the 5th nurse (Nurse N5) on Tuesday in the modified shift 152. Also, the work pattern that the 4th nurse (Nurse N4) was assigned to on Wednesday in the past adjusted shift 163a is assigned to the 4th nurse (Nurse N4) on Wednesday in the modified shift 152.
[0092] The reallocation processing unit 124 then calculates the constraint satisfaction rate for the modified shift 152a whose assignment has been corrected by this fitting. The satisfaction rate indicates the percentage of constraints C1 to C4 that are satisfied. If the satisfaction rate is equal to or greater than a predetermined threshold (e.g., 100%), the reallocation processing unit 124 outputs the modified shift 152a after the assignment correction to the user terminal 200 as the final adjustment result.
[0093] On the other hand, if the satisfaction rate is below the threshold, the reassignment processing unit 124 performs an optimization calculation to adjust the work schedule assignment within the scope of influence in the modified shift 152a. In this process, the optimization calculation is repeated while changing the initial values for the calculation until the satisfaction rate of the constraints exceeds the threshold. Specifically, the optimization calculation is performed while gradually expanding the range of the assignment slots for reassigning work schedules within the scope of influence.
[0094] Here, as an example, we will assume that the optimization calculation is performed while changing the range of initial value changes in three stages, as illustrated in Figures 16 to 18 below. Figure 16 is the first diagram showing the initial value change pattern. The reassignment processing unit 124 first adjusts the work schedule assignment using the initial value change pattern P1 shown in Figure 16.
[0095] In initial value change pattern P1, the allocation slots for other days of the week that fall within the affected range for the nurse whose allocation change has been requested will be subject to adjustment. In the example in Figure 16, the allocation slots for nurse N4 on Wednesday, Thursday, Saturday, and Sunday will be subject to adjustment.
[0096] The reallocation processing unit 124 performs optimization calculations while changing the initial values of the variables related to the allocation slots to be adjusted. The reallocation processing unit 124 then calculates the constraint satisfaction rate for the obtained optimal solution, and if the satisfaction rate is above a threshold, it outputs the solution as the adjustment result. On the other hand, if the satisfaction rate is below the threshold, the reallocation processing unit 124 readjusts the work schedule allocation using the initial value change pattern P2 shown in Figure 17.
[0097] Figure 17 is a second diagram showing the initial value change pattern. In the initial value change pattern P2 shown in Figure 17, in addition to the adjustment targets in initial value change pattern P1, the assignment slots of other nurses, excluding the nurse whose assignment change was requested, that fall within the scope of influence will be subject to assignment adjustment on the day of the week in which the assignment change was requested. In the example in Figure 17, the assignment slot of nurse N5 on Tuesday will be the new target of adjustment.
[0098] The reallocation processing unit 124 performs optimization calculations while changing the initial values of the variables related to the allocation slots to be adjusted. The reallocation processing unit 124 then calculates the constraint satisfaction rate for the obtained optimal solution, and outputs the solution as the adjustment result if the satisfaction rate is above a threshold. On the other hand, if the satisfaction rate is below the threshold, the reallocation processing unit 124 readjusts the work schedule assignments using the initial value change pattern P3 shown in Figure 18.
[0099] Figure 18 is the third figure showing the initial value change pattern. In the initial value change pattern P3 shown in Figure 18, all allocation slots included in the affected range are subject to allocation adjustment. In the example in Figure 18, the allocation slots for nurse N5 on Tuesday, the allocation slots for nurses N4 and N5 on Wednesday, the allocation slots for nurses N4 and N5 on Thursday, the allocation slots for nurses N4 and N5 on Saturday, and the allocation slots for nurses N4 and N5 on Sunday are subject to adjustment. The reallocation processing unit 124 performs optimization calculations while changing the initial values of the variables related to the allocation slots to be adjusted, and outputs the solution as the adjustment result.
[0100] In this way, the optimization calculation to adjust the work schedule assignment is performed only within the scope of influence of the modified shift 152a. This reduces the calculation time compared to adjusting the entire modified shift 152a. Furthermore, as mentioned above, the scope of influence refers to the range where the change requests are similar and the assignments have been changed and finalized in response to the change requests. Therefore, when the optimization calculation is performed only within the scope of influence of the modified shift 152a, as described above, the probability of obtaining the optimal solution does not decrease significantly compared to when adjusting the entire modified shift 152a. Consequently, the probability of obtaining the optimal solution in a short time increases.
[0101] Furthermore, in the above process, the optimization calculation is performed while gradually expanding the adjustment range of the allocation within the affected area. This makes it possible to obtain the optimal solution in a shorter time compared to when the entire affected area is used as the adjustment range from the beginning, and a reduction in the time required to output the adjustment results can be expected.
[0102] Alternatively, the reallocation processing unit 124 may perform the optimization calculation using the initial value change patterns P1 to P3 described above only within a predetermined time, and after that time has elapsed, terminate the calculation and output the provisional solution at that point as the adjustment result. In this case, the time required to output the adjustment result will be within a practical timeframe.
[0103] Figure 19 is an example flowchart showing the procedure for adjusting work schedule assignments. The process in Figure 19 corresponds to step S14 in Figure 8. [Step S41] The reassignment processing unit 124 applies the work patterns assigned to the allocation slots included in the affected range among the past adjusted shift allocation slots extracted by the affected range calculation unit 123 to the allocation slots at the same position in the modified shift 152. This creates a provisional adjusted shift, known as a "provisional shift".
[0104] [Step S42] The reallocation processing unit 124 calculates the satisfaction rate of the constraints corresponding to the original shift 151 for the provisional shift created in step S41. [Step S43] The reallocation processing unit 124 determines whether the satisfaction rate calculated in step S42 is equal to or greater than a predetermined threshold (for example, 100%) (i.e., whether the constraint is met). If the satisfaction rate is equal to or greater than the threshold, the process proceeds to step S49; if the satisfaction rate is less than the threshold, the process proceeds to step S44.
[0105] Furthermore, if there are both mandatory and non-mandatory constraints corresponding to the shift 151 before the change, step S43 only needs to determine whether the satisfaction rate of the mandatory constraints is above a threshold.
[0106] [Step S44] The reallocation processing unit 124 performs an optimization calculation while changing the initial values of the variables within the current provisional shift's influence range. In this process, as described above, the optimization calculation is repeated while gradually expanding the range of initial value changes within the influence range.
[0107] [Step S45] The reallocation processing unit 124 determines whether the calculation time for the optimization calculation (the time elapsed since the determination of "No" in step S43) exceeds a predetermined specified time. If the calculation time does not exceed the specified time, the process proceeds to step S46; if it exceeds the specified time, the process proceeds to step S49.
[0108] [Step S46] The reallocation processing unit 124 determines whether a solution has been obtained for the optimization calculation. If a solution has not been obtained, the process proceeds to step S44 and the optimization calculation continues. On the other hand, if a solution has been obtained, the process proceeds to step S47.
[0109] [Step S47] The reallocation processing unit 124 updates the current provisional shift based on the obtained solution. [Step S48] The reallocation processing unit 124 calculates the constraint satisfaction rate for the updated provisional shift and determines whether the satisfaction rate is above the threshold (whether the constraint is satisfied). The same value as in step S43 may be used as the threshold. If the satisfaction rate is above the threshold, the process proceeds to step S49. On the other hand, if the satisfaction rate is below the threshold, the process proceeds to step S44. In this case, the optimization calculation is performed by expanding the range of initial value changes within the scope of influence.
[0110] [Step S49] The reallocation processing unit 124 determines the current provisional shift as the adjustment result (adjusted shift). Figure 20 is an example flowchart showing the procedure for outputting the adjustment results. The process in Figure 20 corresponds to the process in step S15 of Figure 8.
[0111] [Step S51] The adjustment result output unit 125 outputs the adjusted shift determined by the reassignment processing unit 124 to the user terminal 200 and displays it on the display device. [Step S52] The adjustment result output unit 125 can accept user operation to change the displayed adjusted shift. If an operation to change the adjusted shift is accepted, the process proceeds to step S53. On the other hand, if no change operation is performed and an operation to confirm the displayed adjusted shift is performed, the process proceeds to step S54.
[0112] [Step S53] The adjustment result output unit 125 changes the work schedule assignment in the adjusted shift in accordance with the user's change operation. After that, when the operation to confirm the adjusted shift with the changed assignment is performed, the process proceeds to step S54.
[0113] [Step S54] The adjustment result output unit 125 registers the pre-change shift 151 corresponding to the adjusted shift as a past pre-change shift in the pre-change shift database 112. The adjustment result output unit 125 also registers the changed shift 152 corresponding to the adjusted shift as a past changed shift in the changed shift database 113, by associating it with the past pre-change shifts registered in the pre-change shift database 112. Furthermore, the adjustment result output unit 125 registers the adjusted shift as a past adjusted shift in the changed shift database 114, by associating it with the past pre-change shifts and past changed shifts registered in the pre-change shift database 112 and the changed shift database 113, respectively.
[0114] In the second embodiment described above, nurses were used as an example of employees, but employees may be other types of employees who work in shifts, such as call center operators. Furthermore, while the first and second embodiments described the modification of work shift schedules, the table assignment adjustment techniques in the first and second embodiments are applicable to cases where any of multiple resources such as people, things, and events are assigned to each field of a table where so-called people, things, and events are set as columns and records.
[0115] Furthermore, the processing functions of the devices shown in each of the above embodiments (for example, the schedule adjustment device 1 and the management server 100) can be implemented by a computer. In this case, a program describing the processing content of the functions that each device should have is provided, and by executing that program on the computer, the above processing functions are implemented on the computer. The program describing the processing content can be recorded on a recording medium that can be read by a computer. Examples of recording media that can be read by a computer include magnetic storage devices, optical discs, and semiconductor memory. Examples of magnetic storage devices include hard disk drives (HDDs) and magnetic tapes. Examples of optical discs include CDs (Compact Discs), DVDs (Digital Versatile Discs), and Blu-ray Discs (BD, registered trademark).
[0116] When distributing a program, portable recording media such as DVDs and CDs containing the program are sold. Alternatively, the program can be stored in the storage device of a server computer and transferred from the server computer to other computers via a network.
[0117] A computer executing a program stores programs, for example, those recorded on a portable storage medium or transferred from a server computer, in its own memory. The computer then reads the program from its memory and executes the processing according to the program. Alternatively, the computer can directly read the program from the portable storage medium and execute the processing according to that program. Furthermore, the computer can sequentially execute the processing according to the programs received from a server computer connected via a network, each time a program is transferred. [Explanation of Symbols]
[0118] 1. Schedule adjustment device 2 Processing Units 3 Databases Work shifts: 11, 13, 21, 23 12,22 Change request
Claims
1. On the computer, From the first work shift, in which work patterns are assigned to each of the multiple time slots and each of the multiple workers within a predetermined period, a request for a change in work pattern for the first assignment slot is accepted. From a database containing multiple past examples of changes to work shifts, similar change examples are extracted where the content of the work pattern change request is similar to the content of the change requested in the aforementioned change request. In the aforementioned similar change case, one or more second assignment slots whose work patterns were changed by assignment adjustments in response to the request for change are identified from among the assignment slots included in the second work shift before the change. The scope of the one or more second assignment slots included in the first work shift is defined as the range within which the work pattern assignment can be changed, and an optimization calculation is performed to optimize the work pattern assignment in the first work shift. A scheduling program that controls the execution of processes.
2. The database registers, as examples of the changes, the third work shift before the change, the fourth work shift in which only the allocation slots that were requested to be changed in the third work shift have been changed, and the fifth work shift obtained by performing the allocation adjustment on the fourth work shift, in association with each other. In extracting similar change cases, one or more sixth work shifts similar to the first work shift are extracted from the third work shifts registered in the database, and a seventh work shift in which only the allocation slot subject to the change request is changed in the first work shift is extracted from the fourth work shifts corresponding to each of the one or more sixth work shifts. In identifying the one or more second allocation slots, the one or more second allocation slots are identified based on the difference between the seventh work shift and the fifth work shift corresponding to the seventh work shift registered in the database. The schedule adjustment program according to claim 1.
3. To the aforementioned computer, Once the one or more second allocation slots are identified, the modified work patterns assigned to each of the one or more second allocation slots are directly assigned to the modifiable range in the first work shift to create an eighth work shift. For the eighth work shift, calculate the satisfaction rate of the constraints corresponding to the first work shift. If the fulfillment rate is equal to or greater than a predetermined threshold, the eighth work shift is assigned and output as an adjustment result. Execute the process, The optimization calculation is performed when the satisfaction rate is less than the threshold. A schedule adjustment program according to claim 1 or 2.
4. In the execution of the aforementioned optimization calculation, While expanding the modifiable range within the range of one or more second assignment slots included in the first work shift, the optimization calculation is repeatedly performed until the satisfaction rate of the constraints corresponding to the first work shift for the work shift obtained as the optimal solution in the optimization calculation exceeds a predetermined threshold. A schedule adjustment program according to claim 1 or 2.
5. Computers From the first work shift, in which work patterns are assigned to each of the multiple time slots and each of the multiple workers within a predetermined period, a request for a change in work pattern for the first assignment slot is accepted. From a database containing multiple past examples of changes to work shifts, similar change examples are extracted where the content of the work pattern change request is similar to the content of the change requested in the aforementioned change request. In the aforementioned similar change case, one or more second assignment slots whose work patterns were changed by assignment adjustments in response to the request for change are identified from among the assignment slots included in the second work shift before the change. The scope of the one or more second assignment slots included in the first work shift is defined as the range within which the work pattern assignment can be changed, and an optimization calculation is performed to optimize the work pattern assignment in the first work shift. How to adjust your schedule.
6. From the first work shift, in which work patterns are assigned to each of the multiple time slots and each of the multiple workers within a predetermined period, a request for a change in work pattern for the first assignment slot is accepted. From a database containing multiple past examples of changes to work shifts, similar change examples are extracted where the content of the work pattern change request is similar to the content of the change requested in the aforementioned change request. In the aforementioned similar change case, one or more second assignment slots whose work patterns were changed by assignment adjustments in response to the request for change are identified from among the assignment slots included in the second work shift before the change. A processing unit performs an optimization calculation to optimize the work schedule assignment in the first work shift, with the range of one or more second assignment slots from among the assignment slots included in the first work shift being defined as the range within which the work schedule assignment can be changed. A scheduling device having the following features.