Report generation method and device, electronic equipment, storage medium and program product

CN122548014APending Publication Date: 2026-08-11CHINA UNITED NETWORK COMM GRP CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-04-02
Publication Date
2026-08-11

AI Technical Summary

Technical Problem

[0005]本申请的目的在于至少提供一种报告生成方法、装置、电子设备、存储介质及程序产品,至少可以解决生成的推理报告不够准确、且不全面的问题,至少可以提高复杂查询的召回率和准确率

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122548014A_ABST
    Figure CN122548014A_ABST
Patent Text Reader

Abstract

This application relates to the field of retrieval and question-answering technology, and discloses a report generation method, apparatus, electronic device, storage medium, and program product, including: receiving a query request; searching for communities matching the query request from multiple communities, including multi-level communities obtained by dividing the same graph into different community division methods and multiple communities with the same attribute, each node in the graph having at least one attribute including entity type, and each node in the community with the same attribute having the same attribute; and generating a reasoning report based on the community matching the query request. By performing information search in two types of communities, multi-level communities and communities with the same attribute, information can be located from two dimensions: hierarchical depth and attribute breadth. Multi-level communities support navigation from the domain of the top-level community to specific knowledge points of the bottom-level community, while communities with the same attribute support cross-level and cross-community retrieval of the same type of entity. The two complement each other, improving the recall and accuracy of complex queries.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of search and question answering technology, and in particular to a report generation method, apparatus, electronic device, storage medium, and program product. Background Technology

[0002] With the development of enterprise-level knowledge bases and intelligent question-answering systems, more and more systems are using knowledge graphs to organize knowledge and perform information retrieval, question answering, and analysis on this basis.

[0003] In related technologies, a simple community division is performed on the knowledge graph, and the query is retrieved from the community. Then, a reasoning report is generated based on the retrieved community.

[0004] However, the simple method of dividing communities and retrieving data to generate responses is not accurate or comprehensive enough when faced with complex query requests. Summary of the Invention

[0005] The purpose of this application is to provide at least one report generation method, apparatus, electronic device, storage medium, and program product, which can at least solve the problems that the generated inference reports are not accurate or comprehensive enough, and can at least improve the recall and accuracy of complex queries.

[0006] To address the aforementioned technical problems, at least one embodiment of this application provides a report generation method, comprising: receiving a query request; searching for communities matching the query request from multiple communities, wherein the multiple communities include multi-level communities obtained by different community division methods of the same graph and multiple communities with the same attribute, wherein each node in the graph has at least one attribute including entity type, and each node in the community with the same attribute has the same attribute; and generating a reasoning report based on the communities matching the query request.

[0007] By conducting information searches in two types of communities—multi-level communities and communities with similar attributes—the search can locate information from both hierarchical depth and attribute breadth. Multi-level communities support navigation from the domain of the top-level community to specific knowledge points in the bottom-level community, while communities with similar attributes support cross-level and cross-community retrieval of similar entities. The two complement each other, significantly improving the recall and accuracy of complex queries.

[0008] In some optional embodiments, the method further includes: obtaining an original document; constructing an initial graph based on the original document, wherein each node of the initial graph has the at least one attribute, and the at least one attribute further includes a semantic description; calculating the semantic similarity between different nodes in the initial graph based on the semantic description of each node; and adding a connection edge between two nodes corresponding to semantic similarity greater than a similarity threshold for the initial graph to obtain an updated graph.

[0009] Traditional graphs rely solely on entities and relation edges extracted from the original document, resulting in the inability to cluster semantically similar but topologically disparate nodes. By adding connecting edges between nodes with high semantic similarity, implicit semantic associations are actively injected into the graph, logically connecting previously fragmented knowledge nodes and providing more complete relational information for subsequent community partitioning. Calculating similarity based on semantic descriptions and adding edges incorporates semantic information into the input graph of the community partitioning algorithm. Compared to relying solely on the original topological structure, the partitioned communities are more thematically cohesive, avoiding the problem of incorrectly assigning semantically related nodes to different communities due to a lack of implicit relationships. When relation extraction from the original document is incomplete, the semantic edge-adding mechanism can play a supplementary role, making the community partitioning results more robust to the quality of the original extraction.

