Data intelligent auxiliary analysis method, system, equipment and medium

By building API warehouse and vector database, combining large language model and BM25 algorithm, the efficiency and flexibility of grid equipment data analysis are solved, efficient and accurate data intelligent auxiliary analysis is achieved, operating processes are simplified and intuitive charts are generated.

CN120407603APending Publication Date: 2025-08-01CHINA ELECTRIC POWER RESEARCH INSTITUTE CO LTD +3

Patent Information

Application Number
CN202510463354.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-14
Publication Date
2025-08-01

AI Technical Summary

Technical Problem

The existing grid equipment data analysis methods are inefficient, unable to process massive data, inaccurate analysis results, difficult to dig deep-level information, and high technical requirements for business personnel, complex operation of business intelligence tools and lack flexibility, making it difficult to adapt to dynamic changes in the power grid equipment field.

Method used

Build an API warehouse and API vector database, perform intelligent assisted analysis through semantic retrieval and large language model, combine BM25 algorithm to recall the enumeration value of the parameter, and use the context separation interactive fusion API search algorithm for API encoding to achieve flexible data analysis.

Benefits of technology

It improves the efficiency and accuracy of data analysis, reduces the technical requirements for business personnel, simplifies the operation process, can adapt to complex grid equipment analysis needs, and generates intuitive graphical display results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120407603A_ABST
    Figure CN120407603A_ABST
Patent Text Reader

Abstract

The invention discloses a data intelligent auxiliary analysis method, system and device and a medium. The method comprises the steps of obtaining a question queried by a user; according to the question queried by the user, performing semantic retrieval in an API vector database to obtain a related API vector; the related API vectors obtained through semantic retrieval are associated with an API warehouse, and APIs associated with the questions are obtained; according to the API associated with the question, a final query conclusion is obtained by utilizing a large language model, and the method, the system, the equipment and the medium have the advantages of being accurate in analysis result and high in flexibility.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of electric power, and relates to a method, system, device and medium for intelligent auxiliary analysis of data. Background Art

[0002] In the management and operation of power grid equipment, business personnel are faced with a vast amount of power data and complex equipment operating conditions. How to analyze these data efficiently and accurately has become a huge challenge. Existing data analysis methods often have many deficiencies, seriously restricting the decision-making efficiency and analysis ability of power grid equipment management personnel.

[0003] Traditional methods: For example, manually sorting data and using tools such as Excel for simple analysis. These methods are not only inefficient but also unable to process the vast amount of power grid equipment data, resulting in inaccurate analysis results and difficulty in mining deep-level information in the data. In equipment management, simple data statistics and display cannot effectively support key tasks such as fault prediction and operation optimization.

[0004] SQL query: Although SQL query plays a certain role in power grid equipment data analysis, it has relatively high technical requirements for business personnel, and many people are difficult to master SQL writing proficiently. Even if they have certain SQL capabilities, complex query statements are still prone to errors, which may lead to incorrect analysis results, thus affecting equipment maintenance decisions, fault diagnosis, and optimization scheduling strategies.

[0005] Using BI analysis tools: Business Intelligence (BI) analysis tools provide a graphical interface and diverse functions, which can help business personnel conduct a certain degree of data analysis. However, BI tools usually require users to have a certain amount of professional knowledge, and the operation is complex, often unable to adapt to the dynamic changes in the power grid equipment field. In addition, BI tools often rely on specific data structures and database systems, lacking sufficient flexibility and being difficult to meet the analysis requirements under different power grid equipment and operating environments.

[0006] The limitations of these traditional methods and tools in power grid equipment management and analysis urgently need to be optimized through more intelligent and efficient analysis methods to improve the reliability, stability, and management efficiency of power grid equipment operation. Summary of the Invention

[0007] The purpose of the present invention is to overcome the above-mentioned disadvantages of the prior art, and provides a method, system, device and medium for intelligent auxiliary analysis of data, which has the characteristics of accurate analysis results and high flexibility.

