Government affair question and answer method, electronic equipment and storage medium

By matching user question text with the business tree of the matter, querying the situation question-and-answer database and the government knowledge base, personalized government guide texts are generated, which solves the problem of low practicality and accuracy of government question-and-answer in the existing technology and realizes efficient and accurate government services.

CN121833906APending Publication Date: 2026-04-10DIGITAL GUANGDONG NETWORK CONSTR CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
DIGITAL GUANGDONG NETWORK CONSTR CO LTD
Filing Date
2026-01-16
Publication Date
2026-04-10

AI Technical Summary

Technical Problem

Existing government affairs Q&A methods lack a refined and structured analysis of the handling situation, and cannot provide personalized filtering and accurate feedback based on the user's specific circumstances, resulting in low practicality and accuracy.

Method used

By matching user question text with nodes in a pre-built business tree, the system identifies the target area for handling matters. Based on these target area matters, it queries a question-and-answer database and a government knowledge base to generate personalized and highly accurate situational guidance text.

Benefits of technology

It has improved the practicality and accuracy of government responses, reduced the time and effort users spend reading and understanding them on their own, achieved the goal of "getting things done in one go," and enhanced the user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121833906A_ABST
    Figure CN121833906A_ABST
Patent Text Reader

Abstract

The embodiment of the invention discloses a government affair question and answer method, electronic equipment and a storage medium, and relates to the technical field of computers. The method comprises the following steps: matching a user question text with nodes of a pre-constructed item service tree to obtain matched nodes, and determining a target region handling item according to the matched nodes; querying a situation question-answer pair library of a region to which the user belongs based on the target region handling item to obtain a target situation question-answer pair set of the target region handling item; identifying a situation to which the user question text belongs based on the target situation question and answer pair set to obtain a target user situation; and querying the government affair knowledge base based on the target region handling item to obtain the target government affair data, identifying the target government affair data based on the target user situation, generating the situation guide text corresponding to the target user situation, and displaying the situation guide text, so that practical and accurate government affair service can be provided for the user, and the user experience is improved. And the practicability and accuracy of government affair answering are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, and in particular to a government affairs question-and-answer method, electronic device, and storage medium. Background Technology

[0002] Currently, government Q&A methods mainly utilize keyword matching or semantic vector search technology to retrieve the most relevant guide entries from the government knowledge base to the user's question text, and then provide the content text of those guide entries as the answer to the user.

[0003] However, existing government knowledge bases are mainly built around macro-level issues, lacking a refined and structured analysis of the specific circumstances of handling affairs. They cannot provide personalized filtering and accurate feedback based on the user's specific situation (such as enterprise type, personal identity, etc.), forcing users to spend a lot of energy to read, understand, and judge the required materials themselves, resulting in low practicality and accuracy of government answers. Summary of the Invention

[0004] This application provides a government affairs question-and-answer method, electronic device, and storage medium, which can provide users with practical and accurate government affairs services, thereby solving the problem of low practicality and accuracy of government affairs answers in the prior art.

[0005] In a first aspect, embodiments of this application provide a government affairs Q&A method, which includes: matching user question text with nodes of a pre-built business tree to obtain matching nodes, and determining the target region's processing item based on the matching nodes; querying a situation Q&A database of the user's region based on the target region's processing item to obtain a target situation Q&A set for the target region's processing item; identifying the situation to which the user question text belongs based on the target situation Q&A set to obtain the target user's situation; querying a government affairs knowledge base based on the target region's processing item to obtain target government affairs data; identifying the target government affairs data based on the target user's situation; generating situation guidance text corresponding to the target user's situation; and displaying the situation guidance text.

[0006] In this embodiment, the user's question text can be matched with nodes in a pre-built business tree to obtain matching nodes. Based on these matching nodes, the target region's processing item can be determined, improving the efficiency and accuracy of identifying the target region's processing item. This provides an accurate data foundation for subsequent retrieval of the question-and-answer database and enhances the context for subsequent retrieval of the government knowledge base. Next, based on the processing item in the target region, the question-and-answer database for the user's region is queried to obtain the target question-and-answer set for the target region's processing item. This allows for accurate retrieval of the question-and-answer pairs corresponding to the target region's processing item. The question-and-answer database can provide a refined and structured analysis of processing situations. Then, based on the target question-and-answer set, the situation to which the user's question text belongs is identified, resulting in the target user's situation. Accurately identifying the target user's situation, i.e., the user's specific circumstances, provides a precise data foundation for generating subsequent situation-specific guidance texts. Then, based on the service items for the target region, the government knowledge base is queried to obtain target government data. This data is then identified based on the target user's situation to generate and display the corresponding situation-specific guidance text. This allows for the generation of personalized, highly accurate service guidance texts tailored to the specific target user's situation, rather than providing generalized answers that encompass all possibilities. This eliminates the need for users to spend considerable effort reading, understanding, and determining the required materials themselves, thereby improving the practicality and accuracy of government responses. Ultimately, this achieves the goal of "one-stop service," providing users with practical and precise government services and enhancing the user experience.

[0007] Secondly, embodiments of this application provide a government affairs Q&A device, which includes: a determining module, used to match user question text with nodes of a pre-built business tree to obtain matching nodes, and determine the target region's processing item based on the matching nodes; a query module, used to query a situation Q&A pair library of the user's region based on the target region's processing item to obtain a target situation Q&A pair set for the target region's processing item; an identification module, used to identify the situation to which the user question text belongs based on the target situation Q&A pair set to obtain the target user's situation; and a generating module, used to query a government affairs knowledge base based on the target region's processing item to obtain target government affairs data, identify the target government affairs data based on the target user's situation, generate situation guidance text corresponding to the target user's situation, and display the situation guidance text.

[0008] Thirdly, embodiments of this application provide an electronic device, which includes: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores a computer program executable by the at least one processor, the computer program being executed by the at least one processor to enable the at least one processor to execute the government affairs question-and-answer method of any embodiment of this application.

[0009] Fourthly, embodiments of this application provide a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the government affairs question-and-answer method as described in any embodiment of this application.

[0010] The descriptions of the second, third, and fourth aspects in this application can be referenced to the detailed description of the first aspect; and the beneficial effects described in the second, third, and fourth aspects can be referenced to the analysis of the beneficial effects in the first aspect, which will not be repeated here.

