Multi-scenario data construction methods, devices, electronic equipment and storage media
By constructing an operation summary graph and generating multi-dimensional walking paths, the problem of single learning dimensions in multi-scenario user behavior modeling is solved. This enables the learning of commonalities in mixed-scenario behaviors and characteristics in single-scenario behaviors, thereby improving the accuracy and personalized service capabilities of the recommendation system.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-17
- Publication Date
- 2026-03-13
AI Technical Summary
Existing technologies suffer from a single learning dimension in multi-scenario user behavior modeling, failing to effectively utilize the behavioral characteristics of single and mixed scenarios, resulting in insufficient recommendation accuracy.
By constructing an operation summary graph and combining multi-dimensional walkthroughs to generate walkthrough paths in single and mixed scenarios, co-occurrence relationship data between the first and second objects is generated, enabling simultaneous learning of the commonalities of mixed scenario behavior and the characteristics of single scenario behavior.
It improves the learning accuracy of graph representation, enabling more accurate identification of user behavior patterns and preferences, and enhancing the accuracy and personalized service capabilities of recommendation systems.
Smart Images

Figure CN119782614B_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of computer technology, specifically to the fields of big data, large models, deep learning, and intelligent recommendation, and specifically to a method, apparatus, electronic device, and storage medium for constructing data for multiple scenarios. Background Technology
[0002] In information flow recommendation systems, multiple scenarios often exist for user consumption. User behavior across these scenarios constitutes a complete behavioral trajectory, and unified modeling of user behavior across multiple scenarios is beneficial for improving recommendation accuracy. Graph models have become a popular user behavior modeling technique in recent years, but there is limited work on multi-scenario behavior modeling. Therefore, how to construct multi-scenario data based on graph models has become an urgent technical problem to be solved. Summary of the Invention
[0003] This disclosure provides a method, apparatus, electronic device, and storage medium for constructing data for multiple scenarios.
[0004] According to one aspect of this disclosure, a method for constructing multi-scenario data is provided, the method comprising:
[0005] Based on the operation data of the first object in multiple scenarios, an operation summary graph is constructed. The operation summary graph includes a first node representing the first object, a second node representing the second object, and an edge connecting the first node and the second node. The second object is the object that publishes resources.
[0006] Based on the operation summary graph, multi-dimensional traversal is performed to generate a first traversal path for each single scene and a second traversal path for each mixed scene;
[0007] Co-occurrence relationship data between the first object and the second object is generated based on the first traversal path and the second traversal path.
[0008] According to another aspect of this disclosure, a multi-scenario data construction apparatus is provided, the apparatus comprising:
[0009] The first construction module is used to construct an operation summary graph based on the operation data of the first object in multiple scenarios. The operation summary graph includes a first node representing the first object, a second node representing the second object, and an edge connecting the first node and the second node. The second object is an object that publishes resources.
[0010] The first generation module is used to perform multi-dimensional traversal based on the operation summary graph, and generate a first traversal path for each single scene and a second traversal path for each mixed scene;
[0011] The second generation module is used to generate co-occurrence relationship data between the first object and the second object based on the first traversal path and the second traversal path.
[0012] According to another aspect of this disclosure, an electronic device is provided, comprising:
[0013] At least one processor; and
[0014] The memory is communicatively connected to the at least one processor; wherein,
[0015] The memory stores instructions that can be executed by the at least one processor to enable the at least one processor to perform any of the methods described in the present disclosure.
[0016] According to another aspect of this disclosure, a non-transitory computer-readable storage medium is provided storing computer instructions, wherein the computer instructions are used to cause the computer to perform any of the methods according to embodiments of this disclosure.
[0017] According to another aspect of this disclosure, a computer program product is provided, including a computer program that, when executed by a processor, implements any of the methods according to embodiments of this disclosure.
[0018] By adopting the scheme disclosed herein, user behavior in both single and mixed scenarios is modeled simultaneously in a graph model. This allows the model to learn the commonalities of mixed scenario behavior as well as the characteristics of single scenario behavior, thereby improving the learning accuracy of graph representation.
[0019] It should be understood that the description in this section is not intended to identify key or essential features of the embodiments of this disclosure, nor is it intended to limit the scope of this disclosure. Other features of this disclosure will become readily apparent from the following description. Attached Figure Description
[0020] The accompanying drawings are provided to better understand this solution and do not constitute a limitation of this disclosure. Wherein:
[0021] Figure 1 This is a flowchart illustrating a multi-scenario data construction method according to an embodiment of the present disclosure;
[0022] Figure 2 This is a schematic diagram summarizing the operations of the recommendation platform according to an embodiment of the present disclosure;
[0023] Figure 3 This is a schematic diagram of the walkthrough path in a single scene and a mixed scene according to embodiments of this disclosure;
[0024] Figure 4 This is a schematic diagram of the structure of a multi-scenario data construction apparatus according to an embodiment of the present disclosure;
[0025] Figure 5 This is a schematic diagram of a scene constructed based on multi-scene data from embodiments of this disclosure;
[0026] Figure 6 This is a schematic diagram of the structure of an electronic device used to implement the multi-scenario data construction method of the embodiments of this disclosure. Detailed Implementation
[0027] The exemplary embodiments of this disclosure are described below with reference to the accompanying drawings, including various details of the embodiments to aid understanding, and should be considered merely exemplary. Therefore, those skilled in the art will recognize that various changes and modifications can be made to the embodiments described herein without departing from the scope of this disclosure. Similarly, for clarity and brevity, descriptions of well-known functions and structures are omitted in the following description.
[0028] In this document, the term "and / or" merely describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent three cases: A alone, A and B simultaneously, and B alone. The term "at least one" in this document indicates any combination of at least two of a plurality of elements. 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. The terms "first" and "second" in this document refer to and distinguish between multiple similar technical terms, not to restrict the order or to limit there to only two. For example, "first feature" and "second feature" refer to two categories / two features; the first feature can be one or more, and the second feature can also be one or more.
[0029] Furthermore, to better illustrate this disclosure, numerous specific details are set forth in the following detailed description. Those skilled in the art will understand that this disclosure can be practiced without certain specific details. In some instances, methods, means, components, and circuits well known to those skilled in the art have not been described in detail in order to highlight the main points of this disclosure.
[0030] Before introducing the technical solutions of the embodiments of this disclosure, the technical terms that may be used in this disclosure will be further explained:
[0031] Operation Summary Graph: A graph structure used to represent the interaction relationships between multiple objects. It contains nodes and connecting edges, where nodes represent objects and connecting edges represent the interaction relationships between objects.
[0032] Multi-dimensional traversal: In a graph structure, this refers to the process of traversing the graph according to certain rules and strategies. Multi-dimensional traversal takes into account different attributes and dimensions of the graph, and can generate a rich variety of traversal paths.
[0033] Co-occurrence relationship data: This represents data showing that two objects appear together in different scenarios. This data can reflect the relationships and patterns between objects.
[0034] Among related technologies, multi-scene modeling techniques can be categorized as follows:
[0035] 1. Unified wandering learning: Ignores context information and cannot learn user preferences in each individual scenario.
[0036] 2. Individual walk-through learning: It can only learn the user's preferences in a single scenario, and cannot transfer scenario behavior, thus it cannot learn the user's overall preferences.
[0037] To at least partially address one or more of the aforementioned problems and other potential issues, this disclosure proposes a multi-scene data construction method based on a graph model. This method simultaneously models the behavior of objects in single and mixed scenes within the graph model, enabling the learning of both the commonalities of mixed scene behavior and the unique characteristics of single-scene behavior, thereby improving the learning accuracy of graph representation. This solves the problem of existing graph model techniques having a single learning dimension for multi-scene behavior data, improving model learning performance and benefiting downstream task metrics.
[0038] This disclosure provides a method for constructing multi-scenario data. Figure 1 This is a flowchart illustrating a multi-scenario data construction method according to an embodiment of the present disclosure. This method can be applied to a multi-scenario data construction device. The multi-scenario data construction device is located in an electronic device. This electronic device includes, but is not limited to, fixed devices and / or mobile devices. For example, fixed devices include, but are not limited to, servers, which can be cloud servers or ordinary servers. Mobile devices include, but are not limited to, mobile phones, tablets, and vehicle-mounted terminals. In some possible implementations, the multi-scenario data construction method can also be implemented by a processor calling computer-readable instructions stored in memory. Figure 1 As shown, this multi-scenario data construction method includes:
[0039] S101. Based on the operation data of the first object in multiple scenarios, construct an operation summary graph; the operation summary graph includes a first node representing the first object, a second node representing the second object, and an edge connecting the first node and the second node, where the second object is the object that publishes resources;
[0040] S102. Perform multi-dimensional traversal based on the operation summary graph to generate the first traversal path in each single scene and the second traversal path in the mixed scene;
[0041] S103. Generate co-occurrence relationship data between the first object and the second object based on the first walk path and the second walk path.
[0042] In this embodiment of the disclosure, operational data refers to the interaction behavior data generated between the first object and the second object in a specific scenario, such as clicking, browsing, purchasing, and commenting. The resources published by the second object include, but are not limited to, articles, long videos, short videos, images, and product links.
[0043] In this embodiment of the disclosure, the user is aware of and agrees to the acquisition and use of the operation data, which complies with the relevant laws and regulations and does not violate public order and good morals.
[0044] In this embodiment of the disclosure, in the operation summary diagram, the first node represents a first object (such as a user), and the second node represents a second object (such as an object that publishes resources, such as a merchant, content creator, etc.).
[0045] In this embodiment of the disclosure, each single scene includes 1 scene; each mixed scene includes at least 2 scenes.
[0046] In this embodiment of the disclosure, in the operation summary diagram, the edges represent the interaction relationship between the first object and the second object, such as a user browsing a merchant's products or clicking on an author's work.
[0047] In some implementations, constructing an operation summary graph includes: First, collecting operation data of a first object (e.g., a user) across multiple scenarios. This operation data may include records of user actions such as clicks, browsing, purchases, following, forwarding, sharing, and liking. Then, using a graph database or graph processing framework, the collected operation data is used to construct an operation summary graph.
[0048] In this embodiment, the operation summary graph can display the behavioral characteristics of the first object in all scenarios, as well as in a single scenario (also known as a separate scenario or a single scene). Thus, the operation summary graph can integrate data from multiple scenarios to form a global behavioral profile. Through this global behavioral profile, the electronic device can quickly and accurately identify the commonalities and differences in the object's behavior across different scenarios. The operation summary graph can also focus on specific scenarios, and analyzing the object's specific behavior in a particular scenario based on the operation summary graph can improve the accuracy of identifying the object's behavioral preferences in a specific environment.
[0049] In some implementations, the operation summary graph can be either directed or undirected. Nodes and edges have attributes to represent different objects and interactions.
[0050] Figure 2 A schematic diagram summarizing the operations of the recommendation platform is shown, such as... Figure 2As shown, double-coiled nodes represent user nodes, and single-coiled nodes represent author nodes; for example, u1, u2, u3, u4, u5, and u6 represent user nodes; a1, a2, a3, a4, a5, a6, and a7 represent author nodes. When connecting edges, different attributes are assigned to the edges according to different scenarios. For example, recommendation scenarios can be divided into one-hop single-column, one-hop double-column, and two-hop scenarios. Figure 2 In the diagram, short dashed lines represent satisfactory consumption in a single-hop scenario, thick solid lines represent satisfactory consumption in a double-hop scenario, and dotted dashed lines represent satisfactory consumption in a two-hop scenario. Figure 2 This diagram showcases the user's satisfactory purchases across mixed scenarios supported by the recommendation platform, as well as their satisfactory purchases in a single scenario. It is understood that this diagram is illustrative rather than restrictive; the number of nodes and scenarios can be increased or decreased as needed, and the node representation and line type can also be set or changed accordingly.
[0051] In this embodiment of the disclosure, multi-dimensional roaming includes single-scene roaming and multi-scene roaming.
[0052] In some implementations, within a single scenario, a first traversal path is generated by traversing an operation summary graph. The first traversal path represents the sequence of interactions between a first object and a second object within the single scenario.
[0053] In some implementations, in a hybrid scenario, the interaction between at least two individual scenarios is considered to generate a second walkthrough path. The second walkthrough path spans different individual scenarios, reflecting the interaction relationship between the first object and the second object in different individual scenarios.
[0054] In some implementations, graph traversal algorithms such as depth-first search (DFS) and breadth-first search (BFS), or random walk-based algorithms, can be used to generate the walking path.
[0055] In this embodiment of the disclosure, co-occurrence relationships can be used to discover the correlation between different features or items in a dataset. For example, in a shopping dataset, if two products are frequently purchased by the same user, then a co-occurrence relationship exists between them, which can be used to build a recommendation system. For example, in a video dataset, co-occurrence relationships can be used to discover the correlation between users and authors. For instance, the co-occurrence of user viewing behavior and an author's work. When a large number of users watch an author's video, it can be considered that there is a co-occurrence relationship between that author's video and the users. This relationship can be used to recommend other works by that author to users, or to recommend that author's videos to other users. Another example is the co-occurrence relationship between users. In a video dataset, co-occurrence relationships between users can be analyzed. When two users watch a large number of the same videos, it can be considered that there is a co-occurrence relationship between these two users. By analyzing the co-occurrence relationships between users, user groups with similar interests or preferences can be discovered, thereby providing them with more personalized recommendation services. Yet another example is the co-occurrence relationship between authors. In a video dataset, co-occurrence relationships between authors can be analyzed. For example, when two authors' videos are frequently watched by users simultaneously, it can be considered that there is a co-occurrence relationship between these two authors. This relationship may stem from similarities in their creative styles, similarities in their themes, or shared influence in certain specific fields. Analyzing co-occurrence relationships among authors can further reveal the diversity and relevance of video content, thereby improving the accuracy and relevance of recommendations.
[0056] In some implementations, co-occurrence relationship data includes the identifiers of the first object, the second object, and the co-occurrence scene. Optionally, the co-occurrence relationship data may further include data such as the number of co-occurrences (how many times they co-occurred within a set time period), the co-occurrence time period (the time period during which co-occurrence occurred), and the co-occurrence location (the location where co-occurrence occurred). For example, co-occurrence relationship data can be represented as the interaction frequency, interaction depth, interaction time, and interaction location between users and merchants, users and content creators, etc.
[0057] For example, suppose there's an e-commerce platform where the first group is the user, and the second group is the merchant. By collecting user activity data such as browsing, purchasing, and reviews on the platform, an activity summary graph can be constructed. Then, based on this graph, multi-dimensional walkthroughs can be performed to generate user interaction paths with merchants in different scenarios (such as searching, browsing, and purchasing). Finally, based on these paths, co-occurrence relationship data between users and merchants can be generated, such as the number of times a user has purchased a product from a particular merchant and the number of times they have viewed it. This data can be used to optimize the accuracy and satisfaction of product recommendations.
[0058] The technical solution of this disclosure constructs an operation summary graph based on the behavioral data of a first object in multiple scenarios. This allows for the fusion of behavioral data from multiple scenarios to generate a more comprehensive operation summary graph, thereby more accurately reflecting the interaction relationship between the first object and the second object. Through multi-dimensional traversal, rich traversal paths can be generated, providing data support for subsequent co-occurrence relationship analysis and helping to discover potential associations and patterns. The generated co-occurrence relationship data can be applied to multiple fields, such as product recommendation, content recommendation, and service recommendation. By deeply mining the co-occurrence relationships between different fields, the accuracy and breadth of recommended content can be improved.
[0059] In some embodiments, an operation summary graph is constructed based on the operation data of the first object in multiple scenarios, including: constructing a first node, a second node, and an edge for each single scenario, wherein the edge identifiers corresponding to the edges in different single scenarios are different; and constructing an operation summary graph based on the first node, the second node, and the edges in each single scenario.
[0060] In this embodiment of the disclosure, a node represents an entity or object in the graph, specifically a user, resource, author, etc.
[0061] In this embodiment of the disclosure, edges represent connections or relationships between nodes. Specifically, they can represent interaction relationships between users and resources, such as browsing, purchasing, forwarding, and commenting. They can also represent interaction relationships between users and authors who publish resources, such as following, unfollowing, recommending, commenting, and replying.
[0062] In this embodiment of the disclosure, the edge identifier is an identifier or label used to distinguish the interaction relationship between nodes in different scenarios. The edge identifier includes at least a scenario identifier used to distinguish scenarios.
[0063] In some implementations, operational data of a first object (such as a user) in different scenarios is collected and organized. This data can include user interactions such as clicks, browsing, purchases, and comments in various scenarios, as well as attributes such as the time, frequency, and result of these interactions. Data collection can be conducted through various methods, including Software Development Kits (SDKs), log analysis, questionnaires, and third-party data platforms. In each single scenario, the first object (such as a user) and the second object interacting with it (such as a product, service, other users, or author) are treated as nodes. An edge is formed between two nodes with an interactive relationship, and this edge is assigned an edge label to indicate the type or nature of the interaction. For example, if user E purchases product F, an edge can be drawn between user E and product F, and the edge label can be "purchase". To distinguish the interactive relationships in different scenarios, different edge labels need to be assigned to the edges in different scenarios. For example, in an e-commerce scenario, the edge label could be "purchase", "browse", or "comment"; in a social scenario, the edge label could be "follow", "like", or "share". This ensures that when integrating data from multiple scenarios, the interaction relationships in different scenarios can be clearly identified.
[0064] In some implementations, the operation summary chart can be flexibly adjusted and optimized according to business needs and analysis objectives. Furthermore, once the operation summary chart is constructed, new scenarios and data sources can be added to it.
[0065] For example, suppose we need to analyze user activity data from a search website to understand user preferences. We can construct an activity summary graph by following these steps: **Define the analysis objective:** Understand user preferences on the search website. **Data collection and organization:** Collect user behavior data on the search website, such as browsing, searching, commenting, liking, and sharing, and organize it into a structured format. **Define nodes and edges:** Let node e represent user E, and node g represent author G. When a user browses works published by author G on the recommendation page, an edge is formed between node e and node g, labeled "Recommended"; when user E watches author G's live stream, another edge is formed between node e and node g, labeled "Live". **Distinguish edge labels for different scenarios:** In the search scenario, edge labels can be various search display formats supported by the search website, such as "Recommended," "Discover," "Trending Searches," and "Live". **Integrate nodes and edges into the graph:** Integrate all user nodes, author nodes, and the edges between them into a single graph to form the activity summary graph.
[0066] The technical solution of this disclosure integrates behavioral data from multiple scenarios to construct a comprehensive and accurate operation summary chart, providing strong support for recommendation analysis and decision-making. Through visualization processing, complex behavioral data can be transformed into an intuitive and easy-to-understand visual representation, significantly reducing the operational complexity of data processing and effectively improving overall data processing efficiency.
[0067] In some embodiments, in the operation summary graph, the first node records the object identifier representing the first object, the second node records the object identifier representing the second object, and the edges record the edge identifier representing the scene.
[0068] In this embodiment of the disclosure, the object identifier (OID) is used to uniquely identify a node in the graph as a string or number, such as a user identifier (ID), author ID, product ID, etc.
[0069] In this embodiment of the disclosure, the edge identifier is a string that can be used to uniquely identify the interaction type or property of edges in the graph. The edge identifier includes at least a scene identifier (SID). The scene identifier is a string that can be used to uniquely identify the scene category in the graph.
[0070] In some implementations, a unique object identifier is assigned to each node when constructing the operation summary graph. The object identifier distinguishes different nodes in the graph, ensuring each node can be uniquely identified. When a node is created, its object identifier is recorded as one of its attributes. This allows for quick location of specific nodes during subsequent analysis and querying. Similar to nodes, a unique scene identifier is assigned to each edge. The scene identifier distinguishes interaction relationships under different scenes in the graph, ensuring each edge can be accurately categorized into its respective scene. The scene identifier can be a string describing the type or nature of the interaction, such as "purchase," "browse," or "comment," or it can be a string describing the scene category, such as "search website," "e-commerce platform," or "video publishing platform." When an edge is created, the scene identifier is recorded as one of its attributes. This allows for quick identification of interaction relationships under specific scenes during subsequent analysis and querying. Nodes with object identifiers and edges with scene identifiers are integrated into the same graph to form a complete operation summary graph. This graph not only contains information about nodes and edges, but also their respective object identifiers and scene identifiers, providing rich data support for subsequent analysis and querying.
[0071] For example, consider an operational summary diagram of an e-commerce website, where nodes represent users and products, and edges represent the interactions between them. The following steps can be used to assign object and scenario identifiers to nodes and edges. First, assign object identifiers to nodes. For user nodes, assign a unique user ID as the object identifier for each user. For product nodes, assign a unique Stock Keeping Unit (SKU) code as the object identifier for each product. Next, assign scenario identifiers to edges. For a user browsing a product, the edge's scenario identifier is "Browsing". For a user purchasing a product, the edge's scenario identifier is "Purchasing". For a user commenting on a product, the edge's scenario identifier is "Commenting". An edge's scenario identifier can contain a diverse sequence of scenario identifiers, such as combinations of specific scenario identifiers like browsing, purchasing, and commenting. This allows each edge to be accurately labeled, reflecting the user's interaction with products or services in different scenarios. These scenario identifiers provide a deeper understanding of user preferences and behavioral patterns, enabling more personalized recommendations and services. Finally, integrate the user nodes with user IDs and the product nodes with SKU codes into the diagram. Edges with scene identifiers (such as "Browse", "Purchase", "Review") are connected to the corresponding nodes. This constructs an operation summary graph containing object and scene identifiers, providing strong support for subsequent analysis and querying.
[0072] The technical solution described in this embodiment improves the accuracy and consistency of data representation by assigning unique object identifiers and scene identifiers to nodes and edges. These object identifiers and scene identifiers allow for rapid location of specific nodes and edges, improving the efficiency of data querying and processing.
[0073] In some embodiments, multi-dimensional traversal is performed based on the operation summary graph to generate a first traversal path in each single scene and a second traversal path in a mixed scene, including: distinguishing different single scenes according to the edge identifiers in the operation summary graph; in each single scene, traversing according to the connection relationship between the first node and the second node to obtain the first traversal path; and in the mixed scene, traversing according to the connection relationship between the first node and the second node to obtain the second traversal path.
[0074] In this embodiment of the disclosure, the traversal path is a path generated by traversing the graph based on the connection relationships between nodes.
[0075] In this embodiment of the disclosure, a single scene is a single specific scene in a multi-scene set, and each scene in the multi-scene set can be used as a single scene.
[0076] In this embodiment of the disclosure, a hybrid scenario includes a combination of at least two single scenarios. Multiple scenarios can form various hybrid scenarios. For example, if multiple scenarios include scenario one, scenario two, and scenario three, then the first hybrid scenario includes scenario one and scenario two; the second hybrid scenario includes scenario two and scenario three; the third hybrid scenario includes scenario one and scenario three; and the fourth hybrid scenario includes scenario one, scenario two, and scenario three.
[0077] In some implementations, different scenarios are distinguished in the operation summary graph based on edge labels. For example, all edges labeled "Purchase" represent the purchase scenario, and all edges labeled "Browse" represent the browsing scenario.
[0078] In some implementations, generating a first traversal path within a single scenario includes: selecting a specific scenario, such as a purchase scenario, from an operation summary graph; selecting a starting node within that scenario, such as a user node; performing Depth-First Search (DFS) or Browsing-First Search (BFS) from the starting node based on the connections between nodes to generate a traversal path within that scenario. This path will contain a series of connected nodes representing objects that the user may access or interact with in that scenario. The generated traversal path is recorded as the first traversal path.
[0079] In some implementations, generating a second walkthrough path within a hybrid scenario includes: selecting at least two individual scenarios from the operation summary graph to combine them into a hybrid scenario; selecting a starting node and setting scenario switching conditions, such as switching from a browsing scenario to a purchasing scenario if the user clicks a purchase button; and starting the walkthrough from the starting node based on the connections between nodes and the scenario switching conditions. During the walkthrough, when the scenario switching conditions are met, the walkthrough path switches to the new scenario and continues walking within that scenario. This generates a hybrid walkthrough path containing multiple scenarios.
[0080] by Figure 2 Based on the operation summary chart shown, Figure 3 The diagram illustrates the walkthrough paths for single-scene and mixed-scene scenarios, as shown below. Figure 3As shown, in a single-column behavior scenario, the path is: Author a2 - User u2 - Author a6 - User u5; in a double-column behavior scenario, the path is: Author a5 - User u3 - Author a2 - User u1; in a two-hop behavior scenario, the path is: Author a4 - User u3 - Author a7 - User u6; and in a mixed behavior scenario (including single-column, double-column, and two-hop behaviors), the path is: Author a1 - User u3 - Author a4 - User u4. It should be understood that this diagram is illustrative rather than restrictive. The number of nodes in each path under a single scenario can be increased or decreased as needed, and the number of nodes and scenarios under mixed scenarios can be increased or decreased as needed.
[0081] For example, suppose there's a summary graph of search website operations, including user nodes, author nodes, and their interactions (such as browsing, following, commenting, and saving). A walkthrough path can be generated by following these steps: Single-scenario walkthrough path generation: Select the "Following" scenario. Select a user node as the starting node. Based on the interaction between the user and the author (e.g., clicking the "Follow" button), perform a depth-first search or breadth-first search from the starting node to generate the walkthrough path for the "Following" scenario. Mixed-scenario walkthrough path generation: Select both the browsing and following scenarios as a mixed scenario. Select a user node as the starting node. Set scenario switching conditions, such as a user clicking the "Follow" button while browsing. Based on the interaction between the user and the author and the scenario switching conditions, start the walkthrough from the starting node. For example, a user might browse multiple work pages from the homepage and then click the "Follow" button when browsing a particular work.
[0082] The technical solution of this disclosure, through multi-dimensional traversal, can generate traversal paths encompassing multiple single and mixed scenarios, improving the comprehensiveness and accuracy of the traversal paths. Furthermore, the generated traversal paths can be used for visualization analysis, helping users more intuitively understand their behavioral paths and interaction relationships in different scenarios, thus enhancing user experience. Based on the generated traversal paths, the recommendation system can identify user behavior patterns and preference trends, thereby optimizing personalized recommendation algorithms and improving the accuracy of recommended content and user satisfaction.
[0083] In some embodiments, generating co-occurrence relationship data between a first object and a second object based on a first wandering path and a second wandering path includes: selecting at least two single scenes from multiple scenes as target scenes; determining a target first wandering path and a target second wandering path from the first wandering path and the second wandering path based on the edge identifiers corresponding to the target scenes; and traversing the target first wandering path and the target second wandering path to obtain co-occurrence relationship data.
[0084] In this embodiment of the disclosure, the target scenario is a specific scenario selected from multiple scenarios for analyzing the co-occurrence relationship of objects.
[0085] In this embodiment of the disclosure, co-occurrence relationship data reflects the co-occurrence of objects in different scenarios. This type of data is typically used to analyze the correlation, similarity, or potential connections between objects. For example, co-occurrence relationship data reflects the co-occurrence of a first object and a second object, which are two objects that need to be considered when analyzing object co-occurrence relationships, such as user D and author H.
[0086] In some implementations, at least two individual scenarios are selected as target scenarios from multiple scenarios. These target scenarios can be determined based on business analysis needs; for example, if it is desired to analyze the co-occurrence relationship of objects in user browsing and purchasing scenarios, these two scenarios can be selected as target scenarios.
[0087] In some implementations, based on the edge identifiers corresponding to the target scene, a target first wandering path and a target second wandering path related to the target scene are selected from the previously generated first wandering path and second wandering path. These wandering paths should only contain nodes and edges under the target scene. For example, if single scene one and single scene two are selected as target scenes, and the mixed scene includes a mixed scene composed of single scene one and single scene two, then the second wandering path with the characteristics of this mixed scene is selected from multiple second wandering paths as the target second wandering path. If the mixed scene does not include such a mixed scene composed of single scene one and single scene two, then the target second wandering path is generated based on the first wandering path of single scene one, the second wandering path of single scene two, and the switching form of single scene one and single scene two.
[0088] In some implementations, the first and second walkthrough paths of the target are traversed, recording the number of times and positions where the first and second objects co-occur in each walkthrough path. The co-occurrence data can be a two-dimensional matrix, where rows and columns represent different objects, and the values in the matrix represent the number of times the two objects co-occur. Furthermore, location information of the co-occurrence can also be recorded, such as the scene or node in which they co-occur.
[0089] In some implementations, the generated co-occurrence relationship data is organized and optimized. Operations such as deduplication and filtering of invalid data are performed to ensure the accuracy and reliability of the data. Furthermore, the data can be further analyzed and mined as needed to extract more valuable information.
[0090] In some implementations, the method further includes: in response to detecting a preset trigger operation, outputting co-occurrence relationship data in a visual format. This helps users more intuitively understand the co-occurrence of objects in different scenarios, providing a clear basis for business decisions.
[0091] For example, suppose we have user action data from an e-commerce website, and we've already generated browsing and purchase paths. We want to analyze the co-occurrence relationship between products F and S in these scenarios. We select browsing and purchase scenarios as the target scenarios. From the previously generated paths, we filter out target paths related to both browsing and purchase scenarios. We iterate through these target paths, recording the co-occurrence frequency and position of products F and S in each path. For instance, in the browsing scenario, products F and S might frequently appear on the same page or adjacent pages; in the purchase scenario, users might frequently purchase both products F and S simultaneously.
[0092] The technical solution described in this disclosure, by traversing the walkthrough path and recording the co-occurrence of objects, can accurately reflect the co-occurrence relationship between the first and second objects in different scenarios, providing strong support for accurate recommendations. This method is adaptable to different scenarios and objects; co-occurrence relationship data can be generated simply by selecting the corresponding target scenario and object, improving the efficiency of co-occurrence relationship data generation. Furthermore, the data can be further analyzed and mined as needed to meet the recommendation requirements in different scenarios, thereby improving the accuracy of recommendations.
[0093] In some embodiments, generating co-occurrence relationship data between a first object and a second object based on a first traversal path and a second traversal path includes: traversing all nodes in the first traversal path and the second traversal path to record the co-occurrence relationships between all other nodes; traversing all recorded co-occurrence relationships and filtering the data according to at least one of a preset co-occurrence frequency threshold and scene importance information to obtain co-occurrence relationship data.
[0094] In this embodiment of the disclosure, the traversal path is a path generated by traversing the graph based on the connection relationship between nodes, and is used to represent the behavior pattern of an object in different scenarios.
[0095] In this embodiment of the disclosure, co-occurrence relationship is an association relationship in which two objects appear simultaneously in the same scene or path.
[0096] In this embodiment of the disclosure, the preset co-occurrence frequency threshold is a threshold used to filter meaningful co-occurrence relationships. Only co-occurrence relationships with a co-occurrence frequency exceeding this threshold will be retained.
[0097] In this embodiment of the disclosure, scene importance information is an indicator used to assess the importance of a scene. For example, only co-occurrence relationships that occur in important scenes are given priority or retained. Conversely, co-occurrence relationships that occur in unimportant scenes are given priority or retained.
[0098] In some implementations, the walkthrough path is traversed and co-occurrence relationships are recorded, including:
[0099] Initialize the data structure; specifically, create a data structure (such as a dictionary or database) to store co-occurrence relationship data. This data structure should be able to record the number of times each node co-occurs with other nodes, as well as the context information of the co-occurrence.
[0100] Iterate through each node in the first and second walk paths in turn. For each node in a path, check its connection relationship with other nodes.
[0101] For each node, record its co-occurrence relationship with its neighboring nodes. For example, record the number of co-occurrences (i.e., the number of times two nodes appear adjacently in the path) and the scenario in which the co-occurrence occurs (i.e., in which walk path or scenario the co-occurrence relationship occurs).
[0102] In some implementations, preset co-occurrence frequency thresholds and / or scenario importance information are set according to business needs. These thresholds and metrics are used to filter meaningful co-occurrence relationships. All recorded co-occurrence relationships are iterated through, and data is filtered based on the set thresholds and importance metrics. Only co-occurrence relationships that exceed the threshold or frequently appear in important scenarios are retained. The filtered data is then processed for further analysis and visualization. This may include converting the data to a specific format, removing redundant information, or merging similar co-occurrence relationships.
[0103] In some implementations, the processed co-occurrence data is output in a format that is easy to analyze and visualize, such as a comma-separated values (CSV) file, a table, or a database.
[0104] For example, suppose we have operational data from a social media platform, and we've already generated user browsing paths across different scenarios. Now, we want to analyze the co-occurrence relationships of specific topics (such as "travel" and "food") across these scenarios. We would set a co-occurrence frequency threshold (e.g., 5 times) and scenario importance indicators (e.g., "hot topic discussion forums" and "user profile pages"). We would iterate through user browsing paths across different scenarios, recording each user's mentions and co-occurrence of the topic. We would then filter out co-occurrence relationships that occur more than 5 times or frequently in important scenarios such as "hot topic discussion forums" and "user profile pages." Finally, we would use visualization tools to analyze the co-occurrence of the topics "travel" and "food" across different scenarios, revealing user preferences and associations with different topics.
[0105] The technical solution described in this embodiment can accurately capture the co-occurrence of objects in different scenarios by traversing the walk path and recording co-occurrence relationships. By adjusting the preset co-occurrence frequency threshold or scenario importance information, co-occurrence relationship data that meets specific requirements can be generated more flexibly, improving the generation efficiency and diversity of co-occurrence relationship data.
[0106] In some embodiments, multiple scenarios include scenarios corresponding to different applications.
[0107] In some implementations, multiple scenarios are defined as specific environments or contexts corresponding to different applications. Each application has its unique user interface, functions, and services, which together constitute the application's scenario.
[0108] In some implementations, collecting roaming path data includes: for each application, collecting user behavior data within its context through a built-in behavior tracking system (such as logging, event tracking, etc.). Based on the collected behavior data, generating user roaming paths within each application context. These paths reflect the user's navigation and interaction patterns across different pages, functions, or services.
[0109] In some implementations, generating co-occurrence relationship data includes defining pages, functions, or services as nodes within each application's context. These nodes are the basic units of user behavior. The user's journey within each application context is traversed, and co-occurrence relationships between different nodes are recorded. A co-occurrence relationship can be defined as the number or frequency of times two nodes appear adjacent to each other in the same journey. If the analysis target is cross-application co-occurrence relationships, it is also necessary to integrate and correlate context data from different applications, which can be achieved using user IDs, timestamps, or other unique identifiers.
[0110] In some implementations, meaningful co-occurrence relationship data is filtered based on preset co-occurrence frequency thresholds or scenario importance indicators. Visualization tools (such as network graphs and heatmaps) are used to display co-occurrence relationship data under different application scenarios, helping to discover user behavior patterns and associations across different applications.
[0111] For example, suppose there are two applications: a social media platform and an e-commerce platform. Users switch between these two applications and perform different actions within each. On the social media platform, users browse posts, like, comment, and share content; these actions constitute the user's journey on the social media platform. On the e-commerce platform, users search for products, view details, add items to their cart, and make purchases; these actions constitute the user's journey on the e-commerce website. By integrating contextual data from these two applications, we can discover that after seeing an advertisement for a product on the social media platform, a user might be redirected to the e-commerce platform to make a purchase. This cross-application co-occurrence relationship provides valuable insights for personalized recommendations and marketing strategies. Understanding user behavior patterns and connections across different applications helps businesses develop more effective marketing strategies and plans.
[0112] The technical solution described in this disclosure, because multiple scenarios include scenarios corresponding to different applications, can obtain a comprehensive understanding of user behavior across multiple applications by integrating and analyzing co-occurrence relationship data under different application scenarios. This allows for a more comprehensive understanding of user preferences and needs. This cross-application data integration not only promotes the consistency and personalization of the service experience but also significantly improves the accuracy of recommendations and user satisfaction.
[0113] In some embodiments, multiple scenarios include scenarios corresponding to different projects within the same application.
[0114] In some implementations, the scenarios corresponding to different projects or functional modules are clearly defined within a single application. These scenarios can be categorized based on multiple dimensions such as user behavior, content type, and functional modules. For example, a social media application might include scenarios such as news browsing, friend interaction, video viewing, and live streaming.
[0115] In some implementations, in-application logging systems, event tracking tools, and other technologies are used to collect user behavior data in different scenarios. The collected data undergoes preprocessing operations such as cleaning, deduplication, and formatting to ensure data quality and consistency.
[0116] In some implementations, scene feature extraction includes: analyzing user behavior data in different scenarios to extract key features, such as access frequency, dwell time, and number of interactions. For scenarios involving content (such as articles, images, and videos), content features are extracted, such as categories, tags, and keywords. For certain specific scenarios, it may be necessary to extract technology-related features, such as network speed and device type.
[0117] In some implementations, multi-scenario data analysis includes: identifying user behavior patterns and preferences by analyzing user behavior data in different scenarios; exploring the correlations and mutual influences between different scenarios, such as the probability of a user switching from a news browsing scenario to a video watching scenario; and providing users with personalized content recommendations and feature optimizations based on the results of multi-scenario data analysis.
[0118] In some implementations, the application's layout, functional design, and content recommendations are adjusted based on the analysis results. More precise marketing strategies, such as targeted advertising and event planning, are developed using the results of multi-scenario data analysis. A continuous data monitoring and feedback mechanism is established to promptly identify and address issues within the application, continuously optimizing the effectiveness of multi-scenario data analysis.
[0119] For example, suppose there's a social media application that includes news browsing, friend interaction, and video viewing scenarios. In the news browsing scenario, users can browse the latest news and like, comment, or share content that interests them. In the friend interaction scenario, users can chat with friends, like, comment, and share snippets of their lives and hobbies. In the video viewing scenario, users can watch short videos or live streams, like, comment, share, or purchase related products. Through multi-scenario data analysis, we can discover user behavior patterns and preferences in different scenarios. For example, some users prefer to get the latest information in the news browsing scenario, while others prefer to watch entertainment content in the video viewing scenario. Based on these analysis results, the application can be personalized and optimized, such as pushing more news information to users who like news and providing more video content recommendations to users who like videos.
[0120] The technical solutions described in this disclosure, because multiple scenarios include scenarios corresponding to different projects within the same application, can integrate and optimize co-occurrence relationship data from different projects through multi-scenario data analysis. This reveals potential connections and patterns between data, improving data utilization. By sharing co-occurrence relationship data, applications can gain a deeper understanding of user preferences and behavioral patterns. This enables applications to provide users with more personalized content and services, such as customized recommendations and personalized interfaces, thereby improving the accuracy of recommendations and increasing user satisfaction.
[0121] In some embodiments, the multi-scenario data construction method further includes: constructing a first representation vector of a first object and a second representation vector of a second object in an operation summary graph based on co-occurrence relationship data; and determining, based on the similarity between the first representation vector and the second representation vector, resources to be recommended that match the first object from the resources published by the second object.
[0122] In this embodiment of the disclosure, co-occurrence relationship data refers to the association data between objects in different scenarios. These objects can be users, pages, products, etc., depending on the application scenario. Co-occurrence relationship data can be used to analyze the correlation and similarity between objects.
[0123] In this embodiment of the disclosure, the representation vector is a vector used to describe the characteristics of an object. In resource recommendation methods, representation vectors are typically constructed based on co-occurrence relationship data to represent the similarity and association between objects.
[0124] In this embodiment of the disclosure, similarity is an indicator that measures the degree of similarity between two objects. In resource recommendation methods, similarity is typically used to assess the proximity between the representation vectors of two objects, thereby determining the degree of matching between them.
[0125] In this embodiment of the disclosure, the resources to be recommended are those that meet the user's needs and are selected from the resource library.
[0126] In some implementations, features are extracted for each object based on co-occurrence relationship data. These features may include the object's frequency of occurrence, the number of times it co-occurs with other objects, and the context of co-occurrence. Using the extracted features, a representation vector is constructed for each object. This vector can be a high-dimensional sparse vector, where each dimension represents a feature, and the vector's value represents the importance or strength of that feature.
[0127] In some implementations, for a given first and second object, the similarity of their representation vectors is calculated. There are many methods for calculating similarity, such as cosine similarity, Euclidean distance, and Manhattan distance. The specific method chosen depends on the application scenario and the characteristics of the data.
[0128] In some implementations, determining the resources to be recommended includes: based on the similarity between a first representation vector and a second representation vector, selecting resources from the resources published by the second object that match the first object as resources to be recommended. Resources with higher similarity are more likely to meet the needs and preferences of the first object.
[0129] In some implementations, the selected resources to be recommended are recommended to a first object, and feedback data from the first object is collected. This feedback data can be used to evaluate the recommendation effect and further optimize the recommendation algorithm.
[0130] For example, suppose there's an online shopping platform where user K browses multiple products and purchases some of them. Meanwhile, user Q posts product information on the same platform. By analyzing user K's browsing and purchase history, we can construct co-occurrence relationship data between user K and different products. Based on this co-occurrence relationship data, we construct a representation vector for user K and each product. We calculate the similarity between user K's representation vector and the representation vector of each product. From the products posted by user Q, we select products with high similarity to user K as recommendation resources. These selected products are recommended to user K, and we collect user feedback data to optimize the recommendation algorithm.
[0131] The technical solution described in this disclosure, by constructing representation vectors and calculating similarity, can provide personalized recommendation services for each user, thereby improving the accuracy of recommendations. Utilizing co-occurrence relationship data to construct representation vectors allows for the rapid filtering of resources that match user needs, improving recommendation efficiency.
[0132] The following section uses the user-author graph in a recommendation system scenario as an example to illustrate the construction of data in multiple scenarios.
[0133] 1. Multi-Scenario User Behavior Graph Construction: Extract user behaviors across all scenarios. When a user has a satisfactory consumption of a resource, a <user, author> pair is formed. Connect the user and the author of the satisfactory resource with an edge. By summarizing all satisfactory consumption behaviors on a single graph, we can obtain all satisfactory consumption behaviors of all users in their respective scenarios. When connecting edges, different attributes are assigned to the edges according to different scenarios. For example, recommendation scenarios can be divided into one-hop single column, one-hop double column, two-hop scenarios, etc. For example, user u2 consumes articles by authors a2, a4, and a6 in a one-hop single column and articles by author a3 in a one-hop double column. User u3 consumes articles by authors a2, a1, and a5 in a one-hop double column and articles by authors a4 and a7 in a two-hop scenario. In multi-scenario graph construction, user nodes (u2, u3) and author nodes (a1, a2, a3, a4, a5, a6, a7) are connected through consumption behaviors to form an operation summary graph, and different attributes (colors) are used to distinguish the consumption behaviors in each scenario.
[0134] 2. Multi-dimensional Journey: Multi-dimensional journeys are performed based on the operation summary graph, simultaneously exploring single-scene and mixed-scene behaviors to achieve comprehensive co-occurrence learning of behaviors in both scenarios. Journeys along edges of the same type are considered single-scene journeys; journeys without edge attribute restrictions are considered mixed-scene journeys. For example, in recommendation scenarios, this distinguishes between single-hop single-column behaviors, single-hop double-column behaviors, and two-hop behaviors, representing both single-scene and mixed-scene behavior journeys. Multi-dimensional journeys on the operation summary graph generate multiple journey paths, with no restrictions on the journey method. This results in single-scene journey paths (e.g., single-column behavior a2-u2-a6-u5) and mixed multi-scene journey paths (e.g., a1-u3-a4-u4).
[0135] 3. Semantic Vector Transfer: Based on multi-dimensional traversal paths, co-occurrence pairs of users in single and mixed scenarios are extracted for graph representation learning training. During training, all nodes use shared embeddings under co-occurrence pairs in different scenarios. While ensuring the unique information of each scenario, this enhances the collaboration and knowledge transfer capabilities between multiple scenarios, thereby more comprehensively depicting user behavior and improving the expressive power of the graph model.
[0136] Graph model training is performed on multi-dimensional traversal paths. First, co-occurring pairs are generated. Then, the node vector representations are optimized to maximize the pair similarity, which can be achieved using cosine similarity.
[0137]
[0138] Or you can directly use the inner product:
[0139] sim = A·B
[0140] With multi-dimensional traversal paths, we can generate both co-occurrence behaviors of users in a unified scenario and co-occurrence behaviors of users in a single scenario. This allows the node vector representation to depict both the general behaviors of users across all scenarios and to retain the unique preferences in a single scenario.
[0141] During training, a positive sample pair (a pair with a co-occurrence relationship, such as a2, u2, u2, u5) and N (N is a positive integer not less than 1) negative sample pairs (a pair without a co-occurrence relationship, such as u1, a7, u1, u6) are input simultaneously, and the contrastive learning loss is calculated:
[0142]
[0143] Where e i A vector representing each node. e represents the vector of positive sample pairs that co-occur with node i. jA vector representing the negative sample pair nodes in a co-occurrence relationship.
[0144] 4. Recommendation based on node vector representation: In a recommendation process, the vector representation e of the target user is obtained. u and the vector representation of all candidate resources e a Calculate e u and all e a Based on the similarity, recommendations with high similarity will be given to users.
[0145] Thus, by constructing graphs of user behavior across multiple scenarios, employing multi-dimensional walkthroughs and semantic vector transfer, the graph model simultaneously models the behavioral sequences of objects in both single and mixed scenarios. This allows the model to learn both the commonalities of behaviors in mixed scenarios and the unique characteristics of behaviors in single scenarios, thereby improving the learning accuracy of the graph representation. This multi-scenario data construction method not only solves the problem of existing graph model technologies having a single learning dimension for multi-scenario behavioral data but also improves the model's learning performance, which is beneficial for improving downstream task metrics.
[0146] This disclosure provides a multi-scenario data construction apparatus, such as... Figure 4 As shown, the multi-scene data construction device may include: a first construction module 401, used to construct an operation summary graph based on the operation data of a first object in multiple scenes, the operation summary graph including a first node representing the first object, a second node representing the second object, and an edge connecting the first node and the second node, the second object being an object that publishes resources; a first generation module 402, used to perform multi-dimensional walking based on the operation summary graph, generating a first walking path in each single scene and a second walking path in a mixed scene; and a second generation module 403, used to generate co-occurrence relationship data between the first object and the second object based on the first walking path and the second walking path.
[0147] In some embodiments, the first construction module 401 includes: a production submodule, used to construct a first node, a second node, and an edge for each single scenario, wherein the edge identifiers corresponding to the edges in different single scenarios are different; and an integration submodule, used to construct an operation summary graph based on the first node, the second node, and the edges in each single scenario.
[0148] In some embodiments, in the operation summary graph, the first node records an object identifier representing a first object, the second node records an object identifier representing a second object, and the edges record edge identifiers representing the scene.
[0149] In some embodiments, the first generation module 402 includes: an identification submodule, configured to distinguish different single scenes based on the edge identifiers in the operation summary graph; a first traversal submodule, configured to traverse according to the connection relationship between the first node and the second node in each single scene to obtain a first traversal path; and a second traversal submodule, configured to traverse according to the connection relationship between nodes in a mixed scene to obtain a second traversal path.
[0150] In some embodiments, the second generation module 403 includes: a selection submodule, configured to select at least two scenarios as target scenarios from multiple scenarios; a determination submodule, configured to determine a target first wandering path and a target second wandering path from a first wandering path and a second wandering path based on the edge identifiers corresponding to the target scenarios; and a first generation submodule, configured to traverse the target first wandering path and the target second wandering path to obtain co-occurrence relationship data.
[0151] In some embodiments, the second generation module 403 includes: a recording submodule, used to record the co-occurrence relationship between all nodes by traversing all nodes in the first and second traversal paths; and a second generation submodule, used to traverse all recorded co-occurrence relationships and filter the data according to at least one of a preset co-occurrence frequency threshold and scene importance information to obtain co-occurrence relationship data.
[0152] In some embodiments, multiple scenarios include scenarios corresponding to different applications.
[0153] In some embodiments, multiple scenarios include scenarios corresponding to different projects within the same application.
[0154] In some embodiments, the multi-scenario data construction apparatus further includes: a second construction module ( Figure 4 (Not shown), used to construct a first representation vector of the first object and a second representation vector of the second object in the operation summary graph based on co-occurrence relationship data; determination module ( Figure 4 (Not shown), used to determine recommended resources that match the first object from the resources published by the second object based on the similarity between the first representation vector and the second representation vector.
[0155] The specific functions and examples of each module and submodule of the apparatus in this disclosure can be found in the relevant descriptions of the corresponding steps in the above method embodiments, and will not be repeated here.
[0156] The multi-scene data construction apparatus of this disclosure improves the learning accuracy of graph representation by simultaneously modeling user behavior in single and mixed scenes in a graph model. This allows the model to learn the commonalities of mixed scene behavior as well as the characteristics of single scene behavior.
[0157] This disclosure provides a scenario illustration of a multi-scenario data construction method, such as... Figure 5 As shown.
[0158] As previously described, the multi-scenario data construction method provided in this disclosure is applied to electronic devices. Electronic devices are intended to represent various forms of digital computers, such as laptops, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframes, and other suitable computers. Electronic devices can also represent various forms of mobile devices, such as personal digital assistants, cellular phones, smartphones, wearable devices, and other similar computing devices.
[0159] Specifically, the electronic device may perform the following operations:
[0160] Based on the operation data of the first object in multiple scenarios, construct an operation summary graph;
[0161] Based on the operation summary graph, multi-dimensional walkthrough is performed to generate the first walkthrough path in each single scene and the second walkthrough path in the mixed scene;
[0162] Co-occurrence relationship data between the first object and the second object is generated based on the first and second walk paths.
[0163] It should be understood that Figure 5 The scene diagrams shown are merely illustrative and not restrictive; those skilled in the art can interpret them based on... Figure 5 Even with various obvious changes and / or substitutions to the examples, the resulting technical solutions still fall within the scope of this disclosure.
[0164] The acquisition, storage, and application of user personal information involved in the technical solution disclosed herein comply with the provisions of relevant laws and regulations and do not violate public order and good morals.
[0165] According to embodiments of this disclosure, this disclosure also provides an electronic device, a readable storage medium, and a computer program product.
[0166] Figure 6 A schematic block diagram of an example electronic device 600 that can be used to implement embodiments of the present disclosure is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device may also represent various forms of mobile devices, such as personal digital assistants, cellular phones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the present disclosure described and / or claimed herein.
[0167] like Figure 6 As shown, device 600 includes a computing unit 601, which can perform various appropriate actions and processes based on a computer program stored in read-only memory (ROM) 602 or a computer program loaded from storage unit 608 into random access memory (RAM) 603. RAM 603 may also store various programs and data required for the operation of device 600. The computing unit 601, ROM 602, and RAM 603 are interconnected via bus 604. Input / output (I / O) interface 605 is also connected to bus 604.
[0168] Multiple components in device 600 are connected to I / O interface 605, including: input unit 606, such as keyboard, mouse, etc.; output unit 607, such as various types of monitors, speakers, etc.; storage unit 608, such as disk, optical disk, etc.; and communication unit 609, such as network card, modem, wireless transceiver, etc. Communication unit 609 allows device 600 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks.
[0169] The computing unit 601 can be various general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of the computing unit 601 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. The computing unit 601 performs the various methods and processes described above, such as the multi-scene data construction method. For example, in some embodiments, the multi-scene data construction method can be implemented as a computer software program tangibly contained in a machine-readable medium, such as storage unit 608. In some embodiments, part or all of the computer program can be loaded and / or installed on device 600 via ROM 602 and / or communication unit 609. When the computer program is loaded into RAM 603 and executed by the computing unit 601, one or more steps of the multi-scene data construction method described above can be performed. Alternatively, in other embodiments, the computing unit 601 may be configured to perform a multi-scenario data construction method by any other suitable means (e.g., by means of firmware).
[0170] Various embodiments of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems-on-chip (SoCs), complex programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include implementations in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a dedicated or general-purpose programmable processor, capable of receiving data and instructions from a storage system, at least one input device, and at least one output device, and transmitting data and instructions to the storage system, the at least one input device, and the at least one output device.
[0171] The program code used to implement the methods of this disclosure may be written in any combination of one or more programming languages. This program code may be provided to a processor or controller of a general-purpose computer, special-purpose computer, or other programmable data processing apparatus, such that when executed by the processor or controller, the program code causes the functions / operations specified in the flowcharts and / or block diagrams to be implemented. The program code may be executed entirely on a machine, partially on a machine, as a standalone software package partially on a machine and partially on a remote machine, or entirely on a remote machine or server.
[0172] In the context of this disclosure, a machine-readable medium can be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can be, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory, read-only memory, erasable programmable read-only memory (EPROM), flash memory, optical fiber, compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.
[0173] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a cathode ray tube (CRT) or liquid crystal display (LCD) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user provides input to the computer. Other types of devices can also be used to provide interaction with the user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including sound input, voice input, or tactile input).
[0174] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as a data server), or computing systems that include middleware components (e.g., an application server), or computing systems that include frontend components (e.g., a user computer with a graphical user interface or web browser through which a user can interact with implementations of the systems and technologies described herein), or any combination of such backend, middleware, or frontend components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., a communication network). Examples of communication networks include local area networks (LANs), wide area networks (WANs), and the Internet.
[0175] Computer systems can include clients and servers. Clients and servers are generally located far apart and typically interact via communication networks. Client-server relationships are created by computer programs running on the respective computers and having a client-server relationship with each other. Servers can be cloud servers, servers in distributed systems, or servers incorporating blockchain technology.
[0176] It should be understood that the various forms of processes shown above can be used to rearrange, add, or delete steps. For example, the steps described in this disclosure can be executed in parallel, sequentially, or in different orders, as long as the desired result of the technical solution disclosed in this disclosure can be achieved, and this is not limited herein.
[0177] The specific embodiments described above do not constitute a limitation on the scope of protection of this disclosure. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the principles of this disclosure should be included within the scope of protection of this disclosure.
Claims
1. A method for constructing multi-scenario data, comprising: Based on the operation data of the first object in multiple scenarios, an operation summary graph is constructed. The operation summary graph includes a first node representing the first object, a second node representing the second object, and an edge connecting the first node and the second node. The second object is the object that publishes resources. The operation summary graph is a directed graph or an undirected graph, and the nodes and edges carry attributes to represent the object type and the type of interaction relationship; Based on the operation summary graph, a multi-dimensional walk is performed to generate a first walk path in each single scene and a second walk path in the mixed scene, wherein the mixed scene includes at least two of the single scenes; Generate co-occurrence relationship data between the first object and the second object based on the first traversal path and the second traversal path; Based on the co-occurrence relationship data, a first representation vector of the first object and a second representation vector of the second object are constructed in the operation summary graph; The step of constructing a first representation vector for the first object and a second representation vector for the second object in the operation summary graph based on the co-occurrence relationship data includes: Using the co-occurrence relationship data as a supervision signal, positive sample pairs and negative sample pairs are constructed. Based on the positive and negative sample pairs, the contrastive learning loss is calculated to obtain the first representation vector and the second representation vector. Based on the similarity between the first representation vector and the second representation vector, resources to be recommended that match the first object are determined from the resources published by the second object.
2. The method according to claim 1, wherein, The step of constructing an operation summary graph based on the operation data of the first object in multiple scenarios includes: For each of the single scenarios, the first node, the second node, and the edge are constructed, wherein the edge identifiers corresponding to the edges in different single scenarios are different; Based on the first node, the second node, and the edge in each of the single scenarios, construct the operation summary graph.
3. The method according to claim 2, wherein, In the operation summary diagram, the first node records the object identifier representing the first object, the second node records the object identifier representing the second object, and the edge records the edge identifier representing the scene.
4. The method according to claim 1, wherein, The step of performing multi-dimensional traversal based on the operation summary graph to generate a first traversal path for each single scene and a second traversal path for mixed scenes includes: Different single scenarios are distinguished based on the edge markers in the operation summary graph; In each single scenario, the first traversal path is obtained by traversing based on the connection relationship between the first node and the second node. In the hybrid scenario, the second traversal path is obtained by traversing based on the connection relationship between the first node and the second node.
5. The method according to claim 1, wherein, The step of generating co-occurrence relationship data between the first object and the second object based on the first traversal path and the second traversal path includes: Select at least two of the single scenarios from the multiple scenarios as the target scenario; Based on the edge identifiers corresponding to the target scene, the target first traversal path and the target second traversal path are determined from the first traversal path and the second traversal path; The co-occurrence relationship data is obtained by traversing the first and second walk paths of the target.
6. The method according to claim 1, wherein, The step of generating co-occurrence relationship data between the first object and the second object based on the first traversal path and the second traversal path includes: By traversing all nodes in the first and second traversal paths, the co-occurrence relationships between all nodes are recorded; The co-occurrence relationships of all records are traversed, and the data is filtered according to at least one of the preset co-occurrence frequency threshold and scene importance information to obtain the co-occurrence relationship data.
7. The method according to claim 1, wherein, The multiple scenarios include scenarios corresponding to different applications, or scenarios corresponding to different projects within the same application.
8. A multi-scenario data construction device, comprising: The first construction module is used to construct an operation summary graph based on the operation data of the first object in multiple scenarios. The operation summary graph includes a first node representing the first object, a second node representing the second object, and an edge connecting the first node and the second node. The second object is an object that publishes resources. The operation summary graph is a directed graph or an undirected graph, and the nodes and edges carry attributes to represent the object type and the type of interaction relationship; The first generation module is used to perform multi-dimensional traversal based on the operation summary graph, and generate a first traversal path in each single scene and a second traversal path in the mixed scene, wherein the mixed scene includes at least two of the single scenes; The second generation module is used to generate co-occurrence relationship data between the first object and the second object based on the first traversal path and the second traversal path; The second construction module is used to construct a first representation vector of the first object and a second representation vector of the second object in the operation summary graph based on the co-occurrence relationship data. The second building module includes: The sample construction submodule is used to construct positive and negative sample pairs by using the co-occurrence relationship data as a supervision signal. The loss calculation submodule is used to calculate the comparative learning loss based on the positive sample pairs and negative sample pairs, and to obtain the first representation vector and the second representation vector. The determination module is used to determine, based on the similarity between the first representation vector and the second representation vector, resources to be recommended that match the first object from the resources published by the second object.
9. The apparatus according to claim 8, wherein, The first building module includes: A submodule is created to construct the first node, the second node, and the edge for each single scenario, wherein the edge identifiers corresponding to the edges are different for different single scenarios; The integration submodule is used to construct the operation summary graph based on the first node, the second node, and the edge in each of the single scenarios.
10. The apparatus according to claim 9, wherein, In the operation summary diagram, the first node records the object identifier representing the first object, the second node records the object identifier representing the second object, and the edge records the edge identifier representing the scene.
11. The apparatus according to claim 8, wherein, The first generation module includes: The identification submodule is used to distinguish different single scenarios based on the edge identifiers in the operation summary graph. The first traversal submodule is used to traverse according to the connection relationship between the first node and the second node in each single scenario to obtain the first traversal path; The second roaming submodule is used to roam according to the connection relationship between the first node and the second node in the mixed scene to obtain the second roaming path.
12. The apparatus according to claim 8, wherein, The second generation module includes: The selection submodule is used to select at least two of the single scenarios as target scenarios from the multiple scenarios; The determination submodule is used to determine the target first wandering path and the target second wandering path from the first wandering path and the second wandering path based on the edge identifier corresponding to the target scene; The first generation submodule is used to traverse the first and second traversal paths of the target to obtain the co-occurrence relationship data.
13. The apparatus according to claim 8, wherein, The second generation module includes: The recording submodule is used to record the co-occurrence relationship between all nodes by traversing all nodes in the first traversal path and the second traversal path; The second generation submodule is used to traverse the co-occurrence relationships of all records and filter the data according to at least one of the preset co-occurrence frequency threshold and scene importance information to obtain the co-occurrence relationship data.
14. The apparatus according to claim 8, wherein, The multiple scenarios include scenarios corresponding to different applications, or scenarios corresponding to different projects within the same application.
15. An electronic device comprising: At least one processor; as well as A memory that is communicatively connected to at least one processor; wherein, The memory stores instructions that can be executed by at least one processor to enable the at least one processor to perform the method of any one of claims 1-7.
16. A non-transitory computer-readable storage medium storing computer instructions, wherein, Computer instructions are used to cause a computer to perform the method according to any one of claims 1-7.
17. A computer program product comprising a computer program stored on a storage medium, wherein the computer program, when executed by a processor, implements the method according to any one of claims 1-7.
Citation Information
Patent Citations
Object recommendation method and device
CN112907334A
Product pushing method, device, electronic equipment and storage medium
CN114092192A
Object recommendation method and device, computer equipment and storage medium
CN114969491A