An Optimization Method for Integrated Services in the Import and Export Supply Chain Based on Collaborative Filtering Algorithm

By distinguishing the causes of zero-interaction samples in the import and export supply chain, calculating the channel expansion coefficient and confidence decay weight, and optimizing the collaborative filtering algorithm, the problem of misjudgment of zero-interaction samples caused by common channel factors is solved, enabling more accurate demand forecasting and procurement decisions, and ensuring the stability of the supply chain.

CN121599420BActive Publication Date: 2026-04-03TUOPU SILU (NANJING) TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202610115738.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2026-01-28
Publication Date
2026-04-03
Estimated Expiration
2046-01-28

AI Technical Summary

Technical Problem

Existing collaborative filtering algorithms fail to effectively distinguish zero-interaction samples caused by common factors in the import and export supply chain, resulting in model prediction errors, affecting the accuracy of procurement decisions, and leading to inventory backlogs or shortages.

Method used

By determining the time granularity of the collected bucket interaction quantities, binary interaction states and item-level global zero interaction states are generated. The channel expansion coefficient and confidence decay weight are calculated, a negative correlation mapping is established, the weighted error is minimized using the implicit collaborative filtering loss function, and the net purchase quantity is calculated in combination with the safety stock to deduce the purchase order date.

Benefits of technology

It enables more accurate demand forecasting and procurement decisions, balances inventory levels with demand fulfillment, and ensures the stable operation of the supply chain.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121599420B_ABST
    Figure CN121599420B_ABST
Patent Text Reader

Abstract

This invention relates to the field of supply chain optimization technology and discloses a comprehensive service optimization method for import and export supply chains based on collaborative filtering algorithms, including the following steps: Step S101, generating binary interaction states and item-level global zero-interaction states; Step S102, generating channel expansion coefficients; Step S103, calculating training sample weights; Step S104, calculating interaction tendency scores; Step S105, summarizing to obtain the total demand forecast for the lead time; Step S106, retroactively calculating the procurement order date. This invention distinguishes the causes of zero-interaction samples, generates item-level global zero-interaction states, calculates channel expansion coefficients, and establishes a negative correlation mapping between these coefficients and confidence decay weights. This provides differentiated sample weights for model training, avoiding interference from false zero-interaction samples caused by channel common-cause censoring; thereby connecting demand forecasting and procurement execution, making demand forecasting more aligned with actual business operations, and ensuring the stable operation of the import and export supply chain.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of supply chain optimization technology, and more specifically, to a method for optimizing integrated import and export supply chain services based on collaborative filtering algorithms. Background Technology

[0002] Against the backdrop of rapid globalization, import and export supply chains involve multiple supply channels, multiple demand entities, and a massive volume of goods. The scientific nature of demand forecasting and procurement decisions directly impacts the stable and efficient operation of the supply chain. Currently, the industry widely employs collaborative filtering algorithms to optimize comprehensive supply chain services. These algorithms train models by analyzing interaction data between demand entities and goods, thereby predicting demand trends and guiding procurement planning. Significant common influencing factors exist within the supply channels of import and export supply chains. Goods within the same channel may fail to generate effective interaction with all demand entities at a specific timeframe due to channel congestion, customs clearance obstacles, or insufficient supply, resulting in zero-interaction samples caused by common channel censoring. This zero-interaction does not stem from a genuine lack of demand from the demand entities, but rather from objective limitations at the channel level.

[0003] Existing collaborative filtering algorithms fail to consider the channel characteristics of import and export supply chains and lack a mechanism to differentiate the causes of zero-interaction samples. They uniformly treat all zero-interaction samples as genuinely indicating no demand and include them equally in model training. This approach causes the model to mistakenly identify spurious zero-interaction samples with missing channel common factors as genuine signals of no demand, leading to biases in the demand patterns learned by the model and inaccurate predictions of interaction tendency and lead time total demand. Procurement decisions based on these inaccurate predictions are prone to inventory backlogs or shortages, failing to adapt to actual business needs and ultimately impacting the optimization of integrated services for the import and export supply chain. Summary of the Invention

[0004] This invention provides a method for optimizing integrated services in the import and export supply chain based on collaborative filtering algorithms, thereby solving the technical problems mentioned in the background.

[0005] This invention provides a method for optimizing integrated services in the import and export supply chain based on collaborative filtering algorithms, comprising the following steps:

[0006] Step S101: Determine the time-granularity of the collected bucket interaction quantities, and generate binary interaction states and item-level global zero interaction states;

[0007] Step S102: Calculate the time series correlation of the global zero-interaction state of the item level within the channel as a synchronization index, calculate the cross-channel baseline correlation as a noise index, and take the ratio of the synchronization index to the noise index to generate the channel expansion coefficient.

[0008] Step S103: Establish a negative correlation mapping between the channel expansion coefficient and the confidence decay weight, assign confidence decay weights to negative samples without interaction, and assign preset fixed values ​​to positive samples with interaction to obtain the training sample weights.

[0009] Step S104: Using the binary interaction state as the fitting target, substitute the training sample weights into the implicit collaborative filtering loss function, and minimize the weighted error to obtain the interaction tendency score.

[0010] Step S105: Convert the interaction tendency score into a probability, combine it with the average consumption per transaction after removing zero interaction periods to calculate the expected demand, and summarize to obtain the total demand forecast for the lead time period.

[0011] Step S106: Extract the safety stock corresponding to the lead time and demand fluctuation of the channel from the historical arrival data, and add the safety stock to the total demand forecast of the lead time and deduct the effective inventory equity to obtain the net purchase quantity. The purchase order date is calculated by working backward from the target arrival date and the channel lead time.

