Intelligent information sorting method and device based on user habit learning

By constructing a weighted priority graph and a topological sorting algorithm, the problems of personalization and consistency in information sorting technology are solved, achieving adaptive personalized information sorting, reducing manual adjustments by users, and improving the stability of sorting and system performance.

CN121579754AActive Publication Date: 2026-02-27XUNKANG INFORMATION TECH (SHENZHEN) CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202511734687.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-11-25
Publication Date
2026-02-27
Estimated Expiration
2045-11-25

AI Technical Summary

Technical Problem

Existing information sorting technologies lack personalized logic and cannot adapt to the personal habits and professional experience of different users, resulting in users needing to manually adjust the order of information and inconsistent sorting results.

Method used

By constructing a weighted priority graph, resolving habitual conflicts, performing connectivity analysis and topological sorting, generating personalized information sorting sequences, and using data cleaning and weight optimization algorithms to adaptively learn user preferences.

Benefits of technology

Personalized sorting logic was implemented, which improved the consistency and reliability of sorting results, reduced the workload of manual adjustments by users, and enhanced the robustness and adaptability of the system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121579754A_ABST
    Figure CN121579754A_ABST
Patent Text Reader

Abstract

The invention discloses an intelligent information sorting method and device based on user habit learning, and the method comprises the steps: obtaining a user historical information sorting record, carrying out the data cleaning and standardization processing, carrying out the statistics of the position relation of information item pairs based on the standardized historical sorting data, calculating the priority weight, and constructing a weighted priority graph; conflict detection is carried out on the weighted priority graph, a bidirectional priority relation is identified, conflict directions are resolved according to weights, and a consistency habit graph is generated; connectivity detection is carried out on the consistency habit graph, and weak connected components and isolated nodes are identified; processing each connected component by adopting a topological sorting algorithm to generate a linear sorting sequence conforming to user habits; and calculating a consistency index of the sorting sequence and historical data to obtain a model quality evaluation result. The problems that an existing information sorting technology is lack of individuation, cannot adapt to user habits and is large in repetitive workload are solved, and intelligent individualized information sorting is achieved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of information processing, in particular to an information intelligent sorting method and device based on user habit learning, and more particularly to a technical solution for automatically generating personalized sorting by extracting sorting preference patterns from user historical operations through machine learning technology. BACKGROUND

[0002] Information sorting technology is an important field in modern information technology, and its core goal is to arrange data items in order according to certain logic to improve the efficiency of users understanding and processing information. In information systems in various industries, it is often necessary to sort and arrange multiple data items according to certain rules so that users can quickly obtain key information.

[0003] At present, common methods of information sorting include fixed rule-based sorting methods and statistical rule-based sorting methods. Fixed rule-based sorting methods usually use pre-set sorting logic, such as arranging by item category, data entry time, or system default order; while statistical rule-based sorting methods analyze a large amount of user behavior data to extract common sorting rules.

[0004] Existing information sorting technology usually uses a single standard or fixed algorithm to organize and present information, and the system automatically generates information sorting according to pre-set rules, but this method cannot adapt to different users' personal habits and professional experience. When the relationship between information items is complex and users have specific preferences for sorting, the sorting logic generated by the system usually has a large difference from the user's expectations, resulting in users needing to spend a lot of time manually adjusting the order of information.

[0005] The existing technology has the following main problems: first, it lacks personalized sorting logic and cannot adapt to different users' personal habits and professional experience; second, users face the problem of heavy repetitive workload and need to manually adjust the order of information each time; third, the system lacks intelligent learning ability and cannot learn and accumulate experience from user's historical operations; fourth, the consistency and standardization of information sorting are insufficient, and the same user may have inconsistent sorting results for similar information items at different times.

[0006] Therefore, an intelligent information sorting technology is needed that can automatically learn sorting preferences from user historical operations, generate personalized sorting schemes, and reduce repetitive manual adjustment work. SUMMARY

[0007] The application aims at solving the technical problems of the prior information sorting technology, such as lack of personalization, incapability of adapting to user habits and large repetitive workload, and provides an information intelligent sorting method and device based on user habit learning, which realizes intelligent personalized information sorting through constructing a weighted priority graph, resolving habit conflicts, connectivity analysis and topological sorting generation.

[0008] To achieve the above object, the application adopts the following technical scheme:

[0009] The information intelligent sorting method based on user habit learning comprises the following steps: obtaining a plurality of historical information sorting records of a user, performing data cleaning and standardization processing on the historical information sorting records to obtain standardized historical sorting data; based on the standardized historical sorting data, the position relationship of each pair of information items in the historical sorting data is counted, the priority weight between each pair of information items is calculated, and a weighted priority graph is constructed; the weighted priority graph is subjected to conflict detection, the information item pairs with bidirectional priority relationship are identified, the conflict direction is resolved according to the weight size, and a consistent habit graph is generated; the consistent habit graph is subjected to connectivity detection, the weakly connected components and isolated nodes are identified, and a complete graph structure representation is obtained; the topological sorting algorithm is used to process each connected component in the complete graph structure representation, and a linear sorting sequence conforming to the user habits is generated; the consistency index of the linear sorting sequence and the historical sorting data is calculated, and a model quality evaluation result is obtained.

[0010] Further, the data cleaning and standardization processing on the historical information sorting records to obtain the standardized historical sorting data comprises: performing deduplication processing on the historical information sorting records, deleting the completely same sorting records, and obtaining the deduplicated sorting records; performing missing value detection on the deduplicated sorting records, identifying the records with missing information items or incomplete position information, and generating an effective record set; performing format unification processing on the identifiers and position indexes of each information item in the effective record set, and obtaining the standardized historical sorting data.

[0011] Further, the counting of the position relationship of each pair of information items in the historical sorting data and the calculation of the priority weight between each pair of information items to construct the weighted priority graph comprises: extracting all simultaneously appearing information item pairs from the standardized historical sorting data, generating a candidate information item pair set; counting the position difference and the order of each information item pair in each historical record in the candidate information item pair set, and obtaining position statistical data; based on the position statistical data, the priority weight of each information item pair is calculated by using an inverse distance function, and the weighted priority graph is constructed.

[0012] Further, the position relationship of each pair of information items in the historical ranking data is counted, the priority weight between each pair of information items is calculated, and a weighted priority graph is constructed, including: identifying, from the standardized historical ranking data, pairs of information items that repeatedly appear in multiple historical records to generate a repeated pair set; for each pair of information items in the repeated pair set, extracting the corresponding single weight value of each historical record to obtain a weight sequence; and performing cumulative aggregation processing on the weight sequence to construct the weighted priority graph.

[0013] Further, the weight sequence is cumulatively aggregated to construct the weighted priority graph, including: for each pair of information items in the repeated pair set, calculating a time decay weight according to the time of each occurrence to obtain a time weighting coefficient; based on the time weighting coefficient and the weight sequence, fusing each single weight using a weighted power average formula to obtain a fused weight value; calculating the ratio of the standard deviation to the mean of the weight sequence to obtain a weight confidence; adding the fused weight value and the weight confidence as edge attributes to the graph structure to generate enhanced edge data; and based on the enhanced edge data and the candidate information item pair set, constructing an adjacency list representation of the graph to construct the weighted priority graph.

[0014] Further, the weighted priority graph is subjected to conflict detection to identify pairs of information items with bidirectional priority relationships, and the conflict direction is resolved according to the weight size to generate a consistency habit graph, including: performing bidirectional edge detection on the weighted priority graph to identify pairs of information items with both positive and negative edges to generate a conflict pair list; for each conflict pair in the conflict pair list, comparing the size of the positive edge weight and the negative edge weight to determine the retained direction; and based on the retained direction, deleting edges in the direction with a weight lower than a preset threshold to generate the consistency habit graph.

[0015] Further, the consistency habit graph is subjected to connectivity detection to identify weakly connected components and isolated nodes to obtain a complete graph structure representation, including: initializing an access marker array for the consistency habit graph to generate a node access state table; based on the node access state table, traversing each node using a depth-first search algorithm to identify each weakly connected component; performing node statistics on each weakly connected component to identify components containing only a single node to generate an isolated node set; for each isolated node in the isolated node set, establishing a connection edge with a neighboring node according to the average position in the historical ranking data to generate a supplementary edge set; and adding the supplementary edge set to the consistency habit graph to obtain the complete graph structure representation.

[0016] Further, the priority weight of each information item pair is calculated by using a reverse distance function to construct the weighted priority graph, comprising: defining a loss function including a frequency item, a location consistency item and a regularization item based on the location statistical data, and establishing a weight optimization objective; based on the weight optimization objective, using a time weighting strategy to randomly extract a sample batch from the standardized historical ranking data to obtain current batch data; calculating the sub-gradient of the loss function with respect to the weight variable for the current batch data to obtain a sub-gradient estimate; based on the sub-gradient estimate, updating the weight variable by using a sub-gradient descent method, and constraining the weight to be non-negative by using a projection operator to obtain updated weight values; iteratively averaging the updated weight values to construct the weighted priority graph.

[0017] Further, the weight variable is updated by using a sub-gradient descent method, and the updated weight values are obtained by constraining the weight to be non-negative through a projection operator, comprising: initializing the first moment estimate variable and the second moment estimate variable of the sub-gradient estimate to establish the initial state of the moment estimate; based on the initial state of the moment estimate and the square of the sub-gradient estimate, updating the first moment estimate by using an exponential moving average method to obtain an updated first moment; based on the initial state of the moment estimate and the square of the sub-gradient estimate, updating the second moment estimate by using an exponential moving average method to obtain an updated second moment; bias correcting the updated first moment and the updated second moment to obtain corrected moment estimates; based on the corrected moment estimates, calculating the weight update step by using an adaptive learning rate formula, and projecting the updated weight to the feasible region by using a projection operator to obtain the updated weight values.

[0018] The application further provides an information intelligent sorting device based on user habit learning, comprising: a data acquisition module for obtaining a plurality of historical information sorting records of a specific user, performing data cleaning and standardization processing on the historical information sorting records to obtain standardized historical sorting data; a graph construction module for statistically analyzing the position relationship between each pair of information items in the historical sorting data based on the standardized historical sorting data, calculating the priority weight between each pair of information items, and constructing a weighted priority graph; a conflict resolution module for detecting conflicts in the weighted priority graph, identifying information item pairs with bidirectional priority relationships, resolving conflict directions according to weight sizes, and generating a consistency habit graph; a connectivity analysis module for detecting connectivity in the consistency habit graph, identifying weakly connected components and isolated nodes, and obtaining a complete graph structure representation; a sorting generation module for processing each connected component by using a topological sorting algorithm based on the complete graph structure representation to generate a linear sorting sequence consistent with user habits; and an evaluation module for calculating the consistency index of the linear sorting sequence with the historical sorting data to obtain a model quality evaluation result.

[0019] The beneficial effects of the present application are:

[0020] By constructing a weighted priority graph to automatically extract user ranking preference patterns, personalized ranking logic is realized, and the problem that existing technologies cannot adapt to different user habits is solved.

[0021] Through the conflict detection and resolution mechanism, stable core habit patterns are extracted from the ranking differences of users at different times, improving the consistency and reliability of the ranking results.

[0022] Through connectivity detection and topological sorting algorithm, the problem of isolated nodes caused by incomplete data can be handled, improving the robustness of the algorithm.

[0023] Through a multi-dimensional model quality evaluation system, the model performance is quantitatively evaluated to support continuous optimization and ensure that the ranking results meet user expectations.

[0024] Through the weight learning mechanism based on optimization theory, the weight calculation is improved from a simple formula to an adaptive learning process, significantly improving the weight precision and system performance. BRIEF DESCRIPTION OF DRAWINGS

[0025] In order to more clearly illustrate the technical solutions of the embodiments of the present disclosure, the following will briefly introduce the drawings needed to be used in the embodiments, the drawings herein are incorporated into the specification and form a part of the specification, which show the embodiments consistent with the present disclosure, and are used to illustrate the technical solutions of the present disclosure together with the specification. It should be understood that the following drawings only show certain embodiments of the present disclosure, and therefore should not be regarded as a limitation on the scope, and for those skilled in the art, other related drawings can also be obtained without creative labor on the basis of these drawings.

[0026] Figure 1 An information intelligent ranking model architecture diagram is provided for the embodiments of the present application.

[0027] Figure 2 A flowchart of a comprehensive energy system intelligent scheduling and control method is provided for the embodiments of the present application.

[0028] Figure 3 A comprehensive energy system intelligent scheduling and control device architecture diagram is provided for the embodiments of the present application. DETAILED DESCRIPTION

[0029] In order to make the objects, technical solutions and advantages of the embodiments of the present disclosure clearer, the following will clearly and completely describe the technical solutions in the embodiments of the present disclosure with reference to the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are only a part of the embodiments of the present disclosure and not all the embodiments. The components of the embodiments of the present disclosure generally described and shown in the drawings can be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of the present disclosure provided in the drawings is not intended to limit the scope of the claimed present disclosure, but only represents selected embodiments of the present disclosure. Based on the embodiments of the present disclosure, all other embodiments obtained by those skilled in the art without creative work fall within the scope of protection of the present disclosure.

[0030] It should be noted that: similar reference numerals and letters represent similar items in the following drawings, so once an item is defined in one drawing, it does not need to be further defined and explained in subsequent drawings.

[0031] The term "and / or" herein only describes an association relationship and means that there can be three relationships, for example, A and / or B can mean that A exists alone, A and B exist together, and B exists alone. In addition, the term "at least one" herein means any one of a plurality or any combination of at least two of a plurality, for example, including at least one of A, B and C can mean including any one or more elements selected from the set consisting of A, B and C.

[0032] In order to make the objects, technical solutions and advantages of the embodiments of the present disclosure clearer, the following will clearly and completely describe the technical solutions in the embodiments of the present disclosure with reference to the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are only a part of the embodiments of the present disclosure and not all the embodiments. The components of the embodiments of the present disclosure generally described and shown in the drawings can be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of the present disclosure provided in the drawings is not intended to limit the scope of the claimed present disclosure, but only represents selected embodiments of the present disclosure. Based on the embodiments of the present disclosure, all other embodiments obtained by those skilled in the art without creative work fall within the scope of protection of the present disclosure.

[0033] In order to make the objects, technical solutions and advantages of the embodiments of the present disclosure clearer, the following will clearly and completely describe the technical solutions in the embodiments of the present disclosure with reference to the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are only a part of the embodiments of the present disclosure and not all the embodiments. The components of the embodiments of the present disclosure generally described and shown in the drawings can be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of the present disclosure provided in the drawings is not intended to limit the scope of the claimed present disclosure, but only represents selected embodiments of the present disclosure. Based on the embodiments of the present disclosure, all other embodiments obtained by those skilled in the art without creative work fall within the scope of protection of the present disclosure.

[0034] The embodiments of the present application provide a kind of based on Figure 1 The information intelligent sorting model architecture shown in the figure, the technical scheme provided by the present application forms a complete closed loop system.The whole system is composed of six core function modules, two key data structures and a feedback optimization path, each part works together to realize the intelligent conversion from user historical data to personalized sorting result.

[0035] As shown in Figure 1As shown, the data flow of the system follows a clear top-down main process. First, the data collection module obtains the user's historical information ordering records from the information system, performs data cleaning, deduplication, and standardization processing, providing high-quality input data for subsequent processing. The processed standardized historical ordering data is passed to the graph construction module, which counts the positional relationship of each pair of information items in historical data and calculates priority weights. During the weight calculation process, the system can selectively enable the weight optimization submodule based on the Adam algorithm to improve the accuracy of weight calculation through adaptive learning rate and matrix estimation techniques. The output of the graph construction module is a weighted priority graph, which is a directed graph data structure where nodes represent information items and directed edges represent priority relationships, and the weight of the edge represents the strength of the relationship.

[0036] The weighted priority graph then enters the conflict resolution module for processing. Since users may exhibit inconsistent preferences for the same pair of information items at different times or in different contexts, there may be bidirectional edges in the graph, i.e., both A prioritizes B and B prioritizes A. The conflict resolution module identifies these conflicts through bidirectional edge detection and resolves them based on weight size, confidence, and other indicators, deleting the direction with smaller weights, generating a consistent habit graph without bidirectional edges. The resolved graph is passed to the connectivity analysis module, which uses the depth-first search algorithm to identify weakly connected components and isolated nodes in the graph and processes isolated nodes by adding edges to ensure the integrity and connectivity of the graph structure.

[0037] The complete graph structure is passed to the ordering generation module, which applies a topological sorting algorithm to each connected component. The topological sorting algorithm arranges the nodes in the graph into a linear sequence based on the priority constraints defined by the directed edges, ensuring that if there is an edge A→B, A must be arranged before B. For multiple connected components, the system merges them according to predefined rules (such as component size, average weight, etc.), and finally generates a complete linear ordering sequence, which is the personalized ordering result output by the system.

[0038] To ensure the quality of the ordering and support continuous improvement, the linear ordering sequence is sent to the evaluation module for quality evaluation. The evaluation module calculates multiple indicators, including coverage (the proportion of information items included in the ordering to the historical appearance items), violation rate (the proportion of conflicts between the ordering and historical records), satisfaction score, etc., to comprehensively evaluate the model performance. The evaluation results are not only reported as model quality output, but also passed back to the graph construction module and conflict resolution module through the feedback optimization path (shown by the dashed arrows in the figure). Based on the evaluation feedback, the system can dynamically adjust the weight calculation parameters, conflict resolution strategies, etc., to achieve self-optimization and performance improvement of the model. This closed-loop feedback mechanism enables the system to continuously evolve with data accumulation and user habit changes, maintaining long-term high performance.

[0039] The entire architecture design embodies the characteristics of modularity, scalability and adaptability. The modules are connected through standardized data interfaces, with clear functional boundaries, facilitating independent development, testing and maintenance. The weight optimization submodule is identified by a dashed box, indicating that it is an optional enhancement component. The base system can use a simple inverse distance formula to calculate the weight, and when higher precision is needed, the optimization algorithm can be enabled. The introduction of the feedback optimization path enables the system to have self-learning ability, automatically adjusting parameters according to actual running results, reducing manual intervention. This design not only improves the intelligence level of the system, but also enhances its adaptability and robustness in different application scenarios.

[0040] Embodiment 1

[0041] As Figure 2 shown, the embodiment provides an information intelligent sorting method based on user habit learning, including the following steps:

[0042] S1 obtains a plurality of historical information sorting records of a user, performs data cleaning and standardization processing on the historical information sorting records, and obtains standardized historical sorting data;

[0043] S2, based on the standardized historical sorting data, statistics the position relationship of each pair of information items in the historical sorting data, calculates the priority weight between each pair of information items, and constructs a weighted priority graph;