[0008] To achieve the above object, the present invention adopts the following technical solutions:

[0009] In a first aspect, the data intelligent assisted analysis method of the present invention includes:

[0010] Obtain the problem queried by the user;

[0011] According to the problem queried by the user, perform semantic retrieval in the API vector database to obtain relevant API vectors;

[0012] Associate the relevant API vectors obtained by semantic retrieval with the API repository to obtain APIs associated with the problem;

[0013] According to the APIs associated with the problem, use a large language model to obtain the final conclusion of the query.

[0014] A further improvement of the data intelligent assisted analysis method of the present invention lies in:

[0015] Further, before performing semantic retrieval in the API vector database according to the problem queried by the user to obtain API vectors, it further includes:

[0016] Construct an API repository, which contains a number of APIs related to device management data analysis;

[0017] Recall the input parameter enumeration values based on the BM25 algorithm, and use the input parameter enumeration values as an extension of the problem queried by the user to complete the problem queried by the user;

[0018] Based on the API vector encoder in the context separation interaction fusion API retrieval algorithm, encode the function descriptions and parameter information of all APIs related to device management data analysis into API vectors, and construct an API vector database through the API vectors.

[0019] Further, the process of using a large language model to obtain the final conclusion of the query according to the APIs associated with the problem is as follows:

[0020] According to the APIs associated with the problem, construct a first large model prompt, input the first large model prompt into the large language model to obtain API parameter values, fill the APIs with the API parameter values to obtain the APIs with filled parameters;

[0021] Execute the APIs with filled parameters to obtain the results of API queries;

[0022] According to the results of the API queries and the problem queried by the user, construct a second large model prompt, input the second large model prompt into the large language model to obtain the final conclusion of the query.

[0023] Further, after obtaining the final conclusion of the query, it further includes:

[0024] Call the chart visualization API to convert the final conclusion of the query into a chart.

[0025] In a second aspect, the data intelligent assisted analysis system of the present invention includes:

[0026] An acquisition module for acquiring the problem of the user's query;

[0027] A semantic retrieval module for performing semantic retrieval in the API vector database according to the problem of the user's query to obtain relevant API vectors;

[0028] An association module for associating the relevant API vectors obtained by semantic retrieval with the API repository to obtain APIs associated with the problem;

[0029] A first query module for using a large language model to obtain the final conclusion of the query according to the APIs associated with the problem.

[0030] The further improvement of the data intelligent assisted analysis system of the present invention lies in:

[0031] Furthermore, it further includes:

[0032] A first construction module for constructing an API repository, which contains several APIs related to device management data analysis;

[0033] A completion module for recalling the input parameter enumeration values based on the BM25 algorithm and using the input parameter enumeration values as an extension of the problem of the user's query to complete the problem of the user's query;

[0034] A second construction module for encoding and converting the function descriptions and parameter information of all APIs related to device management data analysis into API vectors based on the API vector encoder in the context separation interaction fusion API retrieval algorithm, and constructing an API vector database through the API vectors.

[0035] Furthermore, the first query module includes:

[0036] A second query module for constructing a first large model prompt word according to the APIs associated with the problem, inputting the first large model prompt word into the large language model to obtain API parameter values, and filling the APIs with the API parameter values to obtain the APIs with filled parameters;

[0037] An execution module for executing the APIs with filled parameters to obtain the results of API queries;

[0038] A third query module, configured to construct a second large model prompt word according to the result of the API query and the question queried by the user, and input the second large model prompt word into a large language model to obtain the final conclusion of the query.

[0039] Further, it further includes:

[0040] A calling module, configured to call a chart visualization API to convert the final conclusion of the query into a chart.

[0041] In a third aspect, the computer device of the present invention includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the steps of the data intelligent assisted analysis method are implemented.

[0042] In a fourth aspect, the computer-readable storage medium of the present invention stores a computer program, and when the computer program is executed by a processor, the steps of the data intelligent assisted analysis method are implemented.