[0012] The beneficial effects of this invention are as follows: By distinguishing the causes of zero-interaction samples, this invention generates an item-level global zero-interaction state and calculates the channel expansion coefficient, establishing a negative correlation mapping between it and the confidence decay weight. This provides differentiated sample weights for model training, avoiding interference from spurious zero-interaction samples caused by channel common-cause censoring. Combining the interaction tendency score obtained from the weighted loss function and alternating least squares method, it is converted into an interaction probability. This probability is then used to calculate expected demand by excluding the average consumption during zero-interaction periods. Finally, it is overlaid with safety stock and effective inventory equity based on historical data to calculate the net purchase volume, thus retroactively determining the appropriate purchase date. The entire process connects demand forecasting and procurement execution, making demand forecasting more aligned with actual business patterns, providing clear quantitative basis for procurement decisions, balancing inventory levels and demand fulfillment, and ensuring the stable operation of the import / export supply chain. Attached Figure Description

[0013] Figure 1 This is a flowchart of the import and export supply chain integrated service optimization method based on collaborative filtering algorithm of the present invention. Detailed Implementation

[0014] The subject matter described herein will now be discussed with reference to exemplary embodiments. It should be understood that these embodiments are discussed only to enable those skilled in the art to better understand and implement the subject matter described herein, and changes may be made to the function and arrangement of the elements discussed without departing from the scope of this specification. Various processes or components may be omitted, substituted, or added as needed in the examples. Furthermore, features described in some examples may be combined in other examples.

[0015] It should be noted that, unless otherwise defined, the technical or scientific terms used in one or more embodiments of the present invention should have the ordinary meaning understood by one of ordinary skill in the art to which this invention pertains. The terms "first," "second," and similar terms used in one or more embodiments of the present invention do not indicate any order, quantity, or importance, but are merely used to distinguish different components. Terms such as "comprising" or "including" indicate that the element or object preceding the term encompasses the elements or objects listed following the term and their equivalents, without excluding other elements or objects. Terms such as "connected" or "linked" are not limited to physical or mechanical connections, but can include electrical connections, whether direct or indirect. Terms such as "upper," "lower," "left," and "right" are used only to indicate relative positional relationships; when the absolute position of the described object changes, the relative positional relationship may also change accordingly.

[0016] like Figure 1 As shown, the method for optimizing integrated services in the import and export supply chain based on collaborative filtering algorithm includes the following steps:

[0017] Step S101: Determine the time-granularity of the collected bucket interaction quantities, and generate binary interaction states and item-level global zero interaction states;

[0018] Step S102: Calculate the time series correlation of the global zero-interaction state of the item level within the channel as a synchronization index, calculate the cross-channel baseline correlation as a noise index, and take the ratio of the synchronization index to the noise index to generate the channel expansion coefficient.

[0019] Step S103: Establish a negative correlation mapping between the channel expansion coefficient and the confidence decay weight, assign confidence decay weights to negative samples without interaction, and assign preset fixed values ​​to positive samples with interaction to obtain the training sample weights.

[0020] Step S104: Using the binary interaction state as the fitting target, substitute the training sample weights into the implicit collaborative filtering loss function, and minimize the weighted error to obtain the interaction tendency score.

[0021] Step S105: Convert the interaction tendency score into a probability, combine it with the average consumption per transaction after removing zero interaction periods to calculate the expected demand, and summarize to obtain the total demand forecast for the lead time period.

[0022] Step S106: Extract the safety stock corresponding to the lead time and demand fluctuation of the channel from the historical arrival data, and add the safety stock to the total demand forecast of the lead time and deduct the effective inventory equity to obtain the net purchase quantity. The purchase order date is calculated by working backward from the target arrival date and the channel lead time.

[0023] In one embodiment of the present invention, determining the time-granularity collection of bucketed interaction quantities and generating binary interaction states and item-level global zero interaction states includes:

[0024] Set time granularity Number of window buckets With start time and the event timestamp Mapped to time bucket number The mapping formula is:

[0025] ,in, This indicates the floor function;

[0026] For any demand entity With any item In the time bucket number Internal calculation of bucket interaction volume The calculation formula is:

[0027] ,in, Numbering the time bucket Internal and related demand entities With items A collection of business events The number of events is measured in units consistent with those of items.

[0028] For demand entities ,thing and time bucket number Generate binary interactive state The calculation formula is:

[0029] ,in, For indicator functions, if the bucket interaction quantity A value greater than zero indicates a binary interactive state. The value is 1 if it is not 1, and 0 otherwise.

[0030] For items and time bucket number Generate item-level global zero-interaction state The calculation formula is:

[0031] ,in, Let the set of all demand entities be... Inner binary interactive state If the summation result is zero, then the item-level global zero-interaction state is achieved. The value is 1, otherwise it is 0.

[0032] It should be noted that the preferred time granularity values ​​are 1 day, 3 days, and 7 days, set according to the frequency of business events in the import / export supply chain. For example, 1 day is suitable for high-frequency interaction items, 3 days for medium-frequency interaction items, and 7 days for low-frequency interaction items, ensuring that the time bucket can effectively capture interaction patterns without generating excessive redundant data. The preferred window bucket number values ​​are 30 buckets, 60 buckets, and 90 buckets, set according to the business cycle of the import / export supply chain. For example, 30 buckets for short-term analysis, 60 buckets for medium-term analysis, and 90 buckets for long-term analysis. The preferred start time is the first day of the most recent full calendar month for business data records. The event timestamp is the specific time record of the business event, which can be obtained through Enterprise Resource Planning (ERP), Warehouse Management System (WMS), Transportation Management System (TMS), etc. The demand entity is the subject that generates the demand for goods, reflecting the source of the demand. It can be extracted from the customer management module and maintenance site management module of the ERP system, including the combined information of the destination country, customer, and maintenance site, and associated with the business event through a unique identifier field. Items include basic attributes such as item name and specifications. The associated business event set is a collection of business operations related to specific demand entities and items, reflecting the interaction between them. It can be filtered based on the unique identifier of the demand entity and the unique code of the item, extracting pre-defined event types such as outbound, requisition, and order demand triggering. The event quantity is a quantitative indicator for each event in the associated business event set; for example, the outbound quantity field records the actual number of items outbound, and the requisition frequency field records the requisition frequency. The bucketed interaction volume is the cumulative value of the associated business events between the demand entity and the item within a specific time bucket, reflecting the scale of interaction between them within that time bucket. The binary interaction status is an indicator representing whether there is interaction between the demand entity and the item within a specific time bucket, reflecting the presence or absence of interaction. The item-level global zero interaction status is an indicator representing that there is no interaction between all demand entities and the item within a specific time bucket, reflecting the overall interaction status of the item within that time bucket.