[0010] In some optional embodiments, the step of dividing the community based on the updated graph to obtain the multiple communities includes: dividing the updated graph into multi-level communities to obtain the multi-level communities; and dividing the updated graph into attribute-based communities to obtain the multiple communities with the same attribute.

[0011] By implementing multi-level community segmentation and attribute-based community segmentation respectively, two community indexing systems were constructed. Multi-level communities provide a vertical hierarchical perspective (from macro to micro), while communities with the same attribute provide a horizontal typological perspective (aggregation of entities under the same attribute). The two perspectives complement each other, providing a better information foundation for subsequent searches and enabling the system to handle a wider range of question types.

[0012] In some optional embodiments, the step of searching for communities matching the query request from multiple communities includes: searching for communities with the same attribute that match the query request from the multiple communities with the same attribute to obtain at least one community with the same attribute; and searching for communities matching the query request level by level, starting from the top-level community of the multi-level community to obtain a multi-level matching community.

[0013] Simultaneously employing two search paths—same-attribute community retrieval and multi-level community hierarchical retrieval—ensures effective coverage regardless of whether the query emphasizes entity type matching or topic hierarchy matching. Same-attribute community retrieval results provide aggregation of similar information, while multi-level community hierarchical retrieval results provide hierarchical context. These two types of results can be merged when generating subsequent inference reports, resulting in reports with both breadth and depth. The multi-level community search employs a top-down, hierarchical search strategy, avoiding brute-force searches across all levels. It quickly locates relevant macro-domains at the top level and then gradually delves down to specific communities, achieving rapid convergence of the search space.

[0014] In some optional embodiments, the step of searching for communities matching the query request level by level, starting from the top-level community of the multi-level community, to obtain a multi-level matching community includes: searching for top-level communities matching the query request from all top-level communities of the multi-level community; for each top-level community matching the query request, searching for secondary communities matching the query request from all secondary communities corresponding to the top-level community, and continuing the search level by level; and summarizing the communities matching the query request at each level of the multi-level community to obtain the multi-level matching community.

[0015] A hierarchical retrieval strategy is employed, with each step limiting the scope based on the matching results of the previous level. This avoids wasting computational resources in incorrect directions and makes the retrieval path clear and concise. Furthermore, the communities matched at each level are aggregated, allowing subsequent reasoning report generation to utilize top-level domain background, mid-level themes, and bottom-level specific entities and edge knowledge to form a complete reasoning chain, rather than fragmented information pieces. This results in a more plausible final reasoning report. In addition, the aggregated results of multi-level matching communities naturally form a macro-to-micro contextual hierarchy, providing structured input for logical reorganization during subsequent reasoning report generation, significantly improving the logical coherence and depth of the generated report.

[0016] In some optional embodiments, generating the inference report based on the community matching the query request includes: obtaining a community summary report of the community matching the query request; obtaining atomic fragments and triples corresponding to the base community and the community with the same attribute in the community matching the query request, wherein the base community is the bottom community in the multi-level community; and generating the inference report based on the community summary report and the atomic fragments and triples.

[0017] The generated reasoning report integrates community summary reports, atomic fragments, and triples. The community summary report provides the logical framework and thematic background, while the atomic fragments provide specific factual support. This combination gives the report both high generality and sufficient credibility and traceability. By obtaining the atomic fragments and triples corresponding to the base community, it ensures that underlying factual details are not lost during hierarchical aggregation. Furthermore, by obtaining the atomic fragments and triples corresponding to communities with similar attributes, it ensures that similar facts across communities are fully incorporated, guaranteeing the information integrity of the final report. Additionally, combining the community summary report with atomic fragments / triples as input for generating the reasoning report significantly improves the logical consistency and factual accuracy of the generated content, reducing the risk of illusion.

[0018] At least one embodiment of this application also provides a report generation apparatus, comprising: a receiving module for receiving a query request; a search module for searching for communities matching the query request from multiple communities, the multiple communities including multi-level communities obtained by different community division methods of the same graph and multiple communities with the same attribute, each node in the graph having at least one attribute including entity type, and each node in the community with the same attribute having the same attribute; and a generation module for generating a reasoning report based on the communities matching the query request.

