Method and device for determining logistics business
By acquiring shipping request information, utilizing a pre-set pricing model and a real-time decision-making unit, and combining reinforcement learning and a multi-objective optimization function model, the problems of low efficiency and poor matching in logistics business determination are solved, achieving efficient and accurate screening of logistics business.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-21
- Publication Date
- 2026-03-27
AI Technical Summary
The current logistics business determination process is inefficient and unable to accurately select logistics services that meet the needs, making it difficult to dynamically adapt to changes in the logistics market and affecting the overall efficiency and quality of operations.
By acquiring shipping request information, a targeted quote for logistics services is generated using a pre-defined pricing model. Combined with a real-time decision-making unit, a reinforcement learning model and a multi-objective optimization function model are used to select the target logistics services.
It enables efficient and accurate determination of logistics operations, improves the overall efficiency and quality of logistics operations, and ensures the suitability of quotation information with delivery requirements.
Smart Images

Figure CN121745786A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of logistics technology, and in particular to a method and apparatus for determining logistics operations. Background Technology
[0002] In the current process of determining logistics services, the methods for selecting logistics services often rely on manual comparison of logistics service quotes or screening of logistics services from only a single dimension. This not only results in low efficiency in determining logistics services, but also fails to consider the correlation and matching between the shipping request information (including departure location information, destination location information, cargo attribute information, and logistics service information) and the logistics service quotes. It is impossible to accurately screen out logistics services that meet the needs based on the shipping request information, and it is also difficult to dynamically adapt to changes in the logistics market. As a result, it is impossible to efficiently and accurately determine the logistics services that meet the actual shipping needs from various logistics services, thereby affecting the overall efficiency and quality of logistics operations. Summary of the Invention
[0003] This application provides a method and apparatus for determining logistics services, aiming to effectively solve the problem of being unable to efficiently and accurately determine the logistics services that meet the actual delivery needs from various logistics services, thereby affecting the overall efficiency and quality of logistics operations.
[0004] Firstly, this application provides a method for determining logistics services, the method comprising: Obtain shipping request information; wherein, the shipping request information includes departure location information, destination location information, cargo attribute information, and logistics service information; Input the shipping request information into a preset pricing model to obtain pricing information for each logistics service; The quotation information corresponding to each logistics service and the shipping request information are input into the real-time decision unit to obtain the target logistics service; wherein, the target logistics service is one of the logistics services.
[0005] Secondly, this application provides a device for determining logistics operations, the device comprising: The first unit is used to obtain shipping request information; wherein, the shipping request information includes departure location information, destination location information, cargo attribute information, and logistics service information; The second unit is used to input the shipping request information into a preset pricing model to obtain pricing information corresponding to each logistics service. The third unit is used to input the quotation information corresponding to each logistics service and the shipping request information into the real-time decision unit to obtain the target logistics service; wherein, the target logistics service is one of the logistics services.
[0006] Thirdly, this application provides a readable medium including executable instructions, which, when executed by a processor of an electronic device, cause the electronic device to perform any of the methods described in the first aspect.
[0007] Fourthly, this application provides an electronic device including a processor and a memory storing execution instructions, wherein when the processor executes the execution instructions stored in the memory, the processor performs the method as described in any of the first aspects.
[0008] As can be seen from the above technical solution, the method for determining logistics services provided in this application first obtains shipping request information containing departure location information, destination location information, cargo attribute information, and logistics service information, providing a comprehensive and accurate basis for subsequent screening and determination of logistics services. Next, the shipping request information is input into a preset pricing model to obtain pricing information corresponding to each logistics service, realizing the generation of targeted pricing based on specific shipping request information and ensuring the adaptability of pricing information to shipping needs. Finally, the pricing information corresponding to each logistics service and the shipping request information are input into a real-time decision-making unit to obtain the target logistics service. This process fully combines shipping needs and pricing information for decision-making, enabling precise screening of target logistics services that meet actual shipping needs from various logistics services. It effectively solves the problems of low efficiency and poor matching caused by traditional manual comparison or single-dimensional screening, significantly improving the efficiency and accuracy of logistics service determination and ensuring the efficient operation of logistics services.
[0009] The further effects of the aforementioned non-conventional preferred method will be explained below in conjunction with specific embodiments. Attached Figure Description
[0010] To more clearly illustrate the embodiments of this application or the existing technical solutions, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0011] Figure 1 A flowchart illustrating a method for determining logistics operations provided in this application; Figure 2 A schematic diagram of the structure of a logistics operation determination device provided in this application; Figure 3 This is a schematic diagram of the structure of an electronic device provided in this application. Detailed Implementation
[0012] To make the objectives, technical solutions, and advantages of this application clearer, the technical solutions of this application will be clearly and completely described below in conjunction with specific embodiments and corresponding drawings. Obviously, the described embodiments are only a part of the embodiments of this application, and not all of them. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0013] The various non-limiting embodiments of this application will now be described in detail with reference to the accompanying drawings.
[0014] In this specific embodiment, the definitions of the coined words and specific terms involved are as follows: Shipment request information: This refers to all the information provided by the user when initiating a logistics business to clarify the logistics needs, including departure location information, destination location information, cargo attribute information, and logistics service information. It is the core basis for subsequent logistics service selection, quotation calculation, and decision-making.
[0015] Preset pricing model: refers to an algorithm model built based on the logistics company's historical pricing data, service parameters and logistics business scenario rules, which can generate corresponding prices for each logistics service according to the shipping request information. Its core function is to realize the automated and accurate calculation of prices.
[0016] Real-time decision-making unit: This refers to a functional unit that integrates reinforcement learning models and multi-objective optimization function models. It receives quotation information and delivery request information, and determines the target logistics service through algorithm calculation. It is the core module for realizing intelligent selection of logistics services.
[0017] Reinforcement learning model: refers to an algorithm model that uses a deep Q-network (DQN) as its basic architecture, is trained on historical transaction data, and can output the initial selection probability of each logistics service. Its input is quotation information and delivery request information, and the output is a probability value reflecting the suitability of logistics services.
[0018] Multi-objective optimization function model: This refers to a model that takes cost, service quality, and timeliness as the core optimization objectives, calculates the optimization function value of each logistics service by setting weights, and then adjusts the initial selection probability. It is used to balance multi-dimensional needs and improve the accuracy of decision-making.
[0019] Target logistics service: This refers to the single logistics service that best matches the user's shipping request information, selected from multiple candidate logistics services through real-time decision-making unit calculations. It is the final output of the logistics business determination method. It should be noted that a logistics service can be a service provided by a single logistics company, while different logistics services can be understood as logistics services provided by different logistics companies.
[0020] Cost parameter (C): This parameter reflects the cost of logistics services. It is determined based on the pricing information corresponding to the logistics services and is the core indicator for measuring the cost dimension in the multi-objective optimization function model.
[0021] Service quality parameter (Q): refers to the parameter that reflects the level of logistics service quality. It is calculated based on historical service parameters of logistics services (such as on-time delivery rate, cargo damage rate, etc.) and is the core indicator for measuring the service quality dimension in the multi-objective optimization function model.
[0022] Timeliness parameter (T): refers to the parameter that reflects the delivery efficiency of logistics services. It is calculated based on the historical logistics timeliness parameters of logistics services (such as the matching degree between promised delivery time and expected delivery time) and is the core indicator for measuring the timeliness dimension in the multi-objective optimization function model.
[0023] See Figure 1 This application illustrates a method for determining logistics operations according to an embodiment of the present application. The method includes the following steps: S101: Obtain shipping request information.
[0024] The shipment request information includes departure location information, destination location information, cargo attribute information, and logistics service information. The cargo attribute information includes: cargo name, quantity, individual volume, individual weight, and whether it is fragile. The logistics service information includes: expected delivery time, budget range, delivery method, and whether door-to-door service is available.
[0025] It should be noted that obtaining shipping request information is the initial step in determining logistics operations. This is achieved through the system's demand receiving module, which collects complete logistics requests from users. The shipping request information includes departure location information, destination location information, cargo attribute information, and logistics service information. The specific methods for obtaining and processing each piece of information are as follows: The information receiving module provides two methods for receiving shipping request information to adapt to different user scenarios: Online Interface Reception: The module provides an API interface supporting HTTP / HTTPS protocols, allowing third-party platforms such as e-commerce platforms and enterprise ERP systems to call it. When calling, the third-party platform must input complete shipping request information according to the interface specifications, including: departure location information (formatted as "Province / City / District / Detailed Address", such as "No. 1, Yuanlu Road, Nanshan District, Shenzhen City, Guangdong Province"), destination location information (formatted the same as departure location information), cargo attribute information, and logistics service information. The interface has built-in data validation logic; if the input information format is incorrect (e.g., departure location information is not accurate to the district level), an error code and prompt message will be returned until the information conforms to the specifications.
[0026] Offline form entry: The module's front end provides a visual interactive form where users can manually fill in shipping request information. The form has real-time validation for each information field. For example, in the cargo attribute information, individual volume and weight must be entered as positive numbers. If the user enters a negative number or non-numerical content, the form immediately displays a "Please enter a positive number" prompt and locates the incorrect field. In the logistics service information, the expected delivery time must be selected from a date range of "start date - end date" (e.g., "2025-10-01 to 2025-10-03"). If the selected end date is earlier than the start date, the form automatically prevents submission and prompts for adjustment.
[0027] Next, the specific content and processing of each information field are as follows: Departure location information and destination location information: both must be accurate to "province / city / district / detailed address". After receiving the information, the module will automatically extract the "province / city / district" information for subsequent transportation mileage calculation, and the "detailed address" will be used for logistics door-to-door pickup and delivery positioning.
[0028] Goods attribute information: This may include the name, quantity, individual volume, individual weight, and whether it is fragile. The module's processing logic for this type of information is as follows: If the user directly provides the individual volume (unit: cubic meters) and quantity of the goods, the module will automatically calculate the total volume of the goods. The calculation formula is "total volume = individual volume × quantity". For example, if the user enters "individual volume 0.02 cubic meters, quantity 50 pieces", then the total volume = 0.02 × 50 = 1 cubic meter.
[0029] If the user only provides the dimensions of the goods (length × width × height, unit: centimeters), the module first converts the dimensions to cubic meters (conversion formula is "volume = length × width × height ÷ 1000000"), and then multiplies it by the quantity to get the total volume; for example, if the user enters "goods dimensions 50cm × 40cm × 30cm, quantity 10 pieces", then the volume of a single piece = 50 × 40 × 30 ÷ 1000000 = 0.06 cubic meters, and the total volume = 0.06 × 10 = 0.6 cubic meters.
[0030] If the goods are irregularly shaped (such as cylindrical or irregularly shaped), the module provides a "Volume Correction Factor" drop-down selection box (with built-in preset values such as a correction factor of 1.2 for cylindrical goods and 1.5 for irregular goods). After the user selects the corresponding factor, the module adjusts the volume according to "Corrected Total Volume = Calculated Total Volume × Correction Factor". For example, if the calculated total volume of cylindrical goods is 0.8 cubic meters, and a correction factor of 1.2 is selected, then the corrected total volume = 0.8 × 1.2 = 0.96 cubic meters.
[0031] The "Is it a fragile item?" status is stored as a Boolean value (Yes / No) and is used to adjust the timeliness weight in the subsequent multi-objective optimization function model (the timeliness weight is increased for fragile items).
[0032] Logistics service information: including expected delivery time, budget range, delivery method, and whether door-to-door service is available. Among these: The expected delivery time is a date range (e.g., "2025-10-01 to 2025-10-03"), which is used for subsequent timeliness parameter calculations; The budget range is the acceptable logistics cost range for users (unit: yuan, such as "500-800 yuan"), used for cost parameter calculation and reward function calculation; The transportation options include road, rail, and air. After the user selects according to their needs, the module is used to filter logistics services that support that transportation method. The door-to-door service status is stored as a Boolean value (Yes / No). When filtering logistics services, the module only retains candidate logistics services that support door-to-door service (if the user selects "Yes") or do not restrict door-to-door service (if the user selects "No").
[0033] S102: Input the shipping request information into the preset quotation model to obtain the quotation information corresponding to each logistics service.
[0034] As an example, the shipping request information can be input into the preset pricing model first. Then, the preset pricing model can determine the total volume of the goods based on the goods' attribute information; and the preset pricing model can determine the transportation mileage based on the departure location information and the destination location information. Finally, the preset pricing model can determine the pricing information corresponding to each logistics service based on the total volume of the goods, the transportation mileage, and the logistics service information.
[0035] For example, this step is implemented through the system's volume calculation module. The preset pricing model is integrated into the volume calculation module, and the core data support of the model comes from the logistics company's database module (which stores historical pricing data, service parameters, and basic information for each logistics service). After the shipping request information is input into the preset pricing model, the model outputs the pricing information corresponding to each logistics service through three sub-steps: "determining the transportation mileage - filtering candidate logistics services - calculating pricing information." The specific implementation details are as follows: The data support module for the pre-set pricing model, provided by the logistics company's database module, includes the following core data: Historical pricing data: Includes volumetric pricing (unit: RMB / cubic meter), weight surcharge (unit: RMB / kg), remote area premium (percentage), and holiday price adjustment records (date + adjustment amount) for each logistics service over the past 3 years; Basic information: including the coverage area of each logistics service (accurate to the city level), transportation method (road / rail / air), maximum carrying volume (cubic meters), and basic mileage (e.g., 500 kilometers, mileage fees will be charged for distances exceeding this). Data update mechanism: The database module automatically retrieves quotations and service parameters from various logistics service official platforms at 3:00 AM every day, compares them with historical data, and updates the data and records the change log if the difference exceeds 5%. At the same time, it supports administrators to manually upload change files in Excel / CSV format. The system automatically verifies the data format (e.g., quotations must be positive numbers, and the premium for remote areas must be between 0-50%). After the verification is passed, the update is completed to ensure that the data used by the preset quotation model is real-time and accurate.
[0036] It should be noted that the calculation process of the preset pricing model consists of the following four steps: Step 1: Determine the freight transportation mileage and preset pricing model. Call a third-party map API (such as Gaode Map API), and input the departure location information (extract the core address of "province / city / district") and destination location information (in the same format) from the shipping request information. The API will return the transportation mileage (unit: kilometers) between the two locations for the corresponding transportation method (road / rail / air selected by the user). For example, if the user selects "road transportation", the departure location is "Nanshan District, Shenzhen, Guangdong Province", and the destination location is "Pudong New Area, Shanghai", then the API will return a transportation mileage of approximately 1400 kilometers.
[0037] Step 2: Screening Candidate Logistics Services The preset pricing model filters candidate logistics services from the logistics company database module based on the following criteria: Coverage area matching: The coverage area of the logistics service must include both the "city" in the departure location information and the "city" in the destination location information; Shipping method matching: The shipping methods supported by the logistics service are consistent with the shipping method selected by the user; Load capacity matching: The maximum load capacity of the logistics service is greater than or equal to the corrected total volume of the goods; Door-to-door service matching: If the user selects "door-to-door service", only logistics services that support door-to-door service will be retained. For example, if the total volume of the user's goods after adjustment is 1.2 cubic meters, and the user selects "road transport + door-to-door service", the model will filter out all logistics services that "cover Shenzhen-Shanghai, support road transport, have a maximum carrying volume ≥ 1.2 cubic meters, and provide door-to-door service" as candidates.
[0038] Step 3: Calculate the pricing information for each candidate logistics service. The preset pricing model calculates the price for each candidate logistics service in stages based on its historical pricing data and shipping request information, using the following formula: Calculate the base price: Base price = Total volume of goods after adjustment × Volume-based price for logistics services + Total weight of goods × Weight surcharge for logistics services; where, Total weight of goods = Individual weight of goods × Quantity (if the user does not provide the individual weight, it is calculated based on the average weight of similar goods in the database, such as 2 kg / cubic meter for ordinary cardboard boxes); For example, if the volume-based price for logistics services is 200 yuan / cubic meter, the weight surcharge is 1 yuan / kg, the total volume of goods after adjustment is 1.2 cubic meters, and the total weight is 5 kg, then the base price = 1.2 × 200 + 5 × 1 = 245 yuan.
[0039] Calculate mileage fees (if applicable): If the transport mileage > the base mileage of the logistics service (stored in the database, such as 500 km), then the mileage fee = (transport mileage - base mileage) × logistics service unit mileage fee (unit: yuan / km); for example, if the transport mileage is 1400 km, the base mileage is 500 km, and the unit mileage fee is 0.3 yuan / km, then the mileage fee = (1400-500) × 0.3 = 270 yuan; if the transport mileage ≤ base mileage, then the mileage fee is 0.
[0040] Calculating the remote area premium: The model determines whether the "district" in the destination location information belongs to the remote area defined by the logistics service (a pre-set list of remote areas in the database). If so, the remote area premium = (base price + mileage fee) × logistics service remote area premium percentage; for example, the base price is 245 yuan + mileage fee is 270 yuan = 515 yuan, and the remote area premium is 10%, so the premium = 515 × 10% = 51.5 yuan; if it does not belong to a remote area, the premium is 0.
[0041] Calculating Holiday Price Adjustments: The model determines whether the shipping date (the date the user initiates the request, or the shipping date specified by the user) falls within the holiday price adjustment record range for logistics services (the database stores a list of holidays and their corresponding price adjustments). If so, the adjusted price = (base price + mileage fee + remote area premium) × (1 + holiday price adjustment range). For example, if the total cost is 515 + 51.5 = 566.5 yuan, and the holiday price adjustment range is 5%, then the adjusted price = 566.5 × (1 + 5%) ≈ 594.83 yuan. If the price is not within the holiday range, the adjusted price = base price + mileage fee + remote area premium.
[0042] Step 4: Output Quotation Information After the preset quotation model is completed, quotation information is generated for each candidate logistics service. The content includes "logistics service name, final quotation amount (accurate to the cent), quotation composition details (basic quotation, mileage fee, premium, price adjustment amount), and quotation calculation basis". The quotation information of all candidate logistics services is stored in a temporary database for subsequent real-time decision-making unit to call.
[0043] S103: Input the quotation information corresponding to each logistics service and the shipping request information into the real-time decision unit to obtain the target logistics service.
[0044] The target logistics service is one of the various logistics services.
[0045] In one implementation, the real-time decision-making unit includes a reinforcement learning model and a multi-objective optimization function model; the step of inputting the quotation information corresponding to each logistics service and the shipping request information into the real-time decision-making unit to obtain the target logistics service includes the following steps: The quotation information corresponding to each logistics service and the shipping request information are input into the reinforcement learning model to obtain the initial selection probability corresponding to each logistics service. Using the multi-objective optimization function model, the initial selection probability corresponding to each logistics service is adjusted to obtain the final selection probability corresponding to each logistics service; The target logistics service is determined based on the final selection probability of each logistics service. For example, the logistics service with the highest final selection probability can be used as the target logistics service, or the user can choose one of the three logistics services with the highest final selection probability as the target logistics service.
[0046] The reinforcement learning model uses a deep Q-network (DQN) as its base model, has an input layer dimension of 12, three hidden layers, uses ReLU as its activation function, and has an output layer dimension equal to the number of candidate logistics services.
[0047] In one implementation, adjusting the initial selection probability of each logistics service using the multi-objective optimization function model to obtain the final selection probability of each logistics service includes: Based on the pre-set multi-objective optimization function model, determine the optimization function values for each logistics service; For each logistics service, if the optimization function value of the logistics service is higher than the average of the optimization function values of all logistics services, the initial selection probability of the logistics service is increased, wherein the increase in the initial selection probability is determined based on the optimization function value of the logistics service and the average value; if the optimization function value of the logistics service is lower than the average of the optimization function values of all logistics services, the initial selection probability of the logistics service is decreased, wherein the decrease in the initial selection probability is determined based on the optimization function value of the logistics service and the average value. The sum of the final selection probabilities for all logistics services is 1; the optimization function value for the logistics service is determined based on a pre-defined multi-objective optimization function model.
[0048] It should be noted that the preset multi-objective optimization function model is: Optimization function value = C × cost weight + Q × service quality weight + T × timeliness weight.
[0049] Wherein, C is the cost parameter of the logistics service, which is determined based on the corresponding quotation information of the logistics service; Q is the service quality parameter of the logistics service, which is determined based on the historical service parameters of the logistics service; and T is the timeliness parameter of the logistics service, which is determined based on the historical logistics timeliness parameters of the logistics service.
[0050] It should be noted that this step can be implemented through the system's multi-objective reinforcement learning decision-maker module. The real-time decision-making unit is the core component of this module. The real-time decision-making unit includes a reinforcement learning model and a multi-objective optimization function model. Its operation process is divided into three sub-steps: "generating initial selection probabilities - adjusting to obtain final selection probabilities - determining target logistics services". The specific implementation details are as follows: 1. Pre-decision preparation for real-time decision-making units: Data Input: The real-time decision-making unit retrieves the quotation information corresponding to each logistics service from the temporary database, retrieves the complete shipping request information from the demand receiving module, and retrieves the historical service parameters of each logistics service (including the on-time delivery rate, cargo damage rate, customer service response time (95th percentile), and exception handling success rate) and historical logistics timeliness parameters (average delivery time of the same route and cargo type in the past 3 months) from the logistics company database module.
[0051] Data preprocessing: The real-time decision unit standardizes the input data to ensure it is consistent with the training data format of the reinforcement learning model. Quotation information standardization: The final quotations of each logistics service are converted into data that conforms to the model input range according to the formula "Standardized quotation = (final quotation - mean of all candidate logistics service quotations) / standard deviation of all candidate logistics service quotations"; Service parameter standardization: On-time delivery rate (0-100%), goods damage rate (0-0.01%), and exception handling success rate (0-100%) are linearly mapped to the 0-1 range; customer service response time (unit: minutes) is converted according to "standardized response time = (60 - customer service response time) / 60" (if customer service response time > 60 minutes, the standardized response time is 0); Shipment request information processing: Standardize numerical information such as total weight of goods, transportation distance, and expected delivery time (end date of expected delivery time - start date, unit: days), and convert Boolean values such as "whether it is fragile" and "whether door-to-door service is required" into 0-1 codes (yes = 1, no = 0).
[0052] 2. The reinforcement learning model generates the initial selection probabilities for each logistics service: The reinforcement learning model uses a deep Q-network (DQN) as its base model, and its specific architecture and training process are as follows: Model architecture: The input layer has 12 dimensions, corresponding to 12 input features (including: standardized price (1 dimension), historical service parameters (on-time delivery rate, cargo damage rate, customer service response time, and exception handling success rate, totaling 4 dimensions), and shipping request information features (total cargo weight, corrected total volume, transportation distance, expected delivery time, whether it is fragile, whether door-to-door service is available, standardized value of budget range, and shipping method code, totaling 7 dimensions), for a total of 12 dimensions); the hidden layer has 3 layers: the first layer has 64 neurons, the second layer has 32 neurons, and the third layer has 16 neurons, all using ReLU activation function; the output layer dimension is the number of candidate logistics services, and the output value is the initial selection probability of each candidate logistics service (the sum of the probability values is 1).
[0053] Model Training Process: The reinforcement learning model is trained using the "Model Training Unit" of the multi-objective reinforcement learning decision-maker module. The training data comes from nearly 5 years of historical transaction data (containing over 100,000 valid records) in the logistics company's database module. Each record includes input features (12-dimensional features corresponding to the model's input layer) and labels (the logistics service ultimately selected by the user in this transaction (marked as "optimal choice," with a corresponding label probability of 1), and the user's satisfaction rating after the transaction (1-5 points)). The training steps are as follows: (1) Initialize model parameters: weights are initialized using Xavier, biases are initialized to 0; learning rate is set to 0.001, discount factor to 0.9, and experience replay pool capacity to 10000.
[0054] (2) Batch data training: Randomly select 32 data points from historical transaction data as a batch, input them into the model to obtain the predicted selection probability of each logistics service; construct a multi-objective reward function (cost reward = if the quoted price ≤ budget, then (budget - quoted price) / budget × 20, otherwise - (quoted price - budget) / budget × 30; service quality reward = on-time delivery rate × 15 + (1 - damage rate) × 25 + standardized response time × 10; timeliness reward = if the promised delivery time ≤ expected delivery time, then (expected delivery time - promised delivery time) / expected delivery time × 20, otherwise - (promised delivery time - expected delivery time) / expected delivery time × 25; total reward = cost reward + service quality reward + timeliness reward); calculate the cross-entropy loss between the predicted selection probability and the label, use the Adam optimizer to minimize the loss and adjust the model parameters.
[0055] (3) Experience playback and iteration: Store the current batch data into the experience playback pool. When the pool is full, delete the earliest data. Repeat the batch training steps and iterate for 1000 rounds. After each round of training, use the validation set (20% of the historical data) to test the accuracy. When the accuracy is stable above 90% for 10 consecutive rounds, stop training and save the model parameters.
[0056] It is important to emphasize that the process of generating the initial selection probability can be as follows: the real-time decision unit loads the trained reinforcement learning model, inputs the preprocessed "quotation information of each logistics service + shipping request information + historical service parameters" into the model, and the model outputs the initial selection probability of each candidate logistics service through forward propagation; for example, the initial selection probabilities of the three candidate logistics services are 0.4, 0.35 and 0.25 respectively.
[0057] 3. The final selection probability for each logistics service is obtained by adjusting the multi-objective optimization function model: The multi-objective optimization function model adjusts the initial selection probability by calculating the optimization function value. The specific steps are as follows: Step 1: Determine the parameters and weights of the multi-objective optimization function model. The formula for the multi-objective optimization function model is "Optimization function value = C × Cost weight + Q × Service quality weight + T × Timeliness weight", where: Cost parameter (C): Determined based on the pricing information of logistics services. The calculation formula is "C = (user's maximum budget - final logistics service price) / user's maximum budget" (if the final price ≤ the maximum budget, C is positive; if the final price > the maximum budget, C is negative). For example, if the user's maximum budget is 800 yuan and the final logistics service price is 594.83 yuan, then C = (800 - 594.83) / 800 ≈ 0.256. The cost weight is 0.4 by default, and is dynamically adjusted according to the user's budget sensitivity (if the user's budget ≤ the average price of all candidate logistics services, the weight increases to 0.5; if the budget ≥ 1.2 times the average price, the weight decreases to 0.3).
[0058] Service Quality Parameter (Q): Calculated based on historical service parameters of logistics services, the formula is "Q = On-time delivery rate × 0.3 + (1 - Goods damage rate) × 0.4 + (Outbreak handling success rate / 100) × 0.3"; for example, if the on-time delivery rate of logistics services is 98% (0.98), the goods damage rate is 0.005% (0.00005), and the exception handling success rate is 95% (0.95), then Q = 0.98 × 0.3 + (1 - 0.00005) × 0.4 + 0.95 × 0.3 ≈ 0.294 + 0.39998 + 0.285 ≈ 0.97898; the service quality weight is fixed at 0.3.
[0059] Timeliness parameter (T): Calculated based on historical logistics timeliness parameters of the logistics service. The formula is "T = (Expected delivery time - Historical average delivery time of the logistics service) / Expected delivery time" (if the historical average delivery time ≤ expected delivery time, T is a positive value; if it exceeds, T is a negative value). For example, if the expected delivery time is 3 days and the historical average delivery time of the logistics service is 2.5 days, then T = (3 - 2.5) / 3 ≈ 0.1667. The default weight for timeliness is 0.3. If the goods are fragile (the "Is it fragile?" in the shipping request information is 1), the weight increases to 0.4, while the cost weight decreases to 0.3.
[0060] Step 2: Calculate the optimization function value and average value for each logistics service. For each candidate logistics service, substitute the above parameters and weights to calculate the optimization function value. For example, for a logistics service, C=0.256, cost weight 0.4, Q=0.97898, service quality weight 0.3, T=0.1667, and timeliness weight 0.3, then the optimization function value = 0.256×0.4 + 0.97898×0.3 + 0.1667×0.3≈0.1024 + 0.2937 + 0.05≈0.4461. Calculate the average value of the optimization function values for all candidate logistics services. For example, if the optimization function values for three candidate logistics services are 0.4461, 0.38, and 0.32 respectively, then the average value = (0.4461+0.38+0.32) / 3≈0.382.
[0061] Step 3: Adjust the initial selection probabilities to obtain the final selection probabilities. Adjust the initial selection probabilities of each logistics service according to the following rules: If the optimization function value of the logistics service is greater than the average value: the initial selection probability increases by the following margin: (optimization function value of the logistics service - average value) / average value × 20%. For example, if the optimization function value is 0.4461 > the average value is 0.382, and the initial selection probability is 0.4, then the increase is (0.4461 - 0.382) / 0.382 × 20% ≈ 0.1678 × 20% ≈ 0.0336, and the adjusted probability is 0.4 + 0.0336 = 0.4336.
[0062] If the optimization function value of the logistics service is less than the average value, the initial selection probability decreases by the amount of decrease = (average value - optimization function value of the logistics service) / average value × 20%. For example, if the optimization function value is 0.32 < the average value is 0.382 and the initial selection probability is 0.25, then the decrease is (0.382 - 0.32) / 0.382 × 20% ≈ 0.1623 × 20% ≈ 0.0325, and the adjusted probability is 0.25 - 0.0325 = 0.2175.
[0063] Probability Normalization: After adjustment, if the sum of the probabilities of all logistics services is not 1, normalization is performed according to "final selection probability = adjusted probability / sum of adjusted probabilities" to ensure that the sum of the final selection probabilities is 1. For example, after adjustment, the probabilities of the three logistics services are 0.4336, 0.369 (initially 0.35, optimized function value 0.38 close to the average, fine-tuned), and 0.2175, with a sum ≈ 1.0201. After normalization, the final selection probabilities are ≈ 0.425, 0.362, and 0.213.
[0064] 4. Determine the target logistics service and execute subsequent operations: After the real-time decision-making unit outputs the final selection probability of each candidate logistics service, the system's selection execution module determines and executes the target logistics service according to the following logic: Target logistics services identified: If the user enables the "Auto Selection" mode (a preset option in the logistics service information) in the shipping request information, the selection execution module will directly determine the logistics service with the highest final selection probability as the target logistics service; for example, the logistics service corresponding to the final selection probability of 0.425 will be the target logistics service.
[0065] If the user enables "manual confirmation" mode, the execution module will display the information of the top 3 candidate logistics services with the final selection probability (including logistics service name, final price, optimization function value, final selection probability, and historical service parameters) to the user in the form of a visual report (table + chart). After the user manually selects, the system will determine the logistics service selected by the user as the target logistics service and record the user's selection result (for subsequent iterative optimization of the reinforcement learning model).
[0066] Order placement execution: Select the execution module to call the order API of the target logistics service (connect with the logistics service provider in advance and obtain API permissions), and pass in the core data from the shipping request information, such as departure location information, destination location information, cargo attribute information, and expected delivery time.
[0067] Receive the order number and confirmation information (such as estimated pickup time and estimated delivery time) returned by the logistics service API, and store the order number, target logistics service name, order time, and estimated pickup / delivery time in the system order database.
[0068] Send a notification of successful order placement according to the user's preset notification method (SMS, email, system message). The notification content includes the order number, target logistics service information, and logistics tracking link (generated by calling the official tracking interface of the logistics service).
[0069] Exception handling: If the order API call to the target logistics service fails (e.g., API timeout, error code return), the execution module will automatically call the order API of the second-best logistics service (ultimately selecting the second-highest probability) and record the reason for failure (e.g., "API timeout" or "permission expired").
[0070] If the order for the top 3 candidate logistics services fails, the system will immediately send an alarm notification to the administrator (including failure details and shipping request information), and at the same time send an order failure message to the user, suggesting that the user adjust the shipping request information (such as relaxing the expected delivery time or increasing the budget range) or resubmit the request.
[0071] It is important to emphasize that, to ensure the accuracy and adaptability of the logistics business determination method, the system regularly (on the 1st of each month) transmits historical order data (including the actual price of the target logistics service, the actual delivery time, the condition of the goods damaged, and the user satisfaction rating) to the model training unit of the multi-objective reinforcement learning decision-maker module. The reinforcement learning model is iteratively optimized and the model parameters are updated according to the aforementioned training steps. At the same time, the logistics company database module updates the historical price data and service parameters of each logistics service monthly to ensure that the input data of the preset price model and the multi-objective optimization function model are real-time and accurate, and continuously improve the matching accuracy of the target logistics service and user satisfaction.
[0072] As can be seen from the above technical solution, the method for determining logistics services provided in this application first obtains shipping request information containing departure location information, destination location information, cargo attribute information, and logistics service information, providing a comprehensive and accurate basis for subsequent screening and determination of logistics services. Next, the shipping request information is input into a preset pricing model to obtain pricing information corresponding to each logistics service, realizing the generation of targeted pricing based on specific shipping request information and ensuring the adaptability of pricing information to shipping needs. Finally, the pricing information corresponding to each logistics service and the shipping request information are input into a real-time decision-making unit to obtain the target logistics service. This process fully combines shipping needs and pricing information for decision-making, enabling precise screening of target logistics services that meet actual shipping needs from various logistics services. It effectively solves the problems of low efficiency and poor matching caused by traditional manual comparison or single-dimensional screening, significantly improving the efficiency and accuracy of logistics service determination and ensuring the efficient operation of logistics services.
[0073] like Figure 2 The image shows a specific embodiment of a logistics business determination device provided in this application. The device described in this embodiment is a physical device used to execute the method described in the above embodiments. Its technical solution is essentially the same as that of the above embodiments, and the corresponding descriptions in the above embodiments are also applicable to this embodiment. The device in this embodiment includes: The first unit 201 is used to obtain shipping request information; wherein, the shipping request information includes departure location information, destination location information, cargo attribute information and logistics service information; The second unit 202 is used to input the shipping request information into a preset quotation model to obtain quotation information corresponding to each logistics service; The third unit 203 is used to input the quotation information corresponding to each logistics service and the delivery request information into the real-time decision unit to obtain the target logistics service; wherein, the target logistics service is one of the logistics services.
[0074] Optionally, the cargo attribute information includes: cargo name, quantity, individual volume, individual weight, and whether it is a fragile item; the logistics service information includes: expected delivery time, budget range, delivery method, and whether door-to-door service is available.
[0075] Optionally, inputting the shipping request information into a preset pricing model to obtain pricing information corresponding to each logistics service includes: Input the shipping request information into the preset quotation model; The preset pricing model determines the total volume of the goods based on the goods' attribute information; The preset pricing model determines the cargo transportation mileage based on the departure location information and the destination location information; The preset pricing model determines the pricing information for each logistics service based on the total volume of the goods, the transportation distance of the goods, and the logistics service information.
[0076] Optionally, the real-time decision-making unit includes a reinforcement learning model and a multi-objective optimization function model; the step of inputting the quotation information corresponding to each logistics service and the shipping request information into the real-time decision-making unit to obtain the target logistics service includes: The quotation information corresponding to each logistics service and the shipping request information are input into the reinforcement learning model to obtain the initial selection probability corresponding to each logistics service. Using the multi-objective optimization function model, the initial selection probability corresponding to each logistics service is adjusted to obtain the final selection probability corresponding to each logistics service; The target logistics service is determined based on the final selection probability of each logistics service.
[0077] Optionally, the reinforcement learning model uses a deep Q-network (DQN) as the base model, the input layer dimension of the reinforcement learning model is 12, the hidden layer of the reinforcement learning model is set to 3 layers, the activation function of the reinforcement learning model is ReLU, and the output layer dimension of the reinforcement learning model is the number of candidate logistics services.
[0078] Optionally, adjusting the initial selection probability of each logistics service using the multi-objective optimization function model to obtain the final selection probability of each logistics service includes: Based on the pre-set multi-objective optimization function model, determine the optimization function values for each logistics service; For each logistics service, if the optimization function value of the logistics service is higher than the average of the optimization function values of all logistics services, the initial selection probability of the logistics service is increased, wherein the increase in the initial selection probability is determined based on the optimization function value of the logistics service and the average value; if the optimization function value of the logistics service is lower than the average of the optimization function values of all logistics services, the initial selection probability of the logistics service is decreased, wherein the decrease in the initial selection probability is determined based on the optimization function value of the logistics service and the average value. The sum of the final selection probabilities for all logistics services is 1; the optimization function value for the logistics service is determined based on a pre-defined multi-objective optimization function model.
[0079] Optionally, the preset multi-objective optimization function model is: Optimization function value = C × cost weight + Q × service quality weight + T × timeliness weight; Wherein, C is the cost parameter of the logistics service, which is determined based on the corresponding quotation information of the logistics service; Q is the service quality parameter of the logistics service, which is determined based on the historical service parameters of the logistics service; and T is the timeliness parameter of the logistics service, which is determined based on the historical logistics timeliness parameters of the logistics service.
[0080] Figure 3 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. At the hardware level, the electronic device includes a processor, and optionally also includes an internal bus, a network interface, and a memory. The memory may include RAM, such as high-speed random-access memory (RAM), or non-volatile memory, such as at least one disk storage device. Of course, the electronic device may also include other hardware required for other services.
[0081] The processor, network interface, and memory can be interconnected via an internal bus, which can be an ISA (Industry Standard Architecture) bus, a PCI (Peripheral Component Interconnect) bus, or an EISA (Extended Industry Standard Architecture) bus, etc. This bus can be divided into address bus, data bus, control bus, etc. For ease of representation, Figure 3 The symbol is represented by a single double-headed arrow, but this does not mean that there is only one bus or one type of bus.
[0082] Memory is used to store instructions for execution. Specifically, instructions for execution are computer programs that can be executed. Memory can include main memory and non-volatile memory, and it provides the processor with execution instructions and data.
[0083] In one possible implementation, the processor reads the corresponding execution instructions from non-volatile memory into main memory and then executes them. Alternatively, it may obtain the corresponding execution instructions from other devices to form a logistics business determination device at the logical level. The processor executes the execution instructions stored in the memory to implement the logistics business determination method provided in any embodiment of this application through the executed execution instructions.
[0084] The above is as stated in this application. Figure 1 The method executed by the logistics business determination device provided in the illustrated embodiment can be applied to a processor, or implemented by a processor. The processor may be an integrated circuit chip with signal processing capabilities. During implementation, each step of the above method can be completed by integrated logic circuits in the processor's hardware or by instructions in software form. The processor can be a general-purpose processor, including a Central Processing Unit (CPU), a Network Processor (NP), etc.; it can also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field-Programmable Gate Array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. It can implement or execute the methods, steps, and logic block diagrams disclosed in the embodiments of this application. The general-purpose processor can be a microprocessor or any conventional processor.
[0085] The steps of the method disclosed in the embodiments of this application can be directly manifested as being executed by a hardware decoding processor, or executed by a combination of hardware and software modules in the decoding processor. The software modules can reside in random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, registers, or other mature storage media in the art. This storage medium is located in memory, and the processor reads information from the memory and, in conjunction with its hardware, completes the steps of the above method.
[0086] This application also proposes a readable medium that stores execution instructions. When the stored execution instructions are executed by the processor of an electronic device, the electronic device can execute the logistics business determination method provided in any embodiment of this application, and specifically be used to execute the above-mentioned evaluation method.
[0087] The electronic devices described in the foregoing embodiments may be computers.
[0088] Those skilled in the art will understand that the embodiments of this application can be provided as methods or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or a combination of software and hardware.
[0089] The various embodiments in this application are described in a progressive manner. Similar or identical parts between embodiments can be referred to mutually. Each embodiment focuses on describing the differences from other embodiments. In particular, the device embodiments are basically similar to the method embodiments, so the description is relatively simple; relevant parts can be referred to the descriptions of the method embodiments.
[0090] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
[0091] The above description is merely an embodiment of this application and is not intended to limit the scope of this application. Various modifications and variations can be made to this application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of the claims of this application.
Claims
1. A method of determining a logistics service, characterized by, The method comprises: obtaining delivery request information; wherein the delivery request information comprises departure location information, destination location information, cargo attribute information and logistics service information; inputting the delivery request information into a preset pricing model to obtain pricing information corresponding to each logistics service; inputting the pricing information corresponding to each logistics service and the delivery request information into a real-time decision unit to obtain a target logistics service; wherein the target logistics service is one of the logistics services.
2. The method of claim 1, wherein, The cargo attribute information comprises the name, quantity, individual volume, individual weight and fragility of the cargo; and the logistics service information comprises the expected delivery time, budget range, delivery method and door-to-door service.
3. The method of claim 1, wherein, The inputting of the delivery request information into the preset pricing model to obtain the pricing information corresponding to each logistics service comprises: inputting the delivery request information into the preset pricing model; The preset pricing model determines the total volume of the cargo according to the cargo attribute information of the cargo; The preset pricing model determines the cargo transportation mileage according to the departure location information and the destination location information; The preset pricing model determines the pricing information corresponding to each logistics service according to the total volume of the cargo, the cargo transportation mileage and the logistics service information.
4. The method of claim 1, wherein, The real-time decision unit comprises a reinforcement learning model and a multi-objective optimization function model; the inputting of the pricing information corresponding to each logistics service and the delivery request information into the real-time decision unit to obtain the target logistics service comprises: inputting the pricing information corresponding to each logistics service and the delivery request information into the reinforcement learning model to obtain initial selection probabilities corresponding to each logistics service; adjusting the initial selection probabilities corresponding to each logistics service by using the multi-objective optimization function model to obtain final selection probabilities corresponding to each logistics service; determining the target logistics service according to the final selection probabilities corresponding to each logistics service.
5. The method of claim 4, wherein, The reinforcement learning model uses a deep Q network (DQN) as a basic model, the input layer dimension of the reinforcement learning model is 12, the reinforcement learning model has three hidden layers, the activation function of the reinforcement learning model is ReLU, and the output layer dimension of the reinforcement learning model is the number of candidate logistics services.
6. The method of claim 4, wherein, The adjusting of the initial selection probabilities corresponding to each logistics service by using the multi-objective optimization function model to obtain the final selection probabilities corresponding to each logistics service comprises: determining optimization function values of each logistics service according to a preset multi-objective optimization function model; For each logistics service corresponding to the initial selection probability, if the optimization function value of the logistics service is higher than the average value of the optimization function values of all logistics services, the initial selection probability corresponding to the logistics service is increased, wherein the increase range of the initial selection probability is determined according to the optimization function value of the logistics service and the average value; if the optimization function value of the logistics service is lower than the average value of the optimization function values of all logistics services, the initial selection probability corresponding to the logistics service is decreased, wherein the decrease range of the initial selection probability is determined according to the optimization function value of the logistics service and the average value. Wherein, the sum of the final selection probabilities corresponding to all logistics services is 1; the optimization function value of the logistics service is determined according to the preset multi-objective optimization function model.
7. The method of claim 6, wherein, The preset multi-objective optimization function model is: optimization function value = C × cost weight + Q × service quality weight + T × timeliness weight. Wherein, C is the cost parameter of the logistics service, the cost parameter is determined according to the quotation information corresponding to the logistics service; Q is the service quality parameter of the logistics service, the service quality parameter is determined according to the historical service parameter of the logistics service; T is the timeliness parameter of the logistics service, the timeliness parameter is determined according to the historical logistics timeliness parameter of the logistics service.
8. A logistics business determining apparatus characterized by comprising: The device comprises: The first unit is configured to obtain the delivery request information; wherein, the delivery request information comprises the departure location information, the terminal location information, the cargo attribute information and the logistics service information; The second unit is configured to input the delivery request information into the preset quotation model to obtain the quotation information corresponding to each logistics service; The third unit is configured to input the quotation information corresponding to each logistics service and the delivery request information into the real-time decision unit to obtain the target logistics service; wherein, the target logistics service is one of the logistics services.
9. A readable medium characterized by The readable medium comprises execution instructions, when the processor of the electronic device executes the execution instructions, the electronic device executes the method as claimed in any one of claims 1-7.
10. An electronic device, comprising: The electronic device comprises a processor and a memory storing execution instructions, when the processor executes the execution instructions stored in the memory, the processor executes the method as claimed in any one of claims 1-7.