[0011] In this application, the name of the aforementioned government affairs Q&A device does not limit the device or functional module itself. In actual implementation, these devices or functional modules may appear under other names. As long as the function of each device or functional module is similar to that of this application, it falls within the scope of the claims of this application and its equivalents.

[0012] These or other aspects of this application will become more readily apparent in the following description. Attached Figure Description

[0013] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0014] Figure 1 This is a flowchart illustrating a government affairs question-and-answer method provided in an embodiment of this application; Figure 2 This is a schematic diagram of the government affairs question-and-answer device provided in the embodiments of this application; Figure 3 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation

[0015] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of this application.

[0016] It should be noted that the terms "first," "second," "target," and "original," etc., used in the specification, claims, and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in sequences other than those illustrated or described herein. Furthermore, the terms "comprising," "having," and any variations thereof are intended to cover a non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.

[0017] Figure 1 This is a flowchart illustrating a government affairs question-and-answer method provided in this application embodiment. This embodiment can be applied to scenarios where users' government affairs questions need to be answered. The government affairs question-and-answer method provided in this embodiment can be executed by a government affairs question-and-answer device provided in this application embodiment. This device can be implemented through software and / or hardware. In a specific embodiment, the government affairs question-and-answer device can be integrated into an electronic device, such as a computer. The executing entity of this method can be an electronic device. See also... Figure 1 The government affairs Q&A method in this embodiment includes, but is not limited to, the following steps: S110. Match the user's question text with the nodes of the pre-built business tree to obtain the matching nodes, and determine the target area to handle the item based on the matching nodes.

[0018] Among them, the user question text is the specific government affairs question text that the user inputs into the electronic device.

[0019] The business tree is a tree structure pre-constructed based on the original government data, with nodes representing items and edges representing the logical relationships between items. In this embodiment, the original government data is government source data, including service guides and policy texts for all items in a specific region, and one region corresponds to one set of original government data.

[0020] The matters in this application embodiment are government affairs matters, which include main items, sub-items, and processing items. The main item is the top-level classification of government affairs matters, the sub-items are the secondary units under the main item according to approval level, object category, action classification, etc., and the processing item is the smallest granular processing unit under the sub-items according to the actual handling situation (such as new establishment, change, renewal, certificate replacement, cancellation, etc.). Thus, the main item is at a higher level than the sub-items, and the sub-items are at a higher level than the processing items. Furthermore, the processing item corresponds to a specific service guide, that is, one processing item corresponds to one service guide.

[0021] Optionally, the business tree for a matter can be a business tree for a region. The nodes of the business tree for a region are regional matters, namely regional main items, regional sub-items, and regional processing items, and the edges represent the logical relationships between regional matters.

[0022] It should be noted that since the names of items and the service guidelines for handling items in the original government data of different regions may be different, the business tree of a region is a business tree of a specific region, and the regional items are items of a specific region. Furthermore, one region corresponds to one business tree of a region.

[0023] Optionally, the regional matter business tree can be an original regional matter business tree or a standard regional matter business tree; wherein, the nodes of the original regional matter business tree are original regional matters, and the nodes of the standard regional matter business tree are standard regional matters; the original regional matters are the actual regional matters in the original government data, and include the original regional main items, the original regional sub-items, and the original regional processing items; the standard regional matters are the regional matters obtained after standardizing the original regional matters, and include the standard regional main items, the standard regional sub-items, and the standard regional processing items.

[0024] It should be noted that since the original regional items are generally quite long names, keywords such as subject, action, and situation can be extracted from the original regional items to facilitate user understanding. These extracted keywords can then be combined into standard regional items to standardize (i.e. simplify) the original regional items.

[0025] The matching node is the node in the entire business tree that matches the user's question text. The target region processing item is the original region processing item corresponding to the user's question text.

[0026] Specifically, when users need to handle government affairs, they can input their questions into electronic devices via keyboard input, voice input, or other means. This results in a textual question from the user, which in turn provides a response from the electronic device. Based on the response, users can learn about the required materials and other information, making it easier to handle government affairs quickly and accurately.

[0027] After receiving the user's input question text, the electronic device can match the user's question text with the nodes of the pre-built business tree to obtain the matching node. That is, the user's question text can be vectorized to obtain the user text vector, and each node in the business tree can be vectorized to obtain the node vector of the corresponding node. Then, the similarity between the user text vector and the node vector of each node is calculated, and the node with the highest similarity is determined as the matching node.

[0028] Then, the target region processing item is determined based on the matching node. In one implementation, when the item business tree is the original region item business tree, the leaf nodes of the original region item business tree are the original region processing items. In this case, if the matching node is a leaf node, the matching node can be determined as the target region processing item. If the matching node is not a leaf node, all leaf nodes are obtained from the child nodes of the matching node in the original region item business tree, all obtained leaf nodes are displayed, and the user is prompted to select a node from them. Then, the node selected by the user is determined as the target region processing item. This can guide the user to select a specific processing item and provide an accurate data foundation for subsequent answer determination.

[0029] When the service tree is a standard regional service tree, the leaf nodes of the standard regional service tree are standard regional service items. In this case, when the matching node is a leaf node, the matching node can be identified as the target standard regional service item. Based on the target standard regional service item, the regional service item database of the user's region is queried to obtain the original regional service item corresponding to the target standard regional service item, i.e., the target regional service item. The regional service item database includes fields such as service item identifier, standard regional service item, and original regional service item. When the matching node is not a leaf node, all leaf nodes are obtained from the child nodes of the matching node in the standard regional service tree. All the obtained leaf nodes are displayed, and the user is prompted to select a node. Then, the node selected by the user is identified as the target standard regional service item, and the above query process is repeated to obtain the target regional service item. This can guide the user to select a specific service item and provide an accurate data foundation for subsequent answer determination.

[0030] Optionally, the business tree can also be a global business tree. The nodes of the global business tree include global processing items, that is, the leaf nodes of the global business tree are global processing items. The construction steps of the global business tree are as follows: using a semantic recognition generation model, the original government data of multiple regions within the preset area are identified to generate global business paths, wherein the global business paths include global items and the logical relationships between global items; then, the global business tree is constructed with global items as nodes and the logical relationships between global items as edges.

[0031] The preset area refers to the area served by the electronic device. The preset area may include multiple regions, and the user's region is located within the preset area.

[0032] Global items are standardized items obtained by standardizing the regional items in the original government data of all regions within the preset area. Global items include global main items, global sub-items, and global processing items; and each region within the preset area corresponds to a global item business tree.