[0019] In some optional embodiments, the apparatus further includes: a construction module for acquiring an original document; constructing an initial graph based on the original document, wherein each node of the initial graph has the at least one attribute, and the at least one attribute further includes a semantic description; calculating the semantic similarity between different nodes in the initial graph based on the semantic description of each node; and adding connecting edges between two nodes corresponding to semantic similarity greater than a similarity threshold for the initial graph to obtain an updated graph.

[0020] In some optional embodiments, the construction module is used to perform multi-level community division on the updated graph to obtain the multi-level community; and to perform attribute-based community division on the updated graph to obtain the multiple communities with the same attribute.

[0021] In some optional embodiments, the search module is configured to search for communities with the same attribute that match the query request from the plurality of communities with the same attribute, to obtain at least one community with the same attribute; and to search for communities that match the query request level by level, starting from the top-level community of the multi-level community, to obtain a multi-level matching community.

[0022] In some optional embodiments, the search module is used to search for top-level communities that match the query request from all top-level communities in the multi-level community; for each top-level community that matches the query request, search for secondary communities that match the query request from all secondary communities corresponding to the top-level community, and continue searching level by level; and summarize the communities that match the query request at each level in the multi-level community to obtain the multi-level matching community.

[0023] In some optional embodiments, the generation module is used to obtain a community summary report of the community matching the query request; obtain atomic fragments and triples corresponding to the basic community and the community with the same attribute in the community matching the query request, wherein the basic community is the bottom community in the multi-level community; and generate the inference report based on the community summary report and the atomic fragments and triples.

[0024] At least one embodiment of this application also provides an electronic device, including: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to perform the report generation method described above.

[0025] At least one embodiment of this application also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the above-described report generation method.

[0026] At least one embodiment of this application also provides a computer program product, including a computer program that, when executed by a processor, implements the above-described report generation method. Attached Figure Description

[0027] One or more embodiments are illustrated by way of example with reference to the accompanying drawings, and these illustrative descriptions do not constitute a limitation on the embodiments.

[0028] Figure 1 This is a flowchart of a report generation method provided in one embodiment of this application; Figure 2 This is a schematic diagram of a report generation apparatus provided in another embodiment of this application. Detailed Implementation

[0029] Exemplary embodiments will now be described more fully with reference to the accompanying drawings. However, these exemplary embodiments can be implemented in many forms and should not be construed as limited to the examples set forth herein; rather, they are provided to make this application more comprehensive and complete, and to fully convey the concept of the exemplary embodiments to those skilled in the art. The described features, structures, or characteristics may be combined in any suitable manner in one or more embodiments.

[0030] Furthermore, the accompanying drawings are merely illustrative of this application and are not necessarily drawn to scale. The same reference numerals in the drawings denote the same or similar parts, and therefore repeated descriptions of them will be omitted. Some block diagrams shown in the drawings are functional entities and do not necessarily correspond to physically or logically independent entities. These functional entities can be implemented in software, in one or more hardware modules or integrated circuits, or in different network and / or processor devices and / or microcontroller devices.

[0031] Example 1: The report generation method of this embodiment can be applied to electronic devices with communication, computing, and data storage capabilities. Its specific process can be as follows: Figure 1As shown, it includes: S101-S103.

[0032] S101, Receive query request.

[0033] The embodiments of this application do not limit the specific type of query request. In some examples, the user can input the query request into the electronic device via an input device, and the electronic device will then receive the query request.

[0034] In other cases, users can also send the query request to the electronic device from other devices.

[0035] S102, search for communities that match the query request from multiple communities. Multiple communities include multi-level communities obtained by dividing the same graph into different communities and multiple communities with the same attribute. Each node in the graph has at least one attribute, including entity type. Nodes in communities with the same attribute have the same attribute.

[0036] In some cases, the multiple communities need to be constructed before searching for communities that match the query request from multiple communities.