[0044] S3, the conflict detection is performed on the weighted priority graph, the information item pairs with bidirectional priority relationship are identified, the conflict direction is eliminated according to the weight size, and a consistency habit graph is generated;

[0045] S4, the connectivity detection is performed on the consistency habit graph, the weakly connected components and isolated nodes are identified, and a complete graph structure representation is obtained;

[0046] S5, a topological sorting algorithm is used to process each connected component in the complete graph structure representation, and a linear sorting sequence conforming to the user habit is generated;

[0047] S6, the consistency index of the linear sorting sequence and the historical sorting data is calculated, and a model quality evaluation result is obtained.

[0048] Specifically, the core goal of step S1 is to extract valuable sorting information from the original user operation records, and through systematic cleaning and standardization processing, to lay a reliable data foundation for subsequent habit learning. In actual application scenarios, the user's historical information sorting records are usually stored scattered in the operation logs, database transaction records or user behavior tracking systems of the information system. These original data often contain a large amount of noise, repeated records and inconsistent formats.

[0049] First, the system extracts all ranking operation records of a specific user within a certain time window (e.g., the last 3-6 months) from the backend database. Each record typically contains multiple key fields: the ranking item list records the user's final determined information item order, the timestamp identifies the specific moment when the ranking operation occurred, the user identification ensures the accuracy of data attribution, and the operation context may contain business scenario information at the time of ranking. The amount of data in these original records can be quite substantial, possibly reaching hundreds or even thousands of records for active users.

[0050] After obtaining the original data, the system performs a deduplication process as the first data cleaning procedure. The judgment standard for deduplication is to compare the complete content and order of the ranking item list. If the sorting item sets of two records are completely the same and the order is consistent, it is considered as a duplicate record. This duplication may be caused by user's misoperation, system's repeated records or redundancy in data synchronization process. Deduplication not only reduces data redundancy, but more importantly, avoids some ranking patterns from being over-strengthened due to duplicate records, leading to deviation in habit learning. In the deduplication process, the system will keep the record with the latest timestamp, as it better reflects the user's current true preference.

[0051] Next, missing value detection and integrity verification are performed. The system checks whether the necessary fields of each record are complete, paying special attention to whether there are null values, undefined item identifiers or missing position indexes in the ranking item list. For records with too few information items (e.g., less than 3), the system will filter them out, as such records contain too sparse ranking relationship information and cannot provide sufficient reference value for habit learning. In addition, the system also verifies the continuity and uniqueness of the position index to ensure that each information item has a clear and unique position in the ranking.

[0052] Data standardization processing is one of the most critical steps in this step. Since users may use different terms to refer to the same information item at different times or in different scenarios, such as "Project A", "A Project", "prjA" or "ProjectA" may actually refer to the same business object, the system needs to establish a term mapping table to unify these variants. The standardization process includes: converting all information item identifiers to a unified naming specification, eliminating case differences, handling synonyms and abbreviations, and solving coding format inconsistencies. This process may need to combine business knowledge base or natural language processing technology to achieve intelligent matching.

[0053] The standardization of position indices is equally important. Position information in original records can be represented differently, such as counting from 0 or from 1, or using alphabetical sequences (A, B, C, etc.). The system uniformly converts all position indices into a continuous integer sequence starting from 1, ensuring consistent reference frames for subsequent position relationship calculations. For special cases involving parallel positions (e.g., two items sharing the same priority), the system processes them according to predefined rules, assigning each item a unique sequence number.

[0054] After the above processing, the system generates a standardized historical ranking dataset. This dataset has a uniform data structure, with each record containing: standardized user ID, normalized timestamp (uniformly in UTC time zone), standardized information item ID list, continuous position index sequence, and optional metadata fields (such as operation scenario, device type, etc.). This cleaned dataset not only eliminates noise and inconsistencies in the original data, but also provides high-quality input for subsequent statistical analysis and pattern recognition, ensuring the accuracy and reliability of habit learning.

[0055] The core task of step S2 is to transform the user's historical ranking records into a weighted directed graph structure, which can systematically represent the preference intensity of users between different information items. This transformation process is not just a simple data structure transformation, but a knowledge extraction process that extracts continuous preference metrics from discrete ranking instances and constructs a global priority network from local pairwise relationships.

[0056] First, the system extracts all possible information item pair relationships from the standardized historical ranking data. For each ranking record containing n information items, theoretically, there are

[0057] unordered item pairs, but considering directionality, there are actually n(n-1) ordered item pairs. The system iterates through each record and, for any two information items i and j, if i appears before j in the ranking (i.e., pos(i) < pos(j)), a directed edge from i to j is established, denoted as i→j. This extraction process generates a candidate information item pair set, which contains all priority relationship instances exhibited by the user in all historical records.

[0058] Next, the system performs a detailed positional statistical analysis on each candidate information item pair. For information item pair (i,j), the system records its specific performance in each historical record: the positional difference d = |pos(i) - pos(j)| reflects the distance between the two items in the ranking, and this distance value implies the strength of the priority relationship—generally, the closer the distance, the more sensitive the user is to the relative position of the two items, and the clearer the priority relationship; the direction indicator records whether i precedes j, and the statistical distribution of this Boolean value reflects the consistency of user preferences. The system establishes a detailed statistical profile for each information item pair, including its positional difference sequence in all relevant records, the proportion of directional consistency, and the number of times they co-occur.

[0059] Weight calculation is the core technical step in this process. The most basic weight calculation strategy is the inverse distance function, whose basic idea is: the smaller the positional distance, the stronger the priority relationship, and the larger the weight should be. The specific formula is as follows: Where d is the location distance and p is an adjustable exponential parameter. When p=1, the weight is inversely proportional to the distance, which is suitable for linear decay scenarios; when p=2, the weight is inversely proportional to the square of the distance, which more strongly penalizes distant relationships, suitable for scenarios emphasizing local priority. For example, if information item A is at position 2 and information item B is at position 5, then the distance d=3. With p=1, the weight is 1 / 3≈0.333, and with p=2, the weight is 1 / 9≈0.111. The system can also use other weight strategies, such as exponential decay weight w =exp(-λd), where λ is the decay rate. This strategy decays faster when the distance is large and can effectively filter weak correlations.

[0060] For pairs of information items that appear repeatedly in multiple historical records, the system needs to aggregate the weights of multiple observations to obtain a comprehensive priority strength assessment. The simplest aggregation strategy is direct summation. The advantage of this method is its simplicity and intuitiveness; the more times a value appears and the larger its weight in a single instance, the greater the final weight. However, this method has significant limitations: it is sensitive to outliers, and an error in a weight calculation can severely affect the result; it assumes that all historical records are equally important, ignoring the factor of temporal evolution; and it uses linear accumulation, failing to capture the nonlinear interaction effects that may exist between weights.

[0061] To overcome the limitation of simple accumulation, the system can introduce more sophisticated aggregation mechanisms. Time-weighted aggregation takes into account the temporal evolution of user habits, assigning a time decay coefficient a to each observation. Recent records get higher weight coefficients, ensuring that the model can track the latest changes in user habits. Weighted power averaging provides a more flexible aggregation method, allowing different aggregation effects by adjusting the power parameter p - p = 1 corresponds to weighted arithmetic mean, p = 2 corresponds to weighted RMS, p → ∞ approaches the maximum value, and p → -∞ approaches the minimum value.

[0062] In addition to the fusion weight value, the system also calculates the weight confidence to quantify the reliability of the priority relationship. Confidence is defined as , where σ is the standard deviation of the weight sequence, μ is the mean, and ε is a small constant to prevent division by zero. If a certain information item has very stable weight values in different records (small standard deviation), the confidence is high, indicating that the user's preference for this priority relationship is consistent; otherwise, if the weight values fluctuate greatly, the confidence is low, indicating that the user's preference may be unstable or ambiguous. Confidence information has important reference value in subsequent conflict resolution and ranking generation.

[0063] Finally, the system organizes all the calculated weights and confidences into a data structure of a weighted directed graph. The nodes in the graph represent information items, and the directed edges represent priority relationships, with each edge attached to two attributes: the weight value represents the strength of the priority relationship, and the confidence represents the reliability of the relationship. The storage of the graph uses the adjacency list representation method, and each node maintains an out-edge list, with each element in the list being a three-tuple (target node, weight, confidence). This data structure can efficiently support graph traversal operations and flexibly store rich edge attribute information, providing a solid foundation for subsequent conflict detection and topological sorting.

[0064] The core problem to be solved in step S3 is the inherent contradiction of user habits. In real application scenarios, users may exhibit inconsistent or even opposite preferences for the same pair of information items at different times or in different contexts. This phenomenon is manifested in the weighted priority graph as the existence of bidirectional edges - there are edges from A to B and from B to A. If these conflicting relationships are not handled, they will cause the topological sorting algorithm to fail to execute (because there are loops), and more importantly, they reflect the uncertainty and complexity of user habits, which need to be identified and resolved through scientific methods.

[0065] The first step of conflict detection is to systematically scan the weighted preference graph and identify all pairs of information items that have bidirectional preference relations. The system traverses each edge (A, B) in the graph and checks if the reverse edge (B, A) also exists in the graph. This checking process can be efficiently implemented by maintaining a hash table of edges with time complexity O(E), where E is the number of edges. For each detected bidirectional edge pair, the system records the complete information of both directions: the weight WAB and the confidence confAB of the forward edge, the weight WBA and the confidence confBA of the reverse edge, as well as the number of historical records and the time distribution involved in each of the two edges. These information constitutes the detailed profile of the conflict pair, which provides the basis for subsequent resolution strategies.

[0066] Conflict analysis is a key step to understand the complexity of user habits. The system conducts in-depth analysis on each conflict pair, trying to understand the reasons for the conflict. Time distribution analysis checks the distribution pattern of the preference relations in the time axis of both directions: if A→B mainly appears in early records, while B→A mainly appears in recent records, it may indicate that the user's habits have changed; if the records of both directions appear alternately in time, it may suggest that the user's preference is influenced by situational factors, with different choices in different scenarios. Weight difference analysis compares the weight intensity of both directions: if |WAB - WBA| is large, it means that the user has a clear preference for a certain direction, and the conflict may be caused by a few abnormal records; if the weights of both directions are close, it means that the user's preference is indeed uncertain, and needs more careful handling.

[0067] The choice of conflict resolution strategy directly affects the quality of the consistent habit graph generated. The maximum weight strategy is the most intuitive method: compare WAB and WBA, keep the direction with the larger weight, and delete the direction with the smaller weight. The logic of this strategy is that the direction with the larger weight represents the user's stronger or more frequent preference, which should be considered as the dominant direction. For example, if WAB = 2.5 and WBA = 0.8, keep A→B and delete B→A. The net weight strategy goes further, calculates the net weight Wnet = WAB - WBA, if Wnet > 0, keep A→B and update its weight to Wnet; if Wnet < 0, keep B→A and update its weight to |Wnet|. This strategy not only determines the direction, but also adjusts the weight value to reflect the relative intensity difference of the two directions.

[0068] In practical applications, the system also sets a weight difference threshold Δthreshold to handle boundary cases. If |WAB - WBA| < Δthreshold, it means that the weights of the two directions are very close, and the user's preference is highly uncertain. For such cases, the system can take several strategies: completely deleting both edges to avoid introducing unreliable priority relationships; retaining the edge with the larger weight but reducing its confidence to reflect its uncertainty; or introducing third-party information (such as business rules or domain knowledge) to assist decision-making. The threshold setting needs to be tuned according to the specific application scenario, with typical values between 0.1 and 0.5.

[0069] Confidence information plays an important role in conflict resolution. Even if WAB > WBA, if confAB is much smaller than confBA, it means that the direction A→B, although large in weight, is low in reliability (possibly caused by a few extreme records), while B→A, although small in weight, is more stable and reliable. In this case, the system can calculate the comprehensive score:

[0070] (where β is a balance parameter, such as 0.5), and decide which direction to retain based on the comprehensive score rather than just the weight. This method can achieve a better balance between strength and reliability, generating a more robust and consistent habit graph.

[0071] The result of conflict resolution is to generate a consistent habit graph, which is a directed graph without bidirectional edges. In this graph, there is at most one edge between each pair of information items, and the direction of the edge represents the user's dominant preference direction after conflict resolution, while the weight of the edge reflects the strength of this preference. The system will generate a detailed conflict resolution report, recording the total number of conflicts, the resolution strategy and its basis for each conflict pair, and the deleted edge information, etc. These information not only helps to understand the complexity of user habits, but also provides valuable feedback for the continuous optimization of the model.

[0072] The goal of step S4 is to analyze the topological structure of the consistent habit graph and identify the connected components and isolated nodes in the graph, in preparation for subsequent topological sorting. This step, although seemingly an application of pure graph theory algorithms, actually contains a deep understanding of the completeness of user habits and data coverage. An ideal habit graph should be strongly connected or at least weakly connected, meaning that there are direct or indirect priority relationships between all information items. However, in practical applications, due to incomplete data, randomness of user operations, or independence of information items, there are often multiple unconnected connected components or even isolated nodes in the graph.

[0073] The first step of connectivity detection is to initialize necessary data structures. The system creates an array visited[] of the same length as the total number of nodes in the graph, initially all set to false. This array is used to mark which nodes have been visited during graph traversal, to avoid repeated visits and infinite loops. Meanwhile, the system prepares a list to store the identified connected components, each represented by a set of nodes.

[0074] Depth-First Search (DFS) is the core algorithm to identify connected components. The system starts from the first unvisited node and performs DFS traversal. During traversal, the system not only visits successor nodes reachable through outgoing edges of the current node, but also visits predecessor nodes reachable through incoming edges, because we are interested in weakly connected components (ignoring edge directionality, as long as there is a path between nodes). Specifically, for the current node v, the system recursively visits all nodes u that satisfy the following conditions: (1) there is an edge v→u, or (2) there is an edge u→v, and (3) u has not been visited yet. Each visited node is marked as visited[u]=true and added to the set of nodes that are currently being built into a connected component.

[0075] When a DFS traversal is completed, the system finishes the identification of one connected component. This connected component contains all nodes reachable from the starting node through directed edges (ignoring directionality). The system saves this connected component into the result list and continues to find the next unvisited node as a new starting point for the next round of DFS. This process repeats until all nodes are visited. Finally, the system obtains a list of connected components, each represented by a set of nodes, and different components are not connected by edges.

[0076] The analysis of connected components provides important insights into the structure of user habits. Large connected components (containing a large number of nodes) usually correspond to groups of information items that users often operate together, with close associations between these items, and rich priority relationships among them, with users having a clear cognitive order of their relative order. Small connected components may represent relatively independent subsets of information items that are rarely present together in user operations, thus lacking priority relationships across groups. The system will count the size (number of nodes), internal edge density (actual edge number divided by possible edge number), average weight, etc. of each connected component, which helps to understand the modular structure of user habits.

[0077] The identification of isolated nodes is a special case of connected component analysis. Isolated nodes are those nodes that have neither outgoing nor incoming edges, and they form connected components that contain only a single node. The existence of isolated nodes usually has several reasons: the information item rarely appears in the user's history, resulting in insufficient priority relationships; the information item always appears alone and never simultaneously with other items in the ranking; in the conflict resolution process, all edges of the node are deleted. The system collects all isolated nodes into a special set for special processing.

[0078] The handling of isolated nodes is a key technical challenge of this step. If isolated nodes are simply ignored, they will not appear in the final ranking result, which is obviously not in line with user expectations. The system uses a connection strategy based on historical position statistics to handle isolated nodes. For each isolated node, the system traces back to the original historical ranking data and calculates the average position of the node in all records containing it. For example, if node C appears in positions 2, 3, 3, 4, and 5 in 5 records, the average position is (2+3+3+4+5) / 5=3.4. Then, the system finds other nodes with similar average positions in the consistency habit graph and establishes connection edges.

[0079] The specific connection strategy is: for an isolated node C with an average position p, the system finds nodes with average positions in the interval [p-1, p] as predecessors and establishes edges predecessor→C; finds nodes with average positions in the interval [p, p+1] as successors and establishes edges C→successor. The weight of the edge is calculated according to the position distance, and the closer the distance, the greater the weight. If no suitable node is found in the specified interval, the system will gradually expand the search range until at least one predecessor and one successor are found, or the maximum search radius is reached. This method ensures that isolated nodes can be reasonably inserted into the ranking sequence, and their positions are consistent with the statistical rules in historical data.

[0080] The generation of supplementary edges needs to be handled carefully to avoid introducing unreliable priority relationships. The system calculates a lower confidence value (such as 0.3-0.5) for each supplementary edge, reflecting that these edges are based on statistical inference rather than direct observation. The weight calculation adopts a conservative strategy, usually setting a small value to ensure that supplementary edges do not excessively affect the ranking result. The system also checks whether the supplementary edge will create new conflicts with existing edges, and if so, adjusts the direction or weight of the supplementary edge to ensure the consistency of the graph.

[0081] After the isolated nodes are handled, the system gets a complete graph structure representation. This graph has better connectivity, most or even all nodes are connected to the main connected component. The system re-executes the connectivity detection to verify whether the isolated nodes are successfully connected, and counts the number of changes in the connected components. The final graph structure not only preserves the explicit priority relations in the user habits, but also supplements the missing relations through reasonable inference, laying the foundation for generating a complete and coherent ranking sequence.

[0082] Step S5 is the core output link of the entire method, and its task is to convert the priority relation network represented by the graph structure into a linear ranking sequence. This sequence not only needs to meet all the priority constraints (i.e. if there is an edge A→B, then A must be ranked before B), but also needs to conform to the user's overall habit pattern as much as possible. Topological sorting algorithms provide the theoretical basis for achieving this goal, but in practical applications, complex problems such as multiple connected components, tie breaking, and loop detection need to be handled.

[0083] The first step of topological sorting is to calculate the in-degree of each node, which is the number of edges pointing to the node. The in-degree reflects how many other nodes a node is "dependent on" or "constrained by". The system traverses all edges in the graph, and for each edge (u, v), it increments the in-degree counter of node v by 1. At the initialization, all nodes have an in-degree of 0, and after the traversal, each node has an accurate in-degree value. Nodes with an in-degree of 0 are particularly important, as they have no predecessor nodes and are not subject to any priority constraints, and can be used as starting points for sorting. These nodes represent the "most priority" information items in the user's habits, and they should usually be placed at the front of the sequence.

[0084] The system adds all nodes with an in-degree of 0 to a candidate queue. This queue maintains a set of nodes that can be safely added to the sorting result. The meaning of "safe" is that adding these nodes to the result does not violate any priority constraints, because all their predecessor nodes (if any) have already been added to the result. In the initial stage of the algorithm, the candidate queue contains all nodes with an in-degree of 0; as the algorithm progresses, more nodes will have their in-degree become 0 because their predecessors are processed, and thus join the candidate queue.

