Method and apparatus for assigning orders
Patent Information
- Application Number
- CN202611007441.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-07-07
- Publication Date
- 2026-10-09
AI Technical Summary
[0003]上述几种方式普遍存在以下技术缺陷:位置匹配精度低,未能充分利用揽收人员的实时位置;缺乏对订单负载(如订单数量、空间分布、预估耗时)的量化评估,导致资源分配失衡;动态适应能力差,无法响应揽收人员位置变化、新增订单或交通拥堵等实时场景;缺少路径优化逻辑,易造成揽收路线折返
[0019]上述发明中的一个实施例具有如下优点或有益效果:通过实时采集揽收人员的位置信息、新揽收订单的客户位置以及揽收人员已接收的待揽收订单信息;根据揽收人员已接收的待揽收订单信息计算每个揽收人员的综合负载值;以新揽收订单的客户位置为中心确定候选揽收人员集合,并基于揽收人员的位置信息和客户位置计算每个候选揽收人员与客户的距离优先级,以及基于综合负载值计算每个候选揽收人员的负载优先级;根据距离优先级和负载优先级计算每个候选揽收人员的综合匹配得分,并将综合匹配得分最高的候选揽收人员确定为目标揽收人员;对目标揽收人员已接收的待揽收订单与新揽收订单进行揽收路径的动态规划,生成最优揽收顺序,并将新揽收订单的分配指令及最优揽收顺序发送给目标揽收人员的技术方案,可以实现揽收人员实时位置与订单的精准匹配,打破路区划分局限,缩短平均揽收距离;通过构建多维度订单负载评估体系,实现订单均衡分配,避免揽收人员订单堆积或闲置;建立实时动态更新机制,适配揽收人员位置变化、订单状态更新及交通拥堵等场景,提升分配策略灵活性;同时,集成了路径优化逻辑,规划最优揽收顺序,减少折返路程,降低平均揽收时长。
Smart Images