[0037] In some examples, the process of constructing the multiple communities may include: obtaining the original document; extracting entity-relationship-entity triples from the original document and generating at least one attribute for each entity, including the entity type, to obtain the graph; and dividing the graph into communities to obtain the multiple communities.

[0038] The embodiments of this application do not limit the specific form of the original document.

[0039] The electronic device may obtain the original document by downloading it from the network, by having the user directly edit and input it into the electronic device, or by having it sent from another device, etc. This application does not impose any restrictions on this.

[0040] In some examples, extracting entity-relation-entity triples from the original document and generating at least one attribute for each entity may include: processing the original document based on a large language model to extract entity-relation-entity triples from the original document and generating at least one attribute for each entity, the at least one attribute including implementation type.

[0041] The input to a large language model can be the entire original document, or it can be a segment of the original document into multiple atomic fragments.

[0042] The embodiments of this application do not limit the specific type of large language model used. For example, the large language model applied here could be DeepSeek, the chat GPT series, Doubao, etc.

[0043] In some examples, dividing the graph into communities to obtain multiple communities can include: dividing the graph into multi-level communities to obtain multi-level communities; and dividing the graph into communities based on attributes to obtain multiple communities with the same attribute.

[0044] Nodes in a community with the same attribute share a common attribute. Since entities are the nodes that make up the graph, the attributes of an entity are the attributes of the corresponding nodes. If at least one attribute of an entity includes its type, then when the graph is partitioned into communities based on attributes, the resulting communities with the same attribute will include other communities with the same entity type. For example, all nodes in a community with the same attribute might correspond to the entity type "supplier." Another example is that all nodes in a community with the same attribute might correspond to the entity type "manufacturer."

[0045] The embodiments of this application do not impose restrictions on whether nodes in a community with the same attribute possess other shared attributes. For example, if one attribute is nationality and the other is city of residence, and a community with the same attribute is aggregated based on the city of residence of each node being Beijing, then the nationality attribute of each node in this community is indeed China. As another example, if one attribute is nationality and the other is city of residence, and a community with the same attribute is aggregated based on the nationality attribute of each node being China, then the city of residence attribute of each node in this community specifically includes Beijing, Shanghai, Changsha, etc.

[0046] The embodiments of this application do not limit how the graph is divided into multi-level communities. For example, the graph can be divided into multi-level communities based on the Leiden algorithm.

[0047] In other examples, any community partitioning method can be used to partition the graph into communities, obtaining the bottom-level communities (the lowest level communities); then, a community summary report for each bottom-level community is generated; based on the community summary report of each bottom-level community, the semantic similarity between different bottom-level communities is calculated; the bottom-level community as a whole is treated as a node, and connecting edges are added between "bottom-level community nodes" with semantic similarity greater than a set threshold, with semantic similarity used as the weight of the connecting edge, thus obtaining the secondary graph; then, the secondary graph is partitioned into communities to obtain multiple next-level communities, and the graph construction and community partitioning are continued in a loop until the partitioned communities reach the preset community level, thus obtaining the multi-level community.

[0048] The embodiments of this application do not impose limitations on how to calculate the semantic similarity between different underlying communities based on the community summary report of each underlying community. For example, the similarity between the community summary reports of underlying communities can be calculated by calculating the distance between vectors, and this similarity can be used as the semantic similarity between different underlying communities.

[0049] In other examples, the process of constructing the multiple communities may include: obtaining the original document; constructing an initial graph based on the original document, wherein each node in the initial graph has at least one attribute, and the at least one attribute also includes a semantic description; calculating the semantic similarity between different nodes in the initial graph based on the semantic description of each node; adding connecting edges between two nodes corresponding to semantic similarity greater than a similarity threshold for the initial graph to obtain an updated graph; and dividing the communities based on the updated graph to obtain the multiple communities.