[0043] The present invention has the following beneficial effects:

[0044] When the data intelligent assisted analysis method, system, device and medium of the present invention are specifically operated, through the constructed power equipment management data analysis API warehouse and API vector database, APIs related to the user's query problem are intelligently retrieved and associated, thereby greatly improving the efficiency, flexibility and accuracy of data analysis, covering a wide range of query intentions, and then querying with the help of a large language model. The operation is simple and convenient, and the inference efficiency of the large language model is relatively high. BRIEF DESCRIPTION OF THE DRAWINGS

[0045] The specification drawings forming a part of the present invention are used to provide a further understanding of the present invention. The schematic embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation to the present invention. In the drawings:

[0046] Figure 1 is a flowchart of the method of the present invention;

[0047] Figure 2 is a system structure diagram of the present invention;

[0048] Figure 3 is a schematic diagram of the principle of the method of the present invention;

[0049] Figure 4 is a flowchart of the query and offline construction of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0050] Next, the technical solutions in the embodiments of the present invention will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without making creative efforts shall fall within the protection scope of the present invention.

[0051] In the description of the present invention, it should be understood that the terms "include" and "comprise" indicate the presence of the described features, wholes, steps, operations, elements and / or components, but do not exclude the presence or addition of one or more other features, wholes, steps, operations, elements, components and / or their combinations.

[0052] It should also be understood that the terms used in the specification of the present invention are only for the purpose of describing specific embodiments and are not intended to limit the present invention. As used in the specification of the present invention and the appended claims, unless the context clearly indicates otherwise, the singular forms "a", "an" and "the" are intended to include the plural forms.

[0053] It should be further understood that the term "and / or" used in the specification of the present invention and the appended claims refers to any combination and all possible combinations of one or more of the associated listed items, and includes these combinations. For example, A and / or B can represent three cases: A exists alone, A and B exist simultaneously, and B exists alone. In addition, the character " / " in the present invention generally represents an "or" relationship between the contextually related objects.

[0054] It should be understood that although the terms first, second, third, etc. may be used in the embodiments of the present invention to describe preset ranges, etc., these preset ranges should not be limited to these terms. These terms are only used to distinguish the preset ranges from each other. For example, without departing from the scope of the embodiments of the present invention, the first preset range may also be referred to as the second preset range, and similarly, the second preset range may also be referred to as the first preset range.

[0055] Depending on the context, the word "if" as used herein can be interpreted as "when" or "while" or "in response to determining" or "in response to detecting". Similarly, depending on the context, the phrase "if determined" or "if detected (stated condition or event)" can be interpreted as "when determined" or "in response to determining" or "when detected (stated condition or event)" or "in response to detecting (stated condition or event)".

[0056] To make the objectives, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are some, but not all, of the embodiments of the present invention. Usually, the components described and shown in the accompanying drawings here can be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of the present invention provided in the accompanying drawings is not intended to limit the scope of the claimed invention, but merely represents selected embodiments of the present invention. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts fall within the scope of protection of the present invention.

[0057] Schematic diagrams of various structures according to the disclosed embodiments of the present invention are shown in the drawings. These figures are not drawn to scale, where for the purpose of clear expression, some details are enlarged and some details may be omitted. The shapes of various regions and layers shown in the figures and their relative sizes and positional relationships are merely exemplary. In practice, there may be deviations due to manufacturing tolerances or technical limitations, and those skilled in the art can design regions / layers with different shapes, sizes, and relative positions according to actual needs.

[0058] Embodiment 1

[0059] Reference Figure 1 、 Figure 3 And Figure 4 , the data intelligent assisted analysis method of the present invention includes the following steps:

[0060] 1) Construct an API repository for power equipment management data analysis;

[0061] Using the power grid equipment management system, construct multiple API interfaces for querying the status values of power grid equipment. The API interfaces include function names (function), function descriptions, input parameters, output parameters, and input parameter enumeration values. Finally, organize all the APIs into a structured API repository for power grid equipment query. The power grid equipment query can support efficient status query requests and can quickly respond to query requirements from users or systems.