[0085] Tie-breaking is a crucial decision point in topological sorting. When there are multiple nodes in the candidate queue, the algorithm needs to select one to join the sorting result, and this choice affects the specific form of the final sequence. Although all possible choices can produce an effective topological sort that satisfies priority constraints, different choices will lead to differences in the "quality" of the sequence. The system provides several tie-breaking strategies for selection: the alphabetical order strategy selects the node with the smallest node identifier in lexicographical order. This strategy ensures the determinism and repeatability of the sorting result, but may not conform to the user's actual preferences; the out-degree priority strategy selects the node with the largest out-degree, i.e., the node with the most successor nodes. This strategy tends to process nodes with a large "influence range" first, which helps to release more nodes faster; the weight priority strategy calculates the total out-edge weight of each candidate node and selects the node with the largest weight sum. This strategy most directly reflects the strength of the user's preferences and usually produces a sorting that best suits the user's habits.

[0086] The algorithm's main loop is an iterative process. In each iteration, the system selects a node (current) from the candidate queue according to the tie-breaking strategy. node This is added to the end of the results list. Then, the system updates the current... node In-degree of all successor nodes: for each outgoing edge current node →successor, decrement the in-degree of successor by 1, because current node The node has already been processed and no longer constrains the successor. If the in-degree of a successor node becomes 0 after the update, it means that all its predecessors have been processed and it can be safely added to the sorting; the system adds it to the candidate queue. This process is repeated continuously, processing one node at a time, until the candidate queue is empty.

[0087] Verifying the correctness of the algorithm is essential. When the candidate queue is empty, the system checks whether the length of the result list is equal to the total number of nodes in the graph. If they are equal, it means that all nodes have been successfully sorted, and the algorithm terminates normally; if they are not equal, it means that there are still nodes that have not been processed, which can only happen if there is a cycle in the graph. The existence of a cycle means that there is a set of nodes that depend on each other to form a closed loop, and no node's in-degree can be reduced to 0. Although all bidirectional edges should have been eliminated in the conflict resolution in step S3, cycle detection is still required because there may be cycles with a length greater than 2 (such as A→B→C→A).

[0088] The loop handling strategy depends on the specific application requirements. A conservative strategy is to report an error and require human intervention, allowing the user to check the data or adjust the conflict resolution parameters; an aggressive strategy is to automatically break the loop by deleting the edge with the smallest weight in the cycle to eliminate the circular dependency, and then re-executing the topological sorting. The system records detailed information about the loop, including the nodes and edges included in the loop, the weights and confidence levels, which helps to understand the reasons for the loop, which may be due to the user's habit of actually having a circular preference, or due to data noise or incomplete conflict resolution.

[0089] For a graph containing multiple connected components, the system needs to perform topological sorting on each component separately and then merge the results. The merging strategy can be based on multiple criteria: descending order of component size, with larger components (containing more nodes) placed first, which conforms to the intuition of "important first"; ordering by the average weight of the component, with high-weight components placed first, reflecting the user's overall preference strength; ordering by the average position of nodes in the component in historical data, with components with higher positions placed first, maintaining consistency with historical habits. The system can combine multiple criteria to calculate a comprehensive score to determine the order of components.

[0090] The final linear ordering sequence is an ordered list of information items that satisfies all the priority constraints extracted from the consistency habit graph and reflects the user's overall preference pattern through the tie-breaking strategy and component merging strategy. This sequence can be directly applied in information systems as the user's default sorting scheme, reducing the user's manual adjustment workload. The position of each information item in the sequence has a clear basis that can be traced back to specific historical records and priority relationships, ensuring the interpretability and credibility of the sorting results.

[0091] The core goal of step S6 is to quantitatively evaluate the quality of the generated personalized sorting model, identify the strengths and weaknesses of the model, and continuously improve the model performance through a systematic optimization process. This step not only verifies all the previous steps, but also is the key link to form a closed-loop feedback mechanism, ensuring that the system can evolve with data accumulation and user habit changes.

[0092] Coverage is the primary indicator of model completeness. The system counts all different information items that have appeared in the user's history, forming a complete set of information items U. Then it examines the generated ranking sequence and counts the number of information items it contains, forming a set of ranked items S. Coverage is defined as |S| / |U|, i.e. the proportion of information items covered by the ranking sequence out of all information items that have appeared in the history. High coverage (e.g. 90% or above) indicates that the model can handle most of the information items that the user commonly uses, and has good completeness; low coverage may imply a data sparsity problem, where some information items cannot be included in the model because they appear too infrequently or always in isolation. The system lists the uncovered information items in detail, and analyzes their characteristics, providing a basis for improving data collection or model algorithms.

[0093] Violation count is the core indicator of model accuracy. The system reiterates through all of the user's history ranking records, and for each pair of information items (i, j) in each record, it checks their relative position in the generated ranking sequence. If i comes before j in the history record (pos_history(i) < pos_history(j)), but j comes before i in the generated sequence (pos_generated(j) < pos_generated(i)), it counts as one violation. The system accumulates the violation count for all records, and calculates the violation rate: the violation count divided by the total number of information item pair comparisons. A low violation rate (e.g. 10% or below) indicates that the generated ranking is highly consistent with the user's historical habits, and the model accurately captures the user's preferences; a high violation rate indicates that the model has systematic bias, which may be due to inaccurate weight calculation, inappropriate conflict resolution strategy, or unreasonable tie-breaking strategy for topological ranking.

[0094] Satisfaction score provides a comprehensive quality measure. The simplest definition is satisfaction = 1 - violation rate, which directly links satisfaction to accuracy. A more complex definition can introduce a weighting mechanism, giving different penalty weights to different types of violation: if the violation is of a high-weight edge (a priority relationship that the user strongly prefers), the penalty should be heavier; if the violation is of a low-confidence edge (a relationship whose preference is unstable), the penalty can be lighter. The system can also calculate the severity of positional deviation: if i and j are adjacent in the history, but far apart in the generated sequence, this is more serious than if they just switch positions. By considering the number, type, and severity of violations comprehensively, the system calculates a satisfaction score between 0 and 100, which intuitively reflects the model quality.

[0095] Conflict analysis provides insight into the internal contradictions of the model. The system reviews all conflict pairs identified in step S3, counts the total number of conflicts, the proportion of conflict pairs among all information item pairs, and the distribution of weight differences of conflicts, etc. A high conflict rate (e.g., more than 30%) may indicate that the user's habits are inherently unstable or that there is a lot of noise in the data; a low conflict rate indicates that the user's habits are relatively consistent. The system also analyzes the effect of conflict resolution: for each resolved conflict pair, check if the retained direction is consistent with the majority of historical records, and calculate the accuracy of the resolution strategy. If the resolution accuracy is low, it may indicate that the current resolution strategy (e.g., the maximum weight strategy) is not suitable for this user, and other strategies (e.g., the net weight strategy or the confidence-weighted strategy) need to be tried.

[0096] Temporal consistency analysis evaluates the model's ability to adapt to the evolution of user habits. The system divides the historical records into multiple time windows, such as the last month, 1-3 months ago, 3-6 months ago, etc. For each time window, calculate the consistency indicators (violation rate, satisfaction, etc.) between the generated ranking and the records in that window. Ideally, the model should have the highest consistency with recent records and gradually lower consistency with earlier records, indicating that the model successfully captures the user's latest preferences. If the model has low consistency with all time windows, it indicates that the overall quality of the model is poor; if it has high consistency with early records but low consistency with recent records, it indicates that the model overfits old data and fails to track habit changes, and the time decay mechanism needs to be enhanced.

[0097] Based on the evaluation results, the system generates a detailed quality evaluation report. The report uses a structured format and includes the following parts: an executive summary provides key indicators and overall ratings (excellent / good / average / poor); detailed indicators list all calculated indicators and their specific values, accompanied by visual charts (such as violation rate time trend graphs, conflict distribution histograms, etc.); problem diagnosis identifies the main problems of the model, such as "coverage is low, 15% of information items are not included", "violation rate with recent records reaches 20%, time adaptability is insufficient", etc.; optimization suggestions provide specific improvement directions based on the diagnosis results, such as "suggest reducing the time decay constant to enhance the weight of recent data", "suggest using a confidence-weighted conflict resolution strategy", etc.

[0098] Optimization execution is a key step to translate evaluation feedback into model improvement. The system adjusts relevant algorithm parameters or strategy selection based on optimization suggestions. Parameter optimization includes: adjusting the exponential parameter p of inverse distance weighting, if the accuracy of local priority relationships (adjacent items) is insufficient, increase the value of p to strengthen the proximity relationship; adjusting the time decay constant T decay , if the temporal consistency analysis shows that the model is not adaptive enough to recent data, reduce T decayTo enhance the time decay effect, adjust the weight difference threshold for conflict resolution. If conflict analysis shows that a large number of boundary conflicts are resolved incorrectly, increase the threshold to adopt a more conservative resolution strategy. Strategy optimization includes: switching the weight aggregation method from simple accumulation to time-weighted power average; switching the conflict resolution strategy from the maximum weight to the net weight or confidence weight; switching the tie-breaking strategy for topological sorting from alphabetical order to weight priority.

[0099] Optimization effect verification is a necessary step to ensure the effectiveness of improvement. The system uses the optimized parameters and strategies to re-execute steps S1 to S5, generates a new ranking sequence, and then re-calculates all evaluation indicators. By comparing the changes in indicators before and after optimization, the system can quantify the effect of optimization: if the violation rate decreases from 20% to 12% and the satisfaction score increases from 80 to 88, the optimization is successful; if some indicators improve but others worsen, a trade-off analysis is needed, and a multi-objective optimization method may be needed to find a balance point; if all indicators do not improve significantly or even worsen, the optimization direction may be incorrect, and the problem needs to be re-diagnosed or other optimization strategies need to be tried.

[0100] The continuous optimization mechanism ensures that the model can maintain high quality for a long time. The system establishes a regular evaluation plan, such as automatically performing quality evaluation every week or every month, to monitor the trend of model performance changes. When a significant performance decline is detected (such as a decrease in satisfaction score of more than 5 points), the optimization process is automatically triggered. The system also supports incremental learning, which incorporates new data into the training set after the user generates new ranking operations, and quickly adapts to changes in user habits by incrementally updating weights and re-executing conflict resolution, without the need to rebuild the entire model from scratch. Through this closed-loop evaluation-optimization-verification mechanism, the system can continuously improve the quality of personalized ranking, providing users with increasingly accurate and increasingly habit-compliant intelligent ranking services.

[0101] Specifically, S1 includes the following sub-steps:

[0102] S1.1: Extract the user's historical ranking records from the system backend database, including the ranking item list, ranking timestamp, user identification, and other information. For example, extract all ranking operation records of the user in the past 6 months from the operation log of the information management system, each record contains information item ID list, operation time, user ID, and other fields.

[0103] S1.2: De-duplicate the historical information ranking records, delete the completely same ranking records, and get the de-duplicated ranking records. By comparing the content and order of the ranking item list, identify and delete duplicate records, avoid the same operation being counted repeatedly.

[0104] S1.3: Detect missing values in the de-duplicated sorted records, identify records with missing information items or incomplete location information, and generate a set of valid records. Check the completeness of each record, and delete records with less than 3 information items to ensure that there are enough sorting relationships available for learning.

[0105] S1.4: Format the identifiers and location indices of each information item in the set of valid records uniformly, and obtain the standardized historical sorting data. Standardize the information item names to solve problems such as synonyms and abbreviations, for example, unify "Project A", "A Project", and "prjA" into the standard identifier "ProjectA" to ensure term consistency.

[0106] After the above processing, the cleaned standardized historical sorting data set is obtained as the input for subsequent steps.

[0107] Specifically, S2 includes the following sub-steps:

[0108] S2.1: Extract all pairs of information items that appear simultaneously from the standardized historical sorting data, and generate a set of candidate information item pairs. Traverse each historical record, and for any two information items i and j in the record, if i appears before j, establish a directed edge i→j, and add the edge to the candidate set.

[0109] S2.2: Statistically analyze the position difference and order of each information item pair in the set of candidate information item pairs in each historical record, and obtain position statistical data. For an information item pair (i, j), record its position difference d = |pos(i) - pos(j)| and direction indication (whether i is before j).

[0110] S2.3: Based on the position statistical data, calculate the priority weight of each information item pair using the inverse distance function, and construct the weighted priority graph. Use the inverse distance weight formula , where d is the position distance and p is the exponential parameter (typical values are p = 1 or p = 2). For example, if information item A is located at position 2 and information item B is located at position 5 in a record, the distance d = 3 and the weight wAB = 1 / 3 = 0.333.

[0111] S2.4: Identify pairs of information items that repeatedly appear in multiple historical records from the standardized historical sorting data, and generate a set of repeated item pairs. Scan all historical records, count the number of occurrences of each information item pair, and mark the item pairs with a number of occurrences greater than 1 as repeated item pairs.

[0112] S2.5: For each information item pair in the set of repeated pairs, extract the corresponding single-time weight values in the historical records, and obtain a weight sequence. For example, information item pair (A, B) appears in 5 records, and the corresponding weight sequence is {0.333, 0.5, 0.25, 0.4, 0.2}.

[0113] S2.6: Perform cumulative aggregation processing on the weight sequence to construct the weighted priority graph. Using a simple cumulative strategy, add all values in the weight sequence to obtain the maximum weight .

[0114] For the above example, the maximum weight is 0.333+0.5+0.25+0.4+0.2=1.683.

[0115] S2.7: Based on the calculated weight values, construct an adjacency list representation of the weighted directed graph. The nodes in the graph represent information items, the directed edges represent priority relationships, and the edge weights represent priority intensities. Each node in the adjacency list stores all its outgoing edge target nodes and corresponding weights.

[0116] After the above processing, the complete weighted priority network structure is obtained, reflecting the user's personalized ordering preferences.

[0117] Embodiment 2

[0118] This embodiment is based on Embodiment 1, and enhances the weight aggregation processing of step S2.6, specifically including the following sub-steps:

[0119] S2.6.1: For each information item pair in the set of repeated pairs, calculate a time decay weight according to the time of each occurrence, and obtain a time weighting coefficient.

[0120] Define the time decay function , where is the current time, is the time of the th record, and is the decay time constant (e.g. 30 days). Recent records have higher weight coefficients, reflecting the time evolution characteristics of user habits.

[0121] S2.6.2: Based on the time weighting coefficient and the weight sequence, use the weighted power average formula to fuse each single-time weight to obtain a fused weight value.

[0122] Use the weighted power average formula: , where is the power parameter. When , it is the weighted arithmetic mean, , and when , it is the weighted root mean square.

[0123] For example, for the weight sequence {0.333, 0.5, 0.25, 0.4, 0.2} and the time coefficient {0.9, 0.85, 0.8, 0.75, 0.7}, the fusion weight is calculated using p = 1.

[0124] S2.6.3: Calculate the ratio of the standard deviation to the mean of the weight sequence to obtain the weight confidence.

[0125] Calculate the mean of the weight sequence and the standard deviation The confidence is defined as where is a small constant to prevent division by zero. A high confidence indicates that the priority relationship is consistent across different records and is highly reliable.

[0126] S2.6.4: Add the fusion weight value and the weight confidence as edge attributes to the graph structure to generate enhanced edge data.

[0127] In the adjacency list edge data structure, in addition to storing the target node and the weight, the confidence value is also stored, forming a triple (target node, fusion weight, confidence).

[0128] S2.6.5: Construct the adjacency list representation of the graph based on the enhanced edge data and the candidate information item pair set to construct the weighted priority graph.

[0129] Iterate through all information item pairs, add enhanced edge data to the adjacency list of the corresponding source node, and finally form a complete weighted priority graph.

[0130] This embodiment improves the accuracy and reliability of weight calculation by introducing time decay, weighted fusion and confidence quantification.

[0131] This embodiment systematically enhances the weight aggregation process in step S2.6 of embodiment 1 by introducing a time decay mechanism, a multi-dimensional weighted fusion strategy and a confidence quantification method, significantly improving the accuracy and reliability of priority weight calculation. This enhancement scheme fully considers the dynamic evolution characteristics of user habits, enabling the generated weighted priority graph to more accurately reflect the user's current true preferences, rather than simply treating all historical data equally.

[0132] The core idea of step S2.6.1 is to assign different importance weights to historical records at different time points, so that recent records contribute more to the final weight, while the impact of early records gradually decays. This design is based on an important observation that a user's preferences and habits do not remain constant, but evolve over time, with changes in business environment, personal cognitive development, and other factors. The information sorting method that a user frequently used three months ago may no longer be suitable for their current workflow; on the contrary, the operation records of the past week are more likely to represent the user's latest needs and preferences.

[0133] The system first obtains the current time as a reference benchmark point, denoted as This time is usually in Unix timestamp format, in seconds or milliseconds, to ensure the accuracy of time calculation. For each information item pair in the duplicate set, the system extracts the timestamp of each occurrence of the pair in the historical record. Suppose a certain information item pair appears five times in the user's historical record, with timestamps arranged in chronological order from early to late.

[0134] The choice of decay time constant has a significant impact on model performance. In this embodiment, it is recommended to use 30 days as the default value, which means that a record 30 days ago will have its time weight coefficient decay to , i.e., retaining about 37% of the weight; a record 60 days ago decays to , retaining about 14% of the weight; a record 90 days ago decays to , retaining only about 5% of the weight. This decay rate is suitable for most information management scenarios, both making full use of historical data and quickly adapting to habit changes. For scenarios where user habits change quickly, such as news reading, social media browsing, etc., you can set to a smaller value, such as 7 days or 14 days, to make the model more sensitive to the latest preferences; for scenarios where user habits are relatively stable, such as enterprise document management, scientific research data organization, etc., you can set to a larger value, such as 60 days or 90 days, to make full use of long-term accumulated habit data.

[0135] In actual calculation, the system calculates a time weighting coefficient for each historical occurrence of each information item pair. For example, assuming that the current time is January 15, 2024, and a certain information item pair has three occurrences in history, the times are December 20, 2023, January 5, 2024, and January 12, 2024, and a 30-day decay constant is used, then the three records are 26 days, 10 days, and 3 days away from now, respectively. The time weighting coefficients calculated by the formula are: the coefficient of the first record is about 0.420, the coefficient of the second record is about 0.717, and the coefficient of the third record is about 0.905. It can be clearly seen that the more recent records obtain higher weight coefficients, and these coefficients will play a key role in the subsequent weight fusion process.

[0136] The calculation of the time weighting coefficient also needs to consider some boundary conditions and special processing. If the timestamp of a record is later than the current time (this may be caused by system clock desynchronization or data entry error), the system sets the time interval to zero, gives the record a maximum weight coefficient of 1.0, and records a warning message for subsequent troubleshooting. If the time interval is too large, resulting in a weight coefficient less than a certain threshold (such as 0.001), the system can choose to set it directly to zero, which can reduce the amount of calculation without significantly affecting the results. The system also detects the validity of the timestamp to ensure that all time values are within a reasonable range, avoiding calculation errors caused by abnormal data.