[0050] Traditional graphs rely solely on entities and relation edges extracted from the original document, resulting in the inability to cluster semantically similar but topologically disparate nodes. By adding connecting edges between nodes with high semantic similarity, implicit semantic associations are actively injected into the graph, logically connecting previously fragmented knowledge nodes and providing more complete relational information for subsequent community partitioning. Calculating similarity based on semantic descriptions and adding edges incorporates semantic information into the input graph of the community partitioning algorithm. Compared to relying solely on the original topological structure, the partitioned communities are more thematically cohesive, avoiding the problem of incorrectly assigning semantically related nodes to different communities due to a lack of implicit relationships. When relation extraction from the original document is incomplete, the semantic edge-adding mechanism can play a supplementary role, making the community partitioning results more robust to the quality of the original extraction.

[0051] In some examples, the process of constructing an initial graph based on the original document may include: segmenting the original document to obtain multiple atomic fragments; extracting "entity-relationship-entity" triples for each atomic fragment and generating at least one attribute for each entity, which includes a semantic description and entity type, to obtain the initial graph.

[0052] The embodiments of this application do not limit how the original document is segmented. In some examples, the original document can be segmented according to a fixed length; or, a semantic-based document segmentation method can be adopted to segment the original document, and so on.

[0053] This application does not impose any restrictions on how to extract "entity-relation-entity" triples for each atomic fragment and generate at least one attribute for each entity. For example, a large language model can be invoked to extract "entity-relation-entity" triples for each atomic fragment and generate at least one attribute for each entity.

[0054] The embodiments of this application do not impose limitations on how to calculate the semantic similarity between different nodes in the graph based on the semantic description of each node. For example, the similarity between the semantic descriptions of nodes can be calculated by calculating the distance between vectors, and this similarity can be used as the semantic similarity between different nodes.

[0055] The similarity threshold is a preset value, and the specific value of the similarity threshold is not limited in the embodiments of this application. For example, the similarity threshold is 0.6, or 0.7, etc.

[0056] In some examples, community partitioning based on the updated graph can be used to obtain multiple communities. This can include: performing multi-level community partitioning on the updated graph to obtain multi-level communities; or performing attribute-based community partitioning on the updated graph to obtain multiple communities with the same attribute.

[0057] By implementing multi-level community segmentation and attribute-based community segmentation respectively, two community indexing systems were constructed. Multi-level communities provide a vertical hierarchical perspective (from macro to micro), while communities with the same attribute provide a horizontal typological perspective (aggregation of entities under the same attribute). The two perspectives complement each other, providing a better information foundation for subsequent searches and enabling the system to handle a wider range of question types.

[0058] The embodiments of this application do not limit how to perform multi-level community division on the updated graph. For example, the updated graph can be divided into multi-level communities based on the Leiden algorithm to obtain multi-level communities.

[0059] After obtaining multiple communities from S102, you can continue to execute S102 to search for communities that match the query request from among the multiple communities.

[0060] In some examples, searching for communities that match the query request from multiple communities may include: searching for communities with the same attribute that match the query request from the multiple communities with the same attribute to obtain at least one community with the same attribute; and searching for communities that match the query request level by level, starting from the top-level community of the multi-level community to obtain a multi-level matching community.

[0061] By implementing multi-level community segmentation and attribute-based community segmentation respectively, two community indexing systems were constructed. Multi-level communities provide a vertical hierarchical perspective (from macro to micro), while communities with the same attribute provide a horizontal typological perspective (aggregation of entities under the same attribute). The two perspectives complement each other, providing a better information foundation for subsequent searches and enabling the system to handle a wider range of question types.

[0062] Among them, the top-level community is the last community to be divided in the multi-level community division (gradual aggregation multi-level community division), while the basic community (bottom-level community) is the first community to be divided in the multi-level community division (gradual aggregation multi-level community division).

[0063] In some cases, before searching for communities that match the query request from multiple communities, it is necessary to generate a community summary report for each community so that the matching between the community summary report and the query request can be used as the matching between the community and the query request.

[0064] The embodiments of this application do not limit the implementation method for generating community summary reports. For example, the community can be processed based on a large language model to generate a community summary report.

[0065] In some examples, searching for communities with the same attribute that match the query request from the multiple communities with the same attribute may include: calculating the similarity between the community summary report of each community with the same attribute and the query request, and taking the communities with the same attribute whose similarity is greater than a set value as the communities with the same attribute that match the query request.

[0066] The embodiments of this application do not limit the specific value to be set. For example, the set value is 0.7.