[0062] It should be noted that the input parameter enumeration values mainly target long-tail entities in the power grid equipment database unit values. When these long-tail input parameter enumeration values appear in the user query, it is usually difficult for the model to retrieve relevant APIs or fill the parameter slots. Therefore, construct the enumeration values of API input parameters in the API repository for power grid equipment query to supplement more information for subsequent API retrieval and slot filling.

[0063] 2) Construct an API retrieval algorithm for context separation, interaction, and fusion;

[0064] 21) User query expansion;

[0065] In the field of power grid equipment, there may be a large number of long-tail entity classes related to power grid equipment in the API input parameter enumeration values. The occurrence frequency of these enumeration values is relatively low. Therefore, traditional training methods may not train them sufficiently. In this case, the BM25 algorithm is used to recall relevant input parameters through the input parameter enumeration values, so as to ensure that the input parameters corresponding to the dynamically updated long-tail entities in the power equipment scenario can be flexibly recalled, and avoid directly encoding and writing all enumeration values into the API vector database. Specifically:

[0066]

[0067] where q i is the i-th token after the user query Q is segmented; PE represents the information after splicing each long-tail entity enumeration value and its corresponding input parameter information; IDF(q i ) is the inverse document frequency, which measures the importance of the token; f(q i , PE) represents the frequency of q i appearing in PE; L represents the average length of all PEs; Recall(Q, PE) represents the recall score between the user query Q and the API parameter enumeration value PE.

[0068] 22) User query encoder;

[0069] The user query Q and the recalled power grid equipment parameter enumeration value PE are respectively segmented into tokens based on BERT's wordpiece. The user query information tokens are represented as q1, q2,..., qn. Then, the input parameter key and the enumeration value value of the recalled enumeration parameter are respectively segmented into token pairs, represented as <pek0, pev0>; <pek1, pev1>,..., <pekn, pevn>. All tokens are concatenated, and a special token [Q] is inserted after the starting token to indicate the start of the user query. After the user query ends, the token [QR] is inserted to indicate the start of the user query expansion. For each pair of recalled input parameter key, value pairs, the special token [PEK] is inserted to indicate the start of the recalled input parameter key, and the special token [PEV] is inserted to indicate the start of the recalled input parameter value. Finally, the tokens are input into the deep transformer structure of BERT to obtain a set of Embeddings as the vector encoding of these tokens, specifically represented as:

[0070] E q:=BERT([Q], q0, q1,..., q n ,

[0071] [QR], [PEK], pek0, [PEV], pev0,..., [PEK], pek n , [PEV], pev n )

[0072] 23) API encoder;

[0073] The API description information D and the parameter information P are respectively segmented into tokens based on the wordpiece of BERT. The API description information tokens are denoted as d1, d2,..., dn, and the API parameter information tokens are denoted as p1, p2,..., pn. The document encoder inserts a special token [D] after the starting token of BERT to indicate the start of the API function description. After the API function description ends, the token [P] is inserted to indicate the start of the API parameters.

[0074] The token sequence is input into the BERT network, and then the embeddings corresponding to punctuation marks and API code symbols are removed to reduce the number of embedding vectors for each document. Finally, a set of API encoding vectors is output, denoted as E api , that is:

[0075] E api :=Filter(BERT([D], d0, d1,..., d n , [P], p0, p1,..., p n ))

[0076] 24) Interact and fuse the user query with the API vectors;

[0077] The vector encoding E q of the user query and the API vector encoding E api are interactively fused. I(q, a) represents dot - multiplying each query vector separately with all vector representations E api (1:N a ) of the API, taking the calculation result as the similarity score, and taking the maximum value of the similarity. The final relevance score between the user query and the API is the synthesis of the maximum cosine similarity score, that is:

[0078] [[ID=Z8]]

[0079] 25) Construct the optimization objective function:

