Method, device and electronic equipment for predicting demand for goods at a point of sale
By constructing community profiles and product association matrices, and combining them with a hybrid forecasting model, the problems of inaccurate demand forecasting and poor interpretability in the health retail sector have been solved, enabling accurate forecasting and decision support for health consumer products.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- BEIJING RENSHENG INTELLIGENT TECHNOLOGY CO LTD
- Filing Date
- 2025-12-31
- Publication Date
- 2026-06-02
AI Technical Summary
Existing technologies in the health retail sector suffer from inaccurate demand forecasting and poor interpretability, particularly in their insufficient adaptability to new product launches, sudden health events, and seasonal changes, and they lack consideration for community-level user profiles.
By constructing community profiles from multiple data sources, combining community-product association matrices and hybrid prediction models, and integrating dynamic community features with historical sales data, an attention mechanism is used to allocate feature weights, generating accurate product demand prediction results.
It enables precise insights from a one-size-fits-all approach to a personalized experience for each store, improving the accuracy and interpretability of forecasts. It can clearly reveal the driving factors behind demand, providing a reliable basis for decision-making in inventory optimization and personalized marketing.
Smart Images

Figure CN122134386A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the field of retail supply chain management and artificial intelligence technology, in particular to a sales terminal commodity demand prediction method and device and electronic equipment. BACKGROUND
[0002] In the health retail field, accurate demand prediction is the key to optimizing inventory, reducing waste, and improving customer satisfaction. However, traditional prediction methods face significant challenges: 1. Limitations of historical data: Traditional time series prediction models (such as ARIMA, Prophet) mainly rely on the historical sales data of the store itself. For new product launches, sudden health events (such as flu outbreaks), or seasonal changes, historical data is insufficient or ineffective, leading to inaccurate predictions.
[0003] 2. "One-store-one-policy" decision dilemma: Headquarters' procurement plans often fail to fully consider the specific customer group differences served by each store. Applying the same prediction model to all stores cannot adapt to the huge differences in community demographics (population characteristics) and health preferences, leading to stockouts in some stores and inventory overstock in others.
[0004] 3. Strong correlation of health consumption: The demand for health-related goods (such as specific-function health products, medical devices, and low-sugar foods) is highly related to consumers' special attributes (such as age, health status, chronic illness, and health philosophy), which is far from being comparable to general fast-moving consumer goods. Traditional models are difficult to capture these deep correlations.
[0005] Existing demand prediction technologies have obvious defects: 1. Lack of forward-looking insight: Only looking back at historical data, unable to look outside at potential market demand, especially unable to quantify the impact of changes in surrounding community population structure.
[0006] 2. Single feature engineering dimension: User portraits at the community level, an extremely important macro feature, are not introduced into the prediction model, losing key information.
[0007] 3. Poor flexibility and interpretability: Complex deep learning models can improve accuracy to some extent, but their "black box" nature makes it difficult for business personnel to understand the basis for prediction, and it is difficult to quickly integrate business knowledge for adjustment. SUMMARY
[0008] The present application provides a sales terminal commodity demand prediction method, device and electronic equipment to solve the problem of inaccurate prediction and poor interpretability in the health consumption field due to single data dimension and lack of external correlation in the prior art.
[0009] In a first aspect, the present invention provides a method for forecasting the demand for goods at a sales terminal, the method comprising: Acquire multi-source data from various sales terminals and build community profiles for each sales terminal based on the multi-source data; Construct a community product association matrix that links community profiles with demand for health-related consumer goods; Based on the community product association matrix and historical sales data from sales terminals, a pre-set hybrid prediction model is used to generate product demand prediction results.
[0010] This technical solution innovatively constructs and integrates dynamic community profiles and community-product association matrices, deeply combining previously fragmented macro-level population characteristics, micro-level consumption preferences, and historical sales timelines. This achieves a leap from generic, one-size-fits-all predictions to precise insights tailored to each store. Simultaneously, the entire prediction process is highly interpretable, clearly revealing driving factors behind demand such as community population and health risks. This provides direct and reliable decision-making support for refined product selection, inventory optimization, and personalized marketing, effectively addressing the core pain points of inaccurate predictions and poor interpretability in the health consumption sector due to single data dimensions and a lack of external correlations.
[0011] In one alternative implementation, the multi-source data includes a first type of data from the enterprise to which the sales terminal belongs and a second type of data from outside the enterprise; Based on multi-source data, community profiles are built for each sales terminal, including: Centered on the geographical location of each sales terminal and based on at least one business geography rule, the scope of the community served by each sales terminal is dynamically determined. The first and second types of data are aggregated into the community scope to obtain community-level data. Based on community-level data, a community profile is generated for each community.
[0012] This technical solution aggregates internal business data with external environmental data within dynamically defined community areas to construct a precise and feature-rich community profile, effectively overcoming the shortcomings of traditional methods that rely on single sales data and ignore the macro-level characteristics of the area where the store is located. This design enables the demand forecasting model to fully integrate micro-level operational information of enterprises with macro-level population health attributes of the community, generating highly personalized forecasting data for each sales terminal.
[0013] In one alternative implementation, building community profiles for each sales terminal based on multi-source data further includes: A multi-layered framework for the target population is defined; the multi-layered framework includes a basic demographic layer, a health status assessment layer, a health consumption behavior layer, and a health concept awareness layer; the target population is the middle-aged and elderly group. Based on a multi-layered architecture, multi-source data is collected from corresponding data sources, and hierarchical quantitative indicators are generated based on the multi-source data. Based on the geographical information of each sales terminal, the hierarchical quantitative indicators are mapped to the service communities corresponding to each sales terminal, and the hierarchical quantitative indicators are aggregated at the community granularity to obtain the feature sub-vectors of the preset population of each community. The feature vectors are combined according to the multi-level architecture to generate a community multi-level feature vector that represents the preset population in the corresponding community. The community multi-level feature vector is used as the community profile of the preset population.
[0014] This technical solution defines a multi-layered architecture for specific population groups (such as the middle-aged and elderly), including demographics, health, consumption patterns, and cognitive attitudes. It systematically extracts, maps, and aggregates quantitative indicators from multiple data sources to construct a structured and quantifiable multi-layered feature vector for the community. This enables a deep and accurate profile of the health consumption needs of specific population groups within the community. This method not only overcomes the shortcomings of traditional profiling methods, which often suffer from limited dimensions and coarse features, but also captures demand signals from deeper driving factors such as lifestyle habits and health concepts. This significantly enhances the interpretability, relevance, and predictive ability of subsequent demand forecasting models for complex scenarios such as long-tail demand and new product launches.
[0015] In one optional implementation, a community product association matrix is constructed between community profiles and demand for health-related consumer goods, including: Based on historical sales data from sales terminals, community profiles are aligned and paired with product sales and demand vectors within the corresponding time period, using community-time period as the unit, to form training samples required for correlation analysis. Based on training samples, a preset machine learning model is trained, and the parameters of the preset machine learning model are adjusted through a preset optimization algorithm to predict the historical demand of the community for various products, and the trained machine learning model is obtained. Extract the community product association matrix from the trained machine learning model, which represents the relationship between community profile features and product features.
[0016] In this technical solution, training samples are constructed by aligning community profiles with historical product sales in a spatiotemporal dimension, and machine learning models are trained to extract a community product association matrix that can quantify the implicit relationship between community characteristics and product demand. This effectively solves the problems of disconnect between profile features and consumer demand and reliance on human experience to summarize association rules in traditional methods.
[0017] In one optional implementation, the preset hybrid prediction model includes: The first processing channel is used to receive and process historical sales time-series data from the target sales terminal; The second processing channel is used to receive and process the community product association matrix; The third processing channel is used to extract the third encoded features of external risks and opportunities affecting health consumption from the feature vector constructed based on the preset regional health risk index. The feature fusion module is used to fuse the output features of the first processing channel, the second processing channel, and the third processing channel to generate commodity demand prediction results.
[0018] In one optional implementation, based on the community product association matrix and historical sales data from sales terminals, a preset hybrid prediction model is used to generate product demand prediction results, including: Historical sales data from sales terminals are input into the first processing channel to extract the first coded features of dynamic sales trends and cycles related to time. The community commodity association matrix is input into the second processing channel to extract the second encoding features of the static prior preferences of each community for various commodities; Based on the first, second, and third coding features, an attention fusion mechanism is used to dynamically evaluate the importance of each coding feature, assign weights to each coding feature, and generate fused features based on each feature code and its corresponding weights. Based on the fusion features, the feature fusion module is used to generate the product demand forecast results for each product at the target sales terminal within a preset time period in the future.
[0019] This technical solution constructs a hybrid prediction model incorporating both temporal and profiling channels. An attention mechanism is introduced to intelligently and dynamically fuse the temporal dynamic features extracted by the first processing channel, the community static preference features extracted by the second processing channel, and the external health risk features extracted by the third processing channel. This allows for the comprehensive and collaborative mining of the multi-dimensional impact of historical sales patterns, inherent demographic attributes, and external environmental changes on product demand. This design not only significantly enhances the model's ability to perceive and adapt to complex demand signals, particularly strengthening the predictive sensitivity and accuracy for product categories driven by health risk factors, but also, through an interpretable weight allocation mechanism, provides clear business attribution for the prediction results. This offers intelligent support with both high accuracy and high reliability for decisions such as inventory management and precision marketing.
[0020] In an optional implementation, when the predicted product is a product category associated with a preset demographic group, a product demand prediction result is generated using a preset hybrid prediction model based on the community product association matrix and historical sales data from sales terminals. The method further includes: Construct a mapping relationship between regional health risk indices and product categories associated with predefined population groups; An attention fusion mechanism is used to increase the weight of the third encoded feature; Based on the mapping relationship and the improved weights, the feature fusion module is used to generate the product demand prediction results for the preset group.
[0021] This technical solution innovatively constructs a mapping relationship between regional health risk indices and category demand when predicting product categories associated with a predefined population. It also utilizes an attention mechanism to dynamically increase the weight of the third encoded feature reflecting external health risks in the model's decision-making process, achieving highly sensitive predictions of health consumption needs for specific populations (such as the middle-aged and elderly). This method not only effectively captures the impact of sudden external factors such as seasonal diseases and environmental changes on the demand for specific product categories, significantly improving the predictive power and accuracy, but also enhances the model's response to external risk signals, making the prediction results more closely aligned with the actual health consumption scenarios of specific populations.
[0022] In one alternative implementation, the method further includes: Based on community profiles, the results of commodity demand forecasting are analyzed for attribution, and a readable report is generated. The product demand forecast results and readability reports are sent to the corresponding supply chain management system to provide decision-making reference for the supply chain management system.
[0023] This technical solution intelligently links community profiles with demand forecast results and performs attribution analysis to generate highly readable business reports. These reports not only provide forecast figures but also clearly reveal the driving factors behind demand fluctuations, such as community demographics and health characteristics. This design significantly enhances the business guidance value and decision-making credibility of the forecast results, enabling the supply chain management system to execute more precise inventory allocation, procurement plans, and marketing strategies based on clear attribution insights.
[0024] Secondly, the present invention provides a sales terminal commodity demand forecasting device, the device comprising: The community profile building module is used to acquire multi-source data from various sales terminals and build community profiles for each sales terminal based on the multi-source data. The community product association matrix construction module is used to build a community product association matrix between community profiles and the demand for health-related consumer products; The commodity demand forecasting module is used to generate commodity demand forecasting results based on the community commodity association matrix and historical sales data from sales terminals, using a preset hybrid forecasting model.
[0025] Thirdly, the present invention provides an electronic device, comprising: a memory and a processor, wherein the memory and the processor are communicatively connected to each other, the memory stores computer instructions, and the processor executes the computer instructions to perform the sales terminal commodity demand forecasting method described in the first aspect or any corresponding embodiment thereof.
[0026] Fourthly, the present invention provides a computer-readable storage medium storing computer instructions for causing a computer to execute the sales terminal commodity demand forecasting method of the first aspect or any corresponding embodiment described above.
[0027] Fifthly, the present invention provides a computer program product, including computer instructions for causing a computer to execute the sales terminal commodity demand forecasting method described in the first aspect or any corresponding embodiment thereof. Attached Figure Description
[0028] To more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the specific embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.
[0029] Figure 1 This is a schematic diagram of an application scenario according to an embodiment of the present invention; Figure 2 This is a schematic diagram of the first type of sales terminal commodity demand forecasting method according to an embodiment of the present invention; Figure 3 This is a schematic diagram of the second process of the sales terminal commodity demand forecasting method according to an embodiment of the present invention; Figure 4 This is a schematic diagram of the third process of the sales terminal commodity demand forecasting method according to an embodiment of the present invention; Figure 5 This is a schematic diagram of the workflow of the hybrid demand forecasting model in the sales terminal commodity demand forecasting method according to an embodiment of the present invention; Figure 6 This is a schematic diagram of community profiling based on federated learning in the sales terminal commodity demand forecasting method according to an embodiment of the present invention; Figure 7 This is a schematic diagram of the fourth process of the sales terminal commodity demand forecasting method according to an embodiment of the present invention; Figure 8 This is a structural block diagram of a sales terminal commodity demand forecasting device according to an embodiment of the present invention; Figure 9 This is a schematic diagram of the hardware structure of an electronic device according to an embodiment of the present invention. Detailed Implementation
[0030] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0031] It is understood that before using the technical solutions disclosed in the various embodiments of the present invention, users should be informed of the types, scope of use, and usage scenarios of the personal information involved in the present invention and their authorization should be obtained in accordance with relevant laws and regulations through appropriate means.
[0032] The terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of that feature. In the description of this invention, "a plurality of" means two or more, unless otherwise explicitly specified.
[0033] As an optional application scenario of this invention, such as Figure 1 The diagram shown is a structural diagram of the sales terminal commodity demand forecasting system provided by the present invention. The system includes: The multi-source data fusion and community segmentation module 101 is used to aggregate data from multiple internal and external data sources, and dynamically segment the core communities served by a store based on its delivery range, business district radius, or geographical features. This data is aggregated to the community level to generate a tagged profile for each community and a structured social profile dataset 102, such as "elderly highly educated communities," "emerging family communities," and "communities with high incidence of chronic diseases," and includes quantified feature vectors.
[0034] The community-product association matrix construction module 103 is used to mine the quantitative relationship between community profiles and product demand 104.
[0035] A hybrid demand forecasting model 105 is used to receive community profile features, historical sales data, seasonal factors, etc., and make comprehensive forecasts. In the process of making comprehensive forecasts, a fusion mechanism to enhance the characteristics of middle-aged and elderly people is introduced 106, and the forecast results of commodity demand for a specific time period in the future (such as the next week or the next month) are output through a regression layer 107.
[0036] Prediction Result Analysis and Application Module 108: Used to visualize and deeply interpret the commodity demand forecast results, and finally generate an intelligent demand forecast report 109.
[0037] According to an embodiment of the present invention, a method for predicting the demand for goods at a point of sale is provided. It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions. Furthermore, although a logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in a different order than that shown here.
[0038] This embodiment provides a method for predicting the demand for goods at a point of sale (POS) terminal, which can be used in the aforementioned electronic device or terminal device, wherein the electronic device or terminal device is equipped with a POS terminal demand prediction system. Figure 2 This is a flowchart of a sales terminal product demand forecasting method according to an embodiment of the present invention, such as... Figure 2 As shown, the process includes the following steps: Step S201: Obtain multi-source data from each sales terminal and build a community profile for each sales terminal based on the multi-source data.
[0039] Specifically, sales terminals include offline stores and service nodes.
[0040] In the community profile construction phase, through multi-source data fusion and dynamic geofencing algorithm of community division module, the geographical boundaries of each sales terminal's exclusive service community are automatically delineated by taking the geographical coordinates of each sales terminal as the center and integrating information such as delivery range and business district radius. Subsequently, multi-source heterogeneous data obtained from internal business systems and external data sources are cleaned, standardized and spatially aligned, and aggregated into the delineated community units. Finally, feature engineering is used to generate quantitative profile feature vectors that represent the comprehensive status of each community.
[0041] Step S202: Construct a community product association matrix between community profiles and demand for health-related consumer goods.
[0042] Specifically, in the association matrix construction stage, the community-product association matrix construction module uses historical time period data to align the profile feature vectors of each community with the sales records of health consumer products of the associated sales terminals in the corresponding time period in terms of time and space, forming a structured training sample set. Then, the system uses machine learning algorithms such as matrix factorization to train the samples, learn the implicit association patterns between community features and product features, and finally extract and solidify a quantifiable community-product preference association matrix.
[0043] Step S203: Based on the community product association matrix and historical sales data of sales terminals, a preset hybrid prediction model is used to generate product demand prediction results.
[0044] Specifically, in the demand forecast generation stage, the historical sales time series data of the target sales terminal, the latest profile feature vector of its community, and the aforementioned correlation matrix are used as inputs and fed into a pre-trained hybrid neural network model. The model processes the time series signal and static community features through its internal multi-branch architecture, and then performs integrated calculations through a feature fusion layer to finally output the numerical sequence of demand forecasts for each product of the sales terminal in the future specified period.
[0045] The sales terminal product demand forecasting method provided in this embodiment innovatively constructs and integrates dynamic community profiles and community-product association matrices, deeply combining previously fragmented macro-level population characteristics, micro-level consumption preferences, and historical sales timelines. This achieves a leap from extensive forecasting with a one-size-fits-all approach to precise insights tailored to each store. Simultaneously, the entire forecasting process is highly interpretable, clearly revealing driving factors behind demand such as community population and health risks. This provides direct and reliable decision-making support for refined product selection, inventory optimization, and personalized marketing, effectively addressing the core pain points of inaccurate forecasting and poor interpretability in the health consumption sector due to single data dimensions and a lack of external correlations.
[0046] This embodiment provides a method for predicting the demand for goods at a point of sale (POS) terminal, which can be used in the aforementioned electronic device or terminal device, wherein the electronic device or terminal device is equipped with a POS terminal demand prediction system. Figure 3 This is a flowchart of a sales terminal product demand forecasting method according to an embodiment of the present invention, such as... Figure 3 As shown, the process includes the following steps: Step S301: Obtain multi-source data from each sales terminal and build a community profile for each sales terminal based on the multi-source data.
[0047] Specifically, the multi-source data includes the first type of data from the enterprise to which the sales terminal belongs and the second type of data from outside the enterprise; the first type of data is internal business data, including: enterprise CRM (Customer Relationship Management) system (user registration information, delivery address), member consumption data, and APP (Application) location data.
[0048] Step S301 above includes: Step S3011: Based on the geographical location of each sales terminal and at least one business geography rule, dynamically determine the community range served by the sales terminal.
[0049] Specifically, taking the geographical coordinates of each sales terminal (such as a store) as the center, and based on at least one preset business or geographically related rule (e.g., delivery radius, walking distance, administrative or business district boundaries, natural geographical barriers), the core geographical area actually served and covered by the terminal is dynamically and automatically calculated and delineated. This area is defined as the "service community" of the sales terminal.
[0050] Step S3012: Aggregate the first type of data and the second type of data into the community scope to obtain community-level data.
[0051] Specifically, raw information from internal enterprise systems (first-class data, such as member addresses and sales records) and external data sources (second-class data, such as demographic data and regional health reports) is filtered and aggregated within the geographical boundaries of each service community defined in step one, based on its inherent or associated geographic tags (such as addresses and statistical block codes), using spatial matching algorithms. This process aggregates and transforms originally scattered, individual, or larger regional data into a unified community-level dataset with the community as the basic statistical unit.
[0052] Step S3013: Generate a community profile for each community based on community-level data.
[0053] Specifically, based on the obtained community-level dataset, feature extraction and computation are used to generate a unique, structured digital description—a community profile—for each community. This profile typically includes: Quantized feature vector: A series of standardized numerical features used to accurately represent the community in the model (e.g., population proportion of each age group, average income index, estimated prevalence of specific diseases, etc.).
[0054] It can also include semantic labels: based on feature vectors, the community is given descriptive labels that are easy for humans to understand through rules or clustering models (e.g., "Community of highly educated young families", "Community focused on aging and chronic diseases").
[0055] It should be noted that this embodiment also provides a privacy-preserving community profile construction based on federated learning, such as... Figure 6 The numbers 301 to 306 shown include: 1. Distributed data fusion mechanism: Employing federated learning technology, multi-source distributed data fusion is achieved through model parameter exchange without centralizing the original data; a differential privacy protection algorithm is designed to add noise perturbation during the community profile construction process to protect sensitive personal information; and a data security gateway is established to desensitize and encrypt sensitive data such as medical and health data.
[0056] 2. Cross-domain knowledge transfer learning: Develop a feature transfer mechanism between store profiles to solve the cold start problem for newly opened stores or stores with sparse data; build a regionalized prior knowledge base to transfer the prediction patterns of successful areas to new areas with similar features; and design an incremental learning framework to dynamically update the profile model as the community's population structure changes.
[0057] This embodiment also provides a parallel community profile construction method for a specific population (such as the middle-aged and elderly population), namely, a quantitative system for the health needs of the middle-aged and elderly based on multi-level profiles. The above step S301 includes: Step S3014: Determine the multi-layered structure of the preset population; the multi-layered structure includes a basic demographic layer, a health status assessment layer, a health consumption behavior layer, and a health concept awareness layer; Specifically, this step involves creating a hierarchical health profile for the middle-aged and elderly population, with each level defined as follows: 1. Basic demographic strata: age structure (60-70 years old, stratified by age over 70 years old), family structure (empty nest, living with children); 2. Health Status Assessment Layer: Construct a chronic disease distribution index (prevalence of hypertension, diabetes, and cardiovascular and cerebrovascular diseases) based on regional medical data (de-identified). 3. Health-related consumption behavior layer: Based on consumption data mining, analyze the brand preferences, price sensitivity, and purchase frequency characteristics of middle-aged and elderly customers; 4. Health concept awareness level: Analyze the level of attention to health information (such as the degree of attention to concepts such as "dietary supplements" and "traditional Chinese medicine health preservation") through social media data and search behavior.
[0058] Step S3015: Based on the multi-layered architecture, collect multi-source data from the corresponding data sources and generate hierarchical quantitative indicators based on the multi-source data.
[0059] Based on each defined level, targeted data collection and processing are performed from the corresponding internal and external data sources: Basic demographic data layer: Calculates "percentage of the population aged 70 and above" and "percentage of empty-nest families" from population and housing data.
[0060] Health status assessment layer: Calculate the "community hypertension prevalence index" from desensitized medical statistical reports, etc.
[0061] Health consumption behavior layer: Calculate "average monthly spending on cardiovascular health products by middle-aged and elderly customers" and "promotion sensitivity coefficient" from transaction data.
[0062] Health and wellness concept awareness layer: Calculate the monthly community discussion popularity index for topics related to Traditional Chinese Medicine (TCM) health and wellness from social media texts using natural language processing technology.
[0063] This step outputs a series of discrete, hierarchical quantitative indicators corresponding to each level.
[0064] Step S3016: Based on the geographical information of each sales terminal, the hierarchical quantitative indicators are mapped to the service communities corresponding to each sales terminal, and the hierarchical quantitative indicators are aggregated at the community granularity to obtain the feature sub-vectors of the preset population of each community.
[0065] Specifically, the calculated stratified quantitative indicators are mapped to the specific geographical boundaries of the communities served by each sales terminal, based on their implicit or explicit geographical information (such as personal addresses and statistical areas in data reports). Subsequently, aggregation operations (such as averaging, summing, and calculating percentages) are performed on all similar indicator data mapped to the same community, resulting in a new set of aggregated feature values specific to that community and targeting a predetermined population at each level. These values are organized hierarchically to form the feature sub-vector set for the predetermined population of that community.
[0066] Step S3017: Combine the feature sub-vectors according to the multi-level architecture to generate a community multi-level feature vector representing the preset population in the corresponding community, and use the community multi-level feature vector as the community profile of the preset population.
[0067] Specifically, following a predefined multi-level architecture, the feature sub-vectors generated by each community are sequentially concatenated and combined to form a complete, high-dimensional community multi-level feature vector. This vector mathematically uniquely represents the overall profile of a predefined population (such as the middle-aged and elderly) within a specific geographical community. It integrates multi-dimensional information on population, health, behavior, and attitudes, and serves as a precise and structured community profile for this population, which is then input into subsequent prediction and analysis models.
[0068] Step S302: Construct a community product association matrix between community profiles and the demand for health-related consumer goods. For details, please refer to [link to relevant documentation]. Figure 2 Step S202 of the illustrated embodiment will not be described again here.
[0069] Step S303: Based on the community product association matrix and historical sales data from sales terminals, a pre-set hybrid forecasting model is used to generate product demand forecasting results. For details, please refer to [link to details]. Figure 2 Step S203 of the illustrated embodiment will not be described again here.
[0070] The sales terminal product demand forecasting method provided in this embodiment defines a multi-layered architecture for specific groups (such as the middle-aged and elderly), including demographics, health, consumption patterns, and cognitive beliefs. It systematically extracts, maps, and aggregates quantitative indicators from multiple data sources to construct a structured and quantifiable multi-layered feature vector for the community. This enables a deep and accurate profile of the health consumption needs of specific groups within the community. This method not only overcomes the shortcomings of traditional profiling methods, which are often limited by single dimensions and coarse features, but also captures demand signals from deep-seated driving factors such as lifestyle habits and health concepts. This significantly improves the interpretability, relevance, and predictive ability of subsequent demand forecasting models for complex scenarios such as long-tail products and new products.
[0071] This embodiment provides a method for predicting the demand for goods at a point of sale (POS) terminal, which can be used in the aforementioned electronic device or terminal device, wherein the electronic device or terminal device is equipped with a POS terminal demand prediction system. Figure 4 This is a flowchart of a sales terminal product demand forecasting method according to an embodiment of the present invention, such as... Figure 4 As shown, the process includes the following steps: Step S401: Obtain multi-source data from each sales terminal and construct a community profile for each sales terminal based on the multi-source data. For details, please refer to [link to relevant documentation]. Figure 3 Step S301 of the illustrated embodiment will not be described again here.
[0072] Step S402: Construct a community product association matrix between community profiles and demand for health-related consumer goods.
[0073] Specifically, step S402 includes: Step S4021: Based on historical sales data from sales terminals, and using community-time period as the unit, align and pair community profiles with the sales volume and demand vectors of health-related consumer goods within the corresponding time period to form training samples required for correlation analysis.
[0074] Specifically, the basic unit of analysis is the combination of "community" and "specific time period" (such as one week or one month). For each unit, the following operations are performed: Feature side: Extract the community profile feature vector (i.e., a digital snapshot of the community) at the beginning of the time period.
[0075] Tag side: Summarize the historical sales data of all sales terminals (stores) serving the community for various types of goods (which can be refined to categories) during the time period, and organize them into a product demand vector (each dimension represents the sales volume or demand index of a product).
[0076] Alignment and pairing: Pair the community profile feature vector with the product demand vector to form a feature-label sample.
[0077] By traversing all historical communities and time periods, a large, structured training sample set is constructed.
[0078] Step S4022: Based on the training samples, train the preset machine learning model, adjust the parameters of the preset machine learning model through the preset optimization algorithm, predict the community's historical demand for various products, and obtain the trained machine learning model.
[0079] Specifically, the aforementioned training sample set is input into a pre-defined machine learning model (e.g., matrix factorization model, factorization machine, or deep neural network). The goal of model training is to learn how to accurately predict (or fit) the corresponding product demand vector from the input community profile feature vector.
[0080] During training, a pre-defined optimization algorithm (such as stochastic gradient descent) is used to iteratively adjust the model's internal parameters, minimizing the error between its predicted demand and actual historical demand. Upon completion of training, a machine learning model with optimized parameters is obtained, capable of deeply understanding how community characteristics influence commodity demand.
[0081] Step S4023: Extract the community product association matrix from the trained machine learning model, which represents the community profile features and the health consumption product features.
[0082] Specifically, a matrix is extracted from the trained machine learning model to form a matrix that can represent the correlation weight between the community profile feature dimension and the product feature dimension, and this matrix is used as the community product correlation matrix.
[0083] The rows of this matrix can be understood as the implicit dimensions of the community profile, and the columns can be understood as the implicit dimensions of the products. Each element value in the matrix quantifies the correlation strength or preference coefficient between a certain community feature dimension and a certain product feature dimension.
[0084] Step S403: Based on the community product association matrix and historical sales data of sales terminals, a preset hybrid prediction model is used to generate product demand prediction results.
[0085] Specifically, the input data includes community profiles, historical sales data, and health risk data. Figure 5 The 201 pre-defined hybrid prediction model includes: The first processing channel is used to receive and process historical sales time-series data from the target sales terminal; the first processing channel is... Figure 5 The 202 time series channel uses LSTM (Long Short-Term Memory) or Transformer encoders to process historical sales time series data of target sales terminals (such as target stores) and capture time autocorrelation.
[0086] The second processing channel is used to receive and process the community product association matrix; the second processing channel is... Figure 5 The 203 profile channels are used to input the preprocessed community profile feature vectors representing the relationship between the community profiles and the product association matrix as static features into the fully connected network.
[0087] The third processing channel is used to extract third-encoded features of external risks and opportunities affecting health consumption from the feature vector constructed based on the preset regional health risk index; the third processing channel is... Figure 5 The health risk assessment channel 204 innovatively introduces a regional health risk index. This regional health risk index is a comprehensive indicator constructed by integrating regional epidemiological statistics, seasonal high-incidence disease distribution data, and environmental health monitoring data (such as air quality index). It is used to quantitatively assess the potential impact of the external environment on the health consumption needs of the community population and construct a health risk feature vector.
[0088] The feature fusion module is used to fuse the output features of the first processing channel, the second processing channel, and the point processing channel to generate commodity demand prediction results.
[0089] The workflow of the hybrid demand forecasting model is as follows: Figure 5 As shown, step S403 above includes: Step S4031: Input the historical sales data of the sales terminal into the first processing channel and extract the first coded features of the dynamic sales trend and cycle related to time.
[0090] Specifically, historical sales data from the target sales terminals (typically a time-ordered sales sequence) is input into the first processing channel of the hybrid prediction model. This channel is typically composed of temporal neural networks such as LSTM (Long Short-Term Memory) or Transformer. Its core function is to deeply mine the time dependencies in the sequence data, automatically learning and extracting dynamic patterns inherent in the historical data, such as long-term growth / decline trends, seasonal cycles, holiday effects, and short-term fluctuations. The output of this step is a high-dimensional, first-encoded feature vector that condenses the time dimension information.
[0091] Step S4032: Input the community product association matrix into the second processing channel to extract the second coding features of the static prior preferences of each community for various types of products.
[0092] Specifically, the community-product association matrix is input into the second processing channel of the hybrid prediction model. This channel is typically a fully connected neural network or an embedding layer. Its core function is to decode and apply prior community knowledge. It uses the association matrix to translate the community profile feature vector of the community served by the target sales terminal into the latent preference strengths of that community for various products. The output of this step is a second-encoded feature vector.
[0093] Step S4033: Based on the first encoding, second encoding features, and third encoding features, an attention fusion mechanism is used to dynamically evaluate the importance of each encoding feature (i.e., Figure 5 (205), assign weights to each encoded feature, and generate fused features based on each feature encoding and its corresponding weight.
[0094] Specifically, the first encoded features (temporally dynamic) from the first processing channel, the second encoded features (static preferences) from the second processing channel, and the third encoded features (e.g., contextual features such as external health risks) from the third processing channel are all input into an attention fusion module. The core function of this module is to perform context-aware feature importance assessment and integration. It does not simply concatenate or average the input features, but dynamically calculates the importance score (i.e., weight) of each encoded feature to the current prediction target based on the specific prediction task (e.g., predicting which product and when). Then, all features are weighted and fused according to these weights to generate a unified, comprehensive, and focused fused feature representation.
[0095] Step S4034: Based on the fusion features, the feature fusion module is used to generate the product demand forecast results for each product at the target sales terminal within a preset time period in the future.
[0096] Specifically, the generated fused feature representation is input into the final output layer of the hybrid prediction model, namely the feature fusion module (usually a regression network consisting of one or a series of fully connected layers). The core function of this module is to perform the mapping from the fused features to specific numerical values. It learns the complex nonlinear relationship between the fused features and future product demand, and calculates and outputs the specific demand forecast values for each product (or product category) at the target sales terminal within a preset future time period (e.g., next week, next month). These values constitute the final product demand forecast result (i.e.,...). Figure 5 206).
[0097] Step S4035: When the predicted product is a product category associated with a preset population, construct a mapping relationship between the regional health risk index and the product category associated with the preset population; use an attention fusion mechanism to increase the weight of the third coding feature; based on the mapping relationship and the increased weight, use a feature fusion module to generate the product demand prediction result for the preset population.
[0098] Specifically, this step involves a feature enhancement and fusion mechanism for the middle-aged and elderly population, including: First, establish a mapping relationship between regional health risk index and commodity demand, such as: peak flu season → increased demand for immune health products; deteriorating air quality → increased demand for respiratory protective products; seasonal changes → changes in demand for joint care products, etc.
[0099] Establish specialized predictive sub-models for common health problems among middle-aged and elderly people, such as cardiovascular health, bone health, and blood sugar management.
[0100] The system employs an attention mechanism to dynamically weight the outputs of the three channels, with a particular emphasis on increasing the weight of the health risk channel for products related to middle-aged and elderly individuals (such as medications for chronic diseases and health care devices). For example: 1. Adaptive feature weighting based on age structure: We will construct an age-stratified attention mechanism to automatically increase the weight of health-related features in communities with a high proportion of middle-aged and elderly people; design a seasonal weight adjustment strategy to dynamically adjust the parameters of the prediction model for the high incidence of seasonal diseases that are sensitive to middle-aged and elderly people; and develop a new product penetration rate prediction algorithm that takes into account the acceptance cycle and diffusion pattern of new products among middle-aged and elderly people.
[0101] 2. The integration of consumption decision-making factors among middle-aged and elderly individuals is also considered: Price sensitivity modeling: quantifying the price elasticity of middle-aged and elderly groups for different product categories based on historical promotional data; Brand loyalty assessment: predicting the impact of brand preference on demand through repeat purchase rate and brand switching cost analysis; Social influence factor: considering word-of-mouth communication and herd consumption behavior among middle-aged and elderly groups.
[0102] In step S4035 above, when it is identified that the product to be predicted belongs to a predefined category associated with a specific population (e.g., predicting cardiovascular drugs or health products related to the middle-aged and elderly population), a specific processing logic is first activated. The core of this logic is to construct and invoke a mapping knowledge base. This knowledge base explicitly establishes a quantitative correspondence between regional health risk indices (such as influenza activity, air quality index, and seasonal disease distribution) and the demand for related categories of specific populations. For example, the knowledge base might record that "when the regional influenza index exceeds threshold X, the expected basic demand for immune-boosting health products among the middle-aged and elderly population in the corresponding community will increase by Y%."
[0103] During the attention fusion mechanism of the hybrid prediction model, in addition to the routine feature importance assessment, a targeted adjustment rule is forcibly injected. This rule, based on a knowledge base mapping regional health risk indices to predefined population-related product categories and current real-time regional health risk data, significantly increases the weight of "third-encoded features" (i.e., features reflecting external health risks) from the third processing channel in the current fusion decision. This means that when predicting such specific products, the model will listen more to and adopt external environmental health risk signals, giving them a more dominant influence in the final decision.
[0104] When the feature fusion module performs the final numerical prediction, it will take into account both inputs: The fusion feature representation is derived from weighted adjustments (where health risk features have been enhanced).
[0105] The knowledge base provides basic correction amounts or adjustment factors for the mapping relationship between regional health risk indices and product categories associated with predefined populations.
[0106] The feature fusion module integrates this information into its regression calculation, thereby generating the final product demand forecast for the product categories associated with the preset population. This result is not only based on general time series and profile patterns, but also deeply integrates the direct impact of external health risks, making the forecast more sensitive, accurate, and business-foresighted in the face of external shocks such as changes in the epidemic and seasonal transitions.
[0107] Step S404: Attribution analysis of the commodity demand forecast results based on community profiles and generate a readability report; send the commodity demand forecast results and the readability report to the corresponding supply chain management system to provide decision-making reference for the supply chain management system.
[0108] Specifically, the prediction results are visualized and deeply interpreted through the prediction result analysis and application module, and outputs not only predicted numbers, but also readable reports, such as: "It is predicted that the demand for protein powder in store A will increase by 20% next week, mainly driven by the recent increase of a large number of fitness enthusiasts in the community it serves" or "Community B is an aging community, and it is recommended to increase the stock ratio of joint care products."
[0109] The sales terminal commodity demand forecasting method provided in this embodiment innovatively constructs a mapping relationship between regional health risk index and category demand when forecasting related categories for a preset population. It also uses an attention mechanism to dynamically increase the weight of the third coding feature reflecting external health risks in the model decision-making, thereby achieving highly sensitive prediction of health consumption demand for specific groups (such as the middle-aged and elderly).
[0110] As one or more specific application embodiments of the present invention, combined withFigure 7 The present invention provides a further detailed description of the sales terminal product demand forecasting method, such as... Figure 7 As shown, the specific process is as follows: 1. Data aggregation and community segmentation: Through multi-source data fusion and community segmentation modules, data is regularly pulled from internal and external systems to update the community profiles of each store.
[0111] 2. Relationship Learning: The community-product relationship matrix construction module trains or updates the community-product relationship model based on historical data.
[0112] 3. Model Training and Prediction: A hybrid prediction model is trained using historical data. During the prediction period, the latest community profile features and historical sales data are input into the model to obtain product demand forecasts.
[0113] 4. Results Application: The prediction results are sent to the procurement system and inventory management system through the prediction result analysis and application module to guide automatic replenishment and delivery scheduling, and at the same time generate analysis reports for managers to make decisions.
[0114] In this embodiment, when constructing the social profile in step 1 and predicting commodity demand in step 3, a quantitative system for the health needs of middle-aged and elderly people based on multi-level profiles is also provided, including: I. Layered modeling of health profiles for middle-aged and elderly populations, with each layer defined as follows: 1. Basic demographic strata: age structure (60-70 years old, stratified by age over 70 years old), family structure (empty nest, living with children); 2. Health Status Assessment Layer: Construct a chronic disease distribution index (prevalence of hypertension, diabetes, and cardiovascular and cerebrovascular diseases) based on regional medical data (de-identified). 3. Health-related consumption behavior layer: Based on consumption data mining, analyze the brand preferences, price sensitivity, and purchase frequency characteristics of middle-aged and elderly customers; 4. Health concept awareness level: Analyze the level of attention to health information (such as the degree of attention to concepts such as "dietary supplements" and "traditional Chinese medicine health preservation") through social media data and search behavior.
[0115] II. Health Risk-Driven Demand Forecasting Mechanisms: 1. Establish a mapping relationship between regional health risk index and demand for health-related consumer goods, such as: 1) During peak flu season, demand for immune-boosting health supplements increases; 2) Deteriorating air quality → Increased demand for respiratory protective equipment; 3) Seasonal changes → Changes in demand for joint care products; 2. Establish specialized predictive sub-models for common health problems among middle-aged and elderly people, such as cardiovascular health, bone health, and blood sugar management.
[0116] To ensure privacy protection, a privacy-preserving community profile construction method based on federated learning is also provided: 1. Distributed data fusion mechanism: Employing federated learning technology, multi-source data fusion is achieved through model parameter exchange without centralizing the original data; a differential privacy protection algorithm is designed to add noise perturbation during the community profile construction process to protect sensitive personal information; and a data security gateway is established to desensitize and encrypt sensitive data such as medical and health data.
[0117] 2. Cross-domain knowledge transfer learning: Develop a feature transfer mechanism between store profiles to solve the cold start problem for newly opened stores or stores with sparse data; build a regionalized prior knowledge base to transfer the prediction patterns of successful areas to new areas with similar features; and design an incremental learning framework to dynamically update the profile model as the community's population structure changes.
[0118] In demand forecasting, a dynamic weight adjustment mechanism tailored to the consumption characteristics of middle-aged and elderly individuals is also provided: 1. Adaptive feature weights based on age structure: 1. Construct an age-stratified attention mechanism to automatically increase the weight of health-related features in communities with a high proportion of middle-aged and elderly people; design a seasonal weight adjustment strategy to dynamically adjust the parameters of the prediction model for the high incidence of seasonal diseases that are sensitive to middle-aged and elderly people; develop a new product penetration rate prediction algorithm that takes into account the acceptance cycle and diffusion pattern of new products among middle-aged and elderly people.
[0119] 2. The integration of consumption decision-making factors among middle-aged and elderly individuals is also considered: Price sensitivity modeling: quantifying the price elasticity of middle-aged and elderly groups for different product categories based on historical promotional data; Brand loyalty assessment: predicting the impact of brand preference on demand through repeat purchase rate and brand switching cost analysis; Social influence factor: considering word-of-mouth communication and herd consumption behavior among middle-aged and elderly groups.
[0120] The sales terminal demand forecasting method provided in this embodiment achieves accurate quantification of the health consumption needs of middle-aged and elderly people through hierarchical profiling modeling and health risk assessment, overcoming the shortcomings of traditional models in predicting demand from segmented populations. The weight adjustment mechanism designed specifically for the consumption characteristics of middle-aged and elderly people enables the model to adapt to the demographic characteristics of different communities, significantly improving the accuracy and practicality of the forecasts. By employing federated learning and differential privacy technologies, multi-source data fusion is achieved while protecting user privacy, addressing the compliance challenges of using health data. Through the above technical solutions, the demand forecasting problem for the middle-aged and elderly population in the health retail sector is effectively solved, providing reliable technical support for refined store operations and supply chain optimization.
[0121] This embodiment also provides a sales terminal commodity demand forecasting device, which is used to implement the above embodiments and preferred embodiments, and will not be repeated for details already described. As used below, the term "module" can be a combination of software and / or hardware that implements a predetermined function. Although the device described in the following embodiments is preferably implemented in software, hardware implementation, or a combination of software and hardware, is also possible and contemplated.
[0122] This embodiment provides a sales terminal product demand forecasting device, such as... Figure 8 As shown, it includes: The community profile building module 801 is used to obtain multi-source data from various sales terminals and build community profiles for each sales terminal based on the multi-source data.
[0123] The Community Product Association Matrix Construction Module 802 is used to construct a community product association matrix between community profiles and the demand for health-related consumer products.
[0124] The commodity demand forecasting module 803 is used to generate commodity demand forecasting results based on the community commodity association matrix and historical sales data of sales terminals using a preset hybrid forecasting model.
[0125] In some optional implementations, the multi-source data includes a first type of data from the enterprise to which the sales terminal belongs and a second type of data from outside the enterprise; the community profile construction module 801 includes: The community scope determination unit is used to dynamically determine the community scope served by each sales terminal, centered on the geographical location of each sales terminal and based on at least one business geography rule.
[0126] The data fusion unit is used to aggregate the first type of data and the second type of data to the community level to obtain community-level data.
[0127] The community profile generation unit is used to generate a community profile for each community based on community-level data.
[0128] In some optional implementations, the community profile building module 801 further includes: The multi-level architecture determination unit is used to determine the multi-level architecture of the preset population; the multi-level architecture includes a basic demographic layer, a health status assessment layer, a health consumption behavior layer, and a health concept awareness layer; the preset population is the middle-aged and elderly group. The hierarchical quantitative indicator generation unit is used to collect multi-source data from corresponding data sources based on a multi-level architecture, and generate hierarchical quantitative indicators based on the multi-source data.
[0129] The feature sub-vector generation unit is used to map the hierarchical quantitative indicators to the service communities corresponding to each sales terminal based on the geographical information of each sales terminal, and to aggregate the hierarchical quantitative indicators at the community granularity to obtain the feature sub-vectors of the preset population in each community.
[0130] The community profile construction unit for the preset population is used to combine feature sub-vectors according to a multi-level architecture to generate a community multi-level feature vector representing the preset population in the corresponding community, and use the community multi-level feature vector as the community profile of the preset population.
[0131] In some optional implementations, the community product association matrix construction module 802 includes: The training sample generation unit is used to align and pair community profiles with the sales volume and demand vectors of health-related consumer goods within the corresponding time period, based on historical sales data from sales terminals, using community-time period as the unit, to form the training samples required for correlation analysis.
[0132] The model training unit is used to train a preset machine learning model based on training samples, adjust the parameters of the preset machine learning model through a preset optimization algorithm, predict the community's historical demand for various products, and obtain the trained machine learning model.
[0133] The community commodity association matrix construction unit is used to extract the community commodity association matrix representing the relationship between community profile features and health consumption product features from the trained machine learning model.
[0134] In some optional implementations, the preset hybrid prediction model includes: The first processing channel is used to receive and process historical sales time-series data from the target sales terminal; The second processing channel is used to receive and process the community product association matrix; The third processing channel is used to extract the third encoded features of external risks and opportunities affecting health consumption from the feature vector constructed based on the preset regional health risk index. The feature fusion module is used to fuse the output features of the first processing channel, the second processing channel, and the third processing channel to generate commodity demand prediction results.
[0135] In some optional implementations, the commodity demand forecasting module 803 includes: The time-series processing unit is used to input historical sales data from the sales terminal into the first processing channel and extract the first coded features of dynamic sales trends and cycles related to time.
[0136] The profile processing unit is used to input the community product association matrix into the second processing channel and extract the second encoded features of the static prior preferences of each community for various types of products.
[0137] The feature fusion unit is used to dynamically evaluate the importance of each coding feature based on the first coding feature, the second coding feature and the third coding feature using an attention fusion mechanism, assign weights to each coding feature, and generate fused features based on each feature code and its corresponding weights.
[0138] The demand forecasting unit is used to generate product demand forecasts for each product at target sales terminals within a preset time period based on fused features and using a feature fusion module.
[0139] In some optional implementations, when the predicted product is a product category associated with a preset demographic, the product demand prediction module 803 further includes: The dynamic weight adjustment and demand prediction unit is used to construct the mapping relationship between the regional health risk index and the product categories associated with the preset population; the attention fusion mechanism is used to enhance the weight of the third coding feature; based on the mapping relationship and the enhanced weight, the feature fusion module generates the product demand prediction results for the preset population.
[0140] In some alternative embodiments, the device further includes: The forecast result analysis and application module is used to perform attribution analysis on the product demand forecast results based on community profiles and generate a readable report. It then sends the product demand forecast results and the readable report to the corresponding supply chain management system, providing decision-making references for the system. Its function is consistent with the forecast result analysis and application module in the sales terminal product demand forecasting system.
[0141] The sales terminal product demand forecasting device provided in this embodiment of the invention can execute the sales terminal product demand forecasting method provided in any embodiment of the invention, and has the corresponding functional modules and beneficial effects for executing the method. Further functional descriptions of the above modules and units are the same as in the corresponding embodiments described above, and will not be repeated here.
[0142] Figure 9 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present invention.
[0143] The following is a detailed reference. Figure 9This diagram illustrates a structural schematic suitable for implementing an electronic device according to embodiments of the present invention. The electronic device may include a processor (e.g., a central processing unit, graphics processor, etc.) 901, which can perform various appropriate actions and processes according to a program stored in read-only memory (ROM) 902 or a program loaded from memory 908 into random access memory (RAM) 903. The RAM 903 also stores various programs and data required for the operation of the electronic device. The processor 901, ROM 902, and RAM 903 are interconnected via a bus 904. An input / output (I / O) interface 905 is also connected to the bus 904.
[0144] Typically, the following devices can be connected to I / O interface 905: input devices 906 including, for example, touchscreens, touchpads, keyboards, mice, cameras, microphones, accelerometers, gyroscopes, etc.; output devices 907 including, for example, liquid crystal displays (LCDs), speakers, vibrators, etc.; memory devices 908 including, for example, magnetic tapes, hard disks, etc.; and communication devices 909. Communication device 909 allows electronic devices to exchange data via wireless or wired communication with other devices. Although Figure 9 Electronic devices with various devices are shown, but it should be understood that it is not required to implement or have all of the devices shown, and more or fewer devices may be implemented or have instead.
[0145] In particular, according to embodiments of the present invention, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments of the present invention include a computer program product comprising a computer program carried on a non-transitory computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via a communication device 909, or installed from a memory 908, or installed from a ROM 902. When the computer program is executed by the processor 901, it performs the functions defined in the sales terminal merchandise demand forecasting method of the embodiments of the present invention.
[0146] Figure 9 The electronic device shown is merely an example and should not be construed as limiting the functionality and scope of use of the embodiments of the present invention.
[0147] This invention also provides a computer-readable storage medium. The methods described above according to embodiments of the invention can be implemented in hardware or firmware, or implemented as computer code that can be recorded on a storage medium, or implemented as computer code downloaded via a network and originally stored on a remote storage medium or a non-transitory machine-readable storage medium and then stored on a local storage medium. Thus, the methods described herein can be processed by software stored on a storage medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware. The storage medium can be a magnetic disk, optical disk, read-only memory, random access memory, flash memory, hard disk, or solid-state drive, etc.; further, the storage medium can also include combinations of the above types of memory. It is understood that computers, processors, microprocessor controllers, or programmable hardware include storage components capable of storing or receiving software or computer code. When the software or computer code is accessed and executed by the computer, processor, or hardware, the terminal sales demand forecasting method shown in the above embodiments is implemented.
[0148] A portion of this invention can be applied as a computer program product, such as computer program instructions, which, when executed by a computer, can invoke or provide the methods and / or technical solutions according to the invention through the operation of the computer. Those skilled in the art will understand that the forms in which computer program instructions exist in a computer-readable medium include, but are not limited to, source files, executable files, installation package files, etc. Correspondingly, the ways in which computer program instructions are executed by a computer include, but are not limited to: the computer directly executing the instructions, or the computer compiling the instructions and then executing the corresponding compiled program, or the computer reading and executing the instructions, or the computer reading and installing the instructions and then executing the corresponding installed program. Here, the computer-readable medium can be any available computer-readable storage medium or communication medium accessible to a computer.
[0149] Although embodiments of the invention have been described in conjunction with the accompanying drawings, those skilled in the art can make various modifications and variations without departing from the spirit and scope of the invention, and such modifications and variations all fall within the scope defined by the appended claims.
Claims
1. A method for forecasting demand for goods at a sales terminal, characterized in that, The method includes: Acquire multi-source data from each sales terminal, and construct a community profile for each sales terminal based on the multi-source data; Construct a community product association matrix between the aforementioned community profile and the demand for health-related consumer goods; Based on the community product association matrix and historical sales data from sales terminals, a preset hybrid prediction model is used to generate product demand prediction results.
2. The method according to claim 1, characterized in that, The multi-source data includes first-type data from the enterprise to which the sales terminal belongs and second-type data from outside the enterprise; Based on the aforementioned multi-source data, community profiles are constructed for each sales terminal, including: Centered on the geographical location of each sales terminal and based on at least one business geography rule, the scope of the community served by the sales terminal is dynamically determined; The first type of data and the second type of data are aggregated into the community scope to obtain community-level data; Based on the community-level data, a community profile is generated for each community.
3. The method according to claim 1, characterized in that, Building community profiles for each sales terminal based on the aforementioned multi-source data also includes: A multi-layered structure is defined for the target population; the multi-layered structure includes a basic demographic layer, a health status assessment layer, a health consumption behavior layer, and a health concept awareness layer; the target population is the middle-aged and elderly group. Based on the multi-layered architecture, multi-source data is collected from corresponding data sources, and hierarchical quantitative indicators are generated based on the multi-source data. Based on the geographical information of each sales terminal, the hierarchical quantitative indicators are mapped to the service communities corresponding to each sales terminal, and the hierarchical quantitative indicators are aggregated at the community granularity to obtain the feature sub-vectors of the preset population of each community. The feature sub-vectors are combined according to a multi-level architecture to generate a community multi-level feature vector representing a preset population within the corresponding community. The community multi-level feature vector is then used as a community profile of the preset population.
4. The method according to claim 1, characterized in that, Constructing a community product association matrix between the aforementioned community profile and the demand for health-related consumer goods includes: Based on historical sales data from sales terminals, the community profiles are aligned and paired with the sales volume and demand vectors of health-related consumer goods within the corresponding time period, using community-time period as the unit, to form the training samples required for correlation analysis. Based on the training samples, a preset machine learning model is trained, and the parameters of the preset machine learning model are adjusted through a preset optimization algorithm to predict the historical demand of the community for various products, and a trained machine learning model is obtained. From the trained machine learning model, extract the community product association matrix that represents the relationship between community profile features and health-related consumer product features.
5. The method according to claim 1, characterized in that, The preset hybrid prediction model includes: The first processing channel is used to receive and process historical sales time-series data from the target sales terminal; The second processing channel is used to receive and process the community product association matrix; The third processing channel is used to extract the third encoded features of external risks and opportunities affecting health consumption from the feature vector constructed based on the preset regional health risk index. The feature fusion module is used to fuse the output features of the first processing channel, the second processing channel, and the third processing channel to generate the commodity demand prediction result.
6. The method according to claim 5, characterized in that, Based on the community product association matrix and historical sales data from sales terminals, a pre-defined hybrid prediction model is used to generate product demand prediction results, including: The historical sales data of the sales terminal is input into the first processing channel to extract the first coded features of the dynamic sales trend and cycle related to time. The community product association matrix is input into the second processing channel to extract the second encoding features of the static prior preferences of each community for various types of products; Based on the first encoding, the second encoding feature, and the third encoding feature, an attention fusion mechanism is used to dynamically evaluate the importance of each encoding feature, assign weights to each encoding feature, and generate fused features based on each feature encoding and its corresponding weights. Based on the fusion features, the feature fusion module generates a prediction of the demand for each product at the target sales terminal within a preset time period.
7. The method according to claim 6, characterized in that, When the predicted product is a product category associated with a predefined demographic, a product demand prediction result is generated using a predefined hybrid prediction model based on the community product association matrix and historical sales data from sales terminals. This also includes: Construct a mapping relationship between regional health risk indices and product categories associated with predefined population groups; An attention fusion mechanism is used to increase the weight of the third encoded feature; Based on the mapping relationship and the improved weights, the feature fusion module is used to generate product demand prediction results for the preset population.
8. The method according to claim 1, characterized in that, The method further includes: Based on the community profile, the product demand forecast results are analyzed for attribution, and a readable report is generated. The commodity demand forecast results and readability reports are sent to the corresponding supply chain management system to provide decision-making reference for the supply chain management system.
9. A sales terminal commodity demand forecasting device, characterized in that, The device includes: The community profile building module is used to acquire multi-source data from various sales terminals and build a community profile for each sales terminal based on the multi-source data. The community product association matrix construction module is used to construct a community product association matrix between the community profile and product demand; The commodity demand forecasting module is used to generate commodity demand forecasting results based on the community commodity association matrix and historical sales data of sales terminals using a preset hybrid forecasting model.
10. An electronic device, characterized in that, include: A memory and a processor are communicatively connected, the memory stores computer instructions, and the processor executes the sales terminal commodity demand forecasting method according to any one of claims 1 to 8 by executing the computer instructions.