[0067] In some examples, starting from the top-level community of the multi-level community, the search proceeds level by level to find communities that match the query request, resulting in a multi-level matching community. This may include: searching for top-level communities that match the query request from all top-level communities in the multi-level community; for each top-level community that matches the query request, searching for sub-communities that match the query request from all sub-communities corresponding to the top-level community, and continuing the search level by level; and summarizing the communities that match the query request at each level of the multi-level community to obtain the multi-level matching community.

[0068] The implementation method for searching for top-level communities matching the query request from all top-level communities in this multi-level community is the same as the implementation method for searching for communities with the same attribute matching the query request from multiple communities with the same attribute, and will not be repeated here. The implementation method for searching for communities matching the query request from communities at other levels is also the same as the implementation method for searching for communities with the same attribute matching the query request from multiple communities with the same attribute, and will not be repeated here.

[0069] For example, if there are 3 top-level communities, search for one top-level community that matches the query request. This top-level community has 5 sub-communities, so continue searching for communities that match the query request from these 5 sub-communities, resulting in 2 sub-communities. Then, continue searching for communities that match the query request in the next level of each sub-community until the final search results are the bottom-level communities (basic communities).

[0070] By implementing multi-level community segmentation and attribute-based community segmentation respectively, two community indexing systems were constructed. Multi-level communities provide a vertical hierarchical perspective (from macro to micro), while communities with the same attribute provide a horizontal typological perspective (aggregation of entities under the same attribute). The two perspectives complement each other, providing a better information foundation for subsequent searches and enabling the system to handle a wider range of question types.

[0071] S103, Generate an inference report based on the communities that match the query request.

[0072] The embodiments of this application do not limit how the inference report is generated based on the communities that match the query request. For example, the communities that match the query request can be input into a large language model, which can then generate an inference report based on the communities that match the query request.

[0073] In some examples, generating an inference report based on the communities that match the query request may include: obtaining a community summary report of the communities that match the query request; obtaining atomic fragments and triples corresponding to the base community and communities with the same attribute in the communities that match the query request, wherein the base community is the bottom-level community in the multi-level community; and generating the inference report based on the community summary report and the atomic fragments and triples.

[0074] The generated reasoning report integrates community summary reports, atomic fragments, and triples. The community summary report provides the logical framework and thematic background, while the atomic fragments provide specific factual support. This combination gives the report both high generality and sufficient credibility and traceability. By obtaining the atomic fragments and triples corresponding to the base community, it ensures that underlying factual details are not lost during hierarchical aggregation. Furthermore, by obtaining the atomic fragments and triples corresponding to communities with similar attributes, it ensures that similar facts across communities are fully incorporated, guaranteeing the information integrity of the final report. Additionally, combining the community summary report with atomic fragments / triples as input for generating the reasoning report significantly improves the logical consistency and factual accuracy of the generated content, reducing the risk of illusion.

[0075] In some examples, generating the inference report based on the community summary report, atomic fragments, and triples may include: chaining the community summary report, atomic fragments, and triples as facts related to the query request, inputting the chaining result into a large language model, and having the large language model generate the inference report based on the chaining result.

[0076] In some examples, each element (node, edge) in the graph has an index relationship with its atomic fragments. Based on the element and the index, the corresponding atomic fragment can be obtained. Obtaining the atomic fragments and triples corresponding to the base community and communities with the same attribute in the community matching the query request can include: directly reading the triples from the base community and communities with the same attribute, and obtaining the atomic fragment based on the index corresponding to each element in the base community and communities with the same attribute.

[0077] Example 2: Another embodiment of this application relates to a report generation device. The implementation details of the report generation device in this embodiment are described below. The following implementation details are provided for ease of understanding and are not essential for implementing this solution. A schematic diagram of the report generation device in this embodiment can be seen as follows: Figure 2 As shown, it includes: a receiving module 21 for receiving a query request; a search module 22 for searching for communities that match the query request from multiple communities, including multi-level communities obtained by dividing the same graph into different communities and multiple communities with the same attribute, each node in the graph having at least one attribute including entity type, and each node in the community with the same attribute having the same attribute; and a generation module 23 for generating a reasoning report based on the communities that match the query request.

