Game strategy retrieval method and device based on knowledge graph structured management
By adopting a structured management method based on knowledge graphs in game strategy content management, the problem of lack of systematic management of game strategy content in the existing technology is solved, and efficient and accurate retrieval and management are achieved.
Patent Information
- Application Number
- CN202510593465.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-09
- Publication Date
- 2025-06-06
- Estimated Expiration
- 2045-05-09
AI Technical Summary
In the prior art, the content of game strategy lacks systematic management, low retrieval efficiency, low information structure, and inaccurate search results.
Using a structured management method based on knowledge graphs, we manage and retrieve game strategy content by constructing data objects, analyzing structured files, writing to databases, updating knowledge graphs, providing a visual editing interface, and performing semantic hierarchical analysis.
It improves the efficiency of game strategy retrieval and the accuracy of results, and improves the systematic management and structure of content.
Smart Images

Figure CN120104815A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of data processing technology, and in particular to a game strategy retrieval method and device based on knowledge graph structured management. Background Art
[0002] With the rapid development of the digital game industry, game content is becoming increasingly rich and complex, and players' demand for game strategies continues to grow. A large number of game strategies are scattered on various platforms in the form of text, pictures, videos, etc., but lack a unified organization and structured management, resulting in low efficiency and poor experience for users when searching for specific levels, characters, tasks, etc.
[0003] In the prior art, some platforms organize strategy content in a centralized manner by establishing game encyclopedias, but the following problems still exist: the collection and entry of strategy content mainly rely on manual editing, which is inefficient, highly repetitive, and difficult to maintain structural consistency; there is a lack of systematic data structure, and strategy content usually exists in the form of flat text, which is not conducive to refined management and subsequent association mining; content updates lack mechanism support, and dynamic synchronization of game entries and related data cannot be achieved; when users search for strategies, they can only rely on keyword matching, and cannot perform hierarchical searches based on the semantic relationship of game content; the page display method relies on front-end development, and it is difficult for ordinary users to customize the page structure and display style, and the editing threshold is high. Summary of the invention
[0004] In view of this, an embodiment of the present application provides a game strategy retrieval method and device based on structured management of knowledge graph to solve the problems of low retrieval efficiency, lack of systematic management of strategy content, low degree of information structuring, and inaccurate retrieval results in the prior art.
[0005] In a first aspect of an embodiment of the present application, a game strategy retrieval method based on structured management of a knowledge graph is provided, comprising: in response to a request for newly added game information, constructing a data object containing basic attributes of the newly added game, and encapsulating the data object into a message, and sending the message to a back-end system through a message queue to trigger an encyclopedia entry initialization operation; reading a structured file containing game strategy information uploaded by a user, parsing the fields in the structured file, and mapping the fields to corresponding entry data; writing the entry data into a database, constructing an entity object and a semantic relationship corresponding to the entry data, and encapsulating the entity object and the semantic relationship into an update request message; in response to the update request message, incrementally updating the knowledge graph data according to a predefined knowledge graph pattern, creating or updating game-related entity nodes and semantic relationships between entity nodes; providing a visual editing interface for users to configure the encyclopedia page structure in a drag-and-drop manner based on the generated entry data and entity information, and generating a page rendering configuration file associated with the entry data; performing semantic hierarchical parsing based on the knowledge graph data, combined with keywords and filtering conditions input by the user, determining the retrieval target entity and related entries, and outputting game strategy content and related information semantically related to the keywords.
[0006] According to a second aspect of the embodiment of the present application, a game strategy retrieval device based on structured management of a knowledge graph is provided, including: a construction module, which is used to respond to a request for new game information, construct a data object containing basic attributes of the new game, and encapsulate the data object into a message, which is sent to a back-end system through a message queue to trigger an encyclopedia entry initialization operation; a parsing module, which is used to read a structured file containing game strategy information uploaded by a user, parse the fields in the structured file, and map the fields to corresponding entry data; an encapsulation module, which is used to write the entry data into a database, construct entity objects and semantic relationships corresponding to the entry data, and encapsulate the entity objects and semantic relationships into a database. Encapsulated as an update request message; an update module, used to respond to the update request message, incrementally update the knowledge graph data according to the predefined knowledge graph mode, create or update game-related entity nodes and the semantic relationship between entity nodes; a generation module, used to provide a visual editing interface for users to configure the encyclopedia page structure by dragging and dropping according to the generated entry data and entity information, and generate a page rendering configuration file associated with the entry data; an output module, used to perform semantic hierarchical analysis based on the knowledge graph data, combined with the keywords and filtering conditions entered by the user, determine the retrieval target entity and related entries, and output the game strategy content and related information related to the keyword semantics.
[0007] According to a third aspect of an embodiment of the present application, an electronic device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the steps of the above method are implemented when the processor executes the computer program.
[0008] According to a fourth aspect of an embodiment of the present application, a computer-readable storage medium is provided, which stores a computer program, and when the computer program is executed by a processor, the steps of the above method are implemented.
[0009] At least one of the above technical solutions adopted in the embodiments of the present application can achieve the following beneficial effects: By responding to the request for new game information, a data object containing the basic attributes of the new game is constructed, and the data object is encapsulated as a message, which is sent to the back-end system through the message queue to trigger the encyclopedia entry initialization operation; the structured file containing game strategy information uploaded by the user is read, the fields in the structured file are parsed, and the fields are mapped to the corresponding entry data; the entry data is written into the database, the entity object and semantic relationship corresponding to the entry data are constructed, and the entity object and semantic relationship are encapsulated as an update request message; in response to the update request message, the knowledge graph data is incrementally updated according to the predefined knowledge graph mode, and the game-related entity nodes and the semantic relationship between the entity nodes are created or updated; according to the generated entry data and entity information, a visual editing interface is provided for the user to configure the encyclopedia page structure in a drag-and-drop manner, and a page rendering configuration file associated with the entry data is generated; based on the knowledge graph data, combined with the keywords and screening conditions entered by the user, semantic hierarchical parsing is performed to determine the retrieval target entity and related entries, and output the game strategy content and related information related to the keyword semantics. This application can improve the retrieval efficiency and the accuracy of the retrieval results, and improve the systematic management and structuring of the game strategy content. BRIEF DESCRIPTION OF THE DRAWINGS
[0010] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0011] Figure 1 It is a flowchart of a game strategy retrieval method based on knowledge graph structured management provided in an embodiment of the present application; Figure 2 It is a structural schematic diagram of a game strategy retrieval device based on knowledge graph structured management provided by an embodiment of the present application; Figure 3 It is a schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0012] In the following description, specific details such as specific system structures, technologies, etc. are provided for the purpose of illustration rather than limitation, so as to provide a thorough understanding of the embodiments of the present application. However, it should be clear to those skilled in the art that the present application may also be implemented in other embodiments without these specific details. In other cases, detailed descriptions of well-known systems, devices, circuits, and methods are omitted to prevent unnecessary details from obstructing the description of the present application.
[0013] In the current gaming industry, with the continuous emergence of popular games and sub-categories, a massive amount of game strategy content has been generated on the market. For ordinary users, after obtaining a large amount of strategy information, it is often difficult to quickly and accurately find the specific level, character, equipment and other related information they need. This puts higher requirements on the information management and retrieval of game strategies, requiring a more efficient and intuitive way to organize and display strategy content.
[0014] The following methods are usually used in the prior art to retrieve game strategies and other related information: Manual maintenance of encyclopedias / forums: A common practice is for game manufacturers or community users to manually edit based on forums, Wikis and other platforms, which are not updated in a timely manner and have a low degree of structure.
[0015] Keyword search: Most of them only rely on keywords or titles for simple fuzzy searches. When the strategy system is large, the search accuracy is low, and it is difficult to present complex contextual associations in the results (such as the relationship between characters and equipment, levels and tasks).
[0016] However, the prior art still has the following disadvantages: Information fragmentation: Guide content is stored in the form of scattered texts, pictures, etc., lacking systematic management; Poor scalability: When the game is updated or a new version is released, a lot of repetitive work is required to maintain the strategy information; Lack of relevance: It is difficult to intuitively display the hierarchy or relationship of "level-character-equipment-task", which is not conducive to users' quick positioning or comparison; Difficulty in multi-channel synchronization: If you want to maintain guide content on multiple platforms (PC web pages, apps, communities), you often need to enter it manually multiple times, which can easily cause redundancy or inconsistency.
[0017] Therefore, in view of the problems existing in the above-mentioned prior art. This application proposes a structured management and retrieval technology solution for game strategies. The overall implementation idea of the technical solution of this application includes: using message queues (Message Queue) for event decoupling. After detecting requests such as "adding new games" or "updating game information", the system automatically creates or updates the corresponding encyclopedia entries, and notifies the knowledge graph maintenance module to perform incremental updates. Based on Excel reading and writing tools (xlrd, xlwt), users are supported to batch generate or update information such as games, levels, characters, equipment, props, etc. by uploading Excel files, so as to realize the structured entry of large-scale data. Relying on the low-code platform to realize visual drag-and-drop typesetting, users can flexibly configure and adjust the layout of the game encyclopedia page without professional front-end development, greatly improving editing efficiency. Build a knowledge graph structured management system for game strategies, unify game entities and relationship types through predefined graph modes (schemas), and realize efficient retrieval and association analysis based on graphs.
[0018] Before describing the technical solution of this application in detail, the system architecture involved in the game strategy retrieval method based on structured management of knowledge graph in this application in actual scenarios is described in detail with specific examples. The system functions of this application can be divided into the following four main modules according to business logic: game encyclopedia management module, Excel file parsing module, knowledge graph maintenance module, and low-code editing module. In addition, there are basic components such as search engine / retrieval module and database (or graph database) to provide support.
[0019] 1. Game Encyclopedia Management Module Used to receive requests for "adding new games" or "updating game information"; responsible for encapsulating relevant information into message objects and pushing them to the message queue; providing an interface for adding, modifying, deleting and checking the game encyclopedia for the front end or other modules to call.
[0020] 2. Excel file parsing module The Excel file uploaded by the user is read through xlrd, and the data table structure and content are verified; after parsing, key fields (such as game name, level name, character, equipment, props, etc.) are extracted, and with the help of xlwt or corresponding database writing tools, corresponding entries are generated or updated; the information generated by the analysis is also synchronously sent to the knowledge graph maintenance module to update entities and relationships.
[0021] 3. Knowledge Graph Maintenance Module Contains knowledge graph storage and management functions, which can use graph databases (such as Neo4j, ArangoDB, or Titan) or use relational databases to simulate graph structures; Contains graph update triggers and incremental knowledge graph update algorithms: After receiving messages such as "new games" or "updated strategy information" pushed by the message queue, it automatically performs incremental updates and dynamically maintains entities such as games, levels, and characters and their relationships; The predefined graph schema is used to ensure the uniformity and standardization of various entity types and relationship types in the game field.
[0022] 4. Low-code editing module Provide users with a visual drag-and-drop component for typeset layout of encyclopedia pages; combine the typesetting configuration with entry information to automatically generate the final visual encyclopedia page; and work with the encyclopedia management module to achieve a WYSIWYG encyclopedia content display.
[0023] In addition, it further includes a search and retrieval module, which is used to provide keyword-based indexing and knowledge graph-based semantic search; combined with the knowledge graph maintenance module, it can achieve more refined retrieval and related recommendations based on hierarchical structures such as "game-level-character-equipment".
[0024] The contents of the technical solution of the present application are described in detail below with reference to the accompanying drawings and specific embodiments.
[0025] Figure 1 Schematic diagram of the process of game strategy retrieval method based on knowledge graph structured management provided by the embodiment of the present application. Figure 1 As shown, the game strategy retrieval method based on knowledge graph structured management may specifically include: S101, in response to a request for newly added game information, construct a data object containing basic attributes of the newly added game, encapsulate the data object into a message, and send it to the backend system through a message queue to trigger an encyclopedia entry initialization operation; S102, reading a structured file containing game strategy information uploaded by a user, parsing fields in the structured file, and mapping the fields to corresponding entry data; S103, writing the entry data into the database, constructing entity objects and semantic relationships corresponding to the entry data, and encapsulating the entity objects and semantic relationships into an update request message; S104, in response to the update request message, incrementally updating the knowledge graph data according to a predefined knowledge graph pattern, creating or updating game-related entity nodes and semantic relationships between entity nodes; S105, based on the generated entry data and entity information, providing a visual editing interface for the user to configure the encyclopedia page structure by dragging and dropping, and generating a page rendering configuration file associated with the entry data; S106, based on the knowledge graph data, combined with the keywords and filtering conditions input by the user, perform semantic hierarchical analysis, determine the retrieval target entity and related terms, and output game strategy content and related information related to the keyword semantics.
[0026] In some embodiments, the message queue is sent to the backend system to trigger the encyclopedia entry initialization operation, including: Send the message to the preset message queue to realize asynchronous communication between the front-end request processing module and the back-end encyclopedia processing module; The message queue is monitored in the backend encyclopedia processing module. When a message is received, the initialization operation of the encyclopedia entry is automatically performed. After the initialization of the encyclopedia entry is completed, the entry identification information is generated and the initialization status is recorded; The initialization operation of the encyclopedia entry includes creating a main entry corresponding to the newly added game in the database, and writing the basic attribute information of the newly added game into the main entry.
[0027] Specifically, in this embodiment, for the scenario where a user submits a "new game" or obtains new game data from a third-party API, asynchronous communication between the front-end request processing module and the back-end encyclopedia processing module is implemented through a message queue, thereby triggering the initialization operation of the encyclopedia entry. The specific implementation process is as follows: First, when the user actively submits a "new game" request on the front-end interface, or the system receives new game data from a third-party API, the front-end request processing module will detect the "new game" event and obtain basic attribute data including game name, platform information, initial description, release time, etc. from the user or third party.
[0028] To facilitate subsequent transmission and processing, the front-end request processing module can organize the above basic game attribute data into data objects (such as JSON objects), which include necessary fields such as "game name", "platform", and "publisher".
[0029] Furthermore, the front-end request processing module (or the game encyclopedia management module) further encapsulates the data object into a message object; in this embodiment, a unique identifier and a metadata field for describing the operation type may be specified for the message object, for example: Message type: for example, "GameCreation"; Basic attributes: including game name, initial description, release time, etc.; Other necessary tags: such as source channel, current timestamp, etc.
[0030] Push the message object to the pre-configured message queue (named "GameCreationQueue" in the example) to achieve asynchronous communication with the backend encyclopedia processing module.
[0031] Furthermore, in the backend system, the encyclopedia processing module will continuously monitor the "GameCreationQueue"; once a new message is detected entering the queue, the message will be automatically popped up (or consumed).
[0032] This monitoring operation is usually implemented through polling or event-driven methods. The specific implementation details may depend on the type of message queue (such as RabbitMQ, Kafka, etc.), but the essential goal is to immediately trigger the initialization process of the encyclopedia entry once a new game message appears.
[0033] Furthermore, after taking out the message, the encyclopedia processing module will first verify and parse the basic game attribute data in the message to confirm the data integrity and validity; if the data is incomplete or there is an abnormality, the error information can be written into the log or fed back to the upper-level calling interface.
[0034] After confirming that the data is correct, the encyclopedia processing module will create a main entry corresponding to the newly added game in the database. The specific steps are as follows: Create a new record in the encyclopedia database: for example, insert a new record in the "game_encyclopedia" or "wiki_entries" table, the record content includes the game name, initial description, and related attributes (such as "publisher", "platform information", etc.).
[0035] Generate primary entry identification information: The system can generate a unique entry identifier (such as "EntryID" or "GameID") based on the database's auto-increment primary key or UUID; this identifier will be used for subsequent retrieval and association operations.
[0036] Record initialization status: Write "Created" or "Initialization Successfully" and other flags in the same data record or an associated status table. This step facilitates subsequent inquiries to see whether the encyclopedia entry has completed initialization.
[0037] Furthermore, when the encyclopedia entry initialization operation is completed, the encyclopedia processing module can write the operation result information (such as the newly created entry ID, initialization success flag, timestamp, etc.) into the log file for system operations or technical personnel to audit and trace.
[0038] If the result needs to be returned to the upper layer, the encyclopedia processing module can also encapsulate the response message including "entry identification information" and "creation status" and provide feedback through a specific interface or receipt message. For example: The response format can be JSON, including the "success" field, "entry_id" field, etc. If the automation process needs to be expanded later, the success message can be written to the message queue again to notify other related modules (such as notifying the low-code editing module to update the UI display, etc.).
[0039] Furthermore, in some examples, the initialization of the encyclopedia entry is only for the creation and recording of the main entry of the newly added game. If the level, character, equipment or other entry information needs to be maintained for the game in the future, the same message queue mechanism can be used to implement it, or the incremental update interface of the backend encyclopedia management module can be directly called to perform the operation.
[0040] If the system detects that the newly added game does not have a corresponding game entity node in the knowledge graph, it can automatically send an update request message of "newly added game entity" to the knowledge graph maintenance module after completing the encyclopedia initialization to further trigger the incremental update operation of the graph database. However, this content belongs to the technical links involved in other implementation methods and is not within the focus of this embodiment.
[0041] It can be seen from the above embodiments that in the technical solution of the present application, the introduction of message queues as a means of asynchronous decoupling can effectively reduce the degree of real-time coupling between front-end requests and back-end encyclopedia initialization operations, and improve the stability and scalability of the system. When a new game information request arrives, the back-end can trigger and complete the initialization of the encyclopedia entries in a timely manner based on the message queue, avoiding the front-end or other modules from being blocked due to waiting, and effectively improving the overall processing efficiency. The above specific embodiments have strong flexibility in implementation, and are also applicable to game encyclopedia systems of different scales or types.
[0042] In some embodiments, a structured file uploaded by a user and containing game strategy information is read, fields in the structured file are parsed, and the fields are mapped to corresponding entry data, including: Receive structured files uploaded by users through the front-end interface or interface, and store the structured files in a temporary storage path; Perform format verification on structured files. The verification content includes file structure, header field naming, data type and integrity. If the verification fails, an error message is returned. After verification, parse the data content in the structured file and extract multiple field information related to the game; Based on the mapping rules between fields and system predefined term types, the extracted field content is converted into the corresponding term data structure.
[0043] Specifically, the user uploads an Excel file containing a game strategy through the front-end interface or interface (which can be uploaded automatically by a script or manually by the user). The Excel file includes multiple fields such as level name, character, equipment, props, strategy text, etc.; after receiving the file, the system temporarily stores it in the designated storage path of the server (for example, / temp / uploads / ) and generates a unique file name to facilitate locating the file during subsequent parsing.
[0044] Before parsing, the system performs basic format checks on the Excel file, including: Sheet quantity or name: whether it contains the agreed main sheet, or whether there is at least one valid data sheet; Header field naming: For example, the first line should be "Game Name", "Level Name", "Role", "Task Name", "Reward Description", etc. Data type and integrity: For example, some columns should be strings, some columns should be dates or numeric formats, and integrity checks are performed on the entire row or column.
[0045] If the verification fails (for example, the table header lacks required fields or the data format does not match expectations), the system immediately returns an error message and terminates the subsequent parsing process.
[0046] Furthermore, after confirming that the file passes the format check, the system calls the xlrd library (or other alternative Excel parsing tools) to parse the worksheet content: Read line by line: read each line (or each record unit) and extract the corresponding fields; Data cleaning and conversion: For text fields, remove extra spaces or special characters; for numeric fields, ensure that they are converted to the expected internal format when reading.
[0047] For example, sample fields include: Game name: used to bind the parsed strategy information to the corresponding game. If the corresponding game does not exist yet, the "add game" process can be triggered later; Level name: can be mapped to a sub-page or sub-entry in the encyclopedia system; Role / profession, equipment, props, mission name, reward description: used to subdivide various elements in the game; Guide text: may contain text, image links, operation steps, etc., which are used to present detailed content in the encyclopedia entry later.
[0048] Furthermore, based on the predefined "field-entry type" mapping rules, the system will convert or map the parsed field content into the corresponding entry structure, for example: Main game entry: For example, the "Game Name" field in Excel corresponds to the main encyclopedia entry; Level entries: If a "level name" is detected, a new or updated level entry is created in the encyclopedia system; Sub-entries such as roles, equipment, props, and tasks: each is mapped to the corresponding category in the encyclopedia; Body or description content: mapped to the detailed description field or body rich text field of the entry.
[0049] At the same time, the system can automatically generate or read unique identification information of existing entries (such as entry ID) to facilitate subsequent merging and updating.
[0050] Furthermore, after completing the row-by-row parsing and entry mapping of the Excel data, the system batch creates or updates the corresponding entry data in the database through the entry generation module (or directly calls the relevant API of the encyclopedia management module).
[0051] If a record is detected to match an existing entry (for example, the entry ID is the same, or the game name + level name already exists), enter update mode: Incremental update: only update the fields that have changed (such as strategy description, equipment description, etc.), and keep the rest of the existing information; Version management: The system can record the time of the update operation, the operating user and other metadata as needed to facilitate future tracing or rollback.
[0052] For the convenience of auditing and tracking, the system can also use xlwt or other writing libraries to record the processing results to log files or intermediate tables while writing to the database, including the list of successfully processed entries, update mode, reasons for failure, etc.
[0053] Furthermore, in some examples, after completing the generation (or update) of an entry, if the system detects that new levels, new characters, or new equipment and other knowledge graph entities do not exist or need to be revised, the system can encapsulate the corresponding structured information into a "graph update request" and send it to the knowledge graph maintenance module through a message queue.
[0054] The knowledge graph maintenance module will incrementally create or merge entity nodes and relationships in the graph database based on the update request, so as to keep it consistent with the latest entry status of the encyclopedia system.
[0055] It can be seen from the above embodiments that in some implementations of this application, the Excel parsing tool and predefined mapping rules can be used to efficiently convert batches of game strategy files into encyclopedia entry data, significantly reducing the workload of manual input. At the same time, in the process of writing or updating entries, the system can also trigger the synchronous update of the knowledge graph to ensure the consistency of the encyclopedia and graph data. In large-scale game strategy scenarios, this embodiment can greatly improve operation and maintenance efficiency, and provide rich and accurate structured data support for subsequent association recommendations and advanced retrieval.
[0056] In some embodiments, constructing an entity object and a semantic relationship corresponding to the entry data, and encapsulating the entity object and the semantic relationship into an update request message includes: Based on the generated entry data, the corresponding game semantic element type is identified, and the entry data is converted into an entity object with structured attributes according to a preset entity classification rule; Construct semantic relationships between entity objects based on their associations in the game semantic hierarchy; Encapsulate entity objects and semantic relationships to generate data structures that meet the requirements of the knowledge graph update interface; The encapsulated entity objects and semantic relationships are sent to the message queue as update request messages so that the knowledge graph maintenance module can perform incremental update operations on the knowledge graph data.
[0057] Specifically, in this embodiment, the encyclopedia management module or the entry generation module has obtained structured or semi-structured entry data, which includes multiple fields such as game name, level name, character, equipment, skills, props, tasks, NPC, etc. The system parses and classifies each entry data according to the pre-defined "entity classification rules", for example: If "Game Name" is detected in the field, the data is identified as a "Game" type entity; If "level name" is detected, it is converted to "Level" type entity; If "role" or "occupation" related fields are detected, they are converted to "Role" type entities; The same goes for other entity types (such as "equipment", "skills", "props", etc.).
[0058] After completing the parsing and matching, the system will assign a unique identifier to each entity object (which can be based on the entry ID, automatically generated UUID, etc.), and store the parsed attribute values (such as game publisher, level difficulty, equipment rarity, etc.) in the structured attribute field, thereby constructing an entity object data structure that meets the requirements of the knowledge graph model.
[0059] Furthermore, in this embodiment, the system constructs corresponding relationship types according to the association relationships between entity objects in the game semantic hierarchy. For example: "BelongsTo" relationship: if "Level A corresponds to Game X" is identified in the entry data, then a "Level A belongs to Game X" relationship is generated; "ApplicableTo" relationship: If equipment E is only applicable to a specific character R, the system automatically generates the "equipment E applies to character R" relationship; "AssociatedWith" relationship: When a task T and a prop D are related to each other or need to be used in conjunction, a "task T associated with prop D" relationship can be generated.
[0060] These relationship types are determined by the business needs of the system or predefined graph patterns. If there is a relationship between a character and equipment, a character and a plot node, or a task and an NPC in the parsed field, the corresponding logic can be called to generate a "semantic relationship" object.
[0061] In the process of generating relationships, the system will record the subject entity, object entity and associated attributes (such as number of occurrences, priority, recommendation, etc.) of the relationship to ensure that the relationship can be quickly queried and analyzed in the knowledge graph later.
[0062] Furthermore, when all entity objects and their semantic relationships have been constructed, the system will encapsulate the entity objects and relationship information in a unified data format according to the interface requirements of the knowledge graph maintenance module. JSON or other extensible markup formats are usually used, including the following key information: Entity object list: including entity type, entity name (or identifier), entity attribute fields and values; Relationship list: includes relationship type (such as "belongs to", "applies to", "associated"), unique identifiers of the entities at both ends, and associated attributes.
[0063] In order to maintain decoupling from the backend knowledge graph maintenance module, the system will send the encapsulated update request message to a pre-agreed message queue (such as "GraphUpdateQueue") so that the knowledge graph maintenance module can perform the corresponding incremental update operation after listening to the message.
[0064] Furthermore, after packaging all entity objects and semantic relationships, the system will write this update request message into the message queue with necessary identification information (such as batch number, operating user, timestamp, etc.).
[0065] After the knowledge graph maintenance module consumes the update request from the message queue, it can further determine whether to create a new node / relationship or merge and update the existing nodes / relationships based on the entity and relationship content, thereby realizing real-time or quasi-real-time maintenance of the existing game field knowledge graph.
[0066] If the update is successful, the knowledge graph maintenance module can record the receipt information in the queue or log system so that the encyclopedia management module can query the processing results of the incremental update.
[0067] It can be seen from the above embodiments that in some implementations of this application, by converting the entry data into the structure of "entity object" and "semantic relationship", and then sending it to the knowledge graph maintenance module using the message queue, the dynamic maintenance and upgrade of the knowledge graph in the game field can be realized. For different types of game semantic elements (games, levels, characters, equipment, skills, tasks, etc.), the system can facilitate subsequent graph-based retrieval, association recommendation and reasoning analysis through flexible classification and relationship definition, thereby improving the availability and scalability of game strategy information.
[0068] In some embodiments, incrementally updating the knowledge graph data according to a predefined knowledge graph pattern to create or update game-related entity nodes and semantic relationships between entity nodes includes: According to the entity objects and semantic relationships in the update request message, the received entity types and relationship types are matched and verified according to the predefined knowledge graph model; Perform an existence check on the entity object in the knowledge graph. If the corresponding entity node does not exist, create a new entity node and write the attribute information. If it already exists, update or merge the node attributes according to the attribute changes. Based on the semantic relationship between entity objects, determine whether the corresponding edge relationship already exists in the knowledge graph. If not, create a new relationship edge and set the associated attributes. If it already exists, update the attribute value of the relationship edge.
[0069] Specifically, in this embodiment, the knowledge graph maintenance module continuously monitors a message queue (e.g., "GraphUpdateQueue") or a specific interface exposed to the outside to receive incremental update request messages; When a new update request message appears in the message queue, the knowledge graph maintenance module pops it out (or consumes it) and performs preliminary analysis: Extract entity object list and relationship list; Verify the metadata in the message (such as batch number, source module, message format version, etc.) to ensure that it complies with the communication protocol defined by the system.
[0070] Furthermore, after parsing, the knowledge graph maintenance module matches and verifies the "entity type" and "relationship type" carried in the message according to the predefined knowledge graph schema, for example: Entity type matching: Determine whether "Game", "Level", "Role", "Equipment", "NPC", etc. in the message match the entity type registered in the graph mode; if an unmatched entity type is found, it can be recorded in the exception log or fault tolerance processing can be performed; Relationship type matching: For example, "BelongsTo", "ApplicableTo", and "AssociatedWith" must also match the existing relationship types in the graph.
[0071] For entity objects that pass the matching verification, the knowledge graph maintenance module checks whether the corresponding nodes already exist in the graph database (such as Neo4j, ArangoDB, etc.): Node determination basis: The graph can be queried based on the unique identifier of the entity object (such as ID or name + type combination); Create a node if it does not exist: If the corresponding node is not detected, add the node to the graph and write the node attributes (such as game name, level difficulty, publisher information, etc.); Update or merge attributes if they already exist: If a corresponding node already exists in the graph, update or merge the node attributes according to the attribute fields in the update request, such as updating the character's "health value" or "equipment level".
[0072] Furthermore, after processing the entity object, the knowledge graph maintenance module performs the following operations for each relationship entry according to the "relationship list" carried in the message: Query existing edge relationships: determine whether the same type of relationship between two entity nodes already exists in the graph database; If it does not exist, create a relationship edge: If the relationship does not exist, the system will create a new edge and write the associated attributes (such as "number of occurrences", "weight", "optional conditions", etc.); Update the associated attributes if it already exists: If the relationship already exists, modify or merge it according to the attribute values provided in this update request, such as resetting or accumulating the "association" or "priority".
[0073] In some scenarios (such as batch import of game guide content from Excel), a large number of entity objects and relationships may need to be updated in the same period of time. To avoid too frequent operations on the graph database, this embodiment can centrally process all parsed update requests: One-time verification: first perform type and attribute matching verification on all entities and relationships; Create or update nodes and relationships: Create / update nodes and relationships in batches based on the verification results; Reduce interaction overhead: This can significantly reduce the number of database connections and improve overall processing efficiency.
[0074] Furthermore, after the processing is completed, the knowledge graph maintenance module can generate a receipt message of the operation results, such as a list of entities / relationships that were successfully updated, a list of records that were skipped or had errors, etc. The receipt message can be written back to the original message queue or notified to the business module, so that the subsequent business process can be informed in time that the graph has been updated; If an exception is encountered (such as unmatched entity type, missing attributes, etc.), detailed error information can be recorded in the receipt message or log system for administrators or operation and maintenance personnel to check and handle.
[0075] Furthermore, in some examples, the message queue assumes the function of the "middle decoupling layer": after the encyclopedia management module or Excel parsing module completes the processing of the entry data, it publishes the entity and relationship update information to the message queue, and the knowledge graph maintenance module consumes from the queue and then performs the update; This asynchronous processing mode can effectively improve the scalability of the system: the front-end encyclopedia module or data parsing module does not need to be tightly coupled with the graph database, but only needs to output update request messages in the agreed format; and the knowledge graph maintenance module can autonomously arrange batch updates or handle conflicts, greatly improving the overall efficiency and reliability of the system.
[0076] It can be seen from the above embodiments that in some implementations of the present application, by performing a matching check on the entity type and relationship type in the incremental update request message, and creating or updating the corresponding entity nodes and relationship edges in the graph database, it is possible to ensure the synchronization and improvement of game strategy-related data at the knowledge graph level. This incremental update process not only ensures the consistency of entry data and graph data, but also provides a richer and more real-time knowledge base for subsequent game strategy retrieval, deep association analysis, and recommendation scenarios.
[0077] In some embodiments, based on the generated entry data and entity information, a visual editing interface is provided for the user to configure the encyclopedia page structure by dragging and dropping, and a page rendering configuration file associated with the entry data is generated, including: Present a visual editing interface containing multiple page components on the front-end page; In response to the user's dragging operation in the visual editing interface, components are selected and combined into a page structure, and the selected components are bound to the entry data or entity information; Generate a page rendering configuration file that describes the page structure and data binding relationship based on the user configuration results; The page rendering configuration file is stored in the database and associated with the corresponding entry ID or encyclopedia page ID so that it can be dynamically retrieved and the front-end rendering display can be completed when the page is accessed.
[0078] Specifically, in this embodiment, when the user opens the front-end page of the game encyclopedia management platform, the system will first present a visual editing interface to the user; the interface contains a variety of predefined component options (such as text blocks, picture blocks, video areas, tables, relationship visualization components, etc.), and each component has configurable properties (such as size, position, bindable data types, etc.); the user can drag and drop the required components from the component panel to the corresponding position of the editing area in this interface to form the initial layout structure of the page.
[0079] When a user drags a component (such as a text block) to the page layout, the system will display the configurable items of the component on the right or in a pop-up window, including: Data source selection: Users can choose to bind the component to specific entry data or entity information; for example, map the "Game Introduction" field to a text component to dynamically display the introduction of the current game on the page; Style and appearance: users can configure text size, alignment, line spacing, etc.; for image components, they can configure width and height scaling, margins, etc.; Interaction logic: If the component needs to support interactive operations such as click jump and floating prompt, you can configure it here.
[0080] Users can repeat the above operations to bind multiple components to different entry data fields or relationship attributes (such as character information, equipment lists, level key information, etc.), thereby forming display modules such as rich text content or visual charts.
[0081] Furthermore, after the user completes the component dragging and property binding, the system will automatically generate a configuration file describing the page layout and data binding relationship, usually in JSON or XML format. The configuration file includes: Component list: record the type, location, size and other information of each component; Data source binding: mapping the bound entry fields or entity node attributes for each component; Rendering logic: such as the hierarchical relationship between components, whether linkage display or dynamic refresh is required, etc.
[0082] The system then associates the configuration file with the corresponding entry ID (or encyclopedia page ID) and stores it in the database (or specific configuration repository).
[0083] For example: insert a record into the "page_config" table, which contains fields such as "page_id", "config_file_url", "created_time", etc.; if there are multiple page layouts in the same game encyclopedia, they can be distinguished or versioned according to the page ID.
[0084] Furthermore, when other users or the same user browses the game encyclopedia, the front-end page will first retrieve the corresponding configuration file from the database according to the entry or page identifier visited; The front-end rendering engine obtains the corresponding entry data or entity information (such as game name, level list, character equipment details, etc.) from the back-end in real time according to the definition and binding relationship of each component in the configuration file; Finally, a visual encyclopedia content display is generated on the page. If the relevant entry data or graph information changes, the system can re-pull and render the latest content without changing the front-end code of the page.
[0085] In some examples, the system may also include the following features: Version management: The system can generate a new version configuration every time the user edits the layout, so as to trace back or compare the page effects of different versions; Automatic preview: Before editing is completed, you can click the "Preview" button, and the system will render a preview interface based on the current configuration, allowing users to adjust the layout in time; Multi-device adaptation: In certain implementations, adaptive layout for mobile or large-screen devices can also be supported by adding responsive attributes in the configuration file.
[0086] It can be seen from the above embodiments that in some implementations of this application, a low-code or code-free visual editing interface is used to help users configure the encyclopedia page structure by dragging and dropping, and bind the selected components to existing entries or knowledge graph entity information. This process not only greatly reduces the technical threshold for front-end page development, but also enables encyclopedia pages to be updated instantly as data changes, significantly improving the maintainability and visualization of game strategy content.
[0087] In some embodiments, based on the knowledge graph data, combined with the keywords and screening conditions input by the user, semantic hierarchical analysis is performed to determine the search target entity and related terms, and the game strategy content and related information related to the keyword semantics are output, including: Receive a search request input by a user, the search request including keywords and screening conditions; Based on the maintained knowledge graph data, perform semantic parsing operations to identify the entity type corresponding to the user input keyword, and perform graph path traversal in combination with the screening conditions to determine the target entity set that is semantically associated with the keyword; Retrieve the entry data associated with the target entity set, and generate a result set containing game strategy content, relationship between entities and recommended information according to the preset display logic, and pass the result set to the front-end page for visual display.
[0088] Specifically, in this embodiment, the user enters keywords and a series of optional screening conditions through the front-end search interface, for example: Keyword: "Fire Mage Equipment" Filter conditions: For example, the game name (or ID) is "XX Game", the character category is limited to "Mage", the equipment rarity is greater than a certain threshold, etc.
[0089] The system backend will package the search request into a query object, which contains the text information required for keyword parsing and structured filter fields, and pass it to the knowledge graph retrieval module (or search engine component).
[0090] Furthermore, after receiving the query object, the knowledge graph retrieval module will first perform semantic analysis on the keyword "fire mage equipment". Its core goal is to identify the possible character entity categories corresponding to "fire mage" and the equipment entity types corresponding to "equipment".
[0091] In this process, the system may use a variety of technical methods (such as part-of-speech tagging, entity naming recognition, synonym expansion, etc.) to map keywords to the corresponding entity types or attribute ranges in the knowledge graph: Role Type: Determine whether "Fire Mage" belongs to the category of role or profession; Equipment Type: Determines if the user intends to retrieve equipment entities that are applicable or associated with the role; Filter conditions: Include "XX game", "rarity" or other restrictions in the subsequent query logic.
[0092] Furthermore, after determining the entity type corresponding to the keyword, the system performs graph path traversal or query based on the pre-maintained knowledge graph and combined with the screening conditions. The specific process may include: Locate the starting point entity: filter out the unique node or node set of the game in the knowledge graph based on "XX game"; Role matching: Starting from the game node, traverse along the "role" or "profession" relationship to find the role node that meets the "fire mage" attribute; Equipment Association: Search all equipment nodes associated with the character node along the "ApplicableTo" relationship or other defined relationship types; Attribute screening: For the found equipment nodes, further determine whether their rarity or other attributes meet the screening conditions, leaving the final target entity set.
[0093] Furthermore, after obtaining the target entity set, the system will query the encyclopedia entry data associated with these entity nodes. For example: Equipment corresponding entries: Search for the introduction, attribute description, strategy text, etc. of the "equipment" entry in the encyclopedia database or entry management module; Related recommendations: You can expand the search to "skills that can be paired with this equipment", "strategy chapters related to the Fire Mage", "related NPCs or tasks", etc., if the user has this requirement or the system enables related recommendations by default; According to the preset display logic or template format, the system combines all the queried entry information and graph associations into a result set object (which may include JSON, HTML and other formats). The result set will cover multiple dimensions such as equipment information, character information, strategy instructions, and graph recommendations.
[0094] Finally, the system passes the result set to the front-end for rendering or display. Users can directly view the following on the result page: A list of equipment that matches the keyword "Fire Mage Equipment" and meets the screening criteria (the game it belongs to is "XX Game", equipment rarity, etc.); A diagram of the relationship between equipment, roles, tasks, and other elements (if the system provides a visual map component); Extended recommendations, such as other equipment for the same character, or strategy chapters related to the Fire Mage, so that users can explore further.
[0095] In some examples, if new equipment or character information is subsequently written into the knowledge graph, the system can use an incremental update mechanism to ensure that the latest equipment information or character association relationships are automatically included the next time similar keywords are searched. Users can also dynamically adjust keywords or filtering conditions during the search process, and the system will re-execute the search in real time and update the result display.
[0096] It can be seen from the above embodiments that in some implementations of this application, the knowledge graph is used to perform multi-level semantic analysis on the keywords and screening conditions entered by the user, which can more accurately locate the target entity and output related terms or recommended information, thereby helping users quickly obtain the desired game strategy content and discover more potentially useful information through the association relationship of the graph structure. This method is significantly better than the traditional plain text keyword matching method and can greatly improve the accuracy of game strategy retrieval and user experience.
[0097] The following is an embodiment of the device of the present application, which can be used to execute the embodiment of the method of the present application. For details not disclosed in the embodiment of the device of the present application, please refer to the embodiment of the method of the present application.
[0098] Figure 2 Schematic diagram of the structure of a game strategy retrieval device based on knowledge graph structured management provided by an embodiment of the present application. Figure 2 As shown, the game strategy retrieval device based on knowledge graph structured management includes: The construction module 201 is used to respond to the request for new game information, construct a data object containing basic attributes of the new game, and encapsulate the data object into a message, and send it to the back-end system through the message queue to trigger the encyclopedia entry initialization operation; The parsing module 202 is used to read the structured file containing game strategy information uploaded by the user, parse the fields in the structured file, and map the fields to corresponding entry data; The encapsulation module 203 is used to write the entry data into the database, construct the entity objects and semantic relationships corresponding to the entry data, and encapsulate the entity objects and semantic relationships into an update request message; An update module 204 is used to respond to an update request message, incrementally update the knowledge graph data according to a predefined knowledge graph mode, and create or update game-related entity nodes and semantic relationships between entity nodes; The generation module 205 is used to provide a visual editing interface for the user to configure the encyclopedia page structure by dragging and dropping according to the generated entry data and entity information, and to generate a page rendering configuration file associated with the entry data; The output module 206 is used to perform semantic hierarchical analysis based on the knowledge graph data, combined with the keywords and filtering conditions input by the user, determine the retrieval target entity and related terms, and output the game strategy content and related information related to the keyword semantics.
[0099] In some embodiments, Figure 2 The construction module 201 sends a message to a preset message queue to realize asynchronous communication between the front-end request processing module and the back-end encyclopedia processing module; the message queue is listened to in the back-end encyclopedia processing module, and when a message is received, the initialization operation of the encyclopedia entry is automatically executed, and after the initialization of the encyclopedia entry is completed, the entry identification information is generated and the initialization status is recorded; wherein, the initialization operation of the encyclopedia entry includes creating a main entry corresponding to the newly added game in the database, and writing the main entry into the basic attribute information of the newly added game.
[0100] In some embodiments, Figure 2The parsing module 202 receives the structured file uploaded by the user through the front-end interface or interface, and stores the structured file in a temporary storage path; performs format verification on the structured file, and the verification content includes the file structure, header field naming, data type and integrity. If the verification fails, an error prompt message is returned; after the verification passes, the data content in the structured file is parsed to extract multiple field information related to the game; based on the mapping rules between the field and the system predefined entry type, the extracted field content is converted into the corresponding entry data structure.
[0101] In some embodiments, Figure 2 The encapsulation module 203 identifies the corresponding game semantic element type based on the generated entry data, and converts the entry data into an entity object with structured attributes according to the preset entity classification rules; constructs the semantic relationship between the entity objects according to the association relationship between the entity objects in the game semantic hierarchy; performs data encapsulation on the entity objects and the semantic relationship to generate a data structure that meets the requirements of the knowledge graph update interface; and sends the encapsulated entity objects and semantic relationships as update request messages to the message queue for the knowledge graph maintenance module to perform incremental update operations on the knowledge graph data.
[0102] In some embodiments, Figure 2 The update module 204 performs a matching check on the received entity type and relationship type according to the entity object and semantic relationship in the update request message and the predefined knowledge graph pattern; performs an existence check on the entity object in the knowledge graph. If the corresponding entity node does not exist, a new entity node is created and the attribute information is written. If it already exists, the node attribute is updated or merged according to the attribute changes; based on the semantic relationship between the entity objects, it is determined whether the corresponding edge relationship already exists in the knowledge graph. If not, a new relationship edge is created and the associated attributes are set. If it already exists, the attribute value of the relationship edge is updated.
[0103] In some embodiments, Figure 2 The generation module 205 presents a visual editing interface containing multiple page components on the front-end page; in response to the user's dragging operation in the visual editing interface, components are selected and combined into a page structure, and the selected components are bound to the entry data or entity information; based on the user configuration result, a page rendering configuration file describing the page structure and data binding relationship is generated; the page rendering configuration file is stored in a database, and an association is established with the corresponding entry identifier or encyclopedia page identifier so that it can be dynamically pulled and the front-end rendering display is completed when the page is accessed.
[0104] In some embodiments, Figure 2The output module 206 receives a search request input by a user, the search request including keywords and filtering conditions; based on the maintained knowledge graph data, performs a semantic parsing operation, identifies the entity type corresponding to the keyword input by the user, and performs a graph path traversal in combination with the filtering conditions to determine a target entity set semantically associated with the keyword; retrieves entry data associated with the target entity set, and generates a result set including game strategy content, association relationships between entities, and recommended information according to a preset display logic, and passes the result set to the front-end page for visual display.
[0105] It should be understood that the size of the serial numbers of the steps in the above embodiments does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.
[0106] Figure 3 Schematic diagram of the structure of the electronic device 3 provided in the embodiment of the present application. Figure 3 As shown, the electronic device 3 of this embodiment includes: a processor 301, a memory 302, and a computer program 303 stored in the memory 302 and executable on the processor 301. When the processor 301 executes the computer program 303, the steps in the above-mentioned method embodiments are implemented. Alternatively, when the processor 301 executes the computer program 303, the functions of the modules / units in the above-mentioned device embodiments are implemented.
[0107] Exemplarily, the computer program 303 may be divided into one or more modules / units, which are stored in the memory 302 and executed by the processor 301 to complete the present application. The one or more modules / units may be a series of computer program instruction segments capable of completing specific functions, which are used to describe the execution process of the computer program 303 in the electronic device 3.
[0108] The electronic device 3 may be a desktop computer, a notebook, a PDA, a cloud server, or other electronic device. The electronic device 3 may include, but is not limited to, a processor 301 and a memory 302. Those skilled in the art will appreciate that Figure 3 It is only an example of the electronic device 3 and does not constitute a limitation of the electronic device 3. It may include more or fewer components than shown in the figure, or a combination of certain components, or different components. For example, the electronic device may also include input and output devices, network access devices, buses, etc.
[0109] The processor 301 may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or the processor may be any conventional processor, etc.
[0110] The memory 302 may be an internal storage unit of the electronic device 3, for example, a hard disk or memory of the electronic device 3. The memory 302 may also be an external storage device of the electronic device 3, for example, a plug-in hard disk, a smart media card (SMC), a secure digital (SD) card, a flash card, etc. equipped on the electronic device 3. Further, the memory 302 may also include both an internal storage unit and an external storage device of the electronic device 3. The memory 302 is used to store computer programs and other programs and data required by the electronic device. The memory 302 may also be used to temporarily store data that has been output or is to be output.
[0111] The technicians in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example for illustration. In practical applications, the above-mentioned function allocation can be completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiment can be integrated in a processing unit, or each unit can exist physically separately, or two or more units can be integrated in one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of this application. The specific working process of the units and modules in the above-mentioned system can refer to the corresponding process in the aforementioned method embodiment, which will not be repeated here.
[0112] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0113] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0114] In the embodiments provided in the present application, it should be understood that the disclosed devices / computer equipment and methods can be implemented in other ways. For example, the device / computer equipment embodiments described above are only schematic, for example, the division of modules or units is only a logical function division, and there may be other division methods in actual implementation, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. In addition, the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces, indirect coupling or communication connection of devices or units, which may be electrical, mechanical or other forms.
[0115] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0116] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0117] If the integrated module / unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the present application implements all or part of the processes in the above-mentioned embodiment method, and can also be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium, and the computer program can implement the steps of the above-mentioned various method embodiments when executed by the processor. The computer program may include computer program code, which may be in source code form, object code form, executable file or some intermediate form. The computer-readable medium may include: any entity or device capable of carrying computer program code, recording medium, U disk, mobile hard disk, disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electric carrier signal, telecommunication signal and software distribution medium, etc.
[0118] The above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the technical solutions of the present application are described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some of the technical features therein by equivalents. These modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application, and should all be included in the protection scope of the present application.
Claims
1. A game strategy retrieval method based on knowledge graph structured management, characterized in that: include: In response to a request for newly added game information, a data object containing basic attributes of the newly added game is constructed, and the data object is encapsulated as a message, and sent to a backend system through a message queue to trigger an encyclopedia entry initialization operation; Read the structured file containing game strategy information uploaded by the user, parse the fields in the structured file, and map the fields to corresponding entry data; Writing the entry data into a database, constructing entity objects and semantic relationships corresponding to the entry data, and encapsulating the entity objects and semantic relationships into an update request message; In response to the update request message, incrementally update the knowledge graph data according to a predefined knowledge graph pattern, and create or update game-related entity nodes and semantic relationships between the entity nodes; Based on the generated entry data and entity information, a visual editing interface is provided for the user to configure the encyclopedia page structure by dragging and dropping, and a page rendering configuration file associated with the entry data is generated; Based on the knowledge graph data, combined with the keywords and filtering conditions input by the user, semantic hierarchical analysis is performed to determine the retrieval target entity and related terms, and the game strategy content and related information related to the keyword semantics are output.
2. The method according to claim 1, characterized in that The message queue is sent to the backend system to trigger the initialization operation of the encyclopedia entry, including: Send the message to a preset message queue to implement asynchronous communication between the front-end request processing module and the back-end encyclopedia processing module; The message queue is monitored in the back-end encyclopedia processing module, and when the message is received, the initialization operation of the encyclopedia entry is automatically performed, and after the initialization of the encyclopedia entry is completed, the entry identification information is generated and the initialization status is recorded; The initialization operation of the encyclopedia entry includes creating a main entry corresponding to the newly added game in the database, and writing the main entry into the basic attribute information of the newly added game.
3. The method according to claim 1, characterized in that The reading of the structured file containing game strategy information uploaded by the user, parsing the fields in the structured file, and mapping the fields to corresponding entry data includes: Receiving a structured file uploaded by a user through a front-end interface or interface, and storing the structured file in a temporary storage path; Performing format verification on the structured file, including file structure, header field naming, data type and integrity, and returning an error message if the verification fails; After the verification is passed, the data content in the structured file is parsed to extract multiple field information related to the game; Based on the mapping rules between fields and system predefined term types, the extracted field content is converted into the corresponding term data structure.
4. The method according to claim 1, characterized in that: The step of constructing an entity object and a semantic relationship corresponding to the entry data, and encapsulating the entity object and the semantic relationship into an update request message includes: Based on the generated entry data, the corresponding game semantic element type is identified, and the entry data is converted into an entity object with structured attributes according to a preset entity classification rule; Construct semantic relationships between entity objects based on their associations in the game semantic hierarchy; Encapsulate the entity objects and semantic relationships to generate a data structure that meets the requirements of the knowledge graph update interface; The encapsulated entity objects and semantic relationships are sent to the message queue as update request messages so that the knowledge graph maintenance module can perform incremental update operations on the knowledge graph data.
5. The method according to claim 1, characterized in that The incremental updating of the knowledge graph data according to the predefined knowledge graph mode, creating or updating the game-related entity nodes and the semantic relationships between the entity nodes, includes: According to the entity objects and semantic relationships in the update request message, matching verification is performed on the received entity types and relationship types according to the predefined knowledge graph model; Perform an existence check on the entity object in the knowledge graph. If the corresponding entity node does not exist, create a new entity node and write attribute information. If it already exists, update or merge the node attributes according to the attribute changes. Based on the semantic relationship between the entity objects, determine whether the corresponding edge relationship already exists in the knowledge graph. If not, create a new relationship edge and set the associated attributes. If it already exists, update the attribute value of the relationship edge.
6. The method according to claim 1, characterized in that According to the generated entry data and entity information, a visual editing interface is provided for the user to configure the encyclopedia page structure by dragging and dropping, and a page rendering configuration file associated with the entry data is generated, including: Present a visual editing interface containing multiple page components on the front-end page; In response to a user's dragging operation in the visual editing interface, components are selected and combined into a page structure, and the selected components are bound to the entry data or entity information; Generate a page rendering configuration file that describes the page structure and data binding relationship based on the user configuration results; The page rendering configuration file is stored in a database and associated with a corresponding entry identifier or encyclopedia page identifier so that it can be dynamically retrieved and the front-end rendering display can be completed when the page is accessed.
7. The method according to claim 1, characterized in that Based on the knowledge graph data, combined with the keywords and screening conditions input by the user, semantic hierarchical analysis is performed to determine the search target entity and related terms, and the game strategy content and related information related to the keyword semantics are output, including: Receiving a search request input by a user, wherein the search request includes keywords and screening conditions; Based on the maintained knowledge graph data, perform semantic parsing operations to identify the entity type corresponding to the user input keyword, and perform graph path traversal in combination with the screening conditions to determine the target entity set that is semantically associated with the keyword; The entry data associated with the target entity set is retrieved, and a result set including game strategy content, relationship between entities and recommendation information is generated according to a preset display logic, and the result set is passed to the front-end page for visual display.
8. A game strategy retrieval device based on knowledge graph structured management, characterized in that: include: A construction module, for responding to a request for new game information, constructing a data object containing basic attributes of the new game, and encapsulating the data object into a message, and sending the message to the back-end system through a message queue to trigger an encyclopedia entry initialization operation; A parsing module, used to read a structured file containing game strategy information uploaded by a user, parse the fields in the structured file, and map the fields to corresponding entry data; An encapsulation module, used to write the entry data into a database, construct entity objects and semantic relationships corresponding to the entry data, and encapsulate the entity objects and semantic relationships into an update request message; An update module, configured to respond to the update request message, incrementally update the knowledge graph data according to a predefined knowledge graph mode, and create or update game-related entity nodes and semantic relationships between the entity nodes; A generation module, for providing a visual editing interface for users to configure the encyclopedia page structure by dragging and dropping, and generating a page rendering configuration file associated with the entry data, based on the generated entry data and entity information; The output module is used to perform semantic hierarchical analysis based on the knowledge graph data, combined with the keywords and screening conditions input by the user, determine the retrieval target entity and related entries, and output the game strategy content and related information related to the keyword semantics.
9. An electronic device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 7 are implemented.
10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.
Citation Information
Patent Citations
Automatic game release method, system, equipment and medium
CN117573145A
RAG data acquisition and question and answer generation method and system based on encyclopedia website
CN119441569A
Scalable and Resource-Efficient Knowledge-Graph Completion
US20240311656A1
Structured updated status, requests, user data & programming based presenting & accessing of connections
WO2015036817A1
Knowledge extraction method, apparatus, electronic device, and storage medium
WO2021212682A1
Cited By
Game strategy generation method and device, equipment and storage medium
CN120653789A