[0080] A batch of training samples {qk , a + k , a - k} k∈[1,n] , which consists of n triples, where a + k is the positive API sample of query q k and a - k is the negative API sample of query q k . The optimization objective function L for model training is:

[0081]

[0082] where y i represents the label, 1 represents the positive sample pair, 0 represents the negative sample pair, D i represents the Euclidean distance of the sample pair, and margin is the hyperparameter that constrains the minimum distance between negative sample pairs.

[0083] Fine-tune the model through the optimization objective function to optimize the weights of the model, so that both the user query encoder and the API encoder consider the context interaction of each other.

[0084] Based on the API encoder trained above, offline encode all APIs in the API repository for power grid device queries to obtain the API vector database for power grid device queries.

[0085] 3) Obtain the user's query problem, search for input parameters and enumerated values in the API repository for power grid device queries based on the BM25 algorithm, expand the user's query problem, and then perform semantic retrieval in the API vector database for power grid device queries to obtain relevant API vectors.

[0086] 4) Perform semantic retrieval on the API vector database for power grid device queries according to the user's query problem to obtain relevant APIs;

[0087]

[0088] where E q is the vector representation of the user query, and E api is the API vector representation.

[0089] 5) Associate the API repository for power grid device queries;

[0090] Associate the retrieved API vectors with the API repository for power grid device queries to obtain the APIs associated with this problem;

[0091] 6) API slot filling and generation of API call code for power grid device queries;

[0092] Construct the first large model prompt based on the function description, input parameters, user query, and query expansion of the API associated with the problem. The task description is API parameter slot filling and API call code generation. Then, input the first large model prompt into the large language model to fill the API parameter values and generate the API call code.

[0093] 7) Call the API;

[0094] Execute the API after filling the parameters to obtain the numerical value or data list queried by the API.

[0095] 8) Generate a reply;

[0096] Construct the second large model prompt based on the API, the data value or data list returned by the API query, and the problem of the user query. Then, input the second large model prompt into the large language model to obtain the final conclusion of the query.

[0097] 9) Visualize and display the chart;

[0098] Call the chart visualization API to convert the result of the API query into a chart.

[0099] The present invention has the following characteristics:

[0100] The present invention realizes the full utilization of existing API resources in the business scenarios of the power grid equipment field by constructing an API warehouse for power grid equipment data analysis and an API vector database for power grid equipment data analysis. In addition, based on the large language model, the present invention realizes the intelligent parsing of user query problems and the rapid generation of data analysis results through semantic retrieval, API association, slot filling, API call, and comprehensive answer. Furthermore, the present invention also provides the function of visualizing and displaying charts, converting the queried data list into an intuitive chart, further improving the readability and usability of data analysis. Through natural language input, the parsing of complex data queries and API calls are realized, and business personnel can complete data analysis tasks without the need to have the ability to write SQL. At the same time, by automatically calling the visualization API through task orchestration, the query results are converted into an easy-to-understand chart form, reducing the cumbersome operation of business intelligence (BI) tools and enhancing the business personnel's understanding and application ability of data analysis results.

[0101] Compared with the NL2SQL technology in the field of data intelligent assistance, the advantages of the present invention are as follows: NL2SQL is usually limited to SQL queries in structured databases and shows certain limitations when facing unstructured data, dynamic data, or complex business logics. In contrast, the present invention can flexibly adapt to diverse data query requirements and process various underlying data sources, including unstructured and dynamic data, by invoking query APIs. Additionally, when it comes to complex queries or multi-table joint queries, NL2SQL needs to strictly comply with SQL syntax and highly match the database structure, which makes the process of generating query statements more complex and challenging. In contrast, the present invention encapsulates complex query logics inside the APIs through an API call-based approach, eliminating the need to directly generate complex query statements and avoiding syntax and structure matching issues in SQL generation, thereby improving the accuracy rate.