[0078] In some optional embodiments, the apparatus further includes: a construction module 24, configured to acquire an original document; construct an initial graph based on the original document, wherein each node in the initial graph has at least one attribute, and the at least one attribute further includes a semantic description; calculate the semantic similarity between different nodes in the initial graph based on the semantic description of each node; for the initial graph, add connecting edges between two nodes corresponding to semantic similarity greater than a similarity threshold to obtain an updated graph; and perform community division based on the updated graph to obtain the multiple communities.

[0079] In some optional embodiments, the construction module 24 is used to perform multi-level community division on the updated graph to obtain the multi-level community; and to perform attribute-based community division on the updated graph to obtain the multiple communities with the same attribute.

[0080] In some optional embodiments, the search module 22 is used to search for communities with the same attribute that match the query request from the plurality of communities with the same attribute, to obtain at least one community with the same attribute; and to search for communities that match the query request level by level, starting from the top-level community of the multi-level community, to obtain a multi-level matching community.

[0081] In some optional embodiments, the search module 22 is used to search for top-level communities that match the query request from all top-level communities in the multi-level community; for each top-level community that matches the query request, it searches for secondary communities that match the query request from all secondary communities corresponding to the top-level community, and continues to search level by level; and it summarizes the communities that match the query request at each level in the multi-level community to obtain the multi-level matching community.

[0082] In some optional embodiments, the generation module 23 is used to obtain a community summary report of the community matching the query request; obtain atomic fragments and triples corresponding to the basic community and the community with the same attribute in the community matching the query request, wherein the basic community is the bottom community in the multi-level community; and generate the inference report based on the community summary report and the atomic fragments and triples.

[0083] By conducting information searches in two types of communities—multi-level communities and communities with similar attributes—the search can locate information from both hierarchical depth and attribute breadth. Multi-level communities support navigation from the domain of the top-level community to specific knowledge points in the bottom-level community, while communities with similar attributes support cross-level and cross-community retrieval of similar entities. The two complement each other, significantly improving the recall and accuracy of complex queries.

[0084] It is worth mentioning that all modules involved in this embodiment are logical modules. In practical applications, a logical unit can be a physical unit, a part of a physical unit, or a combination of multiple physical units. Furthermore, to highlight the innovative aspects of this application, this embodiment does not introduce units that are not closely related to solving the technical problems proposed in this application; however, this does not mean that other units are absent in this embodiment.

[0085] It should be noted that the receiving module 21, the searching module 22, and the generating module 23 mentioned above refer to S101 to S103 in the method embodiment. The examples and application scenarios implemented by the above modules and the corresponding steps are the same, but are not limited to the content disclosed in the above method embodiment. It should be noted that the above modules, as part of the apparatus, can be executed in a computer system such as a set of computer-executable instructions.

[0086] Example 3: Another embodiment of this application relates to an electronic device, including: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the report generation methods described in the above embodiments.

[0087] The memory and processor are connected via a bus, which can include any number of interconnecting buses and bridges, connecting various circuits of one or more processors and memories. The bus can also connect various other circuits, such as peripheral devices, voltage regulators, and power management circuits, which are well known in the art and will not be described further herein. The bus interface provides an interface between the bus and the transceiver. The transceiver can be a single element or multiple elements, such as multiple receivers and transmitters, providing a unit for communicating with various other devices over a transmission medium. Data processed by the processor is transmitted over the wireless medium via an antenna, which further receives data and transmits it to the processor.

[0088] The processor manages the bus and general processing, and also provides various functions, including timing, peripheral interfaces, voltage regulation, power management, and other control functions. Memory is used to store data used by the processor during operation.

[0089] Example 4: Another embodiment of this application relates to a computer-readable storage medium storing a computer program. When executed by a processor, the computer program implements the method embodiments described above.

[0090] That is, those skilled in the art will understand that all or part of the steps in the methods of the above embodiments can be implemented by a program instructing related hardware. This program is stored in a storage medium and includes several instructions to cause a device (which may be a microcontroller, chip, etc.) or processor to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0091] Example 5: Another embodiment of this application relates to a computer program product, including a computer program. When executed by a processor, the computer program implements the method embodiments described above.