[0137] The task of step S2.6.2 is to combine the multiple single weight values generated by the same information item pair in multiple historical records with the time weighting coefficient calculated in the previous step to obtain a comprehensive weight value. This fusion process is not a simple arithmetic average, but a more flexible and powerful weighted power average method, which can adjust the fusion strategy according to different application requirements and balance between conservative and aggressive estimates.

[0138] The selection of the power parameter determines the mathematical properties of the fusion. When , the formula degenerates to a weighted arithmetic average, which is the most commonly used and most intuitive average method, and the calculation result is located in the middle of all single weights, without biasing to extreme values. In specific calculation, first, multiply each single weight k with its corresponding time coefficient to obtain a time-weighted weight value; then sum all these weighted weight values; finally, divide the sum of all time coefficients (normalization processing) to obtain the final weight. The advantage of this method is simple calculation and stable result, suitable for most application scenarios.

[0139] When At this point, the formula becomes a weighted root mean square (RMS) calculation. This fusion method is more sensitive to larger weight values ​​and can amplify the influence of high weights. The calculation process is as follows: first, square each individual weight, then multiply it by the time coefficient and sum the results, finally taking the square root. This method is suitable for scenarios where strong priority relationships need to be emphasized. If a certain information item shows a very strong priority relationship (large weight value) in some records, the weighted root mean square will ensure that this strong relationship is fully reflected in the final weight and is not overly diluted by other weaker records.

[0140] In theory, It can take any positive real value, different Different values ​​correspond to different fusion strategies. When As the weighted power average approaches infinity, it approaches the maximum weight, meaning the final weight is primarily determined by the record with the highest weight. This extreme strategy is suitable for scenarios that only focus on the strongest priority relationship. As the weighted power average approaches zero, it approximates the weighted geometric average. This strategy is sensitive to all weight values; any excessively small weight will significantly lower the final result. It is suitable for scenarios requiring consistency across all records. When the value is negative, the formula tends to be a harmonic average, which is biased towards smaller weight values. This is useful in some special applications, but is rarely used in priority weight fusion.

[0141] Let's illustrate the calculation process with a concrete numerical example. Suppose a certain information item pair appears five times in history, and the single-weight sequence calculated using the inverse distance function is... The corresponding time weighting factor is .use The weighted arithmetic mean is calculated as follows: First, calculate the weight of each item, which is respectively... , , , , ;

[0142] Then sum them up to get ;

[0143] The sum of time coefficients is ;

[0144] The final fusion weight is .

[0145] If adopted The weighted root mean square is calculated as follows: First, the product of the square of each term and the time coefficient is calculated, which is respectively... , , , , ;

[0146] summed up ; divided by the sum of time coefficients ; and finally square rooted to get . It can be seen that the fusion weight obtained by the root mean square method (0.358) is slightly higher than the arithmetic mean (0.341), because the root mean square gives more weight to larger single weights (such as 0.5).

[0147] In practical applications, the system usually provides a configuration option for the value of , allowing users or system administrators to adjust it according to specific needs. For most information sorting scenarios, it is recommended to use the weighted arithmetic mean with , as it provides stable and predictable fusion results without excessive bias towards any extreme cases. For scenarios that need to emphasize strong priority relationships, such as step sorting of critical business processes, values of or larger can be tried. The system can also automatically select the optimal value through cross-validation or A / B testing, i.e., trying different values, evaluating the consistency of the generated sorting sequence with actual user operations, and selecting the value with the highest consistency as the final configuration.

[0148] Step S2.6.3 introduces the key concept of weight confidence, which quantifies the reliability and stability of a certain priority relationship. Even if two information pairs have the same fusion weight value, their reliability can be very different: one may be based on multiple highly consistent observations, and the other may be based on a few observations with large fluctuations. The confidence index can distinguish between these two cases, providing important decision-making basis for subsequent conflict resolution and sorting generation.

[0149] The calculation of confidence is based on the statistical dispersion of the weight sequence. The system first calculates the mean of the weight sequence, denoted as , which is the arithmetic mean of all single weight values. The mean reflects the central tendency of the information pair's priority relationship and is the typical level of the weight. Then the standard deviation of the weight sequence is calculated, denoted as , which is a classic statistical measure of the dispersion of weight values.

[0150] The larger the standard deviation, the greater the difference in weight values of the information pair in different historical records, and the less stable the user's preference for this priority relationship; the smaller the standard deviation, the more concentrated the weight values, and the more consistent the user's preference.

[0151] Two comparative examples are used to illustrate the significance of confidence. Example 1: information pair The weight sequence in five historical records is , the mean , the standard deviation , the confidence , is very close to 1, indicating that this priority relationship is highly stable and reliable. Example two: information item pair The weight sequence in five historical records is , the mean (same as example one), but the standard deviation , the confidence , is only about 0.5, indicating that although the average weight is the same, the reliability of this priority relationship is much lower than example one.

[0152] In practical applications, the confidence information plays an important role in multiple aspects. In the conflict resolution phase, when the weights of two directions are close, the system can refer to the confidence to break the tie: choose the direction with higher confidence, even if its weight is slightly smaller, because high confidence means that the direction has been supported more consistently. In the topological sorting phase, if it is necessary to choose among multiple candidate nodes, the system can prefer the node whose connected edges have higher average confidence, ensuring that the sorting decision is based on more reliable priority relationships. In the model evaluation phase, the system can calculate the average confidence of all edges as an indicator of the overall quality of the model: high average confidence indicates that user habits are relatively stable and consistent as a whole, and the model has good reliability; low average confidence may indicate that user habits are unstable or there are data quality problems, and the model results need to be applied more cautiously.

[0153] The calculation of confidence can also be extended and optimized. For example, a time-weighted standard deviation can be introduced, giving higher weight to recent records when calculating the degree of dispersion, so that the confidence better reflects the stability of the current habits. A lower threshold for confidence can be set, such as 0.3 or 0.5, and edges with confidence below the threshold can be specially marked or directly filtered, avoiding unreliable priority relationships affecting the final results. Confidence can be combined with edge weight to calculate a comprehensive score, such as (where is a balance parameter), and the comprehensive score is used instead of the weight value in subsequent processing, achieving a unified consideration of strength and reliability.

[0154] The task of step S2.6.4 is to integrate the fusion weight value and confidence calculated earlier into the data structure of the graph, forming enhanced edge data. This step may seem simple, but it is actually a key link in converting abstract numerical calculation results into operational graph structure representations, laying the data foundation for subsequent graph algorithm processing.

[0155] In a basic weighted directed graph, each edge usually contains only two pieces of information: the source node and the target node (defining the direction of the edge), and a weight value (defining the strength of the edge). This simple edge representation is extended in the present embodiment to an enhanced edge containing three attributes: the target node identifier, indicating which information item the edge points to; the fusion weight value, computed in step S2.6.2 , reflecting the strength of the priority relationship; and the weight confidence, computed in step S2.6.3 , reflecting the reliability of the priority relationship.

[0156] The enhanced edge data is organized in a triple format, which can be represented as . For example, if the edge from information item to information item has a fusion weight of 0.341 and a confidence of 0.986, the edge data is represented as . This triple structure can be implemented in computer memory in multiple ways: most directly, a structure or object containing three fields can be defined, in object-oriented programming languages an Edge class can be created containing three member variables targetNode, weight, and confidence; in functional programming languages a tuple or record type can be used; in database systems each edge can be stored as a row containing four columns, source node ID, target node ID, weight, and confidence.

[0157] The storage of edge data needs to balance the access efficiency and the memory occupation. For sparse graphs (the number of edges is much smaller than the square of the number of nodes), the adjacency list is the most commonly used storage structure. In the adjacency list representation, each node maintains a list storing all the edges departing from the node. Specifically, the system creates a hash table or dictionary, with the node identifiers as keys and the out-edge lists of the nodes as values. For node , its out-edge list can contain multiple triples, such as , indicating that points to , , three nodes, each with its own weight and confidence.

[0158] In constructing the enhanced edge data, the system iterates over all candidate information item pairs. For each pair $(i, j)$, if the fusion weight is computed in step S2.6.2 and the weight is greater than a certain minimum threshold (such as 0.01, filtering out weak relationships with too small weights), the system creates an edge from to . The three attributes of the edge are set as: the target node is , the weight is , the confidence is calculated in step S2.6.3 . This triple is added to the out-edge list of node . If the out-edge list of node does not exist yet (this is the first edge from ), the system creates an empty list first, then adds the edge data.

[0159] The enhanced edge data can also contain some optional metadata to support more advanced functionalities. For example, the number of history records that the edge is based on can be recorded, which is useful for debugging and analysis; the maximum and minimum values of the weight sequence can be recorded, providing information on the range of weight changes; the time of the last observation can be recorded, to determine whether the priority relationship is still active; whether the edge has been processed in conflict resolution and the specific decision of resolution can be recorded for traceability and auditing. These metadata can extend the triple to a more complex data structure, such as a quintuple or an object, which can be flexibly configured according to specific application requirements.

[0160] Data validation is an important step in the process of building enhanced edge data. The system needs to check the completeness and reasonableness of each edge data: the weight value must be positive, usually between 0 and 1 (if using a normalized inverse distance function) or within a reasonable upper bound; the confidence must be between 0 and 1, as it is defined based on probability; the target node must be a valid node identifier, existing in the node set. If any abnormal data is found, the system will record warning or error information, and decide whether to skip the edge, use default values, or abort the entire processing flow according to the configuration.

[0161] Step S2.6.5 is the last step of the entire weight aggregation enhancement process, its task is to organize all the enhanced edge data generated before into a complete graph structure, forming the final weighted priority graph. This graph is the basic data structure for all subsequent processing (conflict detection, topological sorting, etc.), its construction quality directly affects the performance and accuracy of the entire system.

[0162] The construction of the graph starts with initialization. The system first creates an empty graph object, which internally maintains a node set and an edge set. The node set contains all information items that appear in the history records, each node is represented by a unique identifier, which can be the ID, name or other unique key of the information item. The edge set is organized in the form of an adjacency list, as described earlier, which is a mapping from node identifiers to out-edge lists. At the initialization, the edge set is empty, gradually filled as enhanced edge data is added.

[0163] The system iterates through the candidate information item pair set, which contains all information item pairs that appear at least once in the history records. For each item pair , the system checks whether it has already generated an enhanced edge for it. If the enhanced edge from to was successfully created in step S2.6.4 (i.e. the weight is greater than the minimum threshold and the data is valid), the system adds this edge to the graph. The operation is as follows: locate the out-edge list of node in the adjacency list of the graph, create the list if it does not exist, and append the triple to the end of the list.

[0164] During the process of adding edges, the system needs to handle some special cases. The first one is duplicate edge detection: in theory, each pair of information items should generate only one edge, but due to the complexity of the data processing flow, it is possible that duplicate edges are added. The system checks whether the target node already exists in the out-edge list of node before adding the edge, and decides according to the configuration whether to overwrite the old edge (use the newly calculated weight and confidence), keep the old edge (ignore the new data), or report an error. Usually, the overwrite strategy is adopted to ensure that the latest calculation results are used.

[0165] The second one is self-loop detection: a self-loop is an edge that points from a node to itself, i.e. the case of . In the semantics of priority relations, self-loops are meaningless (an information item cannot be prior to itself), so the system should filter out all self-loops. When adding an edge, the system checks whether the source node and the target node are the same, and if they are the same, the edge is skipped and a warning message is recorded. The appearance of a self-loop usually indicates a logical error in the data processing flow, which needs to be investigated and fixed.

[0166] The construction of the graph also involves the management of nodes. Although the addition of edges is the main operation, the system also needs to maintain a complete set of nodes. When iterating over pairs of information items, the system adds all the node identifiers encountered to the node set, ensuring that even if a node has no out-edges (only in-edges or completely isolated), it will appear in the graph. The node set can be implemented as a hash set or a dictionary, supporting fast membership checks and iteration operations. Each node can be associated with some attributes in addition to the identifier, such as the display name of the node, the type, the frequency of appearance in the history record, etc., which are useful in visualization and analysis.

[0167] After construction, the system performs integrity check and statistical analysis on the graph. The integrity check includes: verifying that all target nodes of edges exist in the node set, avoiding dangling references; checking for isolated nodes (having neither incoming nor outgoing edges), counting their number and proportion; verifying that the size of the graph is within the expected range, such as whether the number of nodes is consistent with the total number of information items in historical records, and whether the number of edges is reasonable (usually it should be much smaller than the square of the number of nodes, because not all pairs of information items have priority relationships).

[0168] Statistical analysis provides in-depth understanding of the graph structure. The system calculates and reports the following statistical indicators: total number of nodes, reflecting the scale of information items involved in user operations; total number of edges, reflecting the number of identified priority relationships; average out-degree, i.e. how many outgoing edges each node has on average, reflecting the density of priority relationships; average in-degree, reflecting how many other nodes each node is dependent on on average; weight distribution, such as minimum weight, maximum weight, average weight, median weight, helping to understand the intensity distribution of priority relationships; confidence distribution, such as average confidence, proportion of low-confidence edges (such as edges with confidence less than 0.5), reflecting the overall reliability of priority relationships.

[0169] The final weighted priority graph is a complete, consistent, and information-rich data structure. It not only contains all priority relationships in user habits, but also characterizes the strength and reliability of each relationship through two dimensions of weight and confidence. This graph provides necessary input for subsequent conflict detection: by checking whether there are bidirectional edges (both and ), it can identify contradictions in user habits; by comparing the weight and confidence of bidirectional edges, it can make reasonable conflict resolution strategies. The graph also provides a basis for topological sorting: the topological sorting algorithm will traverse this graph to generate a linear ordering sequence according to the direction and weight of the edges. By introducing time decay, weighted fusion, and confidence quantification, this embodiment significantly improves the quality of the graph, making it more accurately reflect the user's current true preferences, and laying a solid foundation for generating high-quality personalized ordering.

[0170] Embodiment 3

[0171] Step S3: Self-habit conflict detection and resolution

[0172] Perform conflict detection on the weighted priority graph, identify information item pairs with bidirectional priority relationships, resolve conflict directions according to weight size, and generate a consistent habit graph.

[0173] Specifically, this step includes the following sub-steps:

[0174] S3.1: Perform bidirectional edge detection on the weighted priority graph, identify the information item pairs with both forward and backward edges, and generate a conflict pair list.

[0175] Scan all edges in the weighted graph, for each edge (A, B), check if there exists a backward edge (B, A). If yes, mark the node pair (A, B) as a conflict pair, and record the weights of both directions WAB and WBA.

[0176] S3.2: For each conflict pair in the conflict pair list, compare the weights of forward and backward edges, and determine the reserved direction.

[0177] For conflict pair (A, B), compare WAB and WBA. If WAB > WBA, reserve the A→B direction; if WBA > WAB, reserve the B→A direction. This strategy is called the maximum weight strategy, which prioritizes the direction of the user's stronger preference.

[0178] S3.3: Based on the reserved direction, delete the edges of the direction with weight lower than a preset threshold, and generate the consistency habit graph.

[0179] Set a weight difference threshold Δthreshold (e.g., 0.1), if |WAB - WBA| < Δthreshold, it means that the preference intensity of the two directions is close, and either both edges can be deleted or the edge with larger weight can be reserved. For conflict pairs with significant weight difference, delete the edge of the direction with smaller weight. After conflict resolution, the consistency habit graph without bidirectional edges is obtained.

[0180] This step extracts stable core habit patterns from the user's sorting differences at different times through conflict detection and resolution, improving the consistency of the sorting results.

[0181] Embodiment 4

[0182] Step S4: Graph connectivity detection and component analysis

[0183] Perform connectivity detection on the consistency habit graph, identify weakly connected components and isolated nodes, and obtain a complete graph structure representation.

[0184] Specifically, this step includes the following sub-steps:

[0185] S4.1: Initialize the visited flag array of the consistency habit graph, and generate a node visit state table.

[0186] Create a Boolean array visited[] with a length equal to the number of nodes in the graph, and initialize all values to false, which is used to mark whether a node has been visited.

[0187] S4.2: Based on the node access state table, perform a depth-first search algorithm to traverse each node and identify each weakly connected component.

[0188] From the first unvisited node, perform a depth-first search (DFS), recursively visit all adjacent nodes of the current node (including both out- and in-neighbors, as it is a weakly connected component), mark the visited nodes as true and add them to the current connected component set. Repeat the process until all nodes are visited, resulting in multiple weakly connected components.

[0189] S4.3: Perform node statistics on each weakly connected component to identify components containing only a single node and generate a set of isolated nodes.

[0190] Traverse all connected components and count the number of nodes in each component. If a component contains only one node, that node is an isolated node and is added to the set of isolated nodes.

[0191] S4.4: For each isolated node in the set of isolated nodes, establish connection edges with neighboring nodes based on the average position in historical ranking data to generate a set of supplementary edges.

[0192] For each isolated node, analyze its average position in historical ranking data. If the node usually appears in a certain position range, find other nodes in that range and establish connection edges. For example, isolated node C is usually in position 3 in historical records, while nodes B and D are in positions 2 and 4 respectively, so edges B→C and C→D are established, with weights calculated based on position distance.

[0193] S4.5: Add the set of supplementary edges to the consistency habit graph to obtain the complete graph structure representation.

[0194] Add the supplementary edges to the adjacency list of the graph and update the graph structure. Re-execute the connectivity detection to ensure that the isolated nodes have been connected to the main connected component.

[0195] This step ensures the integrity of the graph structure through connectivity detection and isolated node processing, providing a reliable foundation for subsequent topological sorting.

[0196] Embodiment 5

[0197] Step S5: personalized topological sorting generation

[0198] Use a topological sorting algorithm to process each connected component in the complete graph structure representation to generate a linear ordering sequence that conforms to user habits.

[0199] Specifically, this step includes the following sub-steps:

[0200] S5.1: Calculate the in-degree value of each node in the connected component, i.e. the number of edges pointing to the node.

[0201] Traverse all edges in the graph, count the number of times each node is the target node, and get the in-degree array indegree[].

[0202] S5.2: Determine the nodes with in-degree 0 as the starting point set for sorting.

[0203] Scan the in-degree array and add all nodes with in-degree 0 to the candidate queue queue. These nodes have no predecessors and can be used as starting points for sorting.

[0204] S5.3: Choose an appropriate tie-breaking strategy, such as alphabetical order, out-degree priority, weight priority, etc.

[0205] When there are multiple nodes in the candidate queue, a node needs to be selected to join the sorting result. Tie-breaking strategies include: selecting by alphabetical order of node identifiers, selecting by descending order of node out-degree (number of successor nodes), selecting by descending order of total out-edge weight of nodes, etc. This embodiment uses the weight priority strategy to select the node with the largest total out-edge weight.