[0102] Due to the complexity of the business in the power grid equipment field, the requirements for data analysis may be very complex, and the potential number of APIs may also be extremely large. Carrying all API description information may lead to the context exceeding the maximum allowed tokens of the large language model. The present invention constructs an API vector database and retrieves relevant APIs for the user query from the API repository. When the large language model performs text2API conversion, only the APIs relevant to the user question are carried, which can greatly reduce the context size of the large language model input and improve the inference efficiency of the large language model.

[0103] The present invention proposes a context separation, interaction, and fusion mechanism: while maintaining the expression ability of the deep language model, this mechanism can independently pre-compute and encode API information, thereby enhancing the model's performance in online queries. Through a dual-encoder architecture, the user query and the functional descriptions and parameters of the APIs are independently encoded, ensuring that the tokens of the query and the APIs are independent of each other during the encoding process. Therefore, the encoding of the APIs can be pre-processed and cached offline, and only the user query is encoded during the query. The similarity is calculated through vector interaction and fusion, significantly improving the efficiency of online queries.

[0104] By combining the BM25 algorithm, the present invention recalls the long-tail entity class API input parameters and enumeration values that may appear in the user query, and uses them as an extension of the user query, thereby supplementing the context information of the query. In the field of power equipment, user queries often involve the enumeration values of the API input parameters of the long-tail entity class. Due to the small amount of training data for these enumeration values, traditional retrieval models are difficult to effectively capture. In addition, the types of input parameter enumeration values in the power field are numerous and often change with business requirements. It is not practical to directly encode them into the API vector database. Therefore, a parameter enumeration value recall strategy based on the BM25 algorithm is designed. Using this strategy, relevant input parameter enumeration values are recalled during the query process as query extensions, thereby ensuring the flexibility while also ensuring the completeness of the query information.

[0105] Embodiment 2

[0106] Reference Figure 2 , the data intelligent auxiliary analysis system of the present invention includes:

[0107] An acquisition module for acquiring the problem of the user query;

[0108] A semantic retrieval module for performing semantic retrieval in the API vector database according to the problem of the user query to obtain relevant API vectors;

[0109] An association module for associating the relevant API vectors obtained by semantic retrieval with the API repository to obtain the APIs associated with the problem;

[0110] A first query module for obtaining the final conclusion of the query by using a large language model according to the APIs associated with the problem.

[0111] In this embodiment, this embodiment further includes:

[0112] A call module for calling a chart visualization API to convert the final conclusion of the query into a chart.

[0113] In this embodiment, it further includes:

[0114] A first construction module for constructing an API repository, which contains several APIs related to the analysis of power equipment management data;

[0115] A completion module for recalling input parameter enumeration values based on the BM25 algorithm and using the input parameter enumeration values as an extension of the problem of the user query to complete the problem of the user query;

[0116] A second construction module is used to separate the API vector encoder in the interactive fusion API retrieval algorithm based on the context, encode and convert the function descriptions and parameter information of all APIs related to power equipment management data analysis into API vectors, and construct an API vector database through the API vectors.

[0117] In this embodiment, the first query module includes:

[0118] A second query module is used to construct a first large model prompt word according to the API associated with the problem, input the first large model prompt word into the large language model to obtain an API parameter value, and fill the API with the API parameter value to obtain an API with filled parameters;

[0119] An execution module is used to execute the API with filled parameters to obtain the result of the API query;

[0120] A third query module is used to construct a second large model prompt word according to the result of the API query and the problem queried by the user, input the second large model prompt word into the large language model to obtain the final conclusion of the query.

[0121] The division of modules in the embodiments of the present application is illustrative, merely a logical function division. In actual implementation, there may be other division methods. In addition, in each embodiment of the present application, each functional module may be integrated in a processor, may also exist separately physically, or two or more modules may be integrated in one module. The above integrated modules may be implemented in the form of hardware or in the form of software functional modules.

[0122] Embodiment Three