[0092] It should be noted that although several modules or units for the device used to perform actions have been mentioned in the detailed description above, this division is not mandatory. In fact, according to the embodiments of this application, the features and functions of two or more modules or units described above can be embodied in one module or unit. Conversely, the features and functions of one module or unit described above can be further divided and embodied by multiple modules or units.

[0093] Furthermore, although the steps of the method in this application are described in a specific order in the accompanying drawings, this does not require or imply that the steps must be performed in that specific order, or that all the steps shown must be performed to achieve the desired result. Additional or alternative steps may be omitted, multiple steps may be combined into one step, and / or a step may be broken down into multiple steps.

[0094] From the above description of the embodiments, those skilled in the art will readily understand that the exemplary embodiments described herein can be implemented by software or by combining software with necessary hardware.

[0095] Those skilled in the art will understand that the above embodiments are specific embodiments for implementing this application, and in practical applications, various changes can be made to them in form and detail without departing from the spirit and scope of this application.

Claims

1. A report generation method, characterized in that, include: Receive query requests; Search for communities that match the query request from multiple communities. The multiple communities include multi-level communities obtained by dividing the same graph into different communities and multiple communities with the same attribute. Each node in the graph has at least one attribute, including entity type. Each node in the community with the same attribute has the same attribute. A reasoning report is generated based on the communities that match the query request.

2. The method according to claim 1, characterized in that, Also includes: Get the original document; An initial graph is constructed based on the original document, wherein each node of the initial graph has at least one attribute, and the at least one attribute further includes a semantic description; Based on the semantic description of each node, calculate the semantic similarity between different nodes in the initial graph; For the initial graph, add connecting edges between two nodes whose semantic similarity is greater than the similarity threshold to obtain the updated graph; The communities are divided based on the updated graph, resulting in the aforementioned multiple communities.

3. The method according to claim 2, characterized in that, The community division based on the updated graph yields the multiple communities, including: The updated graph is divided into multi-level communities to obtain the multi-level communities; The updated graph is divided into communities based on attributes to obtain the multiple communities with the same attribute.

4. The method according to claim 1, characterized in that, The step of searching for communities that match the query request from multiple communities includes: Search for communities with the same attribute that match the query request from the plurality of communities with the same attribute to obtain at least one community with the same attribute; and search for communities that match the query request level by level, starting from the top-level community of the multi-level community to obtain a multi-level matching community.

5. The method according to claim 4, characterized in that, The process of searching for communities matching the query request, starting from the top-level community of the multi-level community, and progressively searching for communities matching the query request, yields multi-level matching communities, including: Search for the top-level community that matches the query request from all the top-level communities in the multi-level community; For each top-level community that matches the query request, search for the sub-communities that match the query request from all the sub-communities corresponding to the top-level community, and continue the search level by level; The communities that match the query request at each level of the multi-level community are aggregated to obtain the multi-level matching community.

6. The method according to claim 1, characterized in that, The step of generating a reasoning report based on the community matching the query request includes: Obtain a community summary report for the communities that match the query request; Obtain the atomic fragments and triples corresponding to the basic community and the community with the same attribute in the community that matches the query request, wherein the basic community is the bottom community in the multi-level community; The inference report is generated based on the community summary report and the atomic fragments and triples.

7. A report generation device, characterized in that, include: The receiving module is used to receive query requests; The search module is used to search for communities that match the query request from multiple communities. The multiple communities include multi-level communities obtained by dividing the same graph into different communities and multiple communities with the same attribute. Each node in the graph has at least one attribute, including entity type. Each node in the community with the same attribute has the same attribute. The generation module is used to generate a reasoning report based on the communities that match the query request.

8. An electronic device, characterized in that, include: At least one processor; as well as, A memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor to enable the at least one processor to perform the report generation method as described in any one of claims 1 to 6.

9. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by a processor, it implements the report generation method according to any one of claims 1 to 6.

10. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the report generation method according to any one of claims 1 to 6.