[0033] The semantic recognition generation model is a pre-trained large language model. A large language model is a deep learning model that is pre-trained with massive amounts of text data in an unsupervised or self-supervised manner. It has a large number of parameters, can understand natural language, generate coherent text, and complete complex language tasks (such as dialogue, translation, summarization, reasoning, etc.).

[0034] Specifically, raw government data from multiple regions within a preset area can be retrieved from the government knowledge base. This raw government data, along with the first prompt word, is then input into a semantic recognition generation model to obtain global matter paths. Multiple global matter paths exist at this point. A global matter business tree is then constructed, using global matters within each global matter path as nodes and the logical relationships between global matters within each global matter path as edges. The government knowledge base is used to store the raw government data from all regions within a specific area.

[0035] The first prompt may include extracting global matter elements (i.e., the subject, action, and situation) and the hierarchical relationship between global matter elements from the original government data, generating global matters (i.e., global main items, global sub-items, and global processing items) based on global matter elements according to preset rules, determining the logical relationship between global matters based on the hierarchical relationship between global matter elements, and generating global matter paths based on the logical relationship between global matters; the preset rules include using the subject as the name of the global main item, generating the name of the global sub-item according to the concatenation order of the subject and action, and generating the name of the global processing item according to the concatenation order of the subject, action, and situation.

[0036] Specifically, after receiving the original government data and the first prompt word, the semantic recognition generation model processes the original government data according to the first prompt word. For example, it extracts the subject, action, and situation of the matter from the original government data and infers the hierarchical relationship between the subject, action, and situation. Then, it generates a global main item based on the subject, a global sub-item based on the subject and action, and a global processing item based on the subject, action, and situation according to preset rules. It also determines the logical relationship between the global main item, global sub-item, and global processing item based on the hierarchical relationship between the subject, action, and situation. Finally, it generates and outputs multiple global matter paths based on the global main item, global sub-item, and global processing item, as well as the logical relationship between the global main item, global sub-item, and global processing item.

[0037] It should be noted that the original government data input to the semantic recognition generation model can be the original government data of all regions within the preset area, or it can be the original government data of a part of the preset area. This part of the area may or may not include the user's region.

[0038] In this embodiment, by introducing a semantic recognition generation model, the generation efficiency and accuracy of global item paths can be improved, and costs can be reduced. This, in turn, improves the construction efficiency and accuracy of the global item business tree, providing an accurate data foundation for subsequently determining target global processing items. In addition, the global item business tree is applicable to multiple regions, rather than being limited to a specific region, further improving generalization. Furthermore, when the region served by the electronic device changes, the global item business tree can be directly updated, further improving scalability.

[0039] Alternatively, in another implementation, when the item business tree is a global item business tree, the target region processing item is determined based on the matching node, including Sa1-Sa2: Sa1. Determine the target global processing item based on the matching node.

[0040] Among them, the target global processing item is the global processing item corresponding to the user's question text.

[0041] Specifically, when the matching node is a leaf node, the matching node is identified as the target global processing item; when the matching node is a non-leaf node, the user is guided to select based on the child nodes of the matching node in the global item business tree to obtain the target global processing item.

[0042] Furthermore, based on the child nodes of the matching nodes in the global task business tree, the user is guided to select the target global task, including Sb1-Sb6: Sb1. Obtain the child nodes belonging to the first level from the child nodes of the matching node in the global business tree to obtain each candidate node.

[0043] Among them, the candidate node is the child node located at the first level in the child node tree of the matching node in the global event business tree.

[0044] Sb2. Generate an item selection request based on each candidate node and display the item selection request.

[0045] Among them, the task selection request is a command generated by the electronic device to request the user (i.e. the subject of the task) to select a node from multiple candidate nodes.

[0046] Sb3: Obtain the candidate nodes selected by the user for the task selection request, and get the first target node.

[0047] The first target node is a node selected by the user from multiple candidate nodes.

[0048] Sb4. Determine whether the first target node is a leaf node.

[0049] Specifically, Sb6 is executed when the first target node is a leaf node; Sb5 is executed when the first target node is a non-leaf node.

[0050] Sb5. When the first target node is a non-leaf node, obtain the first-level child nodes from the child nodes of the first target node in the global event business tree, obtain each candidate node, and return to execute the event selection request generated based on each candidate node.

[0051] Specifically, when the first target node is a non-leaf node, it indicates that the user needs to be guided to make a selection. At this time, the child nodes belonging to the first level can be obtained from the child nodes of the first target node in the global business tree to obtain each candidate node, and then return to execute Sb2 to continue guiding the user to make a selection until the first target node is a leaf node.

[0052] Sb6. When the first target node is a leaf node, the first target node is determined as the target global processing item.

[0053] In this embodiment, guiding users step by step through nodes in the global business tree can reduce the cognitive load on users, improve the accuracy of user selection, increase computational efficiency, reduce implementation complexity, and thus improve the efficiency and accuracy of determining the target global processing item, providing an accurate data foundation for subsequently determining the processing item in the target region.

[0054] Sa2: Based on the target global processing items, query the regional processing item database of the user's region to obtain the processing items for the target region.

[0055] In this embodiment, the target region's processing item is determined based on the matching node found by matching the user's question text with the global item business tree. This can improve computational efficiency, reduce implementation complexity, and thus improve the efficiency and accuracy of determining the target region's processing item. This provides an accurate data foundation for subsequent answer determination and can serve multiple regions.

[0056] Optionally, when a change is detected in the original government data used to construct the global matter business tree, a semantic recognition generation model is used to identify the most recently updated global matter business tree and the changed original government data, generate the global matter path to be updated and its update event, and update the most recently updated global matter business tree based on the global matter path to be updated and its update event to obtain the latest global matter business tree. This allows the global matter business tree to respond quickly to policy changes and adapt to the latest government matters, while replacing the high-cost and long-cycle model fine-tuning in the existing technology, greatly reducing operation and maintenance costs.

[0057] Optionally, the construction steps of the standard regional service tree are as follows: Using a semantic recognition generation model, the original government data of the user's region is identified to generate standard regional service paths. These paths include the standard regional service items and the logical relationships between them. Then, using the standard regional service items as nodes and the logical relationships between them as edges, the standard regional service tree is constructed. Specific implementation details can be found in the construction details of the global service tree, and will not be elaborated upon here.