[0123] A computer device includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the steps of the data intelligent auxiliary analysis method are implemented. For example, it includes: obtaining the problem queried by the user; performing semantic retrieval in the API vector database according to the problem queried by the user to obtain relevant API vectors; associating the relevant API vectors obtained by semantic retrieval with the API repository to obtain the APIs associated with the problem; and using a large language model according to the APIs associated with the problem to obtain the final conclusion of the query. Among them, the memory may include internal memory, such as high-speed random access memory, and may also include non-volatile memory, such as at least one disk memory, etc.; the processor, the network interface, and the memory are interconnected through an internal bus, and the internal bus may be an Industry Standard Architecture bus, a Peripheral Component Interconnect standard bus, an Extended Industry Standard Architecture bus, etc., and the bus may be divided into an address bus, a data bus, a control bus, etc. The memory is used to store programs. Specifically, the program may include program code, and the program code includes computer operation instructions. The memory may include internal memory and non-volatile memory and provide instructions and data to the processor.

[0124] Embodiment 4

[0125] A computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the data intelligent auxiliary analysis method are implemented. For example, it includes: obtaining the problem queried by the user; performing semantic retrieval in the API vector database according to the problem queried by the user to obtain relevant API vectors; associating the relevant API vectors obtained by semantic retrieval with the API repository to obtain the APIs associated with the problem; and using a large language model according to the APIs associated with the problem to obtain the final conclusion of the query. Specifically, the computer-readable storage medium includes but is not limited to, for example, volatile memory and / or non-volatile memory. The volatile memory may include random access memory (RAM) and / or cache memory, etc. The non-volatile memory may include read-only memory (ROM), hard disk, flash memory, optical disc, magnetic disk, etc.

[0126] Those skilled in the art should understand that the embodiments of the present application can be provided as a method, a system, or a computer program product. Therefore, the present application can take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware aspects. Moreover, the present application can take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk memory, CD-ROM, optical memory, etc.) containing computer-usable program code.

[0127] This application is described with reference to the flowcharts and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the present application. It should be understood that each flow and / or block in the flowchart and / or block diagram, and the combination of flows and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to the processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing device to generate a machine, such that the instructions executed by the processor of the computer or other programmable data processing device produce means for implementing the functions specified in one flow Figure 1 one flow or multiple flows and / or blocks Figure 1 or multiple blocks.

[0128] These computer program instructions can also be stored in a computer-readable memory that can direct a computer or other programmable data processing device to work in a specific manner, such that the instructions stored in the computer-readable memory produce a manufactured article including instruction means that implement the functions specified in one flow Figure 1 one flow or multiple flows and / or blocks Figure 1 or multiple blocks.

[0129] These computer program instructions can also be loaded onto a computer or other programmable data processing device, such that a series of operation steps are executed on the computer or other programmable device to produce a computer-implemented process, and thus the instructions executed on the computer or other programmable device provide steps for implementing the functions specified in one flow Figure 1 one flow or multiple flows and / or blocks Figure 1 or multiple blocks.

[0130] Those skilled in the art will readily conceive of other embodiments of the present invention upon considering the specification and the disclosure of the invention. This application is intended to cover any variations, uses, or adaptations of the present invention, which follow the general principles of the present invention and include common general knowledge or conventional technical means in the technical field not disclosed by the present invention. The specification and examples are only to be considered as exemplary, and the true scope and spirit of the present invention are pointed out by the following claims.

[0131] It should be understood that the present invention is not limited to the exact structures described above and shown in the drawings, and various modifications and changes can be made without departing from its scope. The scope of the present invention is only limited by the appended claims.

[0132] The above are only the preferred embodiments of the present invention and do not impose any limitations on the present invention. Any simple modifications, changes, and equivalent structural changes made to the above embodiments based on the technical essence of the present invention still fall within the protection scope of the technical solution of the present invention.

Claims

1. A data intelligent assisted analysis method, characterized in that Including: Obtain the question queried by the user; Perform semantic retrieval in the API vector database according to the question queried by the user to obtain relevant API vectors; Associate the relevant API vectors with the API repository to obtain APIs associated with the question; According to the APIs associated with the question, use a large language model to obtain the final conclusion of the query.