[0206] S5.4: Initialize the result list result and the candidate queue queue, and add nodes with in-degree 0 to the candidate queue.

[0207] Create an empty list result to store the sorting result, and add the nodes with in-degree 0 identified in step S5.2 to queue.

[0208] S5.5: When the candidate queue is not empty, select a node according to the tie-breaking strategy.

[0209] Select the node with the largest total out-edge weight current from queue node .

[0210] S5.6: Add the selected node to the result list.

[0211] Add current node to the end of the result list.

[0212] S5.7: Update the in-degree values of all successor nodes of the selected node (decrease by 1).

[0213] Traverse all out-edges of current node , for each successor node successor, decrease its in-degree by 1: indegree[successor] -= 1.

[0214] S5.8: Add the successor nodes with in-degree 0 to the candidate queue.

[0215] Check the updated successor nodes in step S5.7. If the in-degree of a node becomes 0, add it to the queue.

[0216] S5.9: Repeat steps S5.5 to S5.8 until the candidate queue is empty.

[0217] Repeat the above steps until the queue is empty, indicating that all nodes have been added to the sorted result.

[0218] S5.10: Check if all nodes have been added to the result list. If not, there is a circular dependency.

[0219] Compare the length of the result with the total number of nodes in the graph. If they are not equal, there is a loop and the topological sorting cannot be completed. At this time, a loop detection and breaking strategy can be used, such as deleting the edge with the smallest weight to break the loop.

[0220] S5.11: Merge the sorted results of each connected component into the final sorting.

[0221] If the graph contains multiple connected components, perform topological sorting on each component separately, then merge the sorted results according to the size of the component or other rules to obtain the final linear sorting sequence.

[0222] This step converts the graph structure into a linear order that conforms to the user's habits through a topological sorting algorithm, realizing the core function of personalized sorting.

[0223] Embodiment 6

[0224] Step S6: Model quality evaluation and optimization

[0225] Calculate the consistency index of the linear sorting sequence with historical sorting data to obtain the model quality evaluation result.

[0226] Specifically, this step includes the following sub-steps:

[0227] S6.1: Calculate the coverage rate to evaluate the coverage of the model on the user's common information items.

[0228] Coverage rate is defined as the ratio of the number of information items included in the generated sorting to the number of all information items that have appeared in the user's historical records. For example, if there are 25 different information items in the user's historical records, and the generated sorting contains 20 of them, the coverage rate is 20 / 25=80%.

[0229] S6.2: Calculate the number of violations to count the number of conflicts between the generated sorting and historical preferences.

[0230] Iterate through the user's historical sorting records. For each record, check if the relative order of information item pairs in the generated sort matches the historical record. If A precedes B in the historical record, but B precedes A in the generated sort, this is counted as a violation. Count all violations and normalize them to a violation rate.

[0231] S6.3: Calculate the satisfaction score and assess the proportion of generated rankings that conform to historical habits.

[0232] The satisfaction score is defined as: 1 - violation rate. For example, if the violation rate is 15%, the satisfaction score is 85%.

[0233] S6.4: Analyze the conflict situation, including the total number of conflicts, intensity distribution, and cause analysis.

[0234] The number of conflict pairs identified in step S3 is counted, the distribution of conflict weight differences is analyzed, and the main causes of conflict (such as changes in user habits, data noise, etc.) are identified.

[0235] S6.5: Calculate the time consistency index to evaluate the model's adaptability to users' recent preferences.

[0236] The historical records are divided into two parts by time: recent (e.g., the last month) and earlier. The consistency between the generated ranking and the records in both parts is calculated. If the consistency of the recent records is significantly higher than that of the earlier records, it indicates that the model can adapt to the evolution of user habits.

[0237] S6.6: Generate a comprehensive quality assessment report, including all indicators and their explanations.

[0238] By integrating the above indicators, an evaluation report is generated, including information such as coverage rate, violation rate, satisfaction score, conflict analysis, and time consistency, providing a basis for optimization.

[0239] S6.7: Determine the optimization direction based on the evaluation results, such as adjusting weight strategies, conflict resolution strategies, etc.

[0240] Analyze the evaluation report to identify weaknesses in the model. For example, if the number of violations is too high, the weight calculation strategy needs to be optimized; if the coverage is insufficient, the conflict resolution strategy needs to be adjusted.

[0241] S6.8: Perform parameter optimization or algorithm adjustment to improve model performance.

[0242] Depending on the optimization direction, adjust relevant parameters or algorithms. For example, adjust the exponential parameter p of the inverse distance weight, or change the conflict resolution threshold Δthreshold.

[0243] S6.9: Compare the model performance before and after optimization to confirm the optimization effect.

[0244] Using the optimized parameters to regenerate the ranking, calculate the indicators, and compare them with the pre-optimization to confirm the performance improvement.

[0245] This step ensures that the ranking results meet user expectations through multi-dimensional quality evaluation and continuous optimization, improving the practicality of the system.

[0246] Embodiment 7

[0247] This embodiment provides a weight learning method based on random non-convex non-smooth optimization as an enhanced scheme for step S2.3 in Embodiment 1.

[0248] S2.3.1: For the position statistical data, define a loss function containing a frequency item, a position consistency item, and a regularization item, and establish a weight optimization target.

[0249] For information items , define the loss function as:

[0250] Where the first item is the frequency item, encouraging the occurrence of weights proportional to the number of ; the second item is the position consistency item, requiring the weight to match the actual position distance; and the third item is the regularization item to prevent overfitting. is the distance weight function, is the weight-to-distance mapping function, is the regularization function (such as regular |w| or SCAD regular) The historical records are divided into batches, each containing records. In the th iteration, weighted random sampling is performed according to the time decay weight to extract a batch , with recent records having a higher probability of being selected.

[0251] S2.3.3: Calculate the sub-gradient of the loss function with respect to the weight variable for the current batch of data to obtain the sub-gradient estimate.

[0252] Calculate the batch loss function with respect to the sub-gradient of . For the absolute value item, the sub-gradient is the sign function; for regular, the sub-gradient is ; for SCAD regular, the sub-gradient is calculated by piecewise according to the value range of . The sub-gradient estimate is obtained.

[0253] S2.3.4: Based on the secondary gradient estimate value, the weight variable is updated by using the secondary gradient descent method, and the weight is constrained to be non-negative by the projection operator, to obtain the updated weight value.

[0254] The projection secondary gradient update is adopted: wherein is a learning rate, is an operator for projecting to the non-negative domain.

[0255] S2.3.5: The updated weight value is iteratively averaged to construct the weighted priority graph.

[0256] The tail average strategy is adopted to average the weights of the last iterations to obtain the final weight. The final weights of all information item pairs are assembled into a weighted priority graph.

[0257] The embodiment improves the weight calculation from a simple formula to an adaptive learning process based on optimization theory, significantly improving the weight precision.

[0258] The embodiment provides a brand-new weight calculation paradigm, upgrading the weight calculation method based on the simple inverse distance formula in embodiment 1 to an adaptive weight learning framework based on modern optimization theory. The core idea of this change is that the weight is no longer directly calculated by a pre-defined mathematical formula, but is learned as a solution to an optimization problem by minimizing a carefully designed loss function. The advantage of this method is that it can consider multiple objectives and constraints at the same time, automatically balance the influence of different factors, and mine more realistic weight values from data, significantly improving the accuracy and robustness of the weight.

[0259] Although the traditional inverse distance formula is simple and intuitive, it has inherent limitations. It only considers the position distance as one factor, ignoring other important information such as the frequency of the priority relationship appearing in history, the consistency of the position relationship in different records, and the reasonable range of the weight value. In addition, the parameters in the inverse distance formula are manually set, lacking a data-driven tuning mechanism, and are difficult to adapt to the special needs of different users and different application scenarios. The embodiment introduces an optimization framework to consider these factors, allowing the data itself to guide the determination of the weight, realizing the transition from experience-driven to data-driven.

[0260] The core of the optimization framework is the loss function, which quantifies the discrepancy between the candidate weight values and the ideal weight values. By minimizing the loss function, the system can find the optimal or approximately optimal weight configuration. The loss function designed in this embodiment has the property of non-convexity and non-smoothness, which reflects the essential complexity of the weight learning problem. Non-convexity means that the loss function can have multiple local minima, and special strategies are needed to avoid falling into poor local solutions during the optimization process; non-smoothness is due to the absolute value terms and some regularization terms included in the loss function, which are not differentiable at some points and require the use of generalized derivative concepts such as subgradients to handle. To efficiently solve such optimization problems, this embodiment uses the stochastic subgradient descent algorithm, which is a widely used optimization method in the field of machine learning, especially suitable for handling large-scale data and non-smooth objective functions.

[0261] The core task of step S2.3.1 is to design a reasonable loss function to convert the weight learning problem into a mathematical optimization problem. The design of the loss function needs to consider multiple objectives: not only to ensure that the learned weights can reflect the statistical regularities in the historical data, but also to ensure the reasonableness and generalization ability of the weight values themselves. The loss function designed in this embodiment consists of three key parts, each corresponding to a specific optimization objective, and forms a unified objective function through weighted combination.

[0262] The first term is the frequency term, which is designed to make the weight proportional to the frequency of the priority relationship in the historical records. The basic logic of this term is: if the information pair frequently appears in a certain order in the history, it means that the user has a strong preference for this priority relationship, and should be given a larger weight; on the contrary, if a certain order only occasionally appears, the weight should be relatively small. The frequency term calculates the contribution of each record by traversing all historical records containing the information pair, and accumulating the contribution of each record. The contribution of each record is determined by two parts: one is the indicator function, which checks whether the order of the information items in the record is indeed from front to back, and only the records with correct order will produce positive contribution; the second is the distance weight function, which gives different weights according to the position distance of the two information items in the record, the closer the distance, the greater the weight, reflecting the assumption that the priority relationship with close positions is more reliable.

[0263] The coefficient in front of the frequency term is negative because the goal of optimization is to minimize the loss function, and we want the weight to be proportional to the frequency, i.e., the higher the frequency, the larger the weight, and the smaller the loss. By adding a negative sign in front of the frequency term, when the weight increases, the absolute value of the negative frequency term also increases, which reduces the total loss, thus guiding the optimization algorithm to increase the weight. This clever design cleverly converts "maximize frequency matching" into "minimize loss function". The specific form of the distance weight function can have multiple choices, including inverse distance function, exponential decay function or Gaussian kernel function, different function forms will lead to different weight distribution characteristics, which can be selected and optimized according to the specific application scene.

[0264] The second term is the position consistency term, which is designed to ensure that the learned weight values match the actual position distances observed in the historical records. The introduction of this term is based on an important observation: the weight is essentially a quantification of the strength of the priority relationship, and this strength should have an inherent connection with the relative position of the information item in the ranking sequence. If we define a mapping function from weight to position distance, then the predicted distance calculated by the weight should be as close as possible to the actual distance in the historical records. The position consistency term quantifies the degree of mismatch by calculating the difference between the predicted distance and the actual distance, and summing the differences for all historical records.

[0265] The difference is measured by the absolute value function, which is a relatively robust loss function for outliers. Compared with the square loss, the absolute value loss has a lighter penalty for extreme deviations, and will not cause the optimization process to pay excessive attention to a small number of abnormal records, thereby improving the stability of the learned weights. The mapping function from weight to distance needs to be designed according to the definition domain of the weight and the value domain of the distance, a simple choice is linear mapping, i.e., the predicted distance is equal to the weight multiplied by a certain proportion coefficient; more complex choices include nonlinear mappings such as logarithmic mappings or power function mappings, which can more flexibly model the relationship between weight and distance. The parameters of the mapping function can be determined by cross-validation or grid search, choosing the parameter configuration that minimizes the loss on the validation set.

[0266] The third term is the regularization term, which is designed to prevent overfitting of the model and improve the generalization ability of the weight. Overfitting is a common problem in machine learning, which refers to the model fitting too much detail and noise of the training data, resulting in poor performance on new data. In the context of weight learning, overfitting can manifest as some weight values being too large or too small, being overly sensitive to individual historical records, and lacking stability. The regularization term applies constraints or penalties to the weight values themselves, guiding the optimization algorithm to find a simpler and smoother weight configuration.

[0267] This embodiment supports multiple regularization functions, each with its specific effect and applicable scenario. L1 regularization, also known as Lasso regularization, is in the form of the sum of the absolute values of the weights. An important property of L1 regularization is that it can produce sparse solutions, i.e., let many weight values exactly equal to zero, which means automatic feature selection in weight learning, filtering out unimportant priority relationships, and simplifying the model structure. SCAD regularization is the abbreviation of smoothly clipped absolute deviation regularization, which is a more advanced regularization method that combines the sparsity of L1 regularization and the smoothness of L2 regularization. SCAD regularization imposes a strong penalty on small weights, encouraging them to shrink to zero, and a weak penalty on large weights, allowing important priority relationships to maintain large weights, avoiding the over-shrinking problem that L1 regularization may cause.

[0268] The three coefficients in the loss function are key parameters that balance different optimization objectives. The first coefficient controls the importance of the frequency term, the larger it is, the more the optimization process values matching historical frequencies; the second coefficient controls the importance of the positional consistency term, the larger it is, the more the optimization process values matching actual positional distances; the third coefficient controls the regularization strength, the larger it is, the stronger the constraint on weights, the simpler the model but possibly underfitting. The setting of these three coefficients needs to be tuned according to specific applications, a commonly used method is to try different coefficient combinations through cross-validation, evaluate the performance on the validation set, and select the combination with the best performance. In practice, we can first fix two coefficients and perform grid search on the third coefficient, then iteratively optimize and gradually approach the optimal configuration.

[0269] The design of the loss function also needs to consider computational efficiency. Since the loss function needs to be calculated repeatedly in the optimization process, its computational complexity directly affects the running time of the entire algorithm. In the loss function designed in this embodiment, both the frequency term and the positional consistency term involve traversing historical records, and the time complexity is proportional to the number of records; the regularization term only involves the calculation of weight values itself, and the time complexity is a constant. To improve efficiency, the system can precompute and cache some intermediate results, such as the positional distance of each information item in each record, to avoid repeated calculation. For large-scale data, random sampling or small batch processing strategies can be used, using only part of the data each time to calculate an approximate value of the loss function, while ensuring the optimization effect and greatly reducing the computational cost.

[0270] Step S2.3.2 introduces the core mechanism of stochastic optimization: mini-batch stochastic gradient descent. In traditional batch gradient descent, the gradient is computed using all training data at each iteration, which is computationally expensive and slow for large-scale data. The mini-batch method computes an approximation of the gradient using only a small subset of data at each iteration, which significantly improves the efficiency and enables the algorithm to handle large-scale data within a reasonable time. This embodiment further introduces a time-weighted sampling strategy on top of the standard mini-batch method, which gives higher probability to recent records in the batch, making the optimization process more attentive to the user's latest habits.

[0271] Batch division is the first step of stochastic sampling. The system divides the historical dataset containing N records into B batches, each containing approximately N divided by B records. The batch size B is a trade-off parameter: the smaller B is, the larger the batch size is, the more data is used in each iteration, the more accurate the gradient estimation is, but the higher the computational cost is; the larger B is, the smaller the batch size is, the faster the computation is in each iteration, but the larger the variance of gradient estimation is, which may lead to unstable optimization process. In practice, the commonly used batch size ranges from 32 to 256 records, and the specific value can be adjusted according to the data size and computational resources. For large-scale datasets containing tens of thousands of records, a larger batch size such as 128 or 256 can be chosen; for small and medium-sized datasets with only a few thousand records, a smaller batch size such as 32 or 64 can be chosen.

[0272] Time-weighted sampling is the innovation of this embodiment. In the standard stochastic sampling, each record has an equal probability of being selected, which means that an old record three months ago and a new record yesterday have the same impact on the optimization process. However, as discussed in Embodiment 2, a user's habits and preferences evolve over time, and recent records better reflect the current true demand. To make the optimization process more attentive to recent data, this embodiment calculates a time-decay weight for each historical record, which decays exponentially with the age of the record. The formula for calculating the time-decay weight is the same as the time-weighted coefficient in Embodiment 2, using an exponential function, and the parameters include the current time, the record time, and the decay time constant.

[0273] In the t-th iteration, the system needs to extract a batch from the N historical records. The extraction process uses weighted random sampling, i.e., the probability of each record being selected is proportional to its time-decay weight. In specific implementation, the system first calculates the time-decay weights of all records, then normalizes the weights so that the sum of all weights is equal to 1, obtaining the sampling probability of each record. Then, the system uses these probabilities to perform random sampling without replacement, extracting a batch size number of records to form the current batch. Random sampling without replacement ensures that the same record does not appear repeatedly in a batch, avoiding information redundancy.

[0274] Weighted random sampling can be implemented in various ways. One simple method is roulette selection: divide the probability interval 0 to 1 into N segments, each with a length equal to the sampling probability of the corresponding record, then generate a random number between 0 and 1, see which segment it falls into, and select the corresponding record. This process is repeated batch size times to get the complete batch. The time complexity of roulette selection is batch size times the number of records, which can be slow for large-scale data. A more efficient method is alias sampling, which builds a special data structure through preprocessing, so that each sampling only takes constant time, and the total time complexity is reduced to the number of records plus the batch size, significantly improving efficiency.

[0275] The effect of time-weighted sampling is that recent records are used more frequently in the optimization process. For example, suppose a record one week ago has a time decay weight of 0.8, and a record two months ago has a weight of 0.2, then the former has four times the probability of being selected into the batch. In the entire optimization process, recent records will be repeatedly sampled and used, and their cumulative contribution to the gradient will dominate, guiding the weight to adjust in a direction that better reflects the latest habits. At the same time, although old records have a lower probability of being sampled, they are not completely ignored, and they still have the opportunity to influence the optimization process, which ensures that the model does not completely forget historical information and strikes a balance between new and old habits.

[0276] The randomness of the batch is an important feature of the stochastic gradient descent algorithm. Because the batch used in each iteration is randomly sampled, the content of the batch in different iterations is different, and the calculated gradient is also different, which introduces a certain amount of randomness and noise. This randomness, although it can lead to an optimization path that is not as smooth as batch gradient descent, also brings some unexpected benefits: it can help the algorithm escape local minima and explore a wider solution space, sometimes finding a better global solution; it also serves as a kind of implicit regularization, preventing the model from overfitting to certain specific data patterns. To control the impact of randomness, the system can set a random seed to ensure the repeatability of experiments, or use the strategy of averaging multiple runs to reduce the impact of random fluctuations on the final results.