[0058] Optionally, the construction steps of the original regional business tree are as follows: using a semantic recognition generation model, the original government data of the user's region is identified to generate the original regional business path, wherein the original regional business path includes the original regional items and the logical relationship between the original regional items; then, the original regional business tree is constructed with the original regional items as nodes and the logical relationship between the original regional items as edges.

[0059] Specifically, the original government data of the user's region and the second prompt word are input into the semantic recognition generation model to obtain the original regional matter path. The second prompt word can include the original regional matters extracted from the original government data and the hierarchical relationship between the original regional matters, and the original regional matter path is generated based on the logical relationship between the original regional matters. The remaining specific implementation details can be found in the construction details of the global matter business tree, and will not be elaborated here.

[0060] Similarly, when changes are detected in the original government data of a user's region, the regional business tree can be dynamically updated. This allows the regional business tree to respond quickly to policy changes and adapt to the latest government matters. It also replaces the high-cost, long-cycle model fine-tuning in existing technologies, greatly reducing operation and maintenance costs.

[0061] Optionally, when determining the target area for processing, the processing item identifier can be obtained from the regional item database of the user's region.

[0062] S120. Based on the query database of the user's region for the target region's processing items, obtain the target situation question and answer set for the target region's processing items.

[0063] The situational question-and-answer pair library is used to store multiple situational question-and-answer pairs for all regional processing items within a specific region, and one situational question-and-answer pair library corresponds to one region. The situational question-and-answer pair includes fields such as question identifier, question, multiple answers, situation corresponding to each answer, processing item identifier, parent question identifier, and parent answer. The question identifier is a unique identifier for the situational question-and-answer pair, the parent question identifier is used to represent the parent situational question-and-answer pair of this situational question-and-answer pair, and the parent answer is used to represent which answer branch of the parent situational question-and-answer pair this situational question-and-answer pair is located in.

[0064] The target situation question-and-answer pair set is a collection of multiple situation question-and-answer pairs belonging to the target region's processing items in the situation question-and-answer pair database.

[0065] Specifically, after obtaining the processing items for the target region, the system can query the question-and-answer database of the user's region based on the processing item identifier of the processing items for the target region, obtain the question-and-answer pairs belonging to the processing items for the target region, and combine the question-and-answer pairs belonging to the processing items for the target region into a target question-and-answer pair set.

[0066] Optionally, the steps for constructing the situation question-and-answer pair library for the target region are as follows: using a semantic recognition generation model, the original government data of the target region is identified to generate situation question-and-answer pairs for each regional service item in the target region and the logical relationships between the situation question-and-answer pairs; then, based on the situation question-and-answer pairs for all regional service items in the target region and the logical relationships between the situation question-and-answer pairs, the situation question-and-answer pair library for the target region is constructed.

[0067] Specifically, the third prompt word and the original government data of the target region can be input into the semantic recognition generation model to obtain the situation question-and-answer pairs for each service item in the target region and the logical relationship between the situation question-and-answer pairs. Then, based on the situation question-and-answer pairs for each service item in the target region, the service item identifier of the corresponding service item, and the logical relationship between the situation question-and-answer pairs, the corresponding situation question-and-answer pair records are generated, including fields such as question identifier, question, multiple answers, situation corresponding to each answer, service item identifier, parent question identifier, and parent answer, thereby constructing a situation question-and-answer pair library for the target region.

[0068] The third prompt can include identifying key discriminative dimensions for each region's processing items from the original government data, such as identity, enterprise type, or situation, and inferring all situations for each region's processing items based on the key discriminative dimensions, summarizing all possible combinations of situations, generating question-and-answer pairs for each situation of the corresponding region's processing items, as well as the logical relationships between multiple question-and-answer pairs, such as dependency relationships and answer branching relationships.

[0069] Specifically, after receiving the third prompt word and the original government data of the target region, the semantic recognition generation model processes the original government data according to the third prompt word. For example, it selects each service item in each region within the target region as the current service item, identifies the service guide for the current service item from the original government data, and extracts key discrimination dimensions such as identity, enterprise type, or situation of the current service item from the service guide. Then, based on the key discrimination dimensions, it infers all the situations of the current service item, summarizes all possible situation combinations, generates question-and-answer pairs for each situation of the current service item, and the logical relationships between multiple question-and-answer pairs, such as dependency relationships and answer branch relationships.

[0070] In this embodiment of the application, by introducing a semantic recognition generation model, the generation efficiency and accuracy of situational question-and-answer pairs and their logical relationships can be improved, and the cost can be reduced. This improves the construction efficiency and accuracy of the situational question-and-answer pair library, providing an accurate data foundation for subsequently determining the target situational question-and-answer pair set.

[0071] S130. Based on the target situation question-answer pair set, identify the situation to which the user's question text belongs, and obtain the target user situation.

[0072] The target user scenario refers to the complete scenario to which the user's question text belongs.

[0073] Specifically, in one possible implementation, the target user scenario is obtained by identifying the scenario to which the user's question text belongs based on the target scenario question-answer pair set, including Sc1-Sc4: Sc1. Using a semantic recognition generation model, the first user scenario to which the user question text belongs and the question-and-answer pair of the scenario to be supplemented are identified based on the user question text and the target scenario question-and-answer pair set.

[0074] The first user scenario refers to the scenario to which the user's question text belongs. The question-and-answer pairs for scenarios that need to be supplemented are the question-and-answer pairs for scenarios that the user needs to complete; they may or may not be empty.

[0075] Specifically, the fourth prompt word, the user's question text, and the target scenario question-answer pair set can be input into the semantic recognition generation model to obtain the first user scenario and the question-answer pair to be supplemented.

[0076] The fourth prompt includes identifying the situation in which the user's question text corresponds to the answer in the question-and-answer pair as the first user situation, and identifying the situation in which the user's question text does not answer in the question-and-answer pair that is interdependent with the first user situation as the situation to be supplemented.