2. The data intelligent assisted analysis method according to claim 1, wherein Before performing semantic retrieval in the API vector database according to the question queried by the user to obtain relevant API vectors, it further includes: Construct an API repository, which contains several APIs related to power equipment management data analysis; Recall the enumerated values of input parameters based on the BM25 algorithm, and use the enumerated values of input parameters as an extension of the question queried by the user to complete the question queried by the user; Based on the API vector encoder in the context-separated interactive fusion API retrieval algorithm, encode the function descriptions and parameter information of all APIs related to power equipment management data analysis into API vectors, and construct an API vector database through the API vectors.

3. The data intelligent assisted analysis method according to claim 1, wherein The process of obtaining the final conclusion of the query according to the APIs associated with the question and using a large language model is as follows: According to the APIs associated with the question, construct a first large model prompt, input the first large model prompt into the large language model to obtain API parameter values, and fill the APIs with the API parameter values to obtain the APIs after filling the parameters; Execute the APIs after filling the parameters to obtain the results of API queries; According to the results of the API queries and the question queried by the user, construct a second large model prompt, input the second large model prompt into the large language model to obtain the final conclusion of the query.

4. The data intelligent assisted analysis method according to claim 3, wherein After obtaining the final conclusion of the query, it further includes: Call the chart visualization API to convert the results of the API query into charts.

5. A data intelligent assisted analysis system, characterized in that, Including: An acquisition module for obtaining the question queried by the user; A semantic retrieval module for performing semantic retrieval in the API vector database according to the question queried by the user to obtain relevant API vectors; An association module for associating the relevant API vectors with the API repository to obtain APIs associated with the question; A first query module for obtaining the final conclusion of the query according to the APIs associated with the question and using a large language model.

6. The data intelligent assisted analysis system according to claim 5, wherein It further includes: A first construction module for constructing an API repository, which contains several APIs related to power equipment management data analysis; A completion module for recalling the long-tail enumerated values of input parameters based on the BM25 algorithm, and using the enumerated values of input parameters as an extension of the question queried by the user to complete the question queried by the user; A second construction module for encoding and converting the function descriptions and parameter information of all APIs related to power equipment management data analysis into API vectors based on the API vector encoder in the context-separated interactive fusion API retrieval algorithm, and constructing an API vector database through the API vectors.

7. The data intelligent assisted analysis system according to claim 5, wherein The first query module includes: A second query module, configured to construct a first large model prompt word according to the API associated with the question, input the first large model prompt word into a large language model to obtain an API parameter value, and fill the API with the API parameter value to obtain an API with filled parameters; An execution module, configured to execute the API with filled parameters to obtain a result of the API query; A third query module, configured to construct a second large model prompt word according to the result of the API query and the question queried by the user, and input the second large model prompt word into the large language model to obtain a final conclusion of the query.

8. The data intelligent assisted analysis system according to claim 7, wherein It further includes: A calling module, configured to call a chart visualization API to convert the result of the API query into a chart.

9. A computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, the steps of the data intelligent assisted analysis method according to any one of claims 1-4 are implemented.

10. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by the processor, the steps of the data intelligent assisted analysis method according to any one of claims 1-4 are implemented.

Citation Information

Patent Citations

  • Question and answer prompt system, question and answer prompt method and device, library construction method and device and model training method and device

    CN117648422A

  • Question and answer method and device, computing equipment, storage medium and program product

    CN118484521A

  • Method and equipment for generating large model API (Application Program Interface) sequence based on retrieval enhancement

    CN118536607A

  • Power equipment data intelligent interaction method, system, equipment and medium

    CN119127921A

  • Language question and answer processing method and device for computer hardware management information

    CN119248914A

Cited By

  • Large model-based coal preparation plant data query method, apparatus and device, and medium

    CN121958359A