[0033] It should be noted that the specific method for calculating the time bucket number is as follows: First, determine the start time, obtain the event timestamp of the business event, calculate the difference between the two, divide the difference by the time granularity, round down the result, and then add 1 to the rounded result to obtain the time bucket number k, where k must satisfy 1≤k≤K; for example, if the start time is January 1, 2024, the time granularity is 1 day, and the event timestamp is January 3, 2024, the difference is 2 days. Dividing 2 by 1 gives 2, rounding down gives 2, and adding 1 gives the time bucket number 3, corresponding to the 3rd time bucket. For a specified demand entity, item, and time bucket, first filter out the set of business events related to the three, then extract the event quantity corresponding to each event in the set, and finally sum all the event quantities. The summed result is the bucket interaction quantity; for example, if the set of related business events of demand entity A and item B in time bucket 5 contains 3 outbound events with event quantities of 5, 3, and 2 respectively, then the bucket interaction quantity is 5+3+2=10.

[0034] It should be noted that the indicator function returns a corresponding value based on the truth or falsity of the condition within the parentheses. When the bucket interaction volume is greater than 0, the condition is true, and the binary interaction state is 1; when the bucket interaction volume is less than or equal to 0, the condition is false, and the binary interaction state is 0. The binary interaction states of each demand entity and item within the time bucket are collected from the entire set of demand entities. All binary interaction states are summed. If the sum is 0, it means that no demand entity interacts with the item, and the item-level global zero interaction state is 1; if the sum is greater than 0, it means that at least one demand entity interacts with the item, and the value is 0. For example, if item C is in time bucket 4, and the binary interaction states of all 5 demand entities are 0, the sum is 0, and the item-level global zero interaction state is 1; if the binary interaction state of one demand entity is 1, the sum is 1, and the value is 0.

[0035] It should be noted that the included business event types are operational events that directly reflect the demand for goods, specifically outbound events, requisition events, order demand trigger events, and stockout trigger events. Outbound events refer to the operation of sending goods out of the warehouse; requisition events refer to the operation of a demanding entity taking goods from inventory; order demand trigger events refer to the record of goods demand triggered after a customer order is generated; and stockout trigger events refer to the demand events recorded by the system when goods are in short supply. For example, when the goods are repair parts, the requisition events of repair stations and the order demand trigger events of customers both belong to the set of related business events. The statistical caliber of the event quantity is a quantitative indicator consistent with the unit of measurement of the goods, without distinguishing event weights, and only counting the actual occurrence of the preset business event types; the event quantity of outbound events is the actual number of items outbound, the requisition event is the actual number of times or items are requisitioned, the order demand trigger event is the number of items required in the order, and the stockout trigger event is the number of items that are out of stock; for example, if the unit of measurement of goods is a piece, an outbound event with 10 pieces outbound has an event quantity of 10; and a requisition event with 3 requisitions of 1 piece each time has an event quantity of 3.

[0036] It should be noted that by setting the time granularity, the number of window buckets, and the start time, continuous business time is divided into quantifiable time buckets. Event timestamps, demand entities, items, and other relevant parameters are collected to calculate the bucket-specific interaction volume. Then, based on the bucket-specific interaction volume, binary interaction states and item-level global zero-interaction states are generated. This transforms scattered business events into structured time-series data, clearly defining the time attribution and presence / absence of interactions, making zero-interaction phenomena quantifiable and analyzable. This avoids analytical biases caused by different time dimension divisions, accurately captures the interaction time sequence characteristics of demand entities and items, provides reliable foundational data for subsequent channel expansion coefficient calculations, ensures the accuracy and effectiveness of subsequent model training data, and helps distinguish between zero interactions caused by no demand and zero interactions caused by unavailable goods.

[0037] In one embodiment of the present invention, the time-series correlation of the global zero-interaction state of the item level within a channel is calculated as a synchronization index, the cross-channel baseline correlation is calculated as a noise index, and the ratio of the synchronization index to the noise index is used to generate a channel expansion coefficient, including:

[0038] Receive item-level global zero-interaction state and item-to-channel mapping Set the total number of time buckets For each item Construct a time series vector containing data from all time bucket locations. The vector representation is:

[0039] ;

[0040] For any channel Construct a set of distinct pairs of items belonging to the same channel. The set is defined as:

[0041] ;

[0042] Calculate the set of item pairs Each group of items Strength of linear correlation between time series vectors The calculation formula is:

[0043] ,in, For items The mean, calculated using the formula is: ;

[0044] Calculate the linear correlation strength The arithmetic mean as a synchronization indicator The calculation formula is:

[0045] ,in, The number of elements in the set;

[0046] Construct a set of cross-channel item pairs belonging to different channels. The set is defined as:

[0047] ;

[0048] Calculate the set of cross-channel item pairs Each group of items Strength of linear correlation between time series vectors And calculate the linear correlation strength. The arithmetic mean is used as a noise index The calculation formula is:

[0049] ;

[0050] Synchronization indicators Divide by noise index With numerical stability term The sum of these values ​​yields the channel expansion coefficient. The calculation formula is:

[0051] ,in, It is a constant greater than zero.