[0077] Specifically, after receiving the fourth prompt word, the user question text, and the target scenario question-answer pair set, the semantic recognition generation model can process the user question text and the target scenario question-answer pair set according to the fourth prompt word. For example, based on the parent question identifier, it determines the logical relationship between multiple scenario question-answer pairs in the target scenario question-answer pair set. Using the questions in the scenario question-answer pairs as nodes and the logical relationship between the scenario question-answer pairs as edges, it constructs a target scenario question-answer tree. The attribute information of the nodes includes all field contents of the scenario question-answer pairs, the direction of the edges is from the parent node to the child node, and the attribute information of the edge is the parent answer of the corresponding edge's incoming node. Secondly, it matches the user question text and the nodes of the target scenario question-answer tree to obtain the matching questions and the matching answers for each matching question. At this time, there may be one or more matching questions, and the scenario corresponding to the matching answer of the matching question is determined as the first user scenario. In this process, when the user's question text answers a question in a situational question-answer pair, the question in that situational question-answer pair is identified as the matching question, and the answer corresponding to the user's question text in that situational question-answer pair is identified as the matching answer. Next, the branch containing the matching answer is determined, and the matching branch is obtained. If the matching question includes all questions in the matching branch, it indicates that the user's question text has answered all questions in the matching branch, and the situational question-answer pair to be supplemented is determined to be empty. If the matching question does not include all questions in the matching branch, it indicates that the user's question text has not answered all questions in the matching branch, and the question at the lowest level among multiple matching questions is identified as the lowest-level question, and the situational question-answer pairs corresponding to all child nodes of the matching answer of the lowest-level question in the target situational question-answer tree are identified as situational question-answer pairs to be supplemented. After that, the first user situation and the situational question-answer pairs to be supplemented are output.

[0078] In the target scenario question-answer tree, all child nodes of the matching answer to the lowest-level question include the outgoing node of the edge containing the matching answer to the lowest-level question and all child nodes of that outgoing node.

[0079] Sc2. Determine whether the question-and-answer pairs for the situation to be supplemented are empty.

[0080] Specifically, if the question-and-answer pair to be supplemented is empty, execute Sc3; if the question-and-answer pair to be supplemented is not empty, execute Sc4.

[0081] Sc3. When the question-and-answer pair for the situation to be supplemented is empty, the first user situation is determined as the target user situation.

[0082] Sc4. When the question-and-answer pair of the situation to be supplemented is not empty, guide the user to complete the situation based on the question-and-answer pair of the situation to be supplemented, obtain the second user situation, and combine the first user situation and the second user situation into the target user situation.

[0083] The second user scenario is the scenario where the user completes the information.

[0084] Specifically, when there are multiple question-and-answer pairs for scenarios to be supplemented, the user is guided to complete the scenarios based on the question-and-answer pairs for the scenarios to be supplemented, thus obtaining the second user scenario, including Sd1-Sd7: Sd1. Based on the parent question identifiers of multiple question-answer pairs for the scenarios to be supplemented, determine the logical relationship between the question-answer pairs for the scenarios to be supplemented, and construct a question-answer tree for the scenarios to be supplemented, with the questions in the question-answer pairs for the scenarios to be supplemented as nodes and the logical relationship between the question-answer pairs for the scenarios to be supplemented as edges.

[0085] In this context, the question-answer tree for the case to be supplemented is a directed tree; the attribute information of the edges is the parent answer of the corresponding edge's ingress node; and the ingress node of an edge is the node that the edge's arrow points to.

[0086] Specifically, each of the multiple question-and-answer pairs to be supplemented is selected as the current question-and-answer pair to be supplemented. The parent question-and-answer pair is determined based on the parent question identifier of the current question-and-answer pair to be supplemented. At this time, there is a logical relationship between the parent question-and-answer pair and the current question-and-answer pair to be supplemented. Then, the questions in the question-and-answer pairs to be supplemented are used as nodes, and the logical relationship between the question-and-answer pairs to be supplemented is used as edges. The direction of the edges is from the parent node to the child node, and the attribute information of the edges is determined as the parent answer of the corresponding edge's ingress node. In this way, a question-and-answer tree to be supplemented is constructed.

[0087] Sd2. Obtain the node belonging to the first level from the question-and-answer tree of the situation to be supplemented, and obtain the second target node.

[0088] Specifically, the second target node at this time is the node belonging to the first level in the question-and-answer tree for the situation to be supplemented.

[0089] Sd3. Generate a question and answer request based on the second target node and display the question and answer request.

[0090] The question-answer request is a command generated by an electronic device to request the user to answer a question.

[0091] Sd4. Obtain the answer information input by the user in response to the question answer request, and determine the target child node based on the answer information and the attribute information of the target edge.

[0092] The answer information is the answer entered by the user in response to the question in the question answer request; the outgoing node of the target edge is the node corresponding to the question in the question answer request, and the outgoing node of the target edge is the node that is not pointed to by the arrow of the edge.

[0093] The target child node is the child node located in the branch corresponding to the answer information within the first-level child node of the node corresponding to the question in the question answer request.

[0094] Specifically, the system obtains the user's answer information in response to the question answer request, and identifies the edge in the question-answer tree of the pending situation that has the node corresponding to the question in the question answer request as the target edge. There may be one or more target edges. Then, the answer information is matched with the attribute information of the target edge (i.e., the parent answer of the corresponding target edge's ingress node) to obtain the matching edge, and the ingress node of the matching edge is identified as the target child node. When the answer information is the same as the parent answer marked on the target edge, the target edge is identified as the matching edge.

[0095] For example, the direction of the edge is from node 1 to node 2, node 1 is the parent node of node 2, and node 2 is the child node of node 1. In this case, node 2 is the in-node of the edge, and node 1 is the out-node of the edge.

[0096] Sd5. Determine whether the target child node is a leaf node.

[0097] Specifically, Sd6 is executed when the target child node is a non-leaf node; Sd7 is executed when the target child node is a leaf node.

[0098] Sd6. When the target child node is a non-leaf node, append the parent answer of the target child node to the previous second user scenario, generate a question answer request based on the target child node, and return to execute and display the question answer request.

[0099] Specifically, if Sd6 is executed for the first time, the previous second user case is empty; if it is not the first time Sd6 is executed, the previous second user case is the second user case obtained in the previous loop execution.

[0100] Sd7. When the target child node is a leaf node, append the corresponding case of the parent answer of the target child node after the previous second user case.

[0101] In this embodiment of the application, by guiding the user to complete the situation step by step through the question-and-answer tree of the situation to be supplemented, the second user situation can include all the situations that need to be supplemented, thereby improving the accuracy and efficiency of determining the second user situation, providing an accurate data foundation for subsequently determining the target user situation, and thus improving the completeness and accuracy of the target user situation.