[0277] The task of step S2.3.3 is to calculate the subgradient of the loss function with respect to the weight variable, which is the basis for the optimization algorithm to update the weight. In the standard gradient descent algorithm, we calculate the gradient of the loss function, i.e. the partial derivative of the loss function with respect to each variable, and then update the variable in the opposite direction of the gradient to make the loss function value decrease. However, the loss function in this embodiment contains absolute value terms and certain non-smooth regularization terms, which are not differentiable at certain points, and the traditional concept of gradient is no longer applicable. The subgradient is a generalization of the gradient concept for non-smooth functions, which provides a theoretical basis and computational tool for optimizing non-smooth functions.

[0278] The mathematical definition of subgradient is: for a function f at a point x, if there exists a vector g such that for any point y, the value of the function at y is greater than or equal to the value of the function at x plus the inner product of g and y minus x, then g is a subgradient of f at x. The geometric meaning of this definition is: the subgradient defines a support hyperplane, which is tangent to the function at the point x, and the function image is completely located above the hyperplane. For differentiable functions, the subgradient is the ordinary gradient; for non-differentiable but continuous functions, the subgradient is a set containing all vectors that satisfy the above conditions.

[0279] For the absolute value term in the loss function, the calculation of the subgradient is relatively simple. The derivative of the absolute value function is positive 1 at positive numbers, negative 1 at negative numbers, and not differentiable at zero, but the subgradient is a closed interval from negative 1 to positive 1. In actual calculation, the sign function is usually used to represent the subgradient of the absolute value: when the variable is positive, the subgradient takes positive 1; when the variable is negative, the subgradient takes negative 1; when the variable is zero, the subgradient can take any value between negative 1 and positive 1, and the commonly used choice is 0. The absolute value term in the position consistency term is the absolute value of the difference between the predicted distance and the actual distance, and its subgradient is equal to the sign of the difference multiplied by the derivative of the predicted distance with respect to the weight.

[0280] For the L1 regularization term, the calculation of the subgradient is similar to the absolute value. The L1 regularization term is the sum of the absolute values of the weights, and the subgradient of each weight variable is the sign function of that weight. When the weight is positive, the subgradient is positive 1, encouraging to reduce the weight; when the weight is negative, the subgradient is negative 1, encouraging to increase the weight; when the weight is zero, the subgradient can take any value between negative 1 and positive 1. This subgradient characteristic of L1 regularization is the reason why it can produce sparse solutions: when the weight is close to zero, the uncertainty of the subgradient allows the optimization algorithm to push the weight exactly to zero, thereby realizing feature selection.

[0281] For the SCAD regularization term, the calculation of the subgradient is more complex, because SCAD is a piecewise defined function with different expressions in different weight value intervals. SCAD regularization is usually defined in three segments: when the absolute value of the weight is less than a certain threshold, SCAD is equal to the absolute value of the weight multiplied by a coefficient, and the subgradient is the sign of the weight multiplied by the coefficient; when the absolute value of the weight is between the threshold and another larger threshold, SCAD is a quadratic function, and the subgradient is the derivative of the quadratic function; when the absolute value of the weight is greater than the second threshold, SCAD is a constant, and the subgradient is zero. In calculation, the system needs to first determine which interval the current weight value falls into, and then apply the corresponding subgradient formula.

[0282] The batch-wise subgradient is calculated by averaging the subgradients of all records in the current batch. For each record in the batch, the system calculates the contribution of the record to the loss function, and then calculates the subgradient of the contribution with respect to the weights. Since the loss function is the sum of the contributions of all records, according to the linearity of the subgradient, the subgradient of the total loss function is equal to the sum of the subgradients of each record. In the mini-batch method, we only calculate the sum of the subgradients of the records in the batch, and then divide by the batch size to get the average of the subgradients as an unbiased estimate of the subgradient of the entire data. Although this estimate has some variance, the expected value is equal to the true subgradient, and in multiple iterations it will tend to the correct optimization direction.

[0283] The implementation of subgradient calculation needs to pay attention to numerical stability. When calculating the sign function, if the value of the variable is very close to zero, due to the limitation of floating-point precision, the sign judgment may be wrong. In order to avoid this problem, the system can set a small threshold, when the absolute value of the variable is less than the threshold, it is considered as zero, and the subgradient takes zero or other predefined value. When calculating the subgradient involving division, it needs to check whether the denominator is zero or close to zero, if so, use a small positive number instead to avoid numerical overflow. For terms that may produce very large or very small values, numerical clipping techniques can be used to limit the subgradient to a reasonable range, preventing gradient explosion or disappearance.

[0284] The calculation of subgradient can also use automatic differentiation technology to simplify. Modern deep learning frameworks such as TensorFlow or PyTorch provide automatic differentiation functions that can automatically calculate the gradient and subgradient of complex functions. By expressing the loss function as a combination of operations supported by these frameworks, the system can call the automatic differentiation interface of the framework to automatically obtain the subgradient without manually deriving and coding. This not only reduces the development workload, but also reduces the possibility of errors and improves the maintainability of the code. For the loss function of the present embodiment, basic operations such as absolute value function, summation function, regularization function, etc. provided by the framework can be used to construct, and then the backpropagation interface is called to calculate the subgradient.

[0285] Step S2.3.4 performs the core operation of the optimization algorithm: updating the weight variable according to the calculated subgradient. This step uses the projected subgradient descent method, which adds a projection operation to the standard subgradient descent to ensure that the updated weights meet certain constraint conditions. In the weight learning problem, an important constraint is that the weights must be non-negative, because negative weights have no meaning in the semantics of priority relations. The projection operation maps the weight values that may violate the constraints back to the feasible region, ensuring that the optimization process is always conducted in the valid solution space.

[0286] The basic update formula of subgradient descent is: new weights equal to old weights minus learning rate times subgradient. Learning rate is a positive number, controlling the step size of each update. The choice of learning rate has important influence on the optimization process: if learning rate is too large, the update step size is too large, which may cause the optimization process to oscillate or even diverge, failing to converge to the optimal solution; if learning rate is too small, the update step size is too small, the optimization process is slow, and it takes many iterations to approach the optimal solution, or even may fall into a local minimum. In practice, learning rate usually adopts a decreasing strategy, that is, gradually reducing learning rate as the number of iterations increases, using a larger learning rate in the early stage to quickly approach the optimal solution, and using a smaller learning rate in the later stage to fine-tune and improve the convergence accuracy.

[0287] There are various forms of commonly used learning rate decreasing strategies. The simplest one is fixed step size, that is, learning rate remains unchanged throughout the optimization process, which is simple to implement, but is often not the optimal choice. More commonly used is time decay, that is, learning rate equals initial learning rate divided by 1 plus decay coefficient times iteration number, which makes learning rate decrease linearly with iteration number. Another one is step decay, that is, multiplying learning rate by a coefficient less than 1 every fixed number of iterations, such as halving learning rate every 100 iterations, which has good effect in practice and is easy to tune. There is also exponential decay, that is, learning rate equals initial learning rate multiplied by iteration number to the power of decay rate, which makes learning rate decrease exponentially, fast in the early stage and slow in the later stage.

[0288] This embodiment recommends using a learning rate strategy inversely proportional to the square root of iteration number, that is, learning rate equals initial learning rate divided by the square root of iteration number plus 1. This strategy has a solid theoretical basis in the theory of stochastic optimization, and can guarantee the convergence of the algorithm on non-convex and non-smooth problems. Specifically, for a loss function that meets certain conditions, the stochastic subgradient descent algorithm using this learning rate strategy can make the average value of the iteration point converge to the neighborhood of the optimal solution at a certain rate. Square root decay is slower than linear decay and faster than fixed step size, achieving a good balance between convergence speed and stability.

[0289] The projection operation is performed after the subgradient update. Standard subgradient update may produce negative weight values, which are unreasonable in the semantics of priority weights. The projection operation maps these negative values to zero, ensuring that all weights are non-negative. Specifically, the projection operation is an element-wise maximum function: for each weight variable, take the maximum of it and zero, if the weight is positive, it remains unchanged, if the weight is negative or zero, it is set to zero. This operation is mathematically called projection to the non-negative quadrant, which is a special case of nearest point projection, that is, finding the nearest point in the feasible region to a given point.

[0290] The projection operation not only guarantees the satisfaction of the constraints, but also has some subtle effects on the optimization process. When a weight becomes negative after an update and is projected to zero, it is actually telling the algorithm that the optimal value of this weight might be zero, and the corresponding priority relationship might not be important or does not exist. In the subsequent iterations, if the subgradient continues to push this weight in the negative direction, it will stay at zero; only when the subgradient becomes negative, pushing the weight in the positive direction, will it leave zero. This mechanism complements the sparsity effect of L1 regularization, and together they promote the automatic elimination of unimportant weights.

[0291] The complete process of projecting the subgradient update is as follows: first, starting from the current weight value, subtract the learning rate multiplied by the subgradient to get an intermediate weight value; then, apply the projection operation to this intermediate value, set negative values to zero, to get the final updated weight value. This process is independent for each weight variable, because the non-negative constraint is element-wise, and there is no coupling between different weights. In implementation, vectorized operations can be used to update all weights at once, improving computational efficiency. Modern numerical computing libraries such as NumPy or PyTorch provide efficient vectorized maximum functions that can be directly applied to weight vectors.

[0292] The progress of the optimization also needs to be monitored during the update process. The system can calculate the loss function value under the current weight configuration at each iteration or every few iterations, and observe whether the loss is decreasing. If the loss continues to decrease, it means that the optimization is proceeding normally; if the loss no longer decreases or starts to rise, it may be due to improper learning rate setting, getting stuck in a local minimum, or being close to the optimal solution. The system can also calculate the change in weights, i.e., the difference between the current weights and the weights from the last iteration, and if the change is very small, it means that the optimization is close to convergence, and early stopping can be considered. These monitoring information can be output to the log or visual interface, helping users understand the optimization status and timely discover and solve problems.

[0293] Step S2.3.5 is the final stage of the optimization process, and its task is to extract the final weight values from the weight sequence generated by multiple iterations, and use these weights to construct the weighted priority graph. Due to the randomness of the stochastic optimization algorithm, the weight values obtained from different iterations will have some fluctuations, and directly using the weights from the last iteration may not be the optimal choice. This embodiment uses the iteration averaging technique to reduce the influence of random fluctuations by averaging the weights from multiple iterations, obtaining more stable and reliable final weights.

[0294] The basic idea of iterative averaging is that while the weight of a single iteration can deviate from the optimal value, the average of multiple iterations will tend to converge to the optimal value. This idea is rigorously mathematically proven in the theory of stochastic optimization: for optimization problems and algorithms that satisfy certain conditions, the average of the iteration points converges to the optimal solution at a certain rate, and this convergence rate is often superior to the convergence rate of a single iteration point. Through averaging, we are actually using the law of large numbers to cancel out random noise and extract stable signals.

[0295] The tail-averaging strategy is used in this embodiment, that is, only the weights of the latter half of the iterations are averaged, and the former half is ignored. The motivation for this strategy is that in the early stages of optimization, the weight values can be far from the optimal solution and contain large errors; as the iterations proceed, the weights gradually approach the optimal solution, and the errors decrease. If all iterations are averaged, the large errors in the early stages will contaminate the average value, reducing the quality of the final result. By using only the latter half of the iterations, we exclude the unstable early stage and only use the stable stage close to convergence, thereby obtaining a more accurate average value.

[0296] Specifically, assuming that a total of T iterations are performed, the tail-averaging calculation starts from the T divided by 2 plus 1 iteration and ends at the T iteration, and the weights of the T divided by 2 iterations are arithmetically averaged. For each weight variable, the maximum weight is equal to the sum of the values of the variable in the T divided by 2 iterations divided by T divided by 2. This calculation is performed independently for all weight variables to obtain a complete maximum weight vector. The tail-averaging calculation can be incrementally performed during the optimization process: the system maintains an accumulator, and after each iteration, it determines whether it has entered the latter half, and if so, it adds the current weight to the accumulator; after the optimization ends, the accumulator is divided by the number of iterations in the latter half to obtain the average value.

[0297] The selection of the dividing point in the tail-averaging strategy is a parameter that can be adjusted. This embodiment suggests using one-half as the dividing point, that is, the latter half of the iterations, which is an empirically effective choice. In some cases, a more conservative dividing point, such as three-fourths, can be used, that is, only the last quarter of the iterations are used, which will further improve the quality of the average value, but also reduces the number of samples participating in the averaging, which may increase the variance. A more aggressive dividing point, such as one-third, can also be used, using the last two-thirds of the iterations, which increases the number of samples and reduces the variance, but may contain some iterations that have not fully converged. The selection of the dividing point can be optimized through cross-validation, trying different dividing points, evaluating the performance of the maximum weight on the validation set, and selecting the configuration with the best performance.

[0298] Besides tail average, there are other averaging strategies to choose from. Full average is the simplest strategy, averaging over all T iterations, simple to implement but potentially influenced by early iterations. Weighted average is to assign different weights to different iterations, such as linearly increasing weights, later iterations have larger weights, this strategy has some theoretical advantages, but requires additional parameter tuning. Exponential moving average is an online averaging method, maintaining an estimate of the average, each iteration updates the average with a weighted combination of the new weight and the old average, the weight is controlled by a decay factor, this method is memory efficient, suitable for very large scale problems, but requires careful selection of the decay factor.

[0299] After getting the final weights, the system starts to construct the weighted priority graph. This process is similar to the graph construction in Example 1 and Example 2, but the source of weights is different: here the weights are learned through optimization, not calculated by simple formulas. The system iterates over all information item pairs, for each pair, checks if its final weight is greater than a minimum threshold, if so, adds a directed edge from the first information item to the second information item in the graph, the edge weight is set to the final weight value. If confidence or other auxiliary information is also calculated during the optimization process, they can also be stored as attributes of the edge.

[0300] The graph construction also includes some post-processing steps. First is weight normalization: although the weights may vary in a large range during the optimization process, in the final graph, it is usually desired that the weights are between 0 and 1, to facilitate subsequent processing and interpretation. The system can normalize all weights, divide them by the maximum weight, so that the maximum weight becomes 1, and other weights are scaled proportionally. Second is sparsification: the weights obtained by optimization may have many small values close to zero, these small weights correspond to edges that have little effect on the ordering of the pair, but increase the storage and computational overhead of the graph. The system can set a sparsification threshold, delete edges with weights less than the threshold, and only keep important edges with larger weights, which not only improves efficiency, but also plays a role in noise reduction.

[0301] The constructed weighted priority graph is a complete data structure that contains all the priority relationships and their strengths learned from historical data. This graph can be stored and transmitted in multiple formats: adjacency list format is suitable for sparse graphs, saving space; adjacency matrix format is suitable for dense graphs, fast access; edge list format is simple and intuitive, easy to serialize. The system can also generate a visualization for the graph, drawing nodes as circles, edges as arrows, and edge thickness or color representing weight size, helping users intuitively understand the structure of priority relationships.

[0302] The embodiment introduces a weight learning framework based on optimization theory, and upgrades the weight calculation from a simple formula calculation to a data-driven adaptive learning process. This transformation brings many advantages: first, the optimization framework can consider multiple objectives such as frequency matching, position consistency and regularization, and balance these objectives through the design of the loss function to obtain more comprehensive and reasonable weights; second, the time-weighted sampling mechanism makes the optimization process focus more on recent data, allowing the learned weights to quickly adapt to changes in user habits; third, the stochastic optimization algorithm is efficient and scalable, and can handle large-scale historical data and complete learning within a reasonable time; finally, the iterative averaging technique reduces the impact of random fluctuations and improves the stability and reliability of the final weights. These advantages work together to significantly improve the accuracy of the weights and lay a solid foundation for generating high-quality personalized rankings.

[0303] Embodiment 8

[0304] The embodiment enhances step S2.3.4 based on embodiment 7, and uses an adaptive optimization algorithm.

[0305] A1: Initialize the first moment estimate variable and the second moment estimate variable of the sub-gradient estimate value, and establish the initial state of the moment estimate.

[0306] Initialize the first moment , the second moment , set the decay rate , .

[0307] A2: Based on the initial state of the moment estimate and the sub-gradient estimate value, update the first moment estimate using the exponential moving average method to obtain the updated first moment.

[0308] Calculate:

[0309] A3: Based on the square of the initial state of the moment estimate and the sub-gradient estimate value, update the second moment estimate using the exponential moving average method to obtain the updated second moment.

[0310] Calculate:

[0311] A4: Bias correct the updated first moment and the updated second moment to obtain the corrected moment estimate.

[0312] A5: Based on the corrected moment estimate, calculate the weight update step using the adaptive learning rate formula, and project the updated weight to the feasible region through the projection operator to obtain the updated weight value.

[0313] This embodiment improves convergence speed and stability by introducing the adaptive learning rate mechanism of the Adam optimizer and adjusting it in conjunction with the characteristics of subgradients.

[0314] This embodiment, based on Embodiment 3, significantly upgrades and improves the weight update mechanism by introducing an adaptive optimization algorithm to replace the standard subgradient descent method. The core idea of ​​this improvement is to no longer use a uniform fixed learning rate for all weight variables, but instead dynamically calculate a personalized adaptive learning rate for each weight variable based on its historical gradient information. This adaptive mechanism can automatically adjust the update speed of different weights, using a smaller learning rate for weights with drastic gradient changes to maintain stability, and a larger learning rate for weights with gentle gradient changes to accelerate convergence, thereby significantly improving the overall convergence speed and stability of the optimization algorithm.

[0315] While the standard subgradient descent method used in Example 3 theoretically guarantees convergence, it has some inherent limitations in practice. The most significant problem is the difficulty in choosing the learning rate: if a global learning rate applicable to all weights is chosen, a contradictory phenomenon often occurs where some weights update too quickly, leading to oscillations, while others update too slowly, resulting in slow convergence. This is because different weight variables have different gradient scales and change characteristics, and their learning rate requirements differ. Manually adjusting the learning rate for each weight is clearly impractical, especially when the number of weights is large. Adaptive optimization algorithms solve this problem automatically, allowing the algorithm itself to determine the optimal learning rate for each weight based on the observed gradient history.

[0316] The adaptive optimization algorithm used in this embodiment is a variant of the Adam algorithm, specifically tailored for subgradient optimization. Adam stands for Adaptive Moment Estimation, one of the most popular optimization algorithms in deep learning and machine learning, widely favored for its excellent performance and robustness. The core mechanism of the Adam algorithm is to maintain exponential moving average estimates of the first and second moments of the gradient for each parameter, and then use these moment estimates to calculate the adaptive learning rate. The first moment estimate captures the average direction of the gradient, similar to the momentum term in the momentum method, which can accelerate convergence and reduce oscillations; the second moment estimate captures the average of the squares of the gradient, reflecting the magnitude of gradient changes, and is used to adjust the learning rate.