[0052] It should be noted that the item-to-channel mapping establishes the association between items and their corresponding main channels, reflecting the item's supply path affiliation. The time series vector is a set of global zero-interaction state data at the item level, arranged in time bucket order. A channel is a business processing object composed of fields related to stable import supply paths, reflecting the item's supply path attributes. The set of item pairs within a channel is a set of pairs of items belonging to the same channel and not repeating each other, reflecting the pairing relationship of items within the same channel. Linear correlation strength is a quantitative indicator measuring the degree of synchronous change between two sets of time series vectors, reflecting the tightness of the association between item pairs in zero-interaction states. The synchronization index is the arithmetic mean of the linear correlation strengths of all item pairs within a channel, reflecting the overall synchronization level of zero-interaction states of items within the same channel. The cross-channel item pair set is a set of pairs of items belonging to different channels, reflecting the pairing relationship of items between different channels. The noise index is the arithmetic mean of the linear correlation strengths of all item pairs across channels, reflecting the baseline association level of zero-interaction states when there is no channel common-cause censoring. The numerical stability term is a constant greater than zero, used to avoid zero denominators in calculations. The channel expansion coefficient is the ratio of the sum of the synchronization index and the noise index plus the numerical stability term, reflecting the expansion effect of the zero-interaction synchronization degree within the channel relative to the baseline.

[0053] It should be noted that the binding of goods and channels is based on the long-term main import supply routes of the goods. Channels that have accounted for more than 70% of the goods' import volume in the past 12 months are prioritized as the main channels. If multiple channels have import volumes that do not exceed 70%, the channel with the highest import frequency is selected as the main channel. If both import volume and frequency are the same, the main channel can be manually designated. For example, if goods X have received 80% of their imports from channel A in the past 12 months, then they are bound to channel A; if goods Y have received 40% of their imports from channel B and 35% from channel C in the past 12 months, and channel B has a higher import frequency than channel C, then they are bound to channel B. Furthermore, if the absolute value of the linear correlation strength is greater than 0.95, such values ​​are considered outliers and can be replaced with the median of all non-outlier linear correlation strengths within that channel.

[0054] It should be noted that the preferred value range for the numerical stability term is 0.001 to 0.01. When the noise index is small, a value closer to 0.001 can reduce interference with the channel expansion coefficient; when the noise index fluctuates significantly, a value closer to 0.01 can enhance computational stability. In the construction of time series vectors, missing data refers to the absence of item-level global zero-interaction state records for a certain item within certain time buckets. The completion rule adopts a forward-filling method, that is, using the item-level global zero-interaction state value of the previous valid time bucket to fill the missing position; if the missing position is in the first time bucket, then the item-level global zero-interaction state value of the next valid time bucket is used to fill it. Furthermore, the deduplication criterion for constructing the item pair set is that the item pairs are unordered and unique, that is, item pairs (i,j) and (j,i) are considered the same item pair, and only one is kept. The efficiency optimization method uses a hash table for deduplication. When traversing items, a hash value of the item pair is generated, and a set of generated hash values ​​is stored. If the hash value of a newly generated item pair already exists, it is skipped; otherwise, it is added to the set and the item pair is recorded. At the same time, for cases where there are too many items in the channel, a batch processing method is adopted, processing 100 items in each batch to reduce memory usage. For example, when processing a channel containing 200 items, it is processed in two batches of 100 items each, and item pairs are constructed and deduplicated in each batch. Finally, the results are merged.

[0055] It should be noted that, based on the item-to-channel mapping and the item-level global zero-interaction state, a time-series vector of the item is constructed. By calculating the linear correlation strength of item pairs within the same channel and across channels, a synchronization index reflecting the synchronization level within the channel and a noise index reflecting the baseline level are obtained. Then, the channel expansion coefficient is generated by combining the ratio of the two with a numerical stability term, thereby quantifying the zero-interaction synchronization expansion effect caused by common factors in the channel. This invention transforms the structural impact at the channel level into a quantifiable index through statistical correlation analysis, providing a basis for distinguishing between zero interaction caused by genuine lack of demand and unavailability of goods. It does not rely on external congestion data or manual rules; it can identify the censoring of common factors in the channel solely through internal business data, making the channel expansion coefficient objective and interpretable. This provides reliable input for subsequent sample weight generation and model training, helping the model reduce misjudgments of false zero-interaction samples.

[0056] In one embodiment of the present invention, a negative correlation mapping between the channel expansion coefficient and the confidence decay weight is established. A confidence decay weight is assigned to non-interactive negative samples, and a preset fixed value is assigned to interactive positive samples to obtain the training sample weights, including:

[0057] Receive channel expansion coefficient Item to channel mapping Binary interactive state and the total number of time buckets And generate binary interactive states within the training window. The calculation formula is:

[0058] ,in, As an indicator function, if the total number of time buckets Binary interactive state within range If the summation result is greater than zero, then the binary interactive state within the training window... The value is 1 if it is not 1, and 0 otherwise.

[0059] Calculate the zero-interaction confidence decay weight based on the negative correlation mapping The calculation formula is:

[0060] ,in, The value ranges from zero to one. The coefficient of channel expansion;

[0061] For each demand entity and item pair, generate training sample weights. The calculation formula is:

[0062] Among them, if the binary interaction state is within the training window If the value is 1, then the training sample weights Fixed to one; if the binary interactive state within the training window If the value is zero, then the training sample weights Take the zero-interaction confidence decay weight of the corresponding item's main channel. .

[0063] It should be noted that the binary interaction state within the training window is an indicator representing whether there is interaction between the demand entity and the item within the training window, reflecting whether there is interaction between them throughout the entire training cycle. The zero-interaction confidence decay weight is a weight value negatively correlated with the channel expansion coefficient, reflecting the credibility of samples without interaction. The preset fixed value is a fixed weight value set for positive samples with interaction, reflecting the standard for setting the contribution of positive samples to training; a value of 1 is preferred. For example, positive samples with interaction represent real demand interactions with high credibility, and a fixed value of 1 can stably highlight their positive contribution to model training, avoiding weight fluctuations that affect training results. Training sample weights are values ​​used to adjust the degree of influence of different samples on model training. Non-interactive negative samples are samples where the demand entity and the item have not interacted within the training window. Interactive positive samples are samples where the demand entity and the item have interacted within the training window.