[0102] Optionally, if there is one question-and-answer pair for the situation to be supplemented, a question-and-answer request is generated directly based on the question in the question-and-answer pair for the situation to be supplemented, and the question-and-answer request is displayed. Then, the answer information input by the user in response to the question-and-answer request is obtained, and the situation corresponding to the answer information in the question-and-answer pair for the situation to be supplemented is determined as the second user situation.

[0103] After determining the second user scenario, the first user scenario and the second user scenario are combined into the target user scenario.

[0104] In this embodiment of the application, by introducing a semantic recognition generation model, the recognition efficiency and accuracy of the question-and-answer pair of the first user scenario and the scenario to be supplemented can be improved, and the cost can be reduced. Furthermore, when the question-and-answer pair of the scenario to be supplemented is not empty, the user is guided to complete the scenario based on the question-and-answer pair of the scenario to be supplemented, which improves the completeness and accuracy of the target user scenario and provides an accurate data foundation for the subsequent determination of the scenario guidance text.

[0105] S140. Based on the target region's processing items, query the government affairs knowledge base to obtain the target government affairs data. Based on the target user's situation, identify the target government affairs data, generate the situation guide text corresponding to the target user's situation, and display the situation guide text.

[0106] Among them, the target government data is the service guide text of the target region's handling items in the government knowledge base.

[0107] The situation guide text is a list of materials and other service guide texts in the target government data that pertain to the situation of the target user. The situation guide text is a simplified version of the text, making it easier for users to read and understand.

[0108] Specifically, the service items for the target region are vectorized, and the service guides corresponding to the service items for the target region are retrieved from the government knowledge base based on the vectors of the service items for the target region, which is the target government data.

[0109] Then, using a semantic recognition generation model, the target government data is identified based on the target user situation, and the situation guidance text corresponding to the target user situation is generated. That is, the fifth prompt word, the target user situation and the target government data are input into the semantic recognition generation model to obtain the situation guidance text corresponding to the target user situation.

[0110] The fifth prompt includes identifying the service guide text corresponding to the target user's situation from the target government data, and sorting and simplifying the service guide text to generate a personalized service guide text that is easy for users to understand.

[0111] Specifically, after receiving the fifth prompt word, the target user situation, and the target government data, the semantic recognition generation model processes the target user situation and the target government data according to the fifth prompt word. For example, it identifies the service guide text corresponding to the target user situation from the target government data, sorts and simplifies the service guide text, generates a situation guide text that is easy for users to understand, and outputs the generated situation guide text.

[0112] The technical solution of this application embodiment can match user question text with nodes of a pre-built business tree to obtain matching nodes, and determine the target region's processing item based on the matching nodes. This improves the efficiency and accuracy of determining the target region's processing item, providing an accurate data foundation for subsequent retrieval of the situation question-and-answer pair database, and also providing enhanced context for subsequent retrieval of the government knowledge base. Next, based on the processing item in the target region, the system queries the situation question-and-answer pair database of the user's region to obtain the target situation question-and-answer pair set for the target region's processing item. This allows for accurate retrieval of the situation question-and-answer pairs corresponding to the target region's processing item. The situation question-and-answer pair database can provide a refined and structured analysis of processing situations. Finally, based on the target situation question-and-answer pair set, the system identifies the situation to which the user question text belongs, thus obtaining the target user's situation. It can accurately identify the target user's situation, i.e., the user's specific circumstances, providing an accurate data foundation for the subsequent generation of situation guidance text. Then, based on the service items of the target region, it queries the government knowledge base to obtain the target government data. Based on the target user's situation, it identifies the target government data and generates situation guidance text corresponding to the target user's situation, and displays the situation guidance text. It can generate personalized and highly accurate service guidance texts specific to the target user's situation, rather than providing general answers that include all possibilities. This eliminates the need for users to spend a lot of effort to read, understand, and judge the required materials themselves, thereby improving the practicality and accuracy of government answers. This achieves the goal of "getting things done in one go," providing users with practical and accurate government services and improving the user experience.

[0113] Figure 2 This is a schematic diagram of a government affairs question-and-answer device provided in an embodiment of this application, with reference to... Figure 2 The government affairs Q&A device may include: The determination module 210 is used to match the user's question text with the nodes of the pre-built business tree of matters to obtain the matching nodes, and determine the processing items in the target area based on the matching nodes; The query module 220 is used to query the question and answer database of the user's region based on the service items of the target region, and obtain the target question and answer set of the service items of the target region; The identification module 230 is used to identify the context to which the user's question text belongs based on the target context question-answer pair set, and to obtain the target user context; The generation module 240 is used to query the government affairs knowledge base based on the target region's handling items, obtain the target government affairs data, identify the target government affairs data based on the target user's situation, generate the situation guide text corresponding to the target user's situation, and display the situation guide text.

[0114] In one embodiment, the item business tree is a global item business tree, and the nodes of the global item business tree include global processing items. The determining module 210 determines the target region processing item based on the matching node, including: determining the target global processing item based on the matching node; and querying the regional item database of the user's region based on the target global processing item to obtain the target region processing item.

[0115] In one embodiment, the determining module 210 determines the target global processing item based on the matching node, including: when the matching node is a leaf node, determining the matching node as the target global processing item; when the matching node is a non-leaf node, guiding the user to select based on the child nodes of the matching node in the global item business tree to obtain the target global processing item.

[0116] In one embodiment, the determining module 210 guides the user to select a target global processing item based on the child nodes of the matching node in the global processing business tree. This includes: obtaining child nodes belonging to the first level from the child nodes of the matching node in the global processing business tree to obtain each candidate node; generating a processing item selection request based on each candidate node and displaying the processing item selection request; obtaining the candidate node selected by the user for the processing item selection request to obtain a first target node; when the first target node is a non-leaf node, obtaining child nodes belonging to the first level from the child nodes of the first target node in the global processing business tree to obtain each candidate node, and returning to execute the generation of a processing item selection request based on each candidate node; when the first target node is a leaf node, determining the first target node as the target global processing item.

[0117] In one embodiment, the identification module 230 identifies the scenario to which the user's question text belongs based on the target scenario question-answer pair set to obtain the target user scenario, including: using a semantic recognition generation model, identifying the first user scenario to which the user's question text belongs and the question-answer pair to be supplemented based on the user's question text and the target scenario question-answer pair set; when the question-answer pair to be supplemented is empty, determining the first user scenario as the target user scenario; when the question-answer pair to be supplemented is not empty, guiding the user to complete the scenario based on the question-answer pair to be supplemented to obtain the second user scenario, and combining the first user scenario and the second user scenario into the target user scenario.

