Protocol customer order collection method and device, equipment and storage medium
The random forest detection model and clustering algorithm are used to detect anomalies and group agreement customer orders, and generate batch collection lists, which solves the problem of low batch order processing efficiency in the existing technology and improves collection efficiency and customer satisfaction.
Patent Information
- Application Number
- CN202410845489.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-27
- Publication Date
- 2024-10-22
AI Technical Summary
The existing technology has low printing efficiency when processing batch orders from contracted customers. Scanning one by one results in inefficiency and error-proneness, increases the work intensity and time cost of couriers, and affects work efficiency and customer satisfaction.
The random forest detection model is used for anomaly detection, and the clustering algorithm and genetic algorithm are combined to group the orders to be collected, generate a batch collection list, update the order status based on the collection instructions, and generate a collection analysis report.
It improves the detection rate of abnormal orders, optimizes the generation of collection instructions, reduces error rates and work intensity, and improves service efficiency and customer satisfaction.
Smart Images

Figure CN118822397A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of logistics technology, and in particular to a method, device, equipment and storage medium for collecting orders from contracted customers. Background Art
[0002] When couriers provide services to contract customers, customers usually choose to place orders in batches to improve order processing efficiency. However, the current process for collecting individual orders is mainly designed to process individual orders one by one, which leads to obvious inadaptability and inefficiency when processing batch orders from contract customers.
[0003] In the process of collecting individual orders, the delivery bill is usually printed based on a single order. However, the batch orders of contract customers require a large number of delivery bills to be printed at one time. The existing process cannot meet the needs of such batch printing, resulting in low printing efficiency and increased workload for couriers.
[0004] Moreover, in the process of picking up individual orders, couriers need to scan each order one by one. For bulk orders from contracted customers, this method of scanning each order is not only inefficient but also prone to errors. In addition, a large amount of scanning work also increases the workload and time cost of couriers.
[0005] In addition, the process of collecting individual orders cannot adapt to the processing requirements of bulk orders, resulting in inefficiency in the entire order processing process, which not only affects the efficiency of couriers, but also affects the satisfaction and loyalty of contract customers.
[0006] Therefore, the existing technology still needs to be improved and developed. Summary of the invention
[0007] The present invention provides a method, device, equipment and storage medium for collecting orders from contracted customers, which are used for batch collection and management of orders from contracted customers.
[0008] A first aspect of the present invention provides a method for collecting orders from contracted customers, the method comprising: obtaining order collection data of contracted customers, and performing anomaly detection on the order collection data through a random forest detection model to obtain orders to be collected; using a clustering algorithm combined with a genetic algorithm to group the orders to be collected to obtain multiple groups of orders to be collected, and generating a batch collection list; generating a collection instruction based on the batch collection list; obtaining a collection result based on the collection instruction, and updating the status of the order to be collected according to the collection result, the status of the order to be collected including collected and failed to collect; collecting and analyzing the orders to be collected whose status is failed to collect, and generating a collection analysis report.
[0009] Optionally, in a first implementation method of the first aspect of the present invention, the order collection data of the agreement customers is obtained, and the order collection data is detected for anomalies through a random forest detection model to obtain orders to be collected, including: obtaining the order collection data of the agreement customers, and preprocessing the order collection data; performing feature engineering on the preprocessed order collection data; inputting the order collection data after feature engineering into the random forest detection model for anomaly detection, and screening out normal orders in the order collection data as orders to be collected according to the detection results of the random forest detection model.
[0010] Optionally, in a second implementation method of the first aspect of the present invention, the clustering algorithm is combined with the genetic algorithm to group the orders to be collected, obtain multiple groups of orders to be collected, and generate a batch collection list, including: using the K-means clustering algorithm combined with the genetic algorithm to group the orders to be collected, obtain multiple groups of order data to be collected, and the shipping addresses of each group of order data to be collected are similar; based on a preset collection list template, traversing the order data of the multiple groups of order data to be collected respectively, and filling the order information into the default parameters of the preset collection list template; checking the data integrity in the filled batch collection list template, and generating a batch collection list if it is complete and correct.
[0011] Optionally, in a third implementation manner of the first aspect of the present invention, the K-means clustering algorithm is combined with a genetic algorithm to group the collection orders to be collected, so as to obtain multiple groups of collection order data, and the mailing addresses of each group of collection order data are similar, including: initializing genetic algorithm parameters, and the genetic algorithm parameters include population size, crossover rate, mutation rate and termination condition; randomly generating a preset number of individuals as an initial population, and each individual in the initial population contains a group of randomly initialized centroids; executing the K-means algorithm for each individual in the initial population, and calculating the fitness value of the corresponding individual respectively, selecting a parent generation for generating the next generation population according to the fitness value, and randomly selecting two parents for crossover operation to generate new individuals, performing mutation operation on the new individuals, and performing iterative operation; selecting the individual with the highest fitness value from the last generation population as the optimal initial centroid combination, using the optimal initial centroid combination to execute the K-means algorithm to obtain a clustering result, and grouping the collection orders to be collected according to the clustering result to obtain multiple groups of collection order data, and the mailing addresses of each group of collection order data are similar.
[0012] Optionally, in a fourth implementation method of the first aspect of the present invention, generating a collection instruction based on the batch collection list includes: importing a batch collection list, sorting the to-be-collected orders in each group of to-be-collected orders in the batch collection list; performing route planning for the grouped and sorted to-be-collected orders according to a shortest path first algorithm to obtain a collection route; assigning collection staff according to the collection route, and generating a collection instruction.
[0013] Optionally, in a fifth implementation of the first aspect of the present invention, the collection result is obtained based on the collection instruction, and the status of the order to be collected is updated according to the collection result, and the status of the order to be collected includes collected and failed collection, including: obtaining the collection result based on the collection instruction, the collection result includes the order to be collected that was successfully collected and the order to be collected that failed to be collected; for the order to be collected that was successfully collected, the status is updated to collected, and the logistics information is updated; for the order to be collected that failed to be collected, the status is updated to failed collection, and the reason for the failure is recorded.
[0014] Optionally, in a sixth implementation of the first aspect of the present invention, the collection and analysis of the pending collection orders with a collection failure status to generate a collection analysis report includes: collecting the pending collection orders with a collection failure status and analyzing the reasons for the failure; classifying and summarizing the collected pending collection orders according to the reasons for the failure to obtain a summary result; and generating a collection analysis report based on the summary result.
[0015] The second aspect of the present invention provides a device for collecting orders from agreement customers, including: an anomaly detection module, used to obtain order collection data of agreement customers, and perform anomaly detection on the order collection data through a random forest detection model to obtain orders to be collected; a grouping module, used to use a clustering algorithm combined with a genetic algorithm to group the orders to be collected, obtain multiple groups of orders to be collected, and generate a batch collection list; a generation module, used to generate collection instructions based on the batch collection list; an update module, used to obtain collection results based on the collection instructions, and update the status of the orders to be collected according to the collection results, the status of the orders to be collected including collected and failed to collect; an analysis module, used to collect and analyze the orders to be collected whose status is failed to collect, and generate a collection analysis report.
[0016] Optionally, in a first implementation manner of the second aspect of the present invention, the anomaly detection module includes: a first acquisition unit, used to acquire the order collection data of the agreement customers and preprocess the order collection data; a processing unit, used to perform feature engineering on the preprocessed order collection data; a detection unit, used to input the order collection data after feature engineering into a random forest detection model for anomaly detection, and screen out normal orders in the order collection data as orders to be collected according to the detection results of the random forest detection model.
[0017] Optionally, in a second implementation method of the second aspect of the present invention, the grouping module includes: a grouping unit, used to use a K-means clustering algorithm combined with a genetic algorithm to group the orders to be collected, and obtain multiple groups of order data to be collected, and the shipping addresses of each group of order data to be collected are similar; a calling unit, used to traverse the order data of the multiple groups of order data to be collected respectively based on a preset collection list template, and fill the order information into the default parameters of the preset collection list template; a first generating unit, used to check the data integrity in the filled batch collection list template, and generate a batch collection list if it is complete and correct.
[0018] Optionally, in a third implementation method of the second aspect of the present invention, the generation module includes: a sorting unit, used to import a batch collection list, and sort the to-be-collected orders in each group of to-be-collected orders in the batch collection list; a planning unit, used to plan the routes for the grouped and sorted to-be-collected orders according to a shortest path first algorithm to obtain a collection route; a second generation unit, used to assign collection staff according to the collection route, and generate collection instructions.
[0019] Optionally, in a fourth implementation of the second aspect of the present invention, the update module includes: a second acquisition unit, used to obtain a collection result based on a collection instruction, the collection result including successfully collected orders to be collected and failed collection orders to be collected; a first update unit, used to update the status of successfully collected orders to be collected to collected, and update the logistics information; a second update unit, used to update the status of failed collection orders to collection failure, and record the reason for the failure.
[0020] Optionally, in a fifth implementation of the second aspect of the present invention, the analysis module includes: an analysis unit, used to collect the to-be-collected orders with a failed collection status and analyze the reasons for the failure; a summary unit, used to classify and summarize the collected to-be-collected orders according to the reasons for the failure to obtain a summary result; and a third generation unit, used to generate a collection analysis report based on the summary result.
[0021] The third aspect of the present invention provides a device for collecting contracted customer orders, comprising: a memory and at least one processor, wherein the memory stores computer-readable instructions, and the memory and the at least one processor are interconnected via a line; the at least one processor calls the computer-readable instructions in the memory so that the device for collecting contracted customer orders executes each step of the method for collecting contracted customer orders as described above.
[0022] A fourth aspect of the present invention provides a computer-readable storage medium, in which computer-readable instructions are stored. When the computer-readable storage medium is run on a computer, the computer executes each step of the method for collecting customer orders according to the agreement as described above.
[0023] In the technical solution provided by the present invention, anomaly detection is performed on order collection data through a random forest detection model to obtain orders to be collected, and a clustering algorithm combined with a genetic algorithm is used to group the orders to be collected to obtain multiple groups of orders to be collected, and a batch collection list is generated, and then a collection instruction is generated based on the batch collection list, and a collection result is obtained based on the collection instruction, and the status of the order to be collected is updated according to the collection result, and finally, the orders to be collected with a failed collection status are collected and analyzed to generate a collection analysis report, and the order collection data is detected for anomalies using a random forest detection model, which can effectively identify abnormal data that does not conform to the normal pattern, thereby improving the detection rate of abnormal orders, and the orders to be collected are grouped through a clustering algorithm combined with a genetic algorithm to generate a batch collection list, so that the collection instructions can be better generated later. In addition, for the failed collection orders to be collected, timely analysis and feedback can provide customers with more accurate solutions and better service experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0024] Figure 1 A first flow chart of the method for collecting orders from contracted customers provided in an embodiment of the present invention;
[0025] Figure 2 A second flow chart of the method for collecting orders from contracted customers provided in an embodiment of the present invention;
[0026] Figure 3 A third flow chart of the method for collecting orders from contracted customers provided in an embodiment of the present invention;
[0027] Figure 4 A fourth flow chart of the method for collecting orders from contracted customers provided in an embodiment of the present invention;
[0028] Figure 5 A fifth flow chart of the method for collecting orders from contracted customers provided in an embodiment of the present invention;
[0029] Figure 6 A sixth flow chart of the method for collecting orders from contracted customers provided in an embodiment of the present invention;
[0030] Figure 7 A schematic diagram of the structure of a device for collecting orders from contracted customers provided in an embodiment of the present invention;
[0031] Figure 8 A schematic diagram of the structure of a device for collecting orders from agreement customers provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0032] The embodiment of the present invention provides a method, device, equipment and storage medium for collecting orders from agreement customers, and the method is used for batch collection management of orders from agreement customers. The method includes: obtaining order collection data of agreement customers, and performing anomaly detection on the order collection data through a random forest detection model to obtain orders to be collected; using a clustering algorithm combined with a genetic algorithm to group the orders to be collected, obtaining multiple groups of orders to be collected, and generating a batch collection list; generating a collection instruction based on the batch collection list; obtaining a collection result based on the collection instruction, and updating the status of the order to be collected according to the collection result, the status of the order to be collected includes collected and failed to collect; collecting and analyzing the orders to be collected with a failed collection status, and generating a collection analysis report.
[0033] The terms "first", "second", "third", "fourth", etc. (if any) in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments described herein can be implemented in an order other than that illustrated or described herein. In addition, the terms "including" or "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0034] For ease of understanding, the specific process of the embodiment of the present invention is described below. Figure 1 A first embodiment of a method for collecting orders from contracted customers in an embodiment of the present invention includes:
[0035] S101. Obtain order collection data of contract customers, and perform anomaly detection on the order collection data through a random forest detection model to obtain orders to be collected.
[0036] It is understandable that the execution subject of the present invention may be a device for collecting orders from contracted customers, or a terminal or a server, which is not limited here. The embodiment of the present invention is described by taking a server as the execution subject as an example.
[0037] In this embodiment, the order collection data of the contracted customers is collected from the order management system. The order collection data includes order number, customer ID, collection time, collection location, product information, delivery method, etc.
[0038] In this embodiment, data preprocessing is required before the order collection data is input into the random forest detection model.
[0039] S102. Use a clustering algorithm combined with a genetic algorithm to group the orders to be collected, obtain multiple groups of orders to be collected, and generate a batch collection list.
[0040] In this embodiment, a clustering algorithm (such as K-means) is used to divide the orders into several initial groups. These initial groups can be used as the initial population optimized by the genetic algorithm. Each initial group is taken as an individual, and the genetic algorithm is used to optimize these groups to maximize the collection efficiency and minimize the travel distance.
[0041] In this embodiment, the genetic algorithm includes selecting a fitness function, crossover and mutation operations, and determining an optimization termination condition.
[0042] In this embodiment, according to the grouping results after genetic algorithm optimization, a batch collection list is generated for each optimized grouping.
[0043] S103: Generate a collection instruction based on the batch collection list.
[0044] In this embodiment, the batch collection list is parsed to extract the order information in each group, including order number, product description, consignee information (name, address, contact number, etc.), estimated collection time, etc.
[0045] In this embodiment, after the collection instruction is generated, verification can be performed. The verification can include checking whether the instruction content is complete and accurate and whether it complies with business rules and format requirements.
[0046] In this embodiment, the verified collection instructions are output to a designated system or device so that the collection personnel can easily obtain and execute them. The output instructions can be in the form of electronic documents, printouts, or notifications on mobile devices. At the same time, it is ensured that the instructions can be accurately distributed to the corresponding collection personnel or teams.
[0047] S104: Obtain a collection result based on the collection instruction, and update the status of the order to be collected according to the collection result. The status of the order to be collected includes collected and failed.
[0048] In this embodiment, the collection result data is obtained from the logistics system based on the collection instruction, including successfully collected orders, failed orders, and corresponding statuses and reasons.
[0049] In this embodiment, each collection instruction is compared with the actual collection result to determine the latest status of each order.
[0050] S105. Collect and analyze the pending collection orders whose status is failed collection, and generate a collection analysis report.
[0051] In this embodiment, the collection analysis report includes a summary and detailed analysis of failed orders. The summary of failed orders includes the total number of failed orders, time distribution, and main reasons for failure. Detailed analysis includes failure reason analysis and data analysis. Data analysis includes quantity analysis, trend analysis, and correlation analysis. Quantity analysis includes counting the total number of failed orders and the proportion of each type of failure reason. Trend analysis includes analyzing the trend of the number of failed orders over time, such as seasonal and cyclical changes. Correlation analysis includes analyzing the correlation between different failure reasons, such as whether inaccurate information and package problems often occur at the same time.
[0052] The present embodiment provides a method for collecting orders from agreement customers, which uses a random forest detection model to perform anomaly detection on order collection data to obtain orders to be collected, and uses a clustering algorithm combined with a genetic algorithm to group the orders to be collected to obtain multiple groups of orders to be collected, and generates a batch collection list, then generates collection instructions based on the batch collection list, and obtains collection results based on the collection instructions, and updates the status of the orders to be collected according to the collection results, and finally collects and analyzes the orders to be collected with a failed collection status to generate a collection analysis report, uses a random forest detection model to perform anomaly detection on order collection data, and can effectively identify abnormal data that does not conform to the normal pattern, thereby improving the detection rate of abnormal orders, and uses a clustering algorithm combined with a genetic algorithm to group the orders to be collected to generate a batch collection list, so that the collection instructions can be better generated later. In addition, for the failed collection orders to be collected, through timely analysis and feedback, more accurate solutions and better service experience can be provided to customers.
[0053] See also Figure 2 The second embodiment of the method for collecting orders from agreement customers in the embodiment of the present invention includes:
[0054] S201. Obtain order collection data of the contracted customer and pre-process the order collection data.
[0055] In this embodiment, the order collection data of the contract customer is obtained by connecting with the data interface of the contract customer.
[0056] In this embodiment, the order collection data is preprocessed, including cleaning data, processing missing values, data conversion, and standardization or normalization of feature data. Cleaning data refers to removing duplicates, erroneous data, and irrelevant data. Processing missing values is to fill missing values according to business logic (such as using mean, median, mode, or specific value). Data conversion, such as converting date and time fields into a format that is easy for the model to process.
[0057] S202: Perform feature engineering on the pre-processed order collection data.
[0058] In this embodiment, feature engineering is performed on the preprocessed order collection data, specifically including: analyzing the data to identify features related to order collection; selecting the most relevant feature subset based on preset screening rules, and then performing feature engineering based on the feature subset, including creating new features (such as time difference, proportion, ratio, etc.) to enhance the detection capability of the model.
[0059] In this embodiment, the features may be further processed by nonlinear transformation (such as logarithmic transformation, Box-Cox transformation, etc.) or dimensionality reduction methods (such as PCA, t-SNE, etc.) to improve the detection capability of the model.
[0060] S203: Input the order collection data processed by feature engineering into the random forest detection model for anomaly detection, and screen out normal orders in the order collection data as orders to be collected according to the detection results of the random forest detection model.
[0061] Understandably, random forest is a powerful ensemble learning method that can effectively handle complex data sets and perform accurate anomaly detection. Random forest reduces the risk of overfitting by integrating multiple decision trees and can handle high-dimensional data and a large number of samples. Random forest constructs multiple decision trees by randomly selecting samples and features, and determines the final prediction result by voting or taking the average.
[0062] In this embodiment, constructing a random forest detection model specifically includes the following methods: collecting historical order collection data, and dividing the preprocessed historical order collection data into a training set and a test set; using statistical tests (such as chi-square test, correlation analysis, etc.) to evaluate the correlation between each feature and the target variable (whether it is abnormal); preliminarily training a random forest model (using fewer trees) to evaluate the importance of each feature; based on these evaluation results, selecting the feature subset most relevant to the target variable; for the construction of each decision tree, performing random sampling with replacement from the training set to generate a training subset; constructing multiple decision trees, and integrating the multiple decision trees to obtain a random forest initial model; using a test set to evaluate the performance of the random forest model, commonly used indicators include accuracy, precision, recall rate, F1 score, etc.; finally, adjusting the parameters of the random forest initial model according to the evaluation results to obtain a random forest detection model.
[0063] In this embodiment, 70% of the data may be used as a training set and 30% of the data may be used as a test set.
[0064] In this embodiment, when constructing a decision tree, parameters are set for each decision tree, such as the maximum depth of the tree, the minimum number of samples for leaf nodes, etc.; at each node, optimal partitioning is performed based on a randomly selected feature subset; at each node of each decision tree, a portion of the feature subset is randomly selected for optimal partitioning.
[0065] In this embodiment, the order collection data after feature engineering is input into the random forest detection model, and the random forest detection model returns a prediction label (normal / abnormal). According to the detection results of the random forest detection model, normal orders in the order collection data are screened out as orders to be collected, and abnormal orders are processed. If the processed abnormal orders meet the normal order standards, they are classified as orders to be collected.
[0066] In this embodiment, a random forest detection model is used to perform anomaly detection on the order collection data of the agreement customers, which has the characteristics of high efficiency and accuracy. By performing feature engineering on the preprocessed order collection data, features can be further created and optimized, so that the random forest detection model can detect anomalies more accurately, further improving the accuracy of the random forest detection model.
[0067] See also Figure 3 A third embodiment of a method for collecting orders from contracted customers in an embodiment of the present invention includes:
[0068] S301. Use K-means clustering algorithm combined with genetic algorithm to group the to-be-collected orders to obtain multiple groups of to-be-collected order data.
[0069] In this embodiment, a K-means clustering algorithm is used in combination with a genetic algorithm to group the orders to be collected, and multiple groups of order data to be collected are obtained, specifically including: initializing genetic algorithm parameters, the genetic algorithm parameters include population size, crossover rate, mutation rate and termination condition; randomly generating a preset number of individuals as the initial population, each individual in the initial population contains a group of randomly initialized centroids; executing the K-means clustering algorithm for each individual in the initial population, and calculating the fitness value of the corresponding individual respectively, selecting the parent generation for generating the next generation population according to the fitness value, and randomly selecting two parents for crossover operation to generate new individuals, performing mutation operation on the new individuals, and performing iterative operation; selecting the individual with the highest fitness value from the last generation population as the optimal initial centroid combination, using the optimal initial centroid combination to execute the K-means algorithm to obtain clustering results, and grouping the orders to be collected according to the clustering results to obtain multiple groups of order data to be collected, and the shipping address of each group of order data to be collected is similar.
[0070] In this embodiment, the mailing addresses of each group of order data to be collected are similar, which can reduce the driving distance and time of the salesperson, thereby improving the overall delivery efficiency.
[0071] S302: Based on a preset collection list template, traverse the order data of multiple groups of order data to be collected respectively, and fill the order information into the default parameters of the preset collection list template.
[0072] In this embodiment, the preset collection list template defines the format of the collection list and the fields that need to be filled in.
[0073] In this embodiment, each set of order data to be collected is traversed to extract order information, and the extracted order information is filled into the corresponding position of the preset collection list template. The order information includes information such as the sender, the sender's address, the recipient, and the recipient's address.
[0074] S303, check the data integrity in the filled batch collection list template, and generate a batch collection list if it is complete and correct.
[0075] In this embodiment, it is checked whether all necessary fields of each order are correctly filled, such as recipient name, address, contact number, order number, etc. It is also possible to verify whether the data in the order is consistent with each other, such as whether the recipient address matches other information in the order.
[0076] In this embodiment, the K-means clustering algorithm is combined with the genetic algorithm to group the orders to be collected, and multiple groups of order data to be collected are obtained. The K-means clustering algorithm can automatically divide the order data into similar clusters, so that the shipping addresses of the orders in the same cluster are similar, which can effectively reduce the distance and time costs of the collection personnel and improve the collection efficiency. In addition, the use of genetic algorithms to optimize the results of K-means clustering can better handle complex data distributions and irregularly shaped clusters, thereby improving the flexibility and adaptability of the algorithm.
[0077] See also Figure 4 A fourth embodiment of a method for collecting orders from contracted customers in an embodiment of the present invention includes:
[0078] S401. Import a batch collection list, and sort the to-be-collected orders in each group of to-be-collected orders in the batch collection list.
[0079] In this embodiment, within each group of to-be-collected orders, the orders are sorted according to a pre-set sorting strategy. The sorting strategy includes: sorting the orders in order from the starting point to the end point to ensure that the travel distance and time are reduced as much as possible during the collection process.
[0080] In this embodiment, the sorting strategy may also include placing high-priority orders in front according to the priority order to ensure that they are processed first.
[0081] In this embodiment, the sorting strategy may also include sorting in time window order. If the order has specific time window requirements (such as must be delivered within a certain time period), the order can be sorted according to these time windows.
[0082] S402: route planning is performed on the grouped and sorted to-be-collected orders according to the shortest path first algorithm to obtain a collection route.
[0083] In this embodiment, the route planning is performed on the grouped and sorted waiting-for-collection orders according to the shortest path first algorithm. When the collection route is obtained, the first route planning is performed on the multiple groups of waiting-for-collection orders, and then the second route planning is performed on each group of sorted waiting-for-collection orders, and finally the first route planning and the second route planning are integrated. When performing the first route planning and the second route planning, the planning is performed according to the shortest path first algorithm.
[0084] As an example, for the grouped collection orders, the starting point is the collection location of the previous group, and the target point is the addresses of all recipients in the group of collection orders. After determining the starting point and the target point, first convert the map data into a graph model, where the nodes represent address points (such as collection centers, recipient addresses, etc.), the edges represent the road sections between the nodes, and the weights of the edges can represent the distance, time or other costs of the road sections. Then use the Dijkstra algorithm to calculate the shortest path from the starting point to each target point. For each target point, the algorithm traverses all nodes in the graph and gradually builds the shortest path from the starting point to the target point.
[0085] When there are multiple target points, the route needs to be further optimized to ensure that the total cost (such as total distance, total time) of the entire collection process is minimized. Multiple target points are combined into one or more efficient collection routes. This can be achieved through heuristic algorithms (such as genetic algorithms, simulated annealing algorithms, etc.).
[0086] S403. Allocate collection agents according to the collection routes and generate collection instructions.
[0087] In this embodiment, collection staff are assigned based on the work area range and working hours of the collection staff and the collection routes pre-configured in the system, and collection tasks are formed, and then collection instructions are generated based on the collection routes and collection tasks.
[0088] In this embodiment, the orders in each group of to-be-collected orders are sorted, which can provide a basis for subsequent route planning based on factors such as geographic location and order priority; moreover, the use of the shortest path first algorithm (such as the Dijkstra algorithm) for route planning can ensure that the generated collection route is optimal in terms of total distance or total time, which helps to improve the collection efficiency; in addition, the collection staff are assigned according to the planned route and specific collection instructions are generated, which can ensure that the staff collects the goods along the optimal route, thereby reducing unnecessary travel and time waste.
[0089] See also Figure 5 A fifth embodiment of a method for collecting orders from contracted customers in an embodiment of the present invention includes:
[0090] S501. Obtaining a collection result based on the collection instruction, where the collection result includes the pending collection orders that were successfully collected and the pending collection orders that were failed to be collected.
[0091] In this embodiment, the collection clerk goes to the designated recipient address to collect the parcel according to the collection instruction. During the collection process, the collection clerk will sign for the parcel and check the integrity of the parcel. After the collection clerk completes the collection task, he will feedback the collection result to the logistics management system or related platform. There are two types of collection results: successful collection and failed collection.
[0092] Collection successful: indicates that the order to be collected has been collected successfully and can proceed to the next step of logistics processing.
[0093] Failed to collect: This means that a problem occurred during the collection process and the order could not be collected successfully.
[0094] S502. For the successfully collected pending collection orders, the status is updated to collected, and the logistics information is updated.
[0095] In this embodiment, for the successfully collected orders to be collected, the specific time when the package was successfully collected is also recorded, the name or number of the person who performed the collection operation is recorded, and the status of the package is recorded, including confirming whether the package is intact, and recording any abnormal situation.
[0096] After the status of a successfully collected order is updated to collected, the relevant logistics information needs to be further updated, including the current location of the package, such as logistics center, transfer station, etc. It can also include updating the estimated time for the package to be delivered to the recipient based on the logistics plan and transportation time.
[0097] S503. For the pending collection orders that failed to be collected, the status is updated to collection failure, and the failure reason is recorded.
[0098] In this embodiment, the reasons for failure include but are not limited to appointment time conflict, the sender cannot be contacted, the sender refuses to pick up the package, the package is damaged, the package does not meet the collection requirements, and transportation problems.
[0099] In this embodiment, by obtaining collection instructions in real time and updating the order status, the order status in the system can be kept timely and accurate, thereby improving the efficiency and accuracy of order management. For pending collection orders that fail to be collected, recording the reasons for the failure can help the company identify the root cause of the problem and take improvement measures, thereby improving the overall service quality and customer satisfaction.
[0100] See also Figure 6 A sixth embodiment of a method for collecting orders from contracted customers in an embodiment of the present invention includes:
[0101] S601. Collect the pending collection orders whose status is collection failure, and analyze the reasons for the failure.
[0102] In this embodiment, the failure reasons of the failed collection orders are analyzed based on information such as order details of the failed collection orders, collection history records, and communication records with the senders.
[0103] Reasons for failure include but are not limited to appointment time conflict, sender cannot be contacted, sender refuses to collect the package, package damage, package does not meet the collection requirements and transportation problems.
[0104] S602: Classify and summarize the collected orders to be collected according to the failure reasons to obtain a summary result.
[0105] In this embodiment, the collected orders to be collected are classified according to the type of failure reasons, and the number of orders under each category is summarized to understand the impact of each failure reason on the overall collection failure rate.
[0106] S603. Generate a collection analysis report based on the summary results.
[0107] In this embodiment, the pre-feasibility study sets up a collection analysis report template in advance. When needed, the collection analysis report template is called, and then the relevant data of the summary results are filled into the default parameters of the collection analysis report template, thereby generating a collection analysis report.
[0108] In this embodiment, the analysis report may use a pie chart, a bar chart, or a line chart to display the distribution and change trend of various failure reasons.
[0109] In this embodiment, failed collection orders are collected and analyzed, and a detailed collection analysis report is generated, which can help the enterprise fully understand and solve various problems in the collection process, optimize the operation process, and improve customer satisfaction and enterprise benefits.
[0110] The above describes the method for collecting orders from agreement customers in the embodiment of the present invention. The following describes the device in the embodiment of the present invention. Figure 7 , the implementation of the device for collecting orders from agreement customers in the embodiment of the present invention includes:
[0111] Anomaly detection module 701 is used to obtain order collection data of contract customers and perform anomaly detection on the order collection data through a random forest detection model to obtain orders to be collected;
[0112] The grouping module 702 is used to group the to-be-collected orders using a clustering algorithm combined with a genetic algorithm to obtain multiple groups of to-be-collected orders and generate a batch collection list;
[0113] A generating module 703 is used to generate a collection instruction based on the batch collection list;
[0114] An updating module 704 is used to obtain a collection result based on the collection instruction, and update the status of the order to be collected according to the collection result. The status of the order to be collected includes collected and failed to be collected.
[0115] The analysis module 705 is used to collect and analyze the pending collection orders with a collection failure status and generate a collection analysis report.
[0116] In this embodiment, the anomaly detection module 701 includes: a first acquisition unit 7011, used to acquire the order collection data of the agreement customer and pre-process the order collection data; a processing unit 7012, used to perform feature engineering processing on the pre-processed order collection data; a detection unit 7013, used to input the order collection data after feature engineering processing into a random forest detection model for anomaly detection, and screen out normal orders in the order collection data as orders to be collected according to the detection results of the random forest detection model.
[0117] In this embodiment, the grouping module 702 includes: a grouping unit 7021, which is used to use the K-means clustering algorithm combined with the genetic algorithm to group the to-be-collected orders, and obtain multiple groups of to-be-collected order data, and the mailing addresses of each group of to-be-collected order data are similar; a calling unit 7022, which is used to traverse the order data of the multiple groups of to-be-collected order data respectively based on a preset collection list template, and fill the order information into the default parameters of the preset collection list template; a first generating unit 7023, which is used to check the data integrity in the filled batch collection list template, and generate a batch collection list if it is complete and correct.
[0118] In this embodiment, the generation module 703 includes: a sorting unit 7031, which is used to import a batch collection list and sort the to-be-collected orders in each group of to-be-collected orders in the batch collection list; a planning unit 7032, which is used to plan the routes of the grouped and sorted to-be-collected orders according to the shortest path first algorithm to obtain a collection route; a second generation unit 7033, which is used to assign collection staff according to the collection route and generate collection instructions.
[0119] In this embodiment, the update module 704 includes: a second acquisition unit 7041, which is used to obtain the collection results based on the collection instructions, and the collection results include the pending collection orders that have been successfully collected and the pending collection orders that have failed to be collected; a first update unit 7042, which is used to update the status of the pending collection orders that have been successfully collected to collected and update the logistics information; a second update unit 7043, which is used to update the status of the pending collection orders that have failed to be collected to failed collection and record the reasons for the failure.
[0120] In this embodiment, the analysis module 705 includes: an analysis unit 7051, which is used to collect the pending collection orders with a failed collection status and analyze the reasons for the failure; a summary unit 7052, which is used to classify and summarize the collected pending collection orders according to the reasons for the failure to obtain a summary result; and a third generation unit 7053, which is used to generate a collection analysis report based on the summary result.
[0121] In this embodiment, the order collection data is detected for anomalies through a random forest detection model to obtain orders to be collected, and a clustering algorithm combined with a genetic algorithm is used to group the orders to be collected to obtain multiple groups of orders to be collected, and a batch collection list is generated, and then a collection instruction is generated based on the batch collection list, and a collection result is obtained based on the collection instruction, and the status of the order to be collected is updated according to the collection result. Finally, the orders to be collected with a failed collection status are collected and analyzed to generate a collection analysis report. The order collection data is detected for anomalies using a random forest detection model, which can effectively identify abnormal data that does not conform to the normal pattern, thereby improving the detection rate of abnormal orders. The orders to be collected are grouped through a clustering algorithm combined with a genetic algorithm to generate a batch collection list, so that the collection instructions can be better generated later. In addition, for the failed collection orders to be collected, timely analysis and feedback can provide customers with more accurate solutions and better service experience.
[0122] above Figure 7 The agreement customer order collection device in the embodiment of the present invention is described in detail from the perspective of modular functional entities. The agreement customer order collection device in the embodiment of the present invention is described in detail from the perspective of hardware processing.
[0123] Figure 8 It is a structural diagram of a protocol customer order collection device provided by an embodiment of the present invention. The device 800 may have relatively large differences due to different configurations or performances, and may include one or more processors (central processing units, CPU) 810 (for example, one or more processors) and a memory 820, and one or more storage media 830 (for example, one or more mass storage devices) storing application programs 833 or data 832. Among them, the memory 820 and the storage medium 830 can be short-term storage or permanent storage. The program stored in the storage medium 830 may include one or more modules (not shown), and each module may include a series of instruction operations in the device 800. Furthermore, the processor 810 can be configured to communicate with the storage medium 830 and execute a series of instruction operations in the storage medium on the device 800.
[0124] The device 800 may also include one or more power supplies 840, one or more wired or wireless network interfaces 850, one or more input and output interfaces 860, and / or one or more operating systems 831, such as Windows Serve, Mac OS X, Unix, Linux, FreeBSD, etc.
[0125] An embodiment of the present invention also provides a computer-readable storage medium, which may be a non-volatile computer-readable storage medium or a volatile computer-readable storage medium. Instructions are stored in the computer-readable storage medium. When the instructions are executed on a computer, the computer executes the steps of the method for collecting orders from agreement customers.
[0126] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working process of the above-described system, device, or unit can refer to the corresponding process in the aforementioned method embodiment and will not be repeated here.
[0127] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a storage medium, including a number of instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM), random access memory (RAM), disk or optical disk and other media that can store program codes.
[0128] As described above, the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features thereof may be replaced by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method for collecting orders from contracted customers, characterized in that: The method for collecting orders from agreed customers includes: Obtain order collection data of the contracted customers, and perform anomaly detection on the order collection data using a random forest detection model to obtain orders to be collected; Using a clustering algorithm combined with a genetic algorithm to group the to-be-collected orders, obtaining multiple groups of to-be-collected orders, and generating a batch collection list; Generate a collection instruction based on the batch collection list; Obtaining a collection result based on the collection instruction, and updating the status of the order to be collected according to the collection result, where the status of the order to be collected includes collected and failed to be collected; Collect and analyze pending collection orders with a failed collection status, and generate a collection analysis report.
2. The method for collecting orders from contracted customers according to claim 1, characterized in that: The step of obtaining order collection data of the contracted customer and performing anomaly detection on the order collection data through a random forest detection model to obtain orders to be collected includes: Obtain order collection data from contracted customers and pre-process the order collection data; Perform feature engineering on the pre-processed order collection data; The order collection data processed by feature engineering is input into the random forest detection model for anomaly detection, and normal orders in the order collection data are screened out as orders to be collected according to the detection results of the random forest detection model.
3. The method for collecting orders from contracted customers according to claim 1, characterized in that: The clustering algorithm combined with the genetic algorithm is used to group the to-be-collected orders to obtain multiple groups of to-be-collected orders, and a batch collection list is generated, including: The K-means clustering algorithm combined with the genetic algorithm is used to group the orders to be collected, and multiple groups of order data to be collected are obtained. The shipping addresses of each group of order data to be collected are similar. Based on a preset collection list template, traverse the order data of the plurality of groups of order data to be collected respectively, and fill the order information into the default parameters of the preset collection list template; Check the data integrity in the filled batch collection list template, and generate the batch collection list if it is complete and correct.
4. The method for collecting orders from contracted customers according to claim 3, characterized in that: The K-means clustering algorithm is combined with the genetic algorithm to group the to-be-collected orders, and multiple groups of to-be-collected order data are obtained. The mailing addresses of each group of to-be-collected order data are similar, including: Initializing genetic algorithm parameters, wherein the genetic algorithm parameters include population size, crossover rate, mutation rate and termination condition; Randomly generate a preset number of individuals as an initial population, each individual in the initial population includes a set of randomly initialized centroids; Execute the K-means algorithm on each individual in the initial population, and calculate the fitness value of the corresponding individual respectively, select the parent generation for generating the next generation population according to the fitness value, and randomly select two parents to perform a crossover operation to generate new individuals, perform a mutation operation on the new individuals, and perform an iterative operation; The individual with the highest fitness value is selected from the last generation population as the optimal initial centroid combination. The K-means algorithm is executed using the optimal initial centroid combination to obtain the clustering result. The orders to be collected are grouped according to the clustering result to obtain multiple groups of order data to be collected. The shipping addresses of each group of order data to be collected are similar.
5. The method for collecting orders from contracted customers according to claim 1, characterized in that: The generating of the collection instruction based on the batch collection list includes: Importing a batch collection list, and sorting the to-be-collected orders in each group of to-be-collected orders in the batch collection list; According to the shortest path priority algorithm, the route of the grouped and sorted waiting collection orders is planned to obtain the collection route; A collection agent is assigned according to the collection route and a collection instruction is generated.
6. The method for collecting orders from contracted customers according to claim 1, characterized in that: The acquiring of the collection result based on the collection instruction and updating the status of the order to be collected according to the collection result, wherein the status of the order to be collected includes collected and failed to be collected, including: Obtaining the collection results based on the collection instructions, including the pending collection orders that were successfully collected and the pending collection orders that failed to be collected; For orders that have been successfully collected and are waiting to be collected, the status is updated to collected, and the logistics information is updated; For pending collection orders that failed to be collected, the status will be updated to collection failed and the reason for the failure will be recorded.
7. The method for collecting orders from contracted customers according to claim 1, characterized in that: The collection and analysis of pending collection orders whose collection status is failed generates a collection analysis report, including: Collect pending collection orders with a collection failure status and analyze the reasons for the failure; Classify and summarize the collected orders to be collected according to the reasons for failure to obtain summary results; Generate a collection analysis report based on the summary results.
8. A device for collecting orders from contracted customers, characterized in that: include: An anomaly detection module is used to obtain order collection data of contract customers and perform anomaly detection on the order collection data through a random forest detection model to obtain orders to be collected; A grouping module, used to group the to-be-collected orders using a clustering algorithm combined with a genetic algorithm, obtain multiple groups of to-be-collected orders, and generate a batch collection list; A generating module, used for generating a collection instruction based on the batch collection list; An updating module, used for obtaining a collection result based on the collection instruction, and updating the status of the order to be collected according to the collection result, where the status of the order to be collected includes collected and failed to be collected; The analysis module is used to collect and analyze the pending collection orders with a failed collection status and generate a collection analysis report.
9. A device for collecting orders from contracted customers, characterized in that: comprising a memory and at least one processor, wherein the memory has computer-readable instructions stored therein; The at least one processor calls the computer-readable instructions in the memory to execute the various steps of the method for collecting customer orders according to any one of claims 1-7.
10. A computer-readable storage medium having computer-readable instructions stored thereon, characterized in that: When the computer-readable instructions are executed by a processor, the various steps of the method for collecting customer orders according to any one of claims 1 to 7 are implemented.