Figure CN122887566A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of logistics and distribution technology, and in particular to a method and apparatus for allocating pickup orders. Background Technology
[0002] In express delivery pickup scenarios, the efficiency of order allocation directly impacts pickup timeliness, the workload of pickup personnel, and customer experience. Currently, express delivery order allocation primarily relies on the following methods: Address matching and district allocation: Based on the customer's order address matching the preset district information, the order is allocated to the pickup personnel on duty in the corresponding district; QR code direct connection allocation: Customers place orders by scanning the pickup personnel's exclusive QR code, and the system directly binds the order to that pickup personnel; Manual allocation coordination: When automatic allocation fails (e.g., address cannot match road area, or no one is on duty in the road area), the station manager will manually allocate the address through the workbench. Simple distance allocation: Some systems only calculate the straight-line distance between the customer and the pickup personnel, and select the nearest pickup personnel for allocation.
[0003] The above methods generally suffer from the following technical defects: low location matching accuracy, failing to make full use of the real-time location of pickup personnel; lack of quantitative assessment of order load (such as order quantity, spatial distribution, and estimated time), leading to unbalanced resource allocation; poor dynamic adaptability, unable to respond to real-time scenarios such as changes in pickup personnel location, new orders, or traffic congestion; and lack of path optimization logic, which easily causes pickup routes to turn back. Summary of the Invention
[0004] In view of this, embodiments of the present invention provide a method and apparatus for allocating pickup orders, which can achieve accurate matching between the real-time location of pickup personnel and orders, break the limitations of road area division, and shorten the average pickup distance; by constructing a multi-dimensional order load assessment system, it can achieve balanced distribution of orders and avoid the accumulation or idleness of pickup personnel's orders; it establishes a real-time dynamic update mechanism to adapt to scenarios such as changes in pickup personnel's location, updates in order status, and traffic congestion, thereby improving the flexibility of the allocation strategy; at the same time, it integrates path optimization logic to plan the optimal pickup order, reduce turnaround distances, and reduce the average pickup time.
[0005] To achieve the above objectives, according to one aspect of the present invention, a method for allocating pickup orders is provided, comprising: Real-time collection of location information of pickup personnel, location of customers for new pickup orders, and information on pending pickup orders received by pickup personnel; Calculate the overall workload value of each pickup personnel based on the pickup order information received by the pickup personnel; A set of candidate pickup personnel is determined centered on the location of the customer of the new pickup order. The distance priority between each candidate pickup personnel and the customer is calculated based on the location information of the pickup personnel and the location of the customer. The load priority of each candidate pickup personnel is also calculated based on the comprehensive load value. The comprehensive matching score of each candidate pickup person is calculated based on the distance priority and the load priority, and the candidate pickup person with the highest comprehensive matching score is determined as the target pickup person; Dynamically plan the pickup path for the pending pickup orders already received by the target pickup personnel and the new pickup orders, generate the optimal pickup order, and send the allocation instruction for the new pickup orders and the optimal pickup order to the target pickup personnel.
[0006] Optionally, the location information of the collection personnel can be collected in real time, including: using a dual-mode positioning module of Global Positioning System and Beidou Satellite Navigation System to collect the latitude and longitude coordinates of the collection personnel at an adaptive sampling frequency; and using a Kalman filter algorithm to smooth the latitude and longitude coordinates of the collection personnel to obtain the location information of the collection personnel.
[0007] Optionally, the information on pending orders received by the collection personnel includes: the number of pending orders, their spatial distribution range, and the estimated remaining collection time. The comprehensive load value of each collection personnel is calculated based on this information, including: calculating a first load based on the number of pending orders and the maximum number of orders a collection personnel can handle per day; calculating a second load based on the spatial distribution range of the pending orders and the preset maximum collection coverage area; calculating a third load based on the estimated remaining collection time and the longest allowed collection time per period; and calculating the comprehensive load value of each collection personnel by weighted summation based on the first load, the second load, and the third load.
[0008] Optionally, the method further includes: inputting regional traffic flow data for a preset first duration into a congestion prediction model to output a road congestion coefficient for a preset second duration in the future, and correcting the estimated remaining collection time based on the road congestion coefficient.
[0009] Optionally, calculating the distance priority between each candidate pickup person and the customer based on the location information of the pickup person and the customer's location includes: calculating the actual geographical distance between each candidate pickup person and the customer based on the location information of the pickup person and the customer's location; and calculating the distance priority between each candidate pickup person and the customer based on the actual geographical distance between each candidate pickup person and the customer and a preset maximum pickup range.
[0010] Optionally, calculating the comprehensive matching score of each candidate pickup person based on the distance priority and the load priority includes: calculating the comprehensive matching score of each candidate pickup person by weighted summation based on the distance priority and the load priority, combined with preset distance priority weights and load priority weights, wherein the sum of the distance priority weights and the load priority weights is 1.
[0011] Optionally, before determining the candidate with the highest comprehensive matching score as the target candidate, the method further includes: determining that the highest comprehensive matching score is not lower than a preset threshold; and, in response to the highest comprehensive matching score being lower than the preset threshold, expanding the screening range of candidate candidates or triggering manual coordination and allocation.
[0012] Optionally, dynamic planning of collection paths is performed on the pending collection orders already received by the target collection personnel and the new collection orders to generate an optimal collection order. This includes: initializing an unvisited order set, which includes the pending collection orders already received by the target collection personnel and the new collection orders; starting from the current location of the target collection personnel, iteratively selecting the collection order closest to the current path endpoint from the unvisited order set until the unvisited order set is empty, thereby generating an optimal collection order; wherein, when there is a collection order with a priority higher than a preset level, that collection order is selected first.
[0013] Optionally, the method further includes: establishing a dynamic refresh mechanism to update the location information and comprehensive load value of the collection personnel in real time at a preset period, and triggering the adjustment of the order allocation strategy when the collection personnel complete a collection order, move their location beyond a preset distance, add a temporary collection order, or cancel a collection order.
[0014] Optionally, the method further includes: in response to detecting that the pickup personnel are offline, refuse orders, or experience a sudden failure, re-placing the new pickup order in the pending pickup order pool, and completing the re-allocation within a preset time.
[0015] According to another aspect of the present invention, an order allocation device is provided, comprising: The data acquisition module is used to collect the location information of the pickup personnel, the location of customers for new pickup orders, and the information of pending pickup orders received by the pickup personnel in real time. The comprehensive load calculation module is used to calculate the comprehensive load value of each pickup personnel based on the pickup order information received by the pickup personnel. The priority calculation module is used to determine a set of candidate pickup personnel centered on the customer location of the new pickup order, and to calculate the distance priority between each candidate pickup personnel and the customer based on the location information of the pickup personnel and the customer location, and to calculate the load priority of each candidate pickup personnel based on the comprehensive load value. The matching score calculation module is used to calculate the comprehensive matching score of each candidate pickup person based on the distance priority and the load priority, and to determine the candidate pickup person with the highest comprehensive matching score as the target pickup person; The path dynamic planning module is used to dynamically plan the collection path between the new collection order and the orders already received by the target collection personnel, generate the optimal collection order, and send the allocation instruction of the new collection order and the optimal collection order to the target collection personnel.
[0016] According to another aspect of the present invention, an electronic device is provided, comprising: one or more processors; and a storage device for storing one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement the order allocation method provided in the embodiments of the present invention.
[0017] According to another aspect of the present invention, a computer-readable medium is provided having a computer program stored thereon, which, when executed by a processor, implements the order allocation method provided in the embodiments of the present invention.
[0018] According to another aspect of the present invention, a computer program product is provided, including a computer program that, when executed by a processor, implements the order allocation method provided in the embodiments of the present invention.
[0019] One embodiment of the above invention has the following advantages or beneficial effects: It collects in real-time the location information of pickup personnel, the location of customers for new pickup orders, and the information of pending pickup orders already received by pickup personnel; calculates the comprehensive load value of each pickup personnel based on the information of pending pickup orders already received by pickup personnel; determines a set of candidate pickup personnel centered on the location of customers for new pickup orders, and calculates the distance priority between each candidate pickup personnel and the customer based on the location information of the pickup personnel and the customer location, and calculates the load priority of each candidate pickup personnel based on the comprehensive load value; calculates the comprehensive matching score of each candidate pickup personnel based on the distance priority and load priority, and determines the candidate pickup personnel with the highest comprehensive matching score as the target pickup. This technical solution involves dynamically planning pickup routes for both existing and new pickup orders received by target pickup personnel, generating the optimal pickup order, and sending the allocation instructions for new pickup orders and the optimal pickup order to the target pickup personnel. This enables precise matching of pickup personnel's real-time location with orders, breaking the limitations of road area divisions and shortening the average pickup distance. By constructing a multi-dimensional order load assessment system, it achieves balanced order distribution, avoiding order accumulation or idleness for pickup personnel. A real-time dynamic update mechanism is established to adapt to scenarios such as changes in pickup personnel's location, order status updates, and traffic congestion, improving the flexibility of allocation strategies. At the same time, it integrates route optimization logic to plan the optimal pickup order, reduce turnaround distances, and lower the average pickup time.
[0020] The further effects of the aforementioned unconventional alternative methods will be explained below in conjunction with specific implementation methods. Attached Figure Description
[0021] The accompanying drawings are provided to better understand the invention and are not intended to unduly limit the scope of the invention. Wherein: Figure 1 This is a schematic diagram illustrating the main steps of the order allocation method according to an embodiment of the present invention; Figure 2 This is a schematic diagram of the order allocation process according to an embodiment of the present invention; Figure 3 This is a schematic diagram of the main modules of the order distribution device according to an embodiment of the present invention; Figure 4 This is an exemplary system architecture diagram in which embodiments of the present invention can be applied; Figure 5 This is a schematic diagram of the structure of a computer system suitable for implementing terminal devices or servers of the present invention. Detailed Implementation
[0022] The following description, in conjunction with the accompanying drawings, illustrates exemplary embodiments of the present invention, including various details to aid understanding. These details should be considered merely exemplary. Therefore, those skilled in the art will recognize that various changes and modifications can be made to the embodiments described herein without departing from the scope and spirit of the invention. Similarly, for clarity and brevity, descriptions of well-known functions and structures are omitted in the following description.
[0023] It should be noted that the technical solutions disclosed in this invention, regarding the collection, updating, analysis, processing, use, transmission, and storage of user personal information, all comply with relevant laws and regulations, are used for legitimate purposes, and do not violate public order and good morals. Necessary measures are taken to prevent unauthorized access to user personal information data and to safeguard user personal information security, network security, and national security.
[0024] To address at least one of the technical problems in existing technologies, such as low location matching accuracy, uneven load, poor dynamic adaptability, lack of path optimization, and lagging anomaly handling, this invention provides a method for allocating pickup orders. This method dynamically allocates pickup orders based on the real-time location of pickup personnel and order load, achieving accurate, efficient, and dynamic allocation. Specifically, this invention's method achieves precise matching between the real-time location of pickup personnel and orders, breaking the limitations of road area divisions and shortening the average pickup distance. By constructing a multi-dimensional order load assessment system, it achieves balanced order allocation, avoiding order accumulation or idleness for pickup personnel. A real-time dynamic update mechanism is established to adapt to scenarios such as changes in pickup personnel location, order status updates, and traffic congestion, improving the flexibility of the allocation strategy. Simultaneously, it integrates path optimization logic to plan the optimal pickup sequence, reducing turnaround distances and lowering the average pickup time. Furthermore, this invention's method optimizes the anomaly handling process, enabling automatic secondary allocation of pickup orders, reducing manual intervention, and improving the experience for both customers and pickup personnel.
[0025] The specific implementation process of the present invention will be described below with reference to the accompanying drawings. In the description of the embodiments of the present invention, all orders mentioned refer to pickup orders.
[0026] Figure 1 This is a schematic diagram illustrating the main steps of the order allocation method according to an embodiment of the present invention. Figure 1 As shown, the order allocation method of this invention mainly includes the following steps S101 to S105.
[0027] Step S101: Real-time collection of the location information of the collection personnel, the location of the customer of the new collection order, and the information of the pending collection orders received by the collection personnel. After the collection order allocation system receives the new collection order to be allocated, the collection order allocation method of the present invention can be triggered. At this time, the location information of the collection personnel, the location of the customer of the new collection order, and the information of the pending collection orders received by the collection personnel will be collected in real time.
[0028] According to one embodiment of the present invention, real-time acquisition of the location information of the collection personnel may specifically include: using a dual-mode positioning module of Global Positioning System and Beidou Satellite Navigation System to acquire the latitude and longitude coordinates of the collection personnel at an adaptive sampling frequency; and using a Kalman filter algorithm to smooth the latitude and longitude coordinates of the collection personnel to obtain the location information of the collection personnel.
[0029] In embodiments of the present invention, the latitude and longitude coordinates (Lng, Lat) of the pickup personnel can be collected in real time using a dual-mode positioning module of GPS (Global Positioning System) and BeiDou satellite navigation system built into the terminal device used by the pickup personnel to receive pickup orders. Real-time collection is performed using an adaptive sampling frequency of 1 time / 30 seconds (which can be automatically increased to 1 time / 10 seconds during peak order periods). Simultaneously, location information can be corrected using base station assistance. Specifically, the collected location information data can be smoothed using a Kalman filter algorithm to ensure that the positioning error is ≤10 meters, thereby effectively avoiding location deviations caused by signal obstruction.
[0030] In embodiments of the present invention, in addition to collecting the location information of the pickup personnel, all pickup order information is also collected simultaneously. Specifically, two types of core order data are acquired simultaneously: newly created pickup order information (including customer's precise location coordinates, shipping time requirements, order priority, goods type, and other attributes) and pickup personnel's received pending pickup order information (including the number of pending pickup orders, customer location coordinates for each order, estimated pickup time, and delayed status markers, etc.).
[0031] After collecting the location information of the pickup personnel and all pickup order information, the collected data can be synchronized to the dispatch center in real time via the network. The WGS-84 unified coordinate system is used for coordinate calibration, and the 3σ outlier detection algorithm is used to remove invalid data such as location jumps and missing order information (data is judged as abnormal when it deviates from the mean by more than 3 times the standard deviation), ensuring the accuracy and consistency of the input data.
[0032] Step S102: Calculate the overall load value of each collection personnel based on the collection order information received by the collection personnel.
[0033] According to one embodiment of the present invention, the information on pending orders received by the collection personnel may include, for example, the number of pending orders, their spatial distribution range, and the estimated remaining collection time. Furthermore, calculating the comprehensive load value for each collection personnel based on the pending order information received may specifically include: calculating a first load based on the number of pending orders and the maximum number of orders a collection personnel can handle per day; calculating a second load based on the spatial distribution range of the pending orders and a preset maximum collection coverage area; calculating a third load based on the estimated remaining collection time and the maximum allowed collection time per time period; and calculating the comprehensive load value for each collection personnel by weighted summation based on the first, second, and third loads.
[0034] In embodiments of this invention, a comprehensive load assessment model is constructed to accurately quantify the remaining collection capacity of collection personnel and avoid load imbalance. When constructing the comprehensive load assessment model, three core load indicators are mainly selected: the number of orders to be collected (N), the spatial distribution range of orders to be collected (D, the radius of the smallest outer circle centered on the current location of the collection personnel), and the estimated remaining collection time (T, dynamically calculated based on order distribution density, historical collection speed, and road congestion coefficient). Simultaneously, a dynamic weight vector W=[0.3, 0.4, 0.3] for each load indicator can be set based on business scenario requirements, with the order spatial distribution range having the highest weight to prioritize path optimization. In specific implementation, the weights of each load indicator can be flexibly adjusted according to the enterprise's scheduling strategy; this invention does not limit this adjustment.
[0035] When quantifying the comprehensive load value using a comprehensive load assessment model, the comprehensive load value of the collection personnel can be calculated using a normalized weighted summation formula. Specifically, firstly, the first load is obtained by dividing the number of orders to be collected by the maximum number of orders a collection personnel can handle per day; the second load is obtained by dividing the spatial distribution range of the orders to be collected by the preset maximum collection coverage range; and the third load is obtained by dividing the estimated remaining collection time by the maximum allowed collection time per period. Then, by combining the preset weights of each load, a normalized weighted summation is performed to obtain the comprehensive load value of the collection personnel. The maximum number of orders a single collection personnel can handle per day can be configured, for example, as 5-15 orders; the preset maximum collection coverage range can be configured, for example, as 1-5 kilometers; and the maximum allowed collection time per period is, for example, 120 minutes by default. The calculated comprehensive load value L∈[0,1] for the collection personnel indicates that the collection personnel's load is more saturated and their remaining collection capacity is weaker.
[0036] According to one embodiment of the present invention, the method for allocating pickup orders may further include: inputting regional traffic flow data for a preset first duration into a congestion prediction model to output a road congestion coefficient for a preset second duration in the future, and correcting the estimated remaining pickup duration based on the road congestion coefficient. The first and second durations can be flexibly set according to business needs, and the present invention does not limit them.
[0037] In embodiments of the present invention, an LSTM (Long Short-Term Memory) congestion prediction model is introduced to estimate road congestion coefficients. Specifically, regional traffic flow data from the past 15 minutes can be input into the congestion prediction model to output a road congestion coefficient C∈[1,3] for the next 30 minutes (where 1 represents smooth traffic and 3 represents severe congestion). This dynamically corrects the estimated remaining pickup time T, for example, by multiplying the estimated remaining pickup time T by the road congestion coefficient C to obtain the corrected estimated remaining pickup time, thereby improving the accuracy of load assessment in conjunction with traffic conditions.
[0038] Step S103: Determine the set of candidate pickup personnel based on the customer's location of the new pickup order, calculate the distance priority between each candidate pickup personnel and the customer based on the pickup personnel's location information and the customer's location, and calculate the load priority of each candidate pickup personnel based on the comprehensive load value.
[0039] In an embodiment of the present invention, the customer's location (GIS coordinates) of a new order is used as the center, and the pickup personnel who are "on duty + on duty time + valid in the road area" are selected according to the preset pickup range (3 kilometers by default, dynamic configuration is supported) to form a set of candidate pickup personnel, and invalid candidates are excluded.
[0040] According to one embodiment of the present invention, calculating the distance priority between each candidate pickup person and the customer based on the location information of the pickup person and the customer location may specifically include: calculating the actual geographical distance between each candidate pickup person and the customer based on the location information of the pickup person and the customer location; and calculating the distance priority between each candidate pickup person and the customer based on the actual geographical distance between each candidate pickup person and the customer and a preset maximum pickup range. Furthermore, when calculating the load priority of each candidate pickup person based on the comprehensive load value, the load priority may be obtained by subtracting the comprehensive load value of the pickup person from 1.
[0041] In embodiments of this invention, a two-dimensional priority is calculated. Specifically, when calculating distance priority, the actual geographical distance S between the pickup personnel and the customer can first be calculated based on the Haversine formula, combining the location coordinates of the pickup personnel and the customer. Then, the actual geographical distance S between the pickup personnel and the customer is converted into distance priority. Specifically, the actual geographical distance S between the pickup personnel and the customer can be divided by a preset maximum pickup range to obtain a distance ratio, and then 1 is subtracted from this distance ratio to obtain the distance priority. The closer S is, the higher the distance priority, highlighting the core logic of "nearby allocation" for pickup orders.
[0042] Load priority can be directly derived from the overall load value of the collection personnel. The lighter the load and the smaller the overall load value, the higher the load priority, thus ensuring load balance among the collection personnel.
[0043] Step S104: Calculate the comprehensive matching score for each candidate pickup person based on distance priority and load priority, and determine the candidate pickup person with the highest comprehensive matching score as the target pickup person. In specific implementation, a weighted summation formula can be used to calculate the comprehensive matching score for each candidate pickup person based on distance priority and load priority, and then determine the target pickup person.
[0044] According to one embodiment of the present invention, the comprehensive matching score of each candidate pickup person is calculated based on distance priority and load priority. Specifically, it may include: calculating the comprehensive matching score of each candidate pickup person by weighted summation based on distance priority and load priority, combined with preset distance priority weights and load priority weights, wherein the sum of distance priority weights and load priority weights is 1.
[0045] In embodiments of the present invention, a weighted summation formula is used to obtain the comprehensive matching score of the pickup personnel. Specifically, the product of distance priority and a preset distance priority weight, and the product of load priority and a preset load priority weight can be calculated first; then, the two products are summed to obtain the comprehensive matching score of the pickup personnel. In specific implementation, the distance priority weight α = 0.6 and the load priority weight β = 0.4 can be set to balance the two objectives of "proximity" and "balance" through weight allocation. Specifically, these two weight values can be flexibly adjusted according to business needs.
[0046] According to one embodiment of the present invention, before determining the candidate pickup personnel with the highest comprehensive matching score as the target pickup personnel, the method may further include: determining that the highest comprehensive matching score is not lower than a preset threshold; and, in response to the highest comprehensive matching score being lower than the preset threshold, expanding the screening range of candidate pickup personnel or triggering manual coordination and allocation.
[0047] In an embodiment of the present invention, the pickup personnel with the highest comprehensive matching score are selected as the target allocation object. If multiple pickup personnel have the same score, the pickup personnel who are closer are selected first; if all scores are below the threshold (default 0.5), the screening range is automatically expanded (by 0.5 kilometers each time, with a maximum of 5 kilometers) or pushed to the allocation personnel for manual coordination and allocation.
[0048] Step S105: Dynamically plan the collection routes for the pending collection orders and new collection orders received by the target collection personnel, generate the optimal collection order, and send the allocation instructions for new collection orders and the optimal collection order to the target collection personnel. After determining the target collection personnel, the present invention can also dynamically plan the collection routes for all collection orders corresponding to the target collection personnel, further shortening the collection time and improving collection efficiency. Specifically, after determining the target collection personnel, the details of the new collection orders and the optimized collection routes (including navigation coordinates and estimated arrival time) are simultaneously pushed to the collection personnel's terminal devices, and the collection personnel's pending collection order list and comprehensive load value are updated in real time. At the same time, a "collection personnel assigned" status notification is pushed to the customer.
[0049] According to one embodiment of the present invention, dynamic planning of collection paths is performed on the pending collection orders and new collection orders already received by the target collection personnel to generate an optimal collection order. Specifically, this may include: initializing an unvisited order set, which includes pending collection orders and new collection orders already received by the target collection personnel; starting from the current location of the target collection personnel, iteratively selecting the collection order closest to the current path endpoint from the unvisited order set until the unvisited order set is empty, thereby generating an optimal collection order; wherein, when there is a collection order with a priority higher than a preset level, the collection order is selected first.
[0050] In an embodiment of the present invention, based on the customer locations of pending orders already received by the target collection personnel and the customer locations of new collection orders, an improved greedy algorithm is used to plan the optimal collection order for each collection order. Specifically, starting from the current location of the collection personnel, each collection order is sorted according to the principle of "increasing distance + time-priority matching" to obtain the optimal collection order. The specific steps are as follows: 1. Initialize the set of unvisited orders U (including new pickup orders and existing pending pickup orders) and the set of planned routes P (initially including the current location of pickup personnel); 2. Select the pickup order from U that is closest to the last node of P. If there is a pickup order with a timeliness priority level of ≥4, then select that pickup order first. 3. Add the selected pickup order to P, and remove the pickup order from U; 4. Repeat steps 2-3 until U is empty, generate the shortest path closed loop, and minimize the total collection distance and time.
[0051] According to one embodiment of the present invention, the method for allocating pickup orders may further include: establishing a dynamic refresh mechanism to update the location information and overall load value of pickup personnel in real time at a preset period, and triggering an adjustment of the order allocation strategy when a pickup personnel completes a pickup order, moves their location beyond a preset distance, adds a temporary pickup order, or cancels a pickup order. In an embodiment of the present invention, a dynamic refresh mechanism with a 30-second cycle is established. When a pickup personnel completes a pickup order, moves significantly (distance ≥ 500 meters), adds a temporary order, or cancels an order, the overall load value and overall matching score of all pickup personnel on duty are recalculated in real time, and the subsequent order allocation strategy is dynamically adjusted to ensure the real-time and optimal allocation of pickup orders.
[0052] According to one embodiment of the present invention, the method for allocating pickup orders may further include: in response to detecting that a pickup personnel is offline, refuses an order, or experiences a sudden malfunction, re-adding the new pickup order to the pending pickup order pool, and completing the re-allocation within a preset time. In an embodiment of the present invention, an emergency handling mechanism for abnormal scenarios is also proposed. In response to abnormal situations such as pickup personnel being offline, refusing an order, or experiencing a sudden malfunction, the system automatically triggers secondary allocation, re-including the new pickup order in the matching pool, and using a fast greedy matching algorithm to complete the screening and allocation of a new optimal pickup personnel within 10 seconds, thus avoiding order delays.
[0053] Figure 2 This is a schematic diagram of the order allocation process according to an embodiment of the present invention. Figure 2 As shown, in one embodiment of the present invention, after receiving a new pickup order submitted by a customer, the order allocation system performs anomaly detection on the new pickup order data. If the anomaly detection passes, it collects the location data of the pickup personnel and performs Kalman filtering optimization to obtain location information. Then, based on the pickup personnel's received pending pickup orders, it calculates the comprehensive load value of each pickup personnel and calculates the distance priority and load priority of each candidate pickup personnel. Based on the distance priority and load priority, it calculates the comprehensive matching score of each candidate pickup personnel to determine the target pickup personnel. Then, it generates the optimal delivery route and route navigation information using an improved greedy path planning algorithm, and sends the new pickup order allocation instruction and the optimal delivery route navigation information to the target pickup personnel.
[0054] When a target pickup person is detected to be offline, refuse an order, or experience a sudden malfunction, the new pickup order is re-added to the pending pickup order pool and reassigned within a preset time. Simultaneously, the pickup person's location information and overall workload are updated in real-time at preset intervals. The order allocation strategy is adjusted when a pickup person completes a pickup order, moves beyond a preset distance, adds a temporary pickup order, or cancels a pickup order.
[0055] Figure 3 This is a schematic diagram of the main modules of the order allocation device according to an embodiment of the present invention. Figure 3 As shown, the order allocation device 300 of this embodiment mainly includes: a data acquisition module 301, a comprehensive load calculation module 302, a priority calculation module 303, a matching score calculation module 304, and a path dynamic planning module 305.
[0056] The data acquisition module 301 is used to collect the location information of the collection personnel, the location of customers of new collection orders, and the information of pending collection orders received by the collection personnel in real time. The comprehensive load calculation module 302 is used to calculate the comprehensive load value of each pickup personnel based on the pickup order information received by the pickup personnel. The priority calculation module 303 is used to determine the set of candidate pickup personnel based on the customer location of the new pickup order, and to calculate the distance priority between each candidate pickup personnel and the customer based on the pickup personnel's location information and the customer's location, and to calculate the load priority of each candidate pickup personnel based on the comprehensive load value. The matching score calculation module 304 is used to calculate the comprehensive matching score of each candidate pickup person based on distance priority and load priority, and to determine the candidate pickup person with the highest comprehensive matching score as the target pickup person; The path dynamic planning module 305 is used to dynamically plan the collection path for the orders to be collected that have been received by the target collection personnel and the new collection orders, generate the optimal collection order, and send the allocation instructions for the new collection orders and the optimal collection order to the target collection personnel.
[0057] According to one embodiment of the present invention, the data acquisition module 301 can be specifically used to: use a dual-mode positioning module of Global Positioning System and Beidou Satellite Navigation System to acquire the latitude and longitude coordinates of the collection personnel at an adaptive sampling frequency; and use a Kalman filter algorithm to smooth the latitude and longitude coordinates of the collection personnel to obtain the location information of the collection personnel.
[0058] According to one embodiment of the present invention, the information on pending orders received by the collection personnel includes: the number of pending orders, the spatial distribution range, and the estimated remaining collection time; the comprehensive load calculation module 302 can be specifically used to: calculate a first load based on the number of pending orders and the maximum number of orders that a collection personnel can carry per day; calculate a second load based on the spatial distribution range of pending orders and the preset maximum collection coverage range; calculate a third load based on the estimated remaining collection time and the longest allowed collection time per period; and calculate the comprehensive load value of each collection personnel by weighted summation based on the first load, the second load, and the third load.
[0059] According to an embodiment of the present invention, the order collection allocation device 300 may further include a data correction module (not shown in the figure), which is used to: input regional traffic flow data of a preset first duration into a congestion prediction model to output a road congestion coefficient of a preset second duration in the future, and correct the estimated remaining collection duration according to the road congestion coefficient.
[0060] According to one embodiment of the present invention, the priority calculation module 303 can be specifically used to: calculate the actual geographical distance between each candidate pickup person and the customer based on the location information of the pickup person and the customer location; and calculate the distance priority between each candidate pickup person and the customer based on the actual geographical distance between each candidate pickup person and the customer and the preset maximum pickup range.
[0061] According to one embodiment of the present invention, the matching score calculation module 304 can be specifically used to: calculate the comprehensive matching score of each candidate pickup person by weighted summation based on distance priority and load priority, combined with preset distance priority weight and load priority weight, wherein the sum of distance priority weight and load priority weight is 1.
[0062] According to one embodiment of the present invention, the order allocation device 300 may further include a matching score verification module (not shown in the figure), which is used to: determine that the highest comprehensive matching score is not lower than a preset threshold before determining the candidate pickup personnel with the highest comprehensive matching score as the target pickup personnel; and, in response to the highest comprehensive matching score being lower than the preset threshold, expand the screening range of candidate pickup personnel or trigger manual coordination allocation.
[0063] According to one embodiment of the present invention, the path dynamic planning module 305 can be specifically used to: initialize an unvisited order set, which includes pending pickup orders received by the target pickup personnel and new pickup orders; starting from the current location of the target pickup personnel, iteratively select the pickup order closest to the current path endpoint from the unvisited order set until the unvisited order set is empty, and generate an optimal pickup order; wherein, when there is a pickup order with a priority higher than a preset level, the pickup order is selected first.
[0064] According to an embodiment of the present invention, the order allocation device 300 may further include an allocation strategy adjustment module (not shown in the figure), which is used to: establish a dynamic refresh mechanism to update the location information and comprehensive load value of the collection personnel in real time at a preset period, and trigger the adjustment of the order allocation strategy when the collection personnel complete the collection order, move their location beyond a preset distance, add a temporary collection order, or cancel the collection order.
[0065] According to one embodiment of the present invention, the order allocation device 300 may further include an exception handling module (not shown in the figure), which is used to: in response to detecting that the pickup personnel are offline, refuse orders, or experience sudden failures, put new pickup orders back into the pending pickup order pool, and complete the reallocation within a preset time.
[0066] According to the technical solution of this invention, the location information of pickup personnel, the location of customers for new pickup orders, and the information of pending pickup orders already received by pickup personnel are collected in real time; the comprehensive load value of each pickup personnel is calculated based on the information of pending pickup orders already received by pickup personnel; a set of candidate pickup personnel is determined with the customer location of the new pickup order as the center, and the distance priority between each candidate pickup personnel and the customer is calculated based on the location information of the pickup personnel and the customer location, and the load priority of each candidate pickup personnel is calculated based on the comprehensive load value; the comprehensive matching score of each candidate pickup personnel is calculated based on the distance priority and the load priority, and the candidate pickup personnel with the highest comprehensive matching score is determined as the target pickup personnel; for the target... This invention employs a technical solution that dynamically plans collection routes between existing pending orders and new orders received by collection personnel, generating an optimal collection order and sending the allocation instructions for new orders and the optimal collection order to the target collection personnel. This enables precise matching of collection personnel's real-time location with orders, breaking the limitations of road area divisions and shortening the average collection distance. By constructing a multi-dimensional order load assessment system, it achieves balanced order distribution, avoiding order backlog or idleness for collection personnel. A real-time dynamic update mechanism adapts to scenarios such as changes in collection personnel location, order status updates, and traffic congestion, improving the flexibility of the allocation strategy. Simultaneously, it integrates route optimization logic to plan the optimal collection order, reducing turnaround distances and lowering the average collection time. Furthermore, the collection order allocation method of this invention optimizes the exception handling process, enabling automatic secondary allocation of collection orders, reducing manual intervention, and improving the experience for both customers and collection personnel.
[0067] Figure 4 An exemplary system architecture 400 is shown, in which the order allocation method or the order allocation apparatus of the present invention can be applied.
[0068] like Figure 4As shown, system architecture 400 may include terminal devices 401, 402, and 403, a network 404, and a server 405. Network 404 serves as the medium for providing communication links between terminal devices 401, 402, and 403 and server 405. Network 404 may include various connection types, such as wired or wireless communication links, or fiber optic cables, etc.
[0069] Users can use terminal devices 401, 402, and 403 to interact with server 405 via network 404 to receive or send messages, etc. Various communication client applications can be installed on terminal devices 401, 402, and 403, such as shopping applications, web browser applications, search applications, instant messaging tools, email clients, social media platform software, etc. (for example only).
[0070] Terminal devices 401, 402, and 403 can be various electronic devices with displays that support web browsing, including but not limited to smartphones, tablets, laptops, and desktop computers.
[0071] Server 405 can be a server providing various services, such as a backend management server supporting shopping websites browsed by users using terminal devices 401, 402, and 403 (for example only). The backend management server can process data such as the received order allocation requests, calculate the overall load of collection personnel, calculate the load priority of collection personnel, calculate matching scores, and perform dynamic path planning, and feed back the processing results (such as the allocation instructions for new collection orders and the optimal collection order - for example only) to the terminal devices.
[0072] It should be noted that the order allocation method provided in this embodiment of the invention is generally executed by server 405, and correspondingly, the order allocation device is generally set in server 405.
[0073] It should be understood that Figure 4 The number of terminal devices, networks, and servers shown is merely illustrative. Depending on implementation needs, any number of terminal devices, networks, and servers can be included.
[0074] The following is for reference. Figure 5 It shows a schematic diagram of the structure of a computer system 500 suitable for implementing terminal devices or servers of the present invention. Figure 5 The terminal device or server shown is merely an example and should not impose any limitation on the functionality and scope of use of the embodiments of the present invention.
[0075] like Figure 5As shown, the computer system 500 includes a central processing unit (CPU) 501, which can perform various appropriate actions and processes based on programs stored in read-only memory (ROM) 502 or programs loaded from storage section 508 into random access memory (RAM) 503. The RAM 503 also stores various programs and data required for the operation of the system 500. The CPU 501, ROM 502, and RAM 503 are interconnected via a bus 504. An input / output (I / O) interface 505 is also connected to the bus 504.
[0076] The following components are connected to I / O interface 505: an input section 506 including a keyboard, mouse, etc.; an output section 507 including a cathode ray tube (CRT), liquid crystal display (LCD), etc., and speakers, etc.; a storage section 508 including a hard disk, etc.; and a communication section 509 including a network interface card such as a LAN card, modem, etc. The communication section 509 performs communication processing via a network such as the Internet. A drive 510 is also connected to I / O interface 505 as needed. A removable medium 511, such as a disk, optical disk, magneto-optical disk, semiconductor memory, etc., is installed on drive 510 as needed so that computer programs read from it can be installed into storage section 508 as needed.
[0077] In particular, according to the embodiments disclosed in this invention, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments disclosed in this invention include a computer program product comprising a computer program carried on a computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via communication section 509, and / or installed from removable medium 511. When the computer program is executed by central processing unit (CPU) 501, it performs the functions defined above in the system of this invention.
[0078] It should be noted that the computer-readable medium shown in this invention can be a computer-readable signal medium or a computer-readable storage medium, or any combination thereof. A computer-readable storage medium can be, for example,—but not limited to—an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of a computer-readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof. In this invention, a computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, apparatus, or device. In this invention, a computer-readable signal medium can include a data signal propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such propagated data signals can take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. Computer-readable signal media can also be any computer-readable medium other than computer-readable storage media, which can send, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device. The program code contained on the computer-readable medium can be transmitted using any suitable medium, including but not limited to: wireless, wire, optical fiber, RF, etc., or any suitable combination thereof.
[0079] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of the present invention. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in a block diagram or flowchart, and combinations of blocks in a block diagram or flowchart, may be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.
[0080] The units or modules described in the embodiments of the present invention can be implemented in software or hardware. The described units or modules can also be housed in a processor; for example, a processor can be described as including a data acquisition module, a comprehensive load calculation module, a priority calculation module, a matching score calculation module, and a path dynamic planning module. The names of these units or modules do not necessarily limit the unit or module itself; for example, a data acquisition module can also be described as "a module for real-time acquisition of location information of pickup personnel, customer locations of new pickup orders, and information on pending pickup orders received by pickup personnel."
[0081] In another aspect, the present invention also provides a computer-readable medium, which may be included in the device described in the above embodiments; or it may exist alone and not assembled into the device. The aforementioned computer-readable medium carries one or more programs that, when executed by a device, cause the device to include: real-time acquisition of location information of collection personnel, customer locations of new collection orders, and information on pending collection orders already received by collection personnel; calculation of the comprehensive load value of each collection personnel based on the pending collection order information already received by collection personnel; determination of a set of candidate collection personnel centered on the customer location of new collection orders, and calculation of the distance priority between each candidate collection personnel and the customer based on the location information of collection personnel and the customer location, and calculation of the load priority of each candidate collection personnel based on the comprehensive load value; calculation of the comprehensive matching score of each candidate collection personnel based on the distance priority and load priority, and determination of the candidate collection personnel with the highest comprehensive matching score as the target collection personnel; dynamic planning of collection paths for pending collection orders already received by the target collection personnel and new collection orders, generation of the optimal collection order, and sending the allocation instruction for new collection orders and the optimal collection order to the target collection personnel.
[0082] According to the technical solution of this invention, the location information of pickup personnel, the location of customers for new pickup orders, and the information of pending pickup orders already received by pickup personnel are collected in real time; the comprehensive load value of each pickup personnel is calculated based on the information of pending pickup orders already received by pickup personnel; a set of candidate pickup personnel is determined with the customer location of the new pickup order as the center, and the distance priority between each candidate pickup personnel and the customer is calculated based on the location information of the pickup personnel and the customer location, and the load priority of each candidate pickup personnel is calculated based on the comprehensive load value; the comprehensive matching score of each candidate pickup personnel is calculated based on the distance priority and the load priority, and the candidate pickup personnel with the highest comprehensive matching score is determined as the target pickup personnel; for the target... This invention employs a technical solution that dynamically plans collection routes between existing pending orders and new orders received by collection personnel, generating an optimal collection order and sending the allocation instructions for new orders and the optimal collection order to the target collection personnel. This enables precise matching of collection personnel's real-time location with orders, breaking the limitations of road area divisions and shortening the average collection distance. By constructing a multi-dimensional order load assessment system, it achieves balanced order distribution, avoiding order backlog or idleness for collection personnel. A real-time dynamic update mechanism adapts to scenarios such as changes in collection personnel location, order status updates, and traffic congestion, improving the flexibility of the allocation strategy. Simultaneously, it integrates route optimization logic to plan the optimal collection order, reducing turnaround distances and lowering the average collection time. Furthermore, the collection order allocation method of this invention optimizes the exception handling process, enabling automatic secondary allocation of collection orders, reducing manual intervention, and improving the experience for both customers and collection personnel.
[0083] The specific embodiments described above do not constitute a limitation on the scope of protection of this invention. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can occur depending on design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this invention should be included within the scope of protection of this invention.
Claims
1. A method for allocating pickup orders, characterized in that, include: Real-time collection of location information of pickup personnel, location of customers for new pickup orders, and information on pending pickup orders received by pickup personnel; Calculate the overall workload value of each pickup personnel based on the pickup order information received by the pickup personnel; A set of candidate pickup personnel is determined centered on the location of the customer of the new pickup order. The distance priority between each candidate pickup personnel and the customer is calculated based on the location information of the pickup personnel and the location of the customer. The load priority of each candidate pickup personnel is also calculated based on the comprehensive load value. The comprehensive matching score of each candidate pickup person is calculated based on the distance priority and the load priority, and the candidate pickup person with the highest comprehensive matching score is determined as the target pickup person; Dynamically plan the pickup path for the pending pickup orders already received by the target pickup personnel and the new pickup orders, generate the optimal pickup order, and send the allocation instruction for the new pickup orders and the optimal pickup order to the target pickup personnel.
2. The method according to claim 1, characterized in that, Real-time collection of location information of pickup personnel, including: A dual-mode positioning module using both the Global Positioning System and the BeiDou Navigation Satellite System is employed to collect the latitude and longitude coordinates of the personnel at an adaptive sampling frequency. The latitude and longitude coordinates of the collection personnel are smoothed using the Kalman filter algorithm to obtain their location information.
3. The method according to claim 1, characterized in that, The information on pending orders received by the collection personnel includes: the number of pending orders, the spatial distribution range of the pending orders, and the estimated remaining collection time; The overall workload value of each pickup personnel is calculated based on the pending pickup order information received by the pickup personnel, including: The first load is calculated based on the number of orders to be collected and the maximum number of orders that a collection personnel can collect per day. The second load is calculated based on the spatial distribution range of the orders to be collected and the preset maximum collection coverage range; The third load is calculated based on the estimated remaining collection time and the longest allowed collection time per period. Based on the first load, the second load, and the third load, the comprehensive load value of each collection personnel is calculated by weighted summation.
4. The method according to claim 3, characterized in that, The method further includes: The regional traffic flow data of the first preset time period is input into the congestion prediction model to output the road congestion coefficient of the second preset time period in the future, and the estimated remaining collection time period is corrected according to the road congestion coefficient.
5. The method according to claim 1, characterized in that, Based on the location information of the pickup personnel and the location of the customer, the distance priority between each candidate pickup personnel and the customer is calculated, including: Calculate the actual geographical distance between each candidate pickup person and the customer based on the location information of the pickup personnel and the customer's location; The distance priority between each candidate pickup person and the customer is calculated based on the actual geographical distance between each candidate pickup person and the customer and the preset maximum pickup range.
6. The method according to claim 1 or 5, characterized in that, The comprehensive matching score for each candidate pickup person is calculated based on the distance priority and the load priority, including: Based on the distance priority and the load priority, and combined with preset distance priority weights and load priority weights, a comprehensive matching score for each candidate pickup person is calculated by weighted summation, wherein the sum of the distance priority weight and the load priority weight is 1.
7. The method according to claim 1, characterized in that, Before identifying the candidate with the highest overall matching score as the target pickup person, the process also includes: Ensure that the highest overall matching score is not lower than a preset threshold; In addition, in response to the highest overall matching score falling below a preset threshold, the screening range of candidate pickup personnel is expanded or manual coordination and allocation are triggered.
8. The method according to claim 1, characterized in that, Dynamically plan the pickup routes for the orders already received by the target pickup personnel and the new pickup orders to generate the optimal pickup order, including: Initialize an unaccessed order set, which includes pending pickup orders already received by the target pickup personnel and the new pickup orders; Starting from the current location of the target pickup personnel, iteratively select the pickup order closest to the current path endpoint from the set of unvisited orders until the set of unvisited orders is empty, thus generating the optimal pickup order; Specifically, when there is a pickup order with a higher priority than the preset level, the pickup order will be selected first.
9. The method according to claim 1, characterized in that, The method further includes: Establish a dynamic refresh mechanism to update the location information and overall load value of pickup personnel in real time at a preset cycle, and trigger the adjustment of the order allocation strategy when pickup personnel complete a pickup order, move their location beyond a preset distance, add a temporary pickup order, or cancel a pickup order.
10. The method according to claim 1, characterized in that, The method further includes: In response to the detection of a pickup personnel being offline, refusing an order, or experiencing a sudden malfunction, the new pickup order is put back into the pending pickup order pool and redistributed within a preset time.
11. A distribution device for collected orders, characterized in that, include: The data acquisition module is used to collect the location information of the pickup personnel, the location of customers for new pickup orders, and the information of pending pickup orders received by the pickup personnel in real time. The comprehensive load calculation module is used to calculate the comprehensive load value of each pickup personnel based on the pickup order information received by the pickup personnel. The priority calculation module is used to determine a set of candidate pickup personnel centered on the customer location of the new pickup order, and to calculate the distance priority between each candidate pickup personnel and the customer based on the location information of the pickup personnel and the customer location, and to calculate the load priority of each candidate pickup personnel based on the comprehensive load value. The matching score calculation module is used to calculate the comprehensive matching score of each candidate pickup person based on the distance priority and the load priority, and to determine the candidate pickup person with the highest comprehensive matching score as the target pickup person; The path dynamic planning module is used to dynamically plan the collection path between the new collection order and the orders already received by the target collection personnel, generate the optimal collection order, and send the allocation instruction of the new collection order and the optimal collection order to the target collection personnel.
12. An electronic device, characterized in that, include: One or more processors; Storage device for storing one or more programs. When the one or more programs are executed by the one or more processors, the one or more processors implement the method as described in any one of claims 1-10.
13. A computer-readable medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the method as described in any one of claims 1-10.
14. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the method as described in any one of claims 1-10.