[0064] It should be noted that the binary interaction states of the demand entity and the item across all time buckets are statistically analyzed. The binary interaction states of all time buckets are summed. If the sum is greater than zero, it means that at least one time bucket in the training window has an interaction, and the binary interaction state in the training window is set to 1. If the sum is equal to zero, it means that there is no interaction in any time bucket, and the value is 0. For example, if there are a total of 5 time buckets, and the binary interaction states of a demand entity and the item in the 5 time buckets are 0, 1, 0, 1, and 0 respectively, the sum is 2, which is greater than zero, and the binary interaction state in the training window is 1. If the binary interaction states of all 5 time buckets are 0, the sum is 0, and the value is 0. In addition, iterate through all demand entity and item pairs, first determine their binary interaction state within the training window; if the state is 1, it is determined to be a positive sample with interaction, and the training sample weight is assigned a preset fixed value; if the state is 0, it is determined to be a negative sample without interaction, and find the zero-interaction confidence decay weight of the corresponding channel according to the item-to-channel mapping, and assign this weight to the training sample weight; for example, if the binary interaction state of a sample within the training window is 1, the training sample weight is 1; if the state of another sample is 0, the zero-interaction confidence decay weight of the corresponding channel is 0.3, and the training sample weight is 0.3.

[0065] It should be noted that the time range of the training window is equal to the total number of time buckets multiplied by the time granularity. The total number of time buckets is the number of time buckets included in the training window. For example, if the total number of time buckets is 30 and the time granularity is 1 day, the time range of the training window is 30 days; if the total number of time buckets is 60 and the time granularity is 3 days, the time range of the training window is 180 days. The start and end times of the training window are consistent with the start and end times of the time buckets, from the start time of the first time bucket to the end time of the last time bucket. When an item has multiple associated channels, the zero-interaction confidence decay weight is matched based on the item's main channel. The main channel is determined by the channel whose import volume accounts for more than 70% in the past 12 months. If there is no channel with a proportion exceeding 70%, the channel with the highest import frequency is taken as the main channel. If the import volume proportion and frequency are the same, the channel priority preset by the business system is used for matching. For example, if an item is associated with channel A and channel B, and the import volume from channel A accounts for 75% in the past 12 months, then channel A is the main channel, and the zero-interaction confidence decay weight of channel A is matched.

[0066] It should be noted that this invention distinguishes between the weight assignments of positive samples with interaction and negative samples without interaction, allowing the model training to place greater emphasis on the contribution of real interaction samples and reduce the interference of unreliable zero-interaction samples. This ensures that the weights of the training samples are highly aligned with the interaction credibility in the business scenario, preventing zero-interaction caused by a lack of demand from being treated the same as zero-interaction caused by the unavailability of goods. This provides more reasonable training input for subsequent collaborative filtering models, thereby helping the model to more accurately learn the interaction patterns between demand entities and items, and improving the relevance and reliability of model training.

[0067] In one embodiment of the present invention, using the binary interaction state as the fitting target, the training sample weights are substituted into the implicit collaborative filtering loss function, and the interaction tendency score is obtained by minimizing the weighted error, including:

[0068] Define the latent vector of the demand entity With item latent vector And construct a weighted squared loss The calculation formula is:

[0069] ,in, To train the binary interactive state within the window, For training sample weights, The regularization coefficient is . It is the vector norm;

[0070] Alternating least squares is used for closed-form updates, with a fixed item latent vector. Update the latent vector of the entity in time The updated formula is:

[0071] ;

[0072] In the potential vector of fixed demand entity Update item potential vectors in real time The updated formula is:

[0073] ;

[0074] in, It is the identity matrix. This represents the matrix inversion operation;

[0075] Calculate interaction tendency score The calculation formula is:

[0076] ,in, This represents the inner product of the latent vector of the demand entity and the latent vector of the item.

[0077] It should be noted that the latent vector of a demand entity is a multi-dimensional vector representing the potential demand preferences of the demand entity, reflecting the potential preference characteristics of the demand entity for various items. The latent vector of an item is a multi-dimensional vector representing the potential attributes and demand responsiveness of an item, reflecting the potential characteristics of the item's suitability for different demand entities. The weighted squared loss is a quantitative indicator that measures the deviation between the model's predicted values ​​and the true values, reflecting the quality of the model's fit. The weighted error term is an error calculation term that incorporates the weights of the training samples, reflecting the degree of contribution of samples with different confidence levels to the model error. The regularization term is a constraint term that limits the complexity of the latent vector, reflecting the strength of the suppression of model overfitting. The regularization coefficient is a parameter that adjusts the strength of the regularization term, reflecting the standard for controlling model complexity; it is preferably a constant between 0.001 and 0.01, which can effectively suppress the dimensionality expansion of the latent vector without weakening the model's ability to learn interaction patterns. The identity matrix is ​​a square matrix with 1s on the main diagonal and 0s on the rest. The interaction propensity score is the strength of the predicted tendency for demand entities and items to interact in the future, reflecting the likelihood of future interaction between the two.

[0078] It should be noted that the weighted squared loss is composed of the direct sum of the weighted error term and the regularization term, which together form the optimization objective of the model. The weighted error term measures the deviation between the model's prediction and the actual interaction state, while the regularization term constrains the size of the latent vectors to avoid excessive model complexity. Their synergistic effect ensures the model both closely matches the data and possesses generalization ability. For example, during model optimization, it is necessary to reduce the weighted error term to better match the interaction data while controlling the regularization term to prevent overfitting. The calculation process for the weighted error term involves first calculating the difference between the binary interaction state within the training window of each demand entity and item pair and the inner product of the corresponding two latent vectors. This difference is then squared and multiplied by the training sample weight of that sample. Finally, the calculation results for all demand entities and item pairs are summed to obtain the weighted error term. The regularization term is calculated as follows: first, the norm squares of all latent vectors of demand entities are calculated separately, and then summed to obtain the norm square sum of demand entity vectors; then, the norm squares of all latent vectors of items are calculated, and summed to obtain the norm square sum of item vectors; finally, the two sums are added together and multiplied by the regularization coefficient to obtain the regularization term. Furthermore, after the latent vectors of demand entities and items are updated to convergence using the alternating least squares method, the updated latent vectors of demand entities and items are subjected to an inner product operation; the result of this inner product is the interaction tendency score, which will not be elaborated upon here.