[0118] In one embodiment, a situational question-and-answer pair includes a question, a situation corresponding to each answer, a parent question identifier, and a parent answer. Multiple situational question-and-answer pairs exist to be supplemented. The identification module 230 guides the user to complete the situation based on the situational question-and-answer pairs to obtain a second user situation. This includes: determining the logical relationship between the situational question-and-answer pairs to be supplemented based on the parent question identifiers of the multiple situational question-and-answer pairs to be supplemented; constructing a situational question-and-answer tree with questions in the situational question-and-answer pairs as nodes and the logical relationship between the situational question-and-answer pairs as edges; the attribute information of the edges is the parent answer of the corresponding edge's ingress node; and obtaining nodes belonging to the first level from the situational question-and-answer tree to obtain... Reach the second target node; generate a question-and-answer request based on the second target node and display the question-and-answer request; obtain the answer information input by the user in response to the question-and-answer request, and determine the target child node based on the answer information and the attribute information of the target edge; the outgoing node of the target edge is the question in the question-and-answer request; when the target child node is a non-leaf node, append the situation corresponding to the parent answer of the target child node to the previous second user situation, generate a question-and-answer request based on the target child node, and return to execute and display the question-and-answer request; when the target child node is a leaf node, append the situation corresponding to the parent answer of the target child node to the previous second user situation.

[0119] In one embodiment, the steps for constructing the global matter business tree in the determination module 210 are as follows: using a semantic recognition generation model, the original government data of multiple regions within a preset area are identified to generate a global matter path; the global matter path includes global matters and the logical relationships between global matters; using global matters as nodes and the logical relationships between global matters as edges, a global matter business tree is constructed.

[0120] In one embodiment, the steps for constructing the situation question-and-answer pair library for the target region in the query module 220 are as follows: using a semantic recognition generation model, the original government data of the target region is identified, and situation question-and-answer pairs for each regional processing item in the target region and the logical relationships between the situation question-and-answer pairs are generated; based on the situation question-and-answer pairs for all regional processing items in the target region and the logical relationships between the situation question-and-answer pairs, the situation question-and-answer pair library for the target region is constructed.

[0121] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the above-described division of functional modules is merely an example. In practical applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above. The specific working process of the functional modules described above can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.

[0122] The government affairs question-and-answer device provided in this embodiment can be applied to the government affairs question-and-answer method provided in any of the above embodiments, and has the corresponding functions and beneficial effects.

[0123] Figure 3 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Figure 3 A block diagram is shown of an exemplary electronic device 11 suitable for implementing embodiments of the present application. Figure 3 The electronic device 11 shown is merely an example and should not impose any limitations on the functionality and scope of use of this embodiment.

[0124] like Figure 3 As shown, the electronic device 11 is represented in the form of a general-purpose computing electronic device. The components of the electronic device 11 may include, but are not limited to: one or more processors or processing units 16, system memory 28, and bus 18 connecting different system components (including system memory 28 and processing unit 16).

[0125] Bus 18 represents one or more of several bus architectures, including a memory bus or memory controller, a peripheral bus, a graphics acceleration port, a processor, or a local bus using any of the various bus architectures. Examples of these architectures include, but are not limited to, industry-standard architecture buses, microchannel architecture buses, enhanced industry-standard architecture buses, Video Electronics Standards Association (VESA) local buses, and peripheral component interconnect buses.

[0126] Electronic device 11 typically includes a variety of computer system readable media. These media can be any available media that can be accessed by electronic device 11, including volatile and non-volatile media, removable and non-removable media.

[0127] System memory 28 may include computer system readable media in the form of volatile memory, such as random access memory 30 and / or cache memory 32. Electronic device 11 may further include other removable / non-removable, volatile / non-volatile computer system storage media. By way of example only, storage system 34 may be used to read and write non-removable, non-volatile magnetic media ( Figure 3 Not shown; usually referred to as a "hard drive"). Although Figure 3 As not shown, a disk drive for reading and writing to a removable non-volatile disk (e.g., a "floppy disk") and an optical disk drive for reading and writing to a removable non-volatile optical disk may be provided. In these cases, each drive may be connected to bus 18 via one or more data media interfaces. System memory 28 may include at least one program product having a set (e.g., at least one) of program modules configured to perform the functions of the embodiments of this application.

[0128] A program / utility 40 having a set (at least one) of program modules 42 may be stored, for example, in system memory 28. Such program modules 42 include, but are not limited to, an operating system, one or more application programs, other program modules, and program data. Each or some combination of these examples may include an implementation of a network environment. Program modules 42 typically perform the functions and / or methods described in the embodiments of this application.

[0129] Electronic device 11 can also communicate with one or more external devices 14 (e.g., keyboard, pointing device, display 24, etc.), and with one or more devices that enable a user to interact with electronic device 11, and / or with any device that enables electronic device 11 to communicate with one or more other computing devices (e.g., network interface card and modem, etc.). Such communication can be performed through input / output interface 22. Furthermore, electronic device 11 can also communicate with one or more networks (e.g., local area network, wide area network, and / or public network) through network adapter 20.

[0130] like Figure 3 As shown, network adapter 20 communicates with other modules of electronic device 11 via bus 18. It should be understood that, although... Figure 3 As not shown, other hardware and / or software modules may be used in conjunction with electronic device 11, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, tape drives, and data backup storage systems.

[0131] The processing unit 16 executes various functional applications and page displays by running programs stored in the system memory 28, such as implementing a government affairs question-and-answer method provided in any embodiment of this application.

[0132] This application provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements, for example, a government affairs question-and-answer method provided in any embodiment of this application.

[0133] The computer storage medium of this embodiment can be any combination of one or more computer-readable media. The computer-readable medium can be a computer-readable signal medium or a computer-readable storage medium. For example, a computer-readable storage medium can be, but is not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of computer-readable storage media (a non-exhaustive list) include: an electrical connection having one or more wires, a portable computer disk, a hard disk, a random access memory, a read-only memory, an erasable programmable read-only memory, an optical fiber, a portable compact disk read-only memory, an optical storage device, a magnetic storage device, or any suitable combination thereof. In this document, a computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, apparatus, or device.

[0134] Computer-readable signal media may include data signals propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such propagated data signals may take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. Computer-readable signal media may also be any computer-readable medium other than computer-readable storage media, capable of sending, propagating, or transmitting programs for use by or in connection with an instruction execution system, apparatus, or device.