[0317] Step A1 is the preparation phase of the adaptive optimization algorithm, which involves initializing the various state variables and hyperparameters required by the algorithm. Although these initialization settings seem simple, they have a significant impact on the algorithm's performance and need to be configured appropriately based on theoretical guidance and practical experience.

[0318] The initialization of the first-moment estimate variable is to set it to a zero vector, i.e., for each weight variable, its corresponding first-moment estimate initial value is zero. This initialization choice is natural and reasonable: before the optimization starts, we have not observed any gradient information, so we have no prior knowledge about the average direction of the gradient, and zero is a neutral starting point that does not bias towards any direction. The first-moment estimate will be updated gradually based on the actual observed subgradients in the subsequent iterations, and gradually accumulate information about the gradient direction. In the early stage of optimization, the first-moment estimate will quickly adjust from zero to a value reflecting the true gradient direction; in the later stage of optimization, the first-moment estimate will tend to be stable, fluctuating slightly around the true gradient direction.

[0319] The second-moment estimate variable is also initialized to a zero vector, and each weight variable has a corresponding second-moment estimate initial value of zero. The second-moment estimate is used to track the moving average of the gradient square, reflecting the variation or fluctuation of the gradient. Initializing to zero means that at the beginning we assume that the variation of the gradient is unknown and needs to be learned through actual observation. The second-moment estimate will gradually increase during the iteration process, because the square of the gradient is always non-negative, and the accumulated average will start from zero and grow. The size of the second-moment reflects the instability of the gradient of the corresponding weight: if the gradient of a certain weight varies greatly in different iterations, its second-moment estimate will be larger; if the gradient is relatively stable, the second-moment estimate will be smaller.

[0320] The decay rate parameter is a key hyperparameter that controls the speed of the exponential moving average, and this embodiment sets two decay rates: the first-moment decay rate and the second-moment decay rate. The first-moment decay rate is usually set to 0.9, which means that in the calculation of the moving average, the weight of the historical information decays at a rate of 0.9, and the weight of the current observation value is 1 minus 0.9, which is 0.1. This setting makes the first-moment estimate sensitive to the gradient of the last ten iterations or so, allowing it to respond quickly to changes in the gradient direction, while retaining some historical memory to smooth out the fluctuations. If the first-moment decay rate is set to a larger value, such as 0.95 or 0.99, the moving average will be smoother and the memory of the historical information will be longer, but the response speed will be slower; if it is set to a smaller value, such as 0.8 or 0.7, the response speed will be faster, but it may be too sensitive and susceptible to noise.

[0321] The decay rate of the second moment is usually set to 0.999, which is a value very close to 1, meaning that the second moment estimate has a strong memory of the history and the moving average changes very slowly. The motivation for this setting is that the statistics of the squared gradient are usually more stable than the gradient itself, and it takes a longer time of observation to get a reliable estimate. With a decay rate close to 1, the second moment estimate will average over the squared gradients of about one thousand iterations, which provides a stable, low-variance estimate and avoids drastic fluctuations in the learning rate due to individual outliers. In some applications, if the optimization process is found to be too sensitive to changes in the learning rate, it can be helpful to increase the decay rate of the second moment further to 0.9999, making the learning rate more stable; conversely, if the learning rate is desired to adapt more quickly to changes in the gradient, it can be decreased to 0.99 or 0.995.

[0322] The default values of these two decay rate parameters, 0.9 and 0.999, are recommended settings in the original paper of the Adam algorithm and have been widely adopted as standard configurations after extensive experimental verification in various machine learning tasks. In most cases, using these default values will achieve satisfactory performance without the need for tuning. However, in some special cases, such as optimization problems with very special structures or data with special statistical properties, it may be necessary to fine-tune these parameters to achieve optimal performance. The tuning method is usually grid search or random search: try a set of candidate values, such as the first moment decay rate between 0.8 and 0.95, and the second moment decay rate between 0.99 and 0.9999, run the optimization algorithm for each set of parameters, evaluate the convergence speed and final performance, and select the best combination.

[0323] In addition to the moment estimation variables and decay rates, some other hyperparameters and auxiliary variables need to be set during the initialization phase. The global learning rate is a scaling factor that controls the overall step size, although the Adam algorithm will calculate an adaptive learning rate for each weight, these adaptive learning rates will be multiplied by the global learning rate, so the global learning rate is still an important parameter. The default global learning rate of the Adam algorithm is usually set to 0.001, which is a reasonable starting point in many tasks. The numerical stability term is a very small positive number, such as ten to the power of -8, which is used to prevent division by zero errors, and when calculating the division involving the second moment estimate, a small number will be added to the denominator to ensure that the division can proceed normally even if the second moment estimate is zero.

[0324] Initialization also includes allocating storage space for each weight variable to hold its corresponding first and second moment estimates. In implementation, these moment estimates are usually organized as vectors or matrices of the same shape as the weight vector, so that efficient vectorized operations can be performed. For example, if there are one thousand weight variables, two vectors of length one thousand are created, one to store the first moment estimates and one to store the second moment estimates. These vectors are all filled with zeros at initialization, and then updated according to the observed subgradients at each iteration. Modern numerical computing libraries provide efficient vector and matrix operations, so that these updates can be performed in parallel, fully utilizing the computational power of the hardware.

[0325] Step A2 performs the update of the first moment estimate, which is one of the core operations of the adaptive optimization algorithm. The first moment estimate can be understood as an exponentially weighted moving average of the gradients, which combines the current observed subgradient and the historically accumulated gradient information, providing a smooth and low-noise gradient estimate to guide the direction of weight update.

[0326] Exponential moving average is a classical time series smoothing technique, whose basic idea is that the new average value is equal to the old average value multiplied by a decay factor, plus the current observation value multiplied by one minus the decay factor. The cleverness of this formula is that it only needs to save one average variable, which can integrate the information of all historical observations, and assigns different weights to observations at different times, with recent observations having large weights and distant observations having small weights, with the weights decaying exponentially over time. This weighting scheme is very consistent with our intuition: in the optimization process, the most recent gradient information reflects the current optimization state better and should be given more attention; while the gradient information long ago may be outdated and should be gradually faded out.

[0327] At the t-th iteration, the system first obtains the subgradient estimate value calculated from the current batch, which is the output of step S2.3.3 and reflects the local gradient information of the loss function on the current batch of data. Then, the system reads the first moment estimate value saved from the last iteration, which integrates all gradient information from the first iteration to the (t-1)-th iteration. Next, the system multiplies the old first moment estimate by the first moment decay rate, which is equivalent to decaying the historical information to make room for new information. At the same time, the current subgradient is multiplied by one minus the first moment decay rate, which is the weight of the new information. Finally, the decayed historical information and the weighted new information are added to obtain the updated first moment estimate.

[0328] This update procedure is element-wise, i.e., for each weight variable, there is an independent first moment estimate that updates according to the corresponding component of the subgradient. The first moment estimates of different weights are independent of each other, each tracking the gradient history of the corresponding weight. In vectorized implementation, one can organize the first moment estimates of all weights into a vector and the subgradients of all weights into another vector, then use vector multiplication and addition to update all the first moment estimates at once, which is much more efficient than looping over each weight.

[0329] The physical meaning of the first moment estimate can be understood from multiple perspectives. From a statistical perspective, it is an estimate of the expected value of the gradient, if the gradient is a random variable, the first moment is the mean of this random variable. In stochastic optimization, since each iteration uses a randomly sampled mini-batch of data, the computed gradient contains random noise, the first moment estimate reduces the impact of noise by averaging multiple observations, extracting the true trend of the gradient. From a dynamics perspective, the first moment estimate is similar to momentum in physics, it accumulates the inertia of motion in the optimization process, making the optimization path smoother, enabling more efficient traversal of flat regions, and accelerating convergence.

[0330] The update of the first moment estimate also has some interesting mathematical properties. If we recursively expand the update formula, we can find that the current first moment estimate is actually a weighted sum of all historical subgradients, with weights exponentially decaying over time. Specifically, the weight of the subgradient at the t-th iteration in the current first moment estimate is 1 minus the decay rate raised to the power of zero, the weight of the subgradient at the t minus 1-th iteration is 1 minus the decay rate raised to the power of one, the weight of the subgradient at the t minus 2-th iteration is 1 minus the decay rate raised to the power of two, and so on. These weights form a geometric series, the sum of which equals 1, which means that the first moment estimate is a normalized weighted average, which will not increase indefinitely as the number of iterations increases.

[0331] The decay rate of the first moment estimate determines the effective window size of historical information. When the decay rate is 0.9, we can roughly estimate that the first moment estimate is mainly affected by the last ten iterations or so, the impact of earlier iterations has decayed to a negligible level. This effective window can be determined by calculating how many powers of the decay rate equal a certain small threshold, for example, the tenth power of 0.9 is approximately equal to 0.35, the twentieth power of 0.9 is approximately equal to 0.12, indicating that the information weight of twenty iterations ago has dropped to about one tenth of the original. This limited memory feature enables the first moment estimate to adapt to changes in the gradient distribution during the optimization process, if the terrain of the loss function changes during the optimization process, the first moment estimate will gradually forget the old gradient pattern and learn the new gradient pattern.

[0332] In practical applications, the update of the first moment estimate is very stable and reliable, and rarely needs special treatment. But in some extreme cases, such as the numerical range of the subgradient is very large, the problem of numerical overflow or underflow may occur. In order to prevent this situation, the system can clip the subgradient to limit it within a reasonable range, such as between negative 10 and positive 10, and values outside the range are truncated to the boundary value. This gradient clipping technique is widely used in deep learning, which can effectively prevent the problem of gradient explosion. Another possible problem is that if the optimization process is very long, the first moment estimate may accumulate rounding errors, leading to a decrease in accuracy. This situation is rare in practice, but if it does occur, you can consider resetting the first moment estimate periodically, or using a higher precision numerical type.

[0333] Step A3 performs the update of the second moment estimate, which is another core operation of the adaptive optimization algorithm. The second moment estimate tracks the exponentially weighted moving average of the square of the subgradient, which reflects the magnitude or volatility of the gradient, and is used to adjust the learning rate of each weight.

[0334] The update formula of the second moment estimate is very similar in form to the first moment estimate, both are exponentially moving averages, but there is a key difference: the second moment estimate uses the square of the subgradient, not the subgradient itself. In the t-th iteration, the system first calculates the square of the current subgradient, which is an element-wise square operation, that is, the square of each component of the subgradient vector. Then, multiply the second moment estimate of the last iteration by the second moment decay rate, to decay the historical information. Next, multiply the current subgradient square by 1 minus the second moment decay rate, to get the weighted value of the new information. Finally, add the decayed historical information and the weighted new information to get the updated second moment estimate.

[0335] The calculation of the square of the subgradient needs to pay attention to numerical stability. Since the square operation will amplify the value, if the absolute value of the subgradient is large, its square may be very large, even exceeding the representation range of the floating point number, causing overflow. In order to prevent this situation, the system can clip the subgradient before calculating the square, to ensure that its absolute value does not exceed a certain upper limit. Another method is to use the calculation in the logarithmic space, that is, to calculate twice the logarithm of the absolute value of the subgradient, instead of directly calculating the square, which is more numerically stable, but needs to be adjusted accordingly in the subsequent steps. In most practical applications, the numerical range of the subgradient is reasonable, and direct calculation of the square will not be a problem, but attention should be paid to this when dealing with special problems.

[0336] The physical meaning of the second moment estimate can be understood from the perspective of variance. In statistics, the second moment is closely related to variance: if the first moment is the mean, the second moment minus the square of the first moment is the variance. Although we do not explicitly compute the variance in the Adam algorithm, the second moment estimate does reflect the dispersion of the gradients. If the gradient of a certain weight varies greatly across iterations, sometimes being large positive and sometimes being large negative, the average of its squared gradient will be large, and the second moment estimate will also be large; if the gradient is relatively stable, fluctuating within a small range, the second moment estimate will be small. This information is very useful for adjusting the learning rate: weights with large gradient fluctuations need a small learning rate to avoid oscillation, while weights with stable gradients can use a large learning rate to speed up convergence.

[0337] The decay rate of the second moment estimate is usually set to a value close to 1, such as 0.999, which makes the second moment estimate have a long memory of historical information. The reason for this design choice is: the statistical properties of the squared gradient are usually more stable than the gradient itself, requiring more samples to obtain a reliable estimate. If a smaller decay rate is used, the second moment estimate will be too sensitive to short-term gradient fluctuations, leading to frequent and drastic changes in the learning rate, affecting the stability of optimization. Using a decay rate close to 1, the second moment estimate will average the long-term gradient statistics, providing a stable, low-variance estimate, making the learning rate adjustment smoother and more reliable.

[0338] Similar to the first moment estimate, the second moment estimate can also be recursively expanded as a weighted sum of all historical second gradients, with weights exponentially decaying over time. When the decay rate is 0.999, the effective window size is about one thousand iterations, which means that the second moment estimate mainly reflects the average level of the squared gradient of the last about one thousand iterations. This long window ensures the stability of the second moment estimate, even if a few iterations have abnormally large or small gradients, they will not have a significant impact on the second moment estimate because their weights are diluted in the long-term average.

[0339] An important property of the second moment estimate is that it is always non-negative, because it is a weighted average of squared values, and squared values are always non-negative. This property is very important when calculating the adaptive learning rate later, because the calculation of the learning rate involves the square root of the second moment estimate, and only non-negative numbers can take the square root. The range of the second moment estimate is from zero to positive infinity, zero represents that the gradient is always zero, which is rarely seen in practice, usually only when the optimization has completely converged to a critical point; a small second moment estimate indicates that the gradient fluctuation is small, and the optimization process is stable; a large second moment estimate indicates that the gradient fluctuation is large, and the optimization process is unstable or the loss function terrain is complex.

[0340] When updating the second moment estimates, memory efficiency needs to be considered. Since the second moment estimates need to store one estimate for each weight variable, the memory cost can become a problem if the number of weights is large. In large-scale optimization problems, the number of weights can reach millions or even billions, and the corresponding second moment estimates also need the same amount of storage. Fortunately, the update of the second moment estimates is element-wise, and no additional temporary storage is needed. The update can be done in-place, i.e., directly modifying the memory location where the second moment estimates are stored, without allocating new memory. Modern optimization libraries usually highly optimize these operations, using SIMD instructions or GPU parallel computation to speed up vector operations, while ensuring memory efficiency and improving computation speed.

[0341] Step A4 performs bias correction, which is a key innovation of the Adam algorithm to address the bias problem of the moment estimates in the early stage of optimization. The root cause of this problem lies in the initialization of the moment estimates: we initialize both the first and second moment estimates to zero, but the true gradient mean and gradient square mean are usually not zero. In the early stage of optimization, the moment estimates have not accumulated enough information and are severely biased towards the initial value of zero, leading to systematically small estimates, which affects the calculation of the learning rate and makes the optimization too slow at the beginning.

[0342] The mechanism of the bias can be understood through mathematical analysis. Consider the update process of the first moment estimate. After the first iteration, the first moment is equal to 1 minus the decay rate multiplied by the first sub-gradient. This value is obviously smaller than the true gradient mean, because it only contains one observation and is scaled by a small coefficient of 1 minus the decay rate. After the second iteration, the first moment is equal to the decay rate multiplied by the previous first moment plus 1 minus the decay rate multiplied by the current sub-gradient. Although it contains two observations, it is still systematically smaller than the true mean due to the exponential decay of the cumulative effect. This bias gradually decreases with the number of iterations, as the moment estimates gradually accumulate more information, but it is significant in the early stage.

[0343] The method of bias correction is to scale the moment estimates by dividing them by a correction factor. For the first moment, the correction factor is 1 minus the decay rate raised to the power of t, where t is the current iteration number. This correction factor is small in the early stage of optimization, making the corrected first moment enlarged to compensate for the small bias caused by initializing to zero. As the iteration number increases, the correction factor gradually approaches 1, and the correction effect gradually weakens, because the moment estimates have already accumulated enough information and the bias is already small. For the second moment, the correction method is exactly the same, except that the decay rate of the second moment is used.

[0344] The design of the correction factor is based on an exact mathematical analysis of the bias. It can be shown that if the true gradient mean is a constant, then the expectation of the uncorrected first-moment estimate is equal to the true mean multiplied by 1 minus the decay rate raised to the power of t, so dividing by this factor gives an unbiased estimate. Similarly, the expectation of the uncorrected second-moment estimate is equal to the true gradient-squared mean multiplied by 1 minus the second-moment decay rate raised to the power of t, and dividing by this factor again gives an unbiased estimate. This correction method is exact in theory and has been proven very effective in practice.

[0345] The effect of bias correction is most significant in the early stages of optimization. At the first iteration, the correction factor for the first moment is 1 minus 0.9 raised to the power of 1, which equals 0.1, meaning that the corrected first moment is 10 times the uncorrected value; the correction factor for the second moment is 1 minus 0.999 raised to the power of 1, which equals 0.001, meaning that the corrected second moment is 1000 times the uncorrected value. This large amplification ensures that even with only one observation, the moment estimates provide reasonable values that are not too small to cause problems with the learning rate. As iterations proceed, the correction factors increase rapidly and approach 1: at the tenth iteration, the correction factor for the first moment is approximately 0.65 and for the second moment is approximately 0.01; at the one-hundredth iteration, the correction factor for the first moment is approximately 0.9999 and for the second moment is approximately 0.095; at the one-thousandth iteration, both correction factors are very close to 1, and the effect of correction is minimal.

[0346] Bias correction not only solves the numerical problem but also has a positive impact on the optimization dynamics. By providing more accurate moment estimates in the early stages, bias correction enables the optimization algorithm to use reasonable learning rates from the beginning and move quickly toward the optimal solution, rather than being overly cautious and slow at the start. This speeds up the overall convergence process and reduces the number of iterations needed to reach a given accuracy. In some problems, the speedup effect of bias correction can be several times, especially in the early stages where progress is fastest.

[0347] In implementing bias correction, it is necessary to keep track of the current iteration number t, which is usually a simple counter that is incremented after each iteration. The calculation of the correction factor involves a power operation, i.e., computing the t-th power of the decay rate, which can have some computational overhead when t is large. One optimization technique is to exploit the recursive nature of the power operation: the t-th power of the decay rate is equal to the (t-1)-th power of the decay rate multiplied by the decay rate, so it is possible to maintain the power of the decay rate in each iteration by updating it through multiplication, rather than recomputing the power each time. This reduces the complexity of the power operation from logarithmic to constant, although the practical benefit of this optimization is not large on modern computers, it can be useful in environments where computational resources are limited.

[0348] The bias-corrected moment estimates form the basis for subsequent calculations of the adaptive learning rate. The corrected first moment provides an unbiased estimate of the gradient direction, indicating which direction the weights should be updated; the corrected second moment provides an unbiased estimate of the gradient variability, indicating how the learning rate should be adjusted. These two estimates combined enable the Adam algorithm to calculate a personalized update step size for each weight that considers both direction and magnitude, achieving efficient adaptive optimization.