[0079] It should be noted that the regularization coefficient ranges from 0.001 to 0.01 and can be determined through cross-validation. Multiple sets of different coefficient values ​​are selected to train the model on the training set, and the model's prediction accuracy is evaluated on the validation set. The coefficient value that maximizes the validation set accuracy without significant overfitting is chosen. For example, selecting coefficients of 0.001, 0.005, and 0.01, the 0.005 coefficient corresponds to the highest validation set accuracy, and the difference between the training and validation set accuracies is small; therefore, 0.005 is selected. The dimension of the latent vector ranges from 10 to 50. When the data scale is large, a dimension of 30 to 50 can be selected to capture more latent features; when the data scale is small, a dimension of 10 to 20 is selected to avoid overfitting. For example, when the sample size is in the 100,000 range, a 30-dimensional vector is selected; when the sample size is in the 10,000 range, a 15-dimensional vector is selected. The iterative stopping conditions for alternating least squares method are as follows: There are two stopping conditions, either one is sufficient: First, the number of iterations reaches a preset maximum value, ranging from 100 to 200; second, the difference in weighted squared loss between two consecutive iterations is less than a preset threshold, for example, a threshold of 0.01. The dimension of the identity matrix is ​​consistent with the dimension of the latent vector. If the latent vector is d-dimensional, then the identity matrix is ​​a d-order square matrix, which will not be elaborated here.

[0080] It should be noted that, using the binary interaction state within the training window as the fitting target, the training sample weights are incorporated into the weighted squared loss of implicit collaborative filtering. The latent vectors of demand entities and items are updated in a closed loop using alternating least squares, and the interaction tendency score is finally obtained through the vector inner product. This invention fully utilizes the differentiated sample weights obtained in the early stages, allowing the model to focus on high-confidence samples during training, while controlling model complexity through regularization terms. This makes the latent features learned by the model more closely resemble real interaction patterns, reduces interference from unreliable zero-interaction samples, and improves the rationality of interaction tendency prediction. Furthermore, the closed loop update using alternating least squares ensures the feasibility and efficiency of model training.

[0081] In one embodiment of the present invention, the interaction tendency score is converted into a probability, and the expected demand is calculated by combining it with the average consumption per transaction after removing zero-interaction periods. The total demand forecast for the lead time is then obtained by summarizing the results, including:

[0082] Interaction tendency score Mapped to interaction probability The calculation formula is:

[0083] ,in, It is an exponential function, with interaction probability. The value ranges from zero to one;

[0084] Calculate the average consumption per session after removing periods of zero interaction. The calculation formula is:

[0085] ,in, For bucketed interaction volume, It is a binary interactive state. For the number of window buckets, For numerically stable terms that are greater than zero, For cumulative operations;

[0086] Calculate the expected demand for entities and items within the forecast window. And summarize to obtain the total demand forecast for the lead time period. The calculation formula is:

[0087] ;

[0088] ;

[0089] in, This is the set of all demand entities.

[0090] It should be noted that the interaction probability is a probability value converted from the interaction tendency score, reflecting the likelihood of a demand entity interacting with an item in the future. Average consumption per interaction is the quantity of item consumed per interaction event after excluding periods of zero interaction, reflecting the average usage level per interaction. Expected demand is the anticipated consumption quantity of an individual demand entity and item within the forecast window, reflecting the expected demand scale of that demand entity for the item. Total lead time demand forecast is the sum of the expected demand for the item from all demand entities, reflecting the overall expected total demand for the item within the forecast window.

[0091] It should be noted that historical data from the past 6 months is selected, and the predicted interaction probability is compared with the actual interaction occurrence rate. If the relative deviation between the predicted result and the actual occurrence rate is less than 5%, the scenario is deemed suitable. If the deviation is greater than or equal to 5%, the conversion logic of the interaction tendency score is readjusted. For example, if the predicted probability of a certain type of interaction is 0.8 and the actual occurrence rate is 0.77, the relative deviation is 3.75%, which is less than 5%, thus indicating suitability. The time range of the prediction window is equal to the number of window buckets multiplied by the time granularity. This is automatically confirmed by associating the time granularity parameter preset by the business system with the number of window buckets parameter. For example, if the number of window buckets is 30 and the time granularity is 1 day, the prediction window time range is 30 × 1 = 30 days; if the number of window buckets is 20 and the time granularity is 3 days, the prediction window time range is 20 × 3 = 60 days.

[0092] It's important to note that the interaction tendency score obtained earlier is converted into an intuitive interaction probability. Simultaneously, the average consumption per transaction is calculated and removed from periods of zero interaction to prevent zero-interaction data from diluting the actual consumption level. This, combined with the number of window buckets corresponding to the prediction window, quantifies the expected demand of individual demand entities. Finally, the expected demands of all demand entities are aggregated to obtain the total lead time demand forecast for the item within the prediction window. This process transforms relative interaction tendency into specific demand quantities, bridging model prediction and procurement execution. The average consumption per transaction more closely reflects real-world interaction scenarios, the interaction probability makes demand forecasts more consistent with actual occurrence patterns, and the aggregated total demand forecast data has clear business implications, providing a direct quantitative basis for procurement planning and ensuring reliable data support for procurement volume planning.