[0135] Program code contained on a computer-readable medium may be transmitted using any suitable medium, including but not limited to: wireless, wire, optical fiber, radio frequency, etc., or any suitable combination thereof.

[0136] Computer program code for performing the operations of this application can be written in one or more programming languages ​​or a combination thereof. Programming languages ​​include object-oriented programming languages ​​as well as conventional procedural programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or it can be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0137] Those skilled in the art will understand that the modules or steps described above in this application can be implemented using general-purpose computing devices. They can be centralized on a single computing device or distributed across a network of multiple computing devices. Optionally, they can be implemented using computer-executable program code, which can then be stored in a storage device for execution by a computing device. Alternatively, they can be fabricated as separate integrated circuit modules, or multiple modules or steps can be fabricated as a single integrated circuit module. Thus, this application is not limited to any particular combination of hardware and software.

[0138] Note that the above are merely preferred embodiments and the technical principles employed in this application. Those skilled in the art will understand that this application is not limited to the specific embodiments described herein, and various obvious changes, readjustments, and substitutions can be made without departing from the scope of protection of this application. Therefore, although this application has been described in detail through the above embodiments, this application is not limited to the above embodiments. Many other equivalent embodiments may be included without departing from the inventive concept of this application, and the scope of this application is determined by the scope of the appended claims.

Claims

1. A government question answering method, characterized in that, The method comprises: matching a user question text and a node of a pre-constructed matter business tree to obtain a matching node, and determining a target regional handling item according to the matching node; querying a case question and answer pair library of a region to which the user belongs based on the target regional handling item to obtain a target case question and answer pair set of the target regional handling item; identifying a case to which the user question text belongs based on the target case question and answer pair set to obtain a target user case; querying a government affair knowledge base based on the target regional handling item to obtain target government affair data, identifying the target government affair data based on the target user case, generating a case guide text corresponding to the target user case, and displaying the case guide text.

2. The government question answering method of claim 1, wherein, The matter business tree is a global matter business tree, and a node of the global matter business tree comprises a global handling item. The target regional handling item is determined according to the matching node, comprising: determining a target global handling item according to the matching node; querying a regional matter library of a region to which the user belongs based on the target global handling item to obtain a target regional handling item.

3. The government question answering method of claim 2, wherein, The target global handling item is determined according to the matching node, comprising: when the matching node is a leaf node, the matching node is determined as the target global handling item; when the matching node is a non-leaf node, a user is guided to select based on a child node of the matching node in the global matter business tree to obtain the target global handling item.

4. The government question answering method of claim 3, wherein, The target global handling item is obtained based on the child node of the matching node in the global matter business tree, comprising: obtaining child nodes belonging to a first level from child nodes of the matching node in the global matter business tree to obtain each candidate node; generating a matter selection request based on the each candidate node, and displaying the matter selection request; obtaining a candidate node selected by the user for the matter selection request to obtain a first target node; when the first target node is a non-leaf node, obtaining child nodes belonging to a first level from child nodes of the first target node in the global matter business tree to obtain each candidate node, and returning to execute the generation of the matter selection request based on the each candidate node; when the first target node is a leaf node, the first target node is determined as the target global handling item.

5. The government question answering method of claim 1, wherein, The target user case is obtained by identifying the case to which the user question text belongs based on the target case question and answer pair set, comprising: using a semantic recognition generation model to identify a first user case and a to-be-supplemented case question and answer pair of the user question text based on the user question text and the target case question and answer pair set; when the to-be-supplemented case question and answer pair is empty, the first user case is determined as the target user case; when the to-be-supplemented case question and answer pair is not empty, a user is guided to complete a case based on the to-be-supplemented case question and answer pair to obtain a second user case, and the first user case and the second user case are combined as the target user case.

6. The government question answering method of claim 5, wherein, The situation question and answer pair includes a question, a situation corresponding to each answer, a parent question identifier, and a parent answer. There are multiple to-be-supplemented situation question and answer pairs. The user is guided to complete a situation based on the to-be-supplemented situation question and answer pair, and a second user situation is obtained. A logical relationship between the to-be-supplemented situation question and answer pairs is determined based on the parent question identifiers of the to-be-supplemented situation question and answer pairs. A to-be-supplemented situation question and answer tree is constructed with the questions in the to-be-supplemented situation question and answer pairs as nodes and the logical relationship between the to-be-supplemented situation question and answer pairs as edges. The attribute information of an edge is the parent answer of the entry node of the corresponding edge. A node belonging to a first level is obtained from the to-be-supplemented situation question and answer tree, and a second target node is obtained. A question answering request is generated based on the second target node, and the question answering request is displayed. Answer information input by a user for the question answering request is obtained, and a target sub-node is determined based on the answer information and the attribute information of a target edge. The exit node of the target edge is the question in the question answering request. When the target sub-node is a non-leaf node, a situation corresponding to the parent answer of the target sub-node is spliced after the last second user situation. A question answering request is generated based on the target sub-node, and the question answering request is displayed. When the target sub-node is a leaf node, a situation corresponding to the parent answer of the target sub-node is spliced after the last second user situation.

7. The government question answering method of claim 2, wherein, The construction steps of the global matter business tree are as follows: A semantic recognition generation model is used to recognize original government data of multiple regions in a preset area, and generate a global matter path. The global matter path includes global matters and logical relationships between the global matters. A global matter business tree is constructed with the global matters as nodes and the logical relationships between the global matters as edges.

8. The government question answering method of claim 1, wherein, The construction steps of the situation question and answer pair library of the target region are as follows: A semantic recognition generation model is used to recognize original government data of the target region, and generate situation question and answer pairs for each region handling item in the target region and logical relationships between the situation question and answer pairs. Based on the situation question and answer pairs for all region handling items in the target region and the logical relationships between the situation question and answer pairs, a situation question and answer pair library of the target region is constructed.

9. An electronic device, comprising: The electronic device includes: at least one processor; and a memory connected to the at least one processor in communication; wherein The memory stores a computer program that can be executed by the at least one processor. The computer program is executed by the at least one processor to enable the at least one processor to execute the government question and answer method of any one of claims 1 to 8.

10. A computer-readable storage medium having stored thereon a computer program, characterized in that, The program is executed by the processor to implement the government question and answer method of any one of claims 1 to 8.