[0349] Step A5 is the final and most crucial step in the entire adaptive optimization process. It transforms the previously calculated corrected moment estimate into actual weight updates and ensures that the updated weights satisfy the non-negativity constraint through a projection operation. This step integrates the calculation of the adaptive learning rate, the updating of weights, and the satisfaction of constraints, representing a perfect combination of algorithm theory and practice.

[0350] The core innovation of the Adam algorithm lies in the calculation of the adaptive learning rate. Unlike standard gradient descent, which uses a uniform fixed learning rate, Adam calculates a personalized learning rate for each weight variable. This learning rate is obtained by dividing the global learning rate by the square root of the corrected second-moment estimate. The square root operation is introduced to transform the second-moment estimate (the mean of the squared gradients) into an estimate of the gradient magnitude, since the standard deviation of the gradient is equal to the square root of the mean of the squared gradients. A small numerical stabilization term is added to prevent division by zero errors; when the second-moment estimate is very small, the denominator will not become zero, thus avoiding numerical overflow.

[0351] This adaptive learning rate design is intuitively reasonable. For weights with large gradient fluctuations, the second moment estimate is large, and the square root is also large, resulting in a small adaptive learning rate. This allows for smaller update steps for these weights, avoiding oscillations caused by gradient noise. For weights with stable gradients, the second moment estimate is small, resulting in a large adaptive learning rate. These weights can move forward in larger steps, accelerating convergence. This automatic adjustment mechanism allows weights with different characteristics to update at a rate suitable for their own characteristics, making the overall optimization process more efficient and stable.

[0352] The weight update formula combines an adaptive learning rate and a corrected first-moment estimate. The update direction is determined by the first-moment estimate, which is a smoothed estimate of the gradient and indicates the direction of the steepest descent of the loss function. The update step size is determined by the product of the adaptive learning rate and the first-moment estimate, which comprehensively considers the global learning speed, the local gradient magnitude, and the degree of gradient variability. Specifically, the new weights equal the old weights minus the adaptive learning rate multiplied by the corrected first moment. This is a standard gradient descent step, but the learning rate is adaptive, and the gradient is smoothed and corrected.

[0353] The global learning rate is a hyperparameter that needs to be tuned, which controls the overall optimization speed. The default global learning rate for Adam is 0.001, which is a reasonable starting point for many tasks. If the optimization process is found to converge too slowly, one can try increasing the global learning rate, such as 0.01 or 0.1, which can speed up convergence but may also lead to instability; if the optimization process is found to oscillate or diverge, one can try decreasing the global learning rate, such as 0.0001 or 0.00001, which can improve stability but may slow down convergence. The tuning of the global learning rate can be automated by learning rate scheduling strategies, such as gradually decreasing the learning rate during the optimization process, or dynamically adjusting the learning rate based on the validation set performance.

[0354] The numerical stability term is usually set to ten to the power of negative eight, which is a small enough value that does not significantly affect normal calculations but can effectively prevent division by zero errors. In cases where the second moment estimate is very small, such as when the gradient of a weight is close to zero, the second moment estimate will also be close to zero. Without the numerical stability term, the calculation of the learning rate would result in a large number or even infinity due to division by a number close to zero. With the numerical stability term, the denominator is at least this small constant, ensuring that the learning rate remains within a finite range. In some applications, if the optimization process is found to be sensitive to the choice of the numerical stability term, one can try adjusting its value, such as ten to the power of negative seven or ten to the power of negative nine, and observe the impact on performance.

[0355] The projection operation is performed after the weight update to ensure that the updated weights satisfy the non-negative constraint. This operation is exactly the same as the projection operation in Example 3: for each weight variable, take the maximum of it and zero, and if the weight is positive, leave it unchanged, and if the weight is negative, set it to zero. The projection operation guarantees the semantic reasonableness of the weights, as negative weights have no meaning in the priority relationship. The projection operation is also related to L1 regularization and sparsity: when a weight is projected to zero, if the subsequent gradient continues to push it in the negative direction, it will remain at zero, achieving automatic feature selection.

[0356] The overall effect of the adaptive optimization algorithm is significantly better than the standard subgradient descent. By calculating a personalized learning rate for each weight, the Adam algorithm can automatically adapt to the different characteristics of different weights without manually tuning the learning rate of each weight. By using the moment estimate to smooth the gradient, the Adam algorithm reduces the impact of random noise, making the optimization path more stable. Through bias correction, the Adam algorithm can provide accurate estimates in the early stages of optimization, accelerating convergence. These advantages make Adam one of the most popular optimization algorithms currently, widely used in deep learning, machine learning, and various optimization problems.

[0357] In specific applications of weight learning, the improvements brought by adaptive optimization algorithms are multi-faceted. First, the convergence speed is significantly improved, and the number of iterations required to achieve the same optimization accuracy can be reduced by half or even more, which saves a lot of computing time when dealing with large-scale data. Second, the optimization stability is enhanced, and even in the case of complex loss function terrain with multiple local minima, the Adam algorithm can stably move towards the good solution, with less oscillation or divergence. Third, the difficulty of hyperparameter tuning is reduced, although Adam still has some hyperparameters to set, but the default values can work well in most cases, without the need for fine-tuning of the learning rate as in the standard gradient descent. Finally, the quality of the final solution is often better, as Adam can explore the solution space more effectively, it has a greater chance to find a better local optimal solution or global optimal solution.

[0358] This embodiment introduces an adaptive optimization mechanism based on the Adam algorithm, which improves the efficiency and effectiveness of weight learning to a new level. The matrix estimation technique provides an accurate characterization of the statistical properties of the gradient, the bias correction preserves the unbiasedness of the estimate, the adaptive learning rate implements personalized update strategies, and the projection operation ensures the satisfaction of constraints. The organic combination of these techniques makes the weight learning process more intelligent, efficient and robust, providing strong technical support for generating high-quality weighted priority graphs, and ultimately improving the performance of the entire personalized ranking system.

[0359] Embodiment 9

[0360] This embodiment provides an information intelligent ranking device based on user habit learning, as shown in Figure 3 , comprising:

[0361] The data acquisition module is used to obtain a plurality of historical information ranking records of a specific user, and to perform data cleaning and standardization processing on the historical information ranking records to obtain standardized historical ranking data. This module realizes the function of step S1 in embodiment 1, including sub-functions such as data extraction, deduplication, missing value detection and format standardization.

[0362] The graph construction module is used to calculate the priority weight between each pair of information items based on the standardized historical ranking data, and to construct a weighted priority graph. This module realizes the function of step S2 in embodiment 1, including sub-functions such as information item pair extraction, position statistics, weight calculation, duplicate item pair processing and weight aggregation.

[0363] Conflict resolution module: used for conflict detection on the weighted priority graph, identifying pairs of information items with bidirectional priority relationships, resolving conflict directions according to weight sizes, and generating a consistent habit graph. This module implements the function of step S3 in embodiment 3, including sub-functions such as bidirectional edge detection, weight comparison, and edge deletion.

[0364] Connectivity analysis module: used for connectivity detection on the consistent habit graph, identifying weakly connected components and isolated nodes, and obtaining a complete graph structure representation. This module implements the function of step S4 in embodiment 4, including sub-functions such as DFS traversal, connected component identification, isolated node detection, and supplementary edge generation.

[0365] Order generation module: used for processing each connected component based on the complete graph structure representation using a topological sorting algorithm, and generating a linear ordering sequence consistent with user habits. This module implements the function of step S5 in embodiment 5, including sub-functions such as in-degree calculation, candidate queue management, tie breaking, and ordering result generation.

[0366] Evaluation module: used for calculating the consistency index of the linear ordering sequence with historical ordering data, and obtaining a model quality evaluation result. This module implements the function of step S6 in embodiment 6, including sub-functions such as coverage calculation, violation frequency statistics, satisfaction score, and comprehensive report generation.

[0367] Each module is connected through a standardized data interface to form a complete information intelligent ordering system. The output of the data collection module is used as the input of the graph construction module, the output of the graph construction module is used as the input of the conflict resolution module, and the process is repeated until the evaluation module outputs the quality evaluation result and feeds back to the graph construction module and the conflict resolution module for parameter optimization.

[0368] The device realizes the complete process of personalized information ordering through modular design, and has good scalability and maintainability.

[0369] The above is only the preferred embodiment of the present application, it should be noted that for those skilled in the art, without departing from the principles of the present application, can make a number of improvements and refinements, these improvements and refinements should be considered as the protection scope of the present application.

[0370] The computer program is stored on a machine-readable storage medium and executed by a processor when run to perform the steps described in the above method embodiments. The storage medium can be a volatile or non-volatile computer-readable storage medium.

[0371] In addition, the embodiment of the present disclosure further provides a computer program product, and a computer program is stored on the computer program product. The computer program is run by a processor to execute the steps provided by any of the embodiments of the present disclosure. For details, refer to the method embodiments described above, which will not be repeated here.

[0372] The computer program product can be implemented by hardware, software or a combination thereof. In an optional embodiment, the computer program product is embodied as a computer storage medium, which can be a volatile or non-volatile computer readable storage medium. In another optional embodiment, the computer program product is embodied as a software product, such as a software development kit (SDK) and the like.

[0373] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working process of the above-described device and apparatus can refer to the corresponding process in the foregoing method embodiments, which will not be repeated here. In several embodiments provided by the present disclosure, it should be understood that the disclosed devices, apparatuses and methods can be implemented by other ways. The apparatus embodiments described above are only schematic, for example, the division of the units is only a logical function division, and there can be another division way in actual implementation, for example, a plurality of units or components can be combined or integrated into another system, or some features can be ignored or not executed. In addition, the coupling or direct coupling or communication connection between the units shown or discussed can be indirect coupling or communication connection through some communication interface, device or unit, which can be electrical, mechanical or other forms.

[0374] The units described as separate components can or can not be physically separate, and the components shown as units can or can not be physical units, i.e. they can be located in one place or distributed on multiple network units. According to actual needs, some or all of the units can be selected to achieve the purpose of the present embodiment.

[0375] In addition, each functional unit in each embodiment of the present disclosure can be integrated into one processing unit, or each unit can exist physically, or two or more units can be integrated into one unit.

[0376] If the functions are implemented in the form of software function units and sold or used as independent products, they can be stored in a nonvolatile computer readable storage medium executable by a processor. Based on this understanding, the technical solutions of the present disclosure essentially or the part that contributes to the prior art or part of the technical solutions can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes a number of instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in various embodiments of the present disclosure. The aforementioned storage medium includes: a U disk, a mobile hard disk, a read-only memory (Read-Only Memory, ROM), a random access memory (Random Access Memory, RAM), a magnetic disk or an optical disk, and various media that can store program codes.

[0377] Finally, it should be noted that: the above-described embodiments are only specific embodiments of the present disclosure, used to illustrate the technical solutions of the present disclosure, and not to limit them. The protection scope of the present disclosure is not limited thereto. Although the present disclosure has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that any person skilled in the art can make modifications or easily think of changes to the technical solutions described in the foregoing embodiments within the technical scope disclosed by the present disclosure, or make equivalent replacements to some of the technical features. The modifications, changes or replacements do not cause the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present disclosure, and should be covered within the protection scope of the present disclosure. Therefore, the protection scope of the present disclosure should be subject to the protection scope of the claims.

Claims

1. An intelligent information sorting method based on user habit learning, characterized in that, Includes the following steps: Obtain multiple historical information sorting records of the user, perform data cleaning and standardization processing on the historical information sorting records, and obtain standardized historical sorting data; Based on the standardized historical sorting data, the positional relationship of each pair of information items in the historical sorting data is statistically analyzed, the priority weight between each pair of information items is calculated, and a weighted priority graph is constructed. Conflict detection is performed on the weighted priority graph to identify information item pairs with bidirectional priority relationships. Conflict directions are resolved according to the weights to generate a consistent habit graph. The consistency graph is subjected to connectivity detection to identify weakly connected components and isolated nodes, resulting in a complete graph structure representation. The topological sorting algorithm is used to process each connected component in the complete graph structure representation to generate a linear sorting sequence that conforms to user habits; The consistency index between the linear sorting sequence and the historical sorting data is calculated to obtain the model quality evaluation result.

2. The method according to claim 1, characterized in that, The historical information sorting records are cleaned and standardized to obtain standardized historical sorting data, including: The historical information sorting records are deduplicated by deleting identical sorting records to obtain the deduplicated sorting records. Missing value detection is performed on the deduplicated sorted records to identify records with missing information items or incomplete position information, and a valid record set is generated. The identifiers and position indices of each information item in the valid record set are processed to unify their formats, resulting in the standardized historical sorted data.

3. The method according to claim 1, characterized in that, The positional relationship of each pair of information items in the historical sorted data is statistically analyzed, the priority weights between each pair of information items are calculated, and a weighted priority graph is constructed, including: Extract all simultaneously occurring information item pairs from the standardized historical sorted data to generate a candidate information item pair set; The positional differences and order of each pair of candidate information items in the set of candidate information items in each historical record are statistically analyzed to obtain positional statistics. Based on the location statistics, the priority weight of each information item pair is calculated using the inverse distance function, and the weighted priority graph is constructed.

4. The method according to claim 1, characterized in that, The positional relationship of each pair of information items in the historical sorted data is statistically analyzed, the priority weights between each pair of information items are calculated, and a weighted priority graph is constructed, including: Identify pairs of information items that appear repeatedly in multiple historical records from the standardized historical sorting data, and generate a set of duplicate item pairs; For each information item pair in the set of duplicate items, extract its corresponding single weight value in each historical record to obtain a weight sequence; The weight sequence is accumulated and aggregated to construct the weighted priority graph.

5. The method according to claim 4, characterized in that, The weighted priority graph is constructed by accumulating and aggregating the weight sequences, including: For each information item pair in the set of repeated items, the time decay weight is calculated based on the time of each occurrence to obtain the time weighting coefficient; Based on the time weighting coefficients and the weight sequence, the weights of each single iteration are fused using a weighted power average formula to obtain the fused weight value. The weighted reliability is obtained by calculating the ratio of the standard deviation to the mean of the weighted sequence. The fusion weight value and the weight reset confidence are added as edge attributes to the graph structure to generate enhanced edge data; Based on the enhanced edge data and the candidate information items, the adjacency list representation of the graph is constructed, and the weighted priority graph is constructed.

6. The method according to claim 1, characterized in that, Conflict detection is performed on the weighted priority graph to identify information item pairs with bidirectional priority relationships. Conflict directions are resolved based on weight magnitude to generate a consistent habit graph, including: Bidirectional edge detection is performed on the weighted priority graph to identify information item pairs that simultaneously have forward and reverse edges, and a list of conflict pairs is generated. For each conflict pair in the list of conflict pairs, compare the weights of the forward edge and the reverse edge to determine the direction to retain; Based on the retained direction, edges with weights below a preset threshold are deleted to generate the consistent habit graph.

7. The method according to claim 1, characterized in that, The consistency graph is subjected to connectivity testing to identify weakly connected components and isolated nodes, resulting in a complete graph structure representation, including: Initialize the access tag array for the consistency habit graph and generate a node access status table; Based on the node access status table, a depth-first search algorithm is used to traverse each node and identify each weakly connected component. Node statistics are performed on each weakly connected component to identify components that contain only a single node, and a set of isolated nodes is generated. For each isolated node in the set of isolated nodes, establish connection edges with adjacent nodes based on the average position in the historical sorting data, and generate a supplementary edge set; Adding the supplementary edge set to the consistent habit graph yields the complete graph structure representation.

8. The method according to claim 3, characterized in that, The priority weights of each information item pair are calculated using an inverse distance function, and the weighted priority graph is constructed, including: For the aforementioned location statistics, a loss function is defined that includes a frequency term, a location consistency term, and a regularization term, and a weight optimization objective is established. Based on the weight optimization objective, a time-weighted strategy is used to randomly extract sample batches from the standardized historical sorted data to obtain the current batch data. Calculate the subgradient of the loss function with respect to the weight variables for the current batch of data to obtain the subgradient estimate; Based on the subgradient estimate, the weight variables are updated using the subgradient descent method, and the weights are constrained to be non-negative by the projection operator to obtain the updated weight values. The updated weight values ​​are iteratively averaged to construct the weighted priority graph.

9. The method according to claim 8, characterized in that, The weight variables are updated using subgradient descent, and the weights are constrained to be non-negative using the projection operator to obtain the updated weight values, including: Initialize the first-order moment estimator and the second-order moment estimator of the subgradient estimate to establish the initial state of the moment estimate; Based on the initial state of the moment estimation and the subgradient estimation value, the first-order moment estimation is updated using the exponential moving average method to obtain the updated first-order moment. Based on the initial state of the moment estimate and the square of the subgradient estimate, the second-order moment estimate is updated using the exponential moving average method to obtain the updated second-order moment. The updated first-order moments and the updated second-order moments are corrected for deviations to obtain the corrected moment estimates; Based on the corrected moment estimation, the weight update step size is calculated using the adaptive learning rate formula, and the updated weights are projected onto the feasible region using the projection operator to obtain the updated weight values.

10. An intelligent information sorting device based on user habit learning, characterized in that, include: The data acquisition module is used to acquire multiple historical information sorting records of a specific user, and to perform data cleaning and standardization processing on the historical information sorting records to obtain standardized historical sorting data. The graph construction module is used to statistically analyze the positional relationship of each pair of information items in the historical sorting data based on the standardized historical sorting data, calculate the priority weight between each pair of information items, and construct a weighted priority graph. The conflict resolution module is used to perform conflict detection on the weighted priority graph, identify information item pairs with bidirectional priority relationships, resolve conflict directions according to weight size, and generate a consistent habit graph. The connectivity analysis module is used to perform connectivity detection on the consistent custom graph, identify weakly connected components and isolated nodes, and obtain a complete graph structure representation; The sorting generation module is used to process each connected component using a topological sorting algorithm based on the complete graph structure representation, and generate a linear sorting sequence that conforms to user habits. The evaluation module is used to calculate the consistency index between the linear sorted sequence and the historical sorted data, and obtain the model quality evaluation result.

Citation Information

Patent Citations

  • Dynamic environment-oriented self-adaptive online sorting method and system

    CN114861093A

  • Multi-level batch text parallel deduplication method, system and equipment and storage medium

    CN119203983A

  • Multi-modal data-driven teaching evaluation report automatic generation and intelligent analysis method

    CN120046863A

  • Intelligent drawing output method and system based on three-dimensional model integration

    CN120876665A

  • Deferred semi-persistent scheduling (SPS) hybrid automatic repeat request (HARQ) codebook appending order and priority

    US20230100939A1