[0093] In one embodiment of the present invention, historical arrival data is used to extract the lead time and safety stock corresponding to demand fluctuations. The total demand forecast for the lead time is then overlaid with the safety stock, and the effective inventory equity is deducted to obtain the net purchase quantity. The purchase order date is then calculated by working backwards from the target arrival date and the lead time.

[0094] For each channel Collect historical total delivery time samples Calculate the estimated lead time for delivery via the channel. The calculation formula is:

[0095] ,in, This indicates taking the sample median;

[0096] For any item With each time bucket Calculate historical bucket requirements and variance The calculation formula is:

[0097] ;

[0098] ;

[0099] in, For the set of all demand entities, For bucketed interaction volume, For the number of window buckets, This represents the historical average demand for buckets.

[0100] Calculate safety stock The calculation formula is:

[0101] ,in, For time granularity, Mapping items to channels, This represents the square root operation;

[0102] Calculate effective inventory equity and net purchases The calculation formula is:

[0103] ;

[0104] ;

[0105] in, For existing available inventory, This refers to the quantity of orders that have been placed but not yet arrived. For the committed quantity to be shipped, For the lead time aggregate demand forecast, This indicates taking the larger value between zero and the result of the AND operation;

[0106] Based on the target delivery date Calculate the procurement order date The calculation formula is:

[0107] ,in, Estimate the lead time for goods to arrive in the main channel.

[0108] It should be noted that the historical total arrival time sample is a collection of records of the time from shipment to warehousing throughout the channel's history. The estimated arrival lead time is based on the median of the historical total arrival time sample. Historical bucket demand is the sum of bucket interactions between all demand entities and items within a single time bucket. Safety stock is the amount of inventory reserved to cope with demand fluctuations and arrival delays, reflecting the supply chain's buffering capacity against uncertainty. Current available inventory is the quantity of items in the current warehouse that can be directly used for distribution. It can be collected through the inventory management module of the Warehouse Management System (WMS), which reads the actual inventory quantity of items in real time and deducts unavailable portions. Orders in transit that have not yet arrived are the quantity of items for which purchase orders have been placed but have not yet been received, reflecting the inventory replenishment resources that are about to arrive. It can be collected through the procurement management module of the Enterprise Resource Planning (ERP) system, which filters the details of purchase orders that have been placed but not yet received and summarizes the quantities. Committed quantities are the quantity of items for which orders have been confirmed but have not yet been shipped, reflecting the inventory resources that have been occupied. It can be collected through the order details module of the order management system, which summarizes the quantity of items in confirmed but unshipped orders. Effective inventory equity is the result of calculating existing available inventory, the quantity of orders in transit but not yet delivered, and the quantity of committed shipments, reflecting the total inventory that can actually be used to cover future demand. Net purchases are the quantity of items that need to be purchased to meet future demand, reflecting the specific scale of procurement execution. Target arrival date is the date on which planned goods are completed and ready for warehousing, reflecting the time target requirement for procurement; preferred values ​​are 15 days before the start of the peak sales season, 30 days before the start of the production plan, or the replenishment completion date corresponding to the inventory warning line. Purchase order date is the planned date for initiating the procurement process, reflecting the time node for procurement execution.

[0109] It should be noted that the current available inventory is the remaining quantity after deducting damaged inventory and reserved inventory from the actual warehouse inventory. Damaged inventory refers to the quantity of items that are unusable due to cosmetic damage, functional failure, or other reasons. Reserved inventory refers to the quantity of items that have been designated for specific orders, repairs, or other purposes. For example, if the actual warehouse inventory is 200, damaged inventory is 10, and reserved inventory is 30, the current available inventory is 200 - 10 - 30 = 160. The target delivery date is set in conjunction with business milestones such as peak sales seasons, production plans, and inventory turnover cycles. The target delivery date is set 15 days before the peak sales season to ensure sufficient inventory during the peak season; the target delivery date is set 30 days before the start of the production plan to ensure smooth production; and the target delivery date is set at 50% of the inventory turnover cycle to maintain a reasonable inventory level.

[0110] It should be noted that this invention fully considers the historical patterns of delivery time and the uncertainty of demand fluctuations, taking into account both the current inventory status and future demand; it ensures that the setting of safety stock is in line with actual demand fluctuations and delivery delays, that the calculation of effective inventory equity reflects the true available inventory, that the calculation of net purchase volume avoids inventory backlog or shortages, and that the backward calculation of the purchase order date ensures timely delivery of goods, providing clear and feasible quantitative basis and time nodes for procurement execution, and ensuring the stable operation of the supply chain.

[0111] It should be noted that the interval and threshold sizes are set for ease of comparison. The size of the threshold depends on the amount of sample data and the base number set by those skilled in the art for each set of sample data, as long as it does not affect the proportional relationship between the parameter and the quantized value. Furthermore, the above formulas are all dimensionless calculations, and the formulas are derived from software simulations using a large amount of collected data to obtain the most recent real-world results. The preset parameters in the formulas are set by those skilled in the art according to the actual situation.

[0112] The embodiments of this example have been described above. However, this example is not limited to the specific implementation methods described above. The specific implementation methods described above are merely illustrative and not restrictive. Those skilled in the art can make many other forms based on the guidance of this example, and all of them are within the protection scope of this example.

Claims

1. A method for optimizing integrated services in the import and export supply chain based on collaborative filtering algorithm, characterized in that, Includes the following steps: Step S101: Determine the time-granularity of the collected bucket interaction quantities, and generate binary interaction states and item-level global zero interaction states; Step S102: Calculate the time series correlation of the global zero-interaction state of the item level within the channel as a synchronization index, calculate the cross-channel baseline correlation as a noise index, and take the ratio of the synchronization index to the noise index to generate the channel expansion coefficient. Step S102 specifically includes: receiving the item-level global zero-interaction state and the item-to-channel mapping, setting the total number of time buckets, and constructing a time series vector containing all time bucket location data for each item; For any channel, construct a set of distinct item pairs belonging to the same channel, calculate the linear correlation strength between the time series vectors of each item pair within the set, and calculate the arithmetic mean of the linear correlation strength as a synchronization index. Construct a set of cross-channel item pairs belonging to different channels, calculate the linear correlation strength between the time series vectors of each item pair in the cross-channel item pair set, and calculate the arithmetic mean of the linear correlation strength as a noise index. Dividing the synchronization index by the sum of the noise index and the numerical stability term yields the channel expansion coefficient, where the numerical stability term is a constant greater than zero. Step S103: Establish a negative correlation mapping between the channel expansion coefficient and the confidence decay weight, assign confidence decay weights to negative samples without interaction, and assign preset fixed values ​​to positive samples with interaction to obtain the training sample weights. Step S103 specifically includes: receiving the channel expansion coefficient, item-to-channel mapping, binary interaction state and total number of time buckets, summing the binary interaction state in all time buckets, and if the summation result is greater than zero, the binary interaction state in the training window takes the value of one; otherwise, the binary interaction state in the training window takes the value of zero. Dividing constant 1 by the sum of constant 1 and channel expansion coefficient yields the zero-interaction confidence attenuation weight, thus achieving a negative correlation mapping between the channel expansion coefficient and the zero-interaction confidence attenuation weight. For each demand entity and item pair, if the binary interaction state within the training window is one, the training sample weight is assigned a constant one; if the binary interaction state within the training window is zero, the corresponding zero interaction confidence decay weight is found according to the item-to-channel mapping, and the training sample weight is assigned a zero interaction confidence decay weight. Step S104: Using the binary interaction state as the fitting target, substitute the training sample weights into the implicit collaborative filtering loss function, and minimize the weighted error to obtain the interaction tendency score. Step S105: Convert the interaction tendency score into a probability, combine it with the average consumption per transaction after removing zero interaction periods to calculate the expected demand, and summarize to obtain the total demand forecast for the lead time period. Step S106: Extract the safety stock corresponding to the lead time and demand fluctuation of the channel from the historical arrival data, and obtain the net purchase quantity by adding the total demand forecast of the lead time to the safety stock and deducting the effective inventory equity. Calculate the purchase order date based on the target arrival date and the channel lead time.

2. The method for optimizing integrated import and export supply chain services based on collaborative filtering algorithm according to claim 1, characterized in that, Set the time granularity, number of window buckets, and start time. Divide the difference between the event timestamp and the start time by the time granularity, round down the result and add one to get the time bucket number. For any demand entity and any item, within the time bucket number, the number of events contained in the set of related business events is accumulated to obtain the bucket interaction volume. The indicator function is used to determine the bucket interaction quantity. If the bucket interaction quantity is greater than zero, the binary interaction state is set to one; otherwise, the binary interaction state is set to zero. For any item and time bucket number, sum the binary interaction states corresponding to all demand entities. If the sum is zero, the item-level global zero interaction state is set to one; otherwise, the item-level global zero interaction state is set to zero.

3. The method for optimizing integrated import and export supply chain services based on collaborative filtering algorithm according to claim 1, characterized in that, Define the latent vectors of demand entities and items, and construct a weighted squared loss. The weighted squared loss consists of a weighted error term and a regularization term. The weighted error term is the sum of the training sample weights multiplied by the squares of the differences between the binary interaction states and the vector inner products within the training window. The regularization term is the sum of the squares of the vector norms multiplied by the regularization coefficient.

4. The method for optimizing integrated import and export supply chain services based on collaborative filtering algorithm according to claim 3, characterized in that, The alternating least squares method is used to perform closed-form updates. Under the condition of fixed item potential vectors, the demand entity potential vectors are updated by matrix inversion operations containing identity matrices. Under the condition of fixed demand entity potential vectors, the item potential vectors are updated by matrix inversion operations containing identity matrices. Calculate the inner product of the updated latent vector of demand entities and the latent vector of items to obtain the interaction tendency score.

5. The method for optimizing integrated import and export supply chain services based on collaborative filtering algorithm according to claim 1, characterized in that, For any demand entity and item, the negative exponent of the interaction tendency score is calculated using an exponential function. The constant 1 is divided by the sum of the constant 1 and the negative exponent to obtain the interaction probability. The numerator is the sum of the bucketed interaction quantities within the window bucket number range, and the denominator is the sum of the binary interaction states within the window bucket number range plus the numerical stability term. The average consumption per transaction is obtained by dividing the numerator by the denominator. The desired demand is obtained by multiplying the number of window buckets, the interaction probability, and the average consumption per transaction. The expected demand within the entire set of demand entities is summed to obtain the total lead time demand forecast for the item within the forecast window.

6. The method for optimizing integrated import and export supply chain services based on collaborative filtering algorithm according to claim 1, characterized in that, For each channel, a sample of the total historical delivery time is collected, and the median of the total historical delivery time sample is selected as the channel's delivery lead time estimate; For any item and each time bucket, sum the bucket interactions within the entire demand entity set to obtain the historical bucket demand. Calculate the variance of the historical bucket demand, divide the estimated channel delivery lead time by the time granularity, multiply the variance by the quotient obtained by dividing the estimated channel delivery lead time by the time granularity, and then take the square root of the product to obtain the safety stock.

7. The method for optimizing integrated import and export supply chain services based on collaborative filtering algorithm according to claim 6, characterized in that, Add the existing available inventory to the quantity of orders that have not yet arrived and subtract the quantity of promised shipments to obtain the effective inventory equity. Add the safety stock to the total demand forecast for the lead time and subtract the effective inventory equity. If the calculation result is greater than zero, the net purchase quantity is the value of the calculation result. If the calculation result is less than or equal to zero, the net purchase quantity is zero. Subtract the estimated lead time for channel delivery from the target delivery date to obtain the procurement order date.

Citation Information

Patent Citations

  • Cross-regional supply chain management method and system based on artificial intelligence

    CN119578804A

  • Intelligent supply chain management system based on dynamic collaborative optimization

    CN120410460A