Method and system for automatically realizing visual data graph based on question and answer type BI system front end

By implementing session management, data analysis, automatic graph generation and page rendering methods in the question-and-answer front-end BI system, the shortcomings in performance, ease of use and customization of data visualization products in the prior art are solved, and efficient and personalized data visualization effects are achieved.

CN119536723APending Publication Date: 2025-02-28BEIJING INSPUR CLOUD COMPUTING CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411489468.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-10-24
Publication Date
2025-02-28

AI Technical Summary

Technical Problem

The existing data visualization products based on the Q&A front-end BI system have shortcomings in performance, ease of use and customization, and cannot meet users' needs for real-time data visualization and personalized data display.

Method used

Through steps such as creating a new session, data query and analysis, automatic chart generation and automatic page rendering, the method of automatically realizing visual data graphs based on the front end of the Q&A BI system is realized. The method includes user input and asking questions, the system performs natural language processing and data analysis, automatically generates charts, and automatically renders them on the page.

Benefits of technology

It improves data integration rate and data quality, meets users' needs for real-time data visualization and personalized data display, and reduces development efficiency and delivery cycle.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119536723A_ABST
    Figure CN119536723A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of front ends, in particular to a method and a system for automatically realizing a visual data graph based on a question and answer type BI system front end, comprising the following steps: creating a new session, analyzing a query result after querying by the question and answer type BI system, automatically generating a response graph according to the analysis result, and automatically rendering a page. The method and the system for automatically realizing the visual data graph based on the question and answer type BI system front end have the beneficial effects that the development efficiency is high, and the delivery period is short; the data integration rate is high, and the data quality is guaranteed; data demand scenes are diversified and can respond in time; business data are presented in real time, various requirements are met, and data display is clear at a glance.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of front-end technology, and specifically to a method and system for automatically realizing visualized data graphs based on a question-and-answer BI system front-end. Background Art

[0002] With the continuous development of big data and artificial intelligence technology, data visualization has become an important means of enterprise decision-making and data analysis. Traditional data visualization tools usually rely on fixed chart types and complex configuration processes, which are difficult to meet users' needs for personalized, efficient and intuitive data visualization. Therefore, a system based on the question-and-answer front-end BI system that automatically realizes the visualization of data graphs has emerged. It combines natural language processing, data analysis and front-end visualization technology, and can automatically build and adjust data visualization effects based on user questions.

[0003] At present, there are already some data visualization products based on question-and-answer front-end BI systems on the market. These products usually combine technologies such as natural language processing, data analysis, and front-end visualization, and can automatically generate corresponding charts and reports based on user questions. However, these products still have some shortcomings in terms of performance, ease of use, and customization. For example, some products have slow response speeds and cannot meet users' needs for real-time data visualization; some products have unfriendly user interfaces, which increases users' learning costs; and some products are limited in customization and cannot meet users' needs for personalized data visualization. Summary of the invention

[0004] The purpose of the present invention is to provide a method and system for automatically realizing visual data graphs based on a question-and-answer BI system front end, so as to solve the problems raised in the above-mentioned background technology.

[0005] To achieve the above object, the present invention provides the following technical solution: a method for automatically realizing a visualized data graph based on a question-and-answer BI system front end, the method comprising the following steps:

[0006] Create a new session. The user fills in the session content to be queried on the interface and submits it, or calls the historical session interface to obtain the historical sessions that the current user has queried, and displays the historical query results on the page;

[0007] After querying the question-and-answer BI system, the query results are analyzed, including recursive filtering of duplicate, non-standard, invalid, erroneous, incomplete, harmful, and personal privacy data, and the data is transformed into data suitable for analysis through smoothing, aggregation, generalization, and normalization;

[0008] Automatically generate corresponding charts based on the analysis results, including encapsulating standard text data into question-and-answer data, and encapsulating non-standard text data into chart data. Chart data encapsulation includes determining whether the data supports pie charts, and giving priority to processing multiple key:value data and assembling them into new chart data objects.

[0009] The page is automatically rendered, rendering the answer text data according to the question-and-answer mode, and rendering the chart data according to specific rules.

[0010] Preferably, the user clicks the Add Session button to fill in the session content in the text box, clicks Send or presses the Enter key on the computer to submit the session content; or clicks on a specific historical session, the page displays the historical query results on the page, and the user makes a new session query under the current session or selects the Result Analysis button for analysis.

[0011] Preferably, recursive filtering of data includes using various algorithms for different processes, such as redundancy removal, quality filtering, word segmentation, and privacy elimination, to specifically split and reorganize the data to ensure data accuracy and privacy protection.

[0012] Preferably, the chart data encapsulation includes specific rules for determining whether the data supports a pie chart. For example, if the value array corresponding to the key in the chart object contains CPI month-on-month data containing %, or there are multiple different array values ​​in the value corresponding to a key (x), and the string units corresponding to all y:[] are inconsistent, a pie chart cannot be used; and data with multiple key:values ​​are processed preferentially, including assembling _x, _y, and _z arrays, and determining whether to return null or perform other processing according to the specific circumstances of the data.

[0013] Preferably, automatic page rendering includes rendering response text data according to a question-and-answer mode, and simulating the typing effect of a GPT printer for output after encapsulating the data according to specific rules; and selecting an appropriate chart type, such as a pie chart, a line chart, a bar chart, for rendering according to the number and specific content of the _x, _y, and _z arrays of the chart data object. If the page is displayed in a table, the Y-axis data and the X-axis data are combined for display.

[0014] A system for automatically realizing a visualized data graph based on a question-and-answer BI system front end, applied to a method for automatically realizing a visualized data graph based on a question-and-answer BI system front end, the system comprising:

[0015] Create a new session module to receive the session content filled in and submitted by the user on the interface, or call the historical session interface to obtain the historical sessions that the current user has queried, and display the historical query results on the page;

[0016] The data query and analysis module is used to query and return large quantities of data through the question-and-answer BI system, and recursively filter the data, including redundancy removal, quality filtering, word segmentation, and privacy elimination. The filtered data is then transformed into data suitable for analysis through smoothing, aggregation, generalization, and normalization.

[0017] The chart automatic generation module is used to automatically generate corresponding charts according to the analysis results, including encapsulating standard text data into question and answer data, encapsulating non-standard text data into chart data, judging whether the data supports pie charts, and giving priority to processing multiple key:value data and assembling them into new chart data objects;

[0018] The page automatic rendering module is used to automatically render charts and text on the page according to the generated chart data and response text data, including simulating typing effects for output after encapsulating data through specific rules, and selecting appropriate chart types for rendering according to the array quantity and specific content of the chart data object.

[0019] Preferably, the new session module also includes a session management function for obtaining a session ID and allowing the user to conduct a new session inquiry in the current session or select a result analysis button for analysis of a given answer.

[0020] Preferably, the data query and analysis module also includes a data quality monitoring function for monitoring the quality of data during the data filtering and conversion process, and issuing a warning or taking other measures when the data quality does not meet the requirements.

[0021] Preferably, the automatic chart generation module also includes a chart type judgment function, which is used to judge the most suitable chart type according to the characteristics of the data and user needs, and generate a corresponding chart data object. The module also includes a data assembly function, which is used to assemble multiple key:value data into a new chart data object, and determine whether to return null or perform other processing according to the specific situation of the data.

[0022] Preferably, the page automatic rendering module also includes a dynamic rendering function, which is used to monitor the data returned by the back end after the front end sends a request, and determine the start and end of rendering according to the textFlag value of the data. The module also includes chart rendering rules, which are used to select an appropriate chart type for rendering according to the array quantity and specific content of the chart data object, and use the Y-axis data and X-axis data to combine and display the table function.

[0023] Compared with the prior art, the present invention has the following beneficial effects:

[0024] The present invention proposes a method and system for automatically realizing visualized data graphs based on the front end of a question-and-answer BI system. Users input questions through a web interface developed by the front end, and then the question-and-answer BI system performs natural language processing (redundancy removal, quality filtering, word segmentation, and privacy elimination) to obtain accurate data analysis results and feed them back to the front end. The front end processes the feedback result data according to specific rules, and after processing, the data is divided into multiple parts for packaging (question, answer data, and chart data need to be processed and packaged separately). Then, the packaged data is rendered on the page by simulating the typing effect of a GPT printer. The development efficiency is high and the delivery cycle is short. The data integration rate is high and the data quality is guaranteed. The data demand scenarios are diverse and can be responded to in a timely manner. The business data is presented in real time to meet various needs, and the data display is clear at a glance. BRIEF DESCRIPTION OF THE DRAWINGS

[0025] Figure 1 The data processing flow chart of the BI system of the present invention;

[0026] Figure 2 Question and answer for the user of the present invention to obtain the data flow chart;

[0027] Figure 3 This is a flow chart of the interface stream response of the present invention;

[0028] Figure 4 The figure is a flow chart of the method of the present invention. DETAILED DESCRIPTION

[0029] In order to make the purpose and technical solution of the present invention clearly and completely described, and the advantages more clearly understood, the embodiments of the present invention are further described in detail with reference to the accompanying drawings. It should be understood that the specific embodiments described herein are part of the embodiments of the present invention, rather than all of the embodiments, and are only used to explain the embodiments of the present invention, and are not used to limit the embodiments of the present invention. All other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0030] For example, see Figures 1 to 4 The present invention provides a technical solution: a method for automatically realizing a visual data graph based on a question-and-answer BI system front end, the method comprising the following steps:

[0031] Step 1: Create a new session

[0032] The user clicks the Add a New Session button on the interface, fills in the conversation content he wants to inquire about in the text box, clicks Send or presses the Enter key on the computer to query the relevant conversation content through the big data of the question-and-answer AI system. Alternatively, when the page is initialized, the historical session interface is called to obtain the historical sessions that the current user has queried. Click a specific historical session, and the page will display the historical query results on the page for users to view the historical question-and-answer results. If the historical results do not meet the user's needs, the user can make a new conversation inquiry under the current session (obtain the session id and enter the new conversation content) or select the result analysis button under the current result to analyze the answer if the user does not understand it.

[0033] Step 2: Analyze the query results after querying the question-and-answer BI system

[0034] After the BI system is queried, a large amount of data will be returned. Among these data, there will be a lot of duplicate, non-standard, invalid, erroneous, incomplete, harmful, and personal privacy data. These data need to be recursively filtered (filtering will use various algorithms to perform specific splitting and reorganization of data for different processes (redundancy removal, quality filtering, word segmentation, privacy elimination)). The filtered data needs to be converted into data suitable for analysis through smoothing, aggregation, generalization, and normalization, and returned to the front end.

[0035] Step 3: Automatically generate corresponding charts based on the analysis results (with visualization tools or plug-ins, etc.)

[0036] After the front end obtains the question and answer results, it analyzes the data and assembles the chart data. The specific component rules are as follows:

[0037] 1. Encapsulate the standard text data in the form of question: question and answer data and answer: answer data.

[0038] 2. Non-standard text data is encapsulated as chart data:

[0039] 2.1. First, you need to determine whether pie charts are supported. For example, if the value array corresponding to the key in the chart object contains CPI month-on-month data containing %, or there are multiple different array values ​​in the value corresponding to a key (x), or the string units corresponding to all y:[] are inconsistent, pie charts cannot be used in these three situations.

[0040] 2.2. For any chart, the data should be processed as follows: determine whether there are multiple key:value pairs in the chart object. If there are multiple pairs, assemble the corresponding keys in the chart object into _x: [key1, key1], and assemble the z: [] in the value corresponding to each key into a new _z: []. When assembling, it is necessary to determine whether the values ​​in the z: [] in the value corresponding to each key are consistent. If they are consistent and the length of z: [] is 1, return _z: [chart [Object.keys (chart) [0]]['z'][0]]; if they are inconsistent and the length is 1, push all the values ​​in z: [] into _z [] and return them; if the length of z: [] in the value corresponding to each key is greater than 1, return null. Assemble the y: [] in the value corresponding to each key into a new _y: [], and determine whether the string units in y [] are consistent. If they are inconsistent, return null. If they are consistent, traverse all keys and push the y: [] in the value corresponding to the key into _y [] and return them. If there are no multiple key:value pairs in the chart object, and the array lengths of x:[], y:[], and z:[] in the value corresponding to the key are all greater than 1, then _x:[] = x:[] (assign all values ​​in the x:[] array to _x:[]), _y:[] = y:[], and _z:[] = z[].

[0041] 2.3. Data other than the above data cannot be encapsulated into data charts and will be uniformly returned as null.

[0042] 2.4. The final chart data is encapsulated into an object, which contains showpie: true / false, indicating whether the pie chart needs to be displayed. True displays the pie chart, false displays the pie chart, or empty does not display the pie chart. The object also contains _x:[], _y:[], _z:[] and other data.

[0043] Step 4: Automatic page rendering to simplify data analysis process

[0044] Page response text data rendering rules: Rendering is performed according to the question-and-answer mode. The rendering process is similar to the GPT printer typing effect (the front end negotiates with the back end when sending a request. The returned data starts with the value of textFlag in the object as startData as data rendering, and ends with the value of textFlag as endData as rendering. Rendering process: After the front end sends a request through fetchEventSource, it keeps listening to the data returned by the back end to clear the textFlag of the returned data. In the non-end state, it keeps waiting for the back end to send data at irregular intervals through EventSourceMessage. After the front end gets the data, it encapsulates it according to specific rules and outputs it by simulating the GPT printer typing effect)

[0045] Page chart rendering rules: If the number of arrays _z:[] is greater than _x:[], the X-axis data of the chart uses the _z:[] array, otherwise use the _x:[] array, and the Y-axis data of the chart uses the _y:[] array. If the page is displayed in a table, use the Y-axis data and the X-axis data together.

[0046] Embodiment 2, based on Embodiment 1, proposes a system for automatically realizing a visualized data graph based on a question-and-answer BI system front end, which is applied to a method for automatically realizing a visualized data graph based on a question-and-answer BI system front end. The system includes:

[0047] A new session module is used to receive the session content filled in and submitted by the user on the interface, or to call the historical session interface to obtain the historical sessions that the current user has queried, and to display the historical query results on the page; it also includes a session management function, which is used to obtain the session id and allow the user to make a new session query under the current session or select the result analysis button for analysis based on the given answer.

[0048] The data query and analysis module is used to query and return large quantities of data through the question-and-answer BI system, and recursively filter the data, including redundancy removal, quality filtering, word segmentation, and privacy elimination processes. The filtered data is then transformed into data suitable for analysis through smoothing, aggregation, generalization, and normalization. It also includes a data quality monitoring function, which is used to monitor the quality of data during the data filtering and conversion process, and to issue warnings or take other measures when the data quality does not meet the requirements.

[0049] The chart automatic generation module is used to automatically generate responsive charts based on the analysis results, including encapsulating standard text data into question and answer data, and encapsulating non-standard text data into chart data, and judging whether the data supports pie charts, and giving priority to processing multiple key:value data and assembling them into new chart data objects; it also includes a chart type judgment function, which is used to judge the most suitable chart type according to the characteristics of the data and user needs, and generate the corresponding chart data object. The module also includes a data assembly function, which is used to assemble multiple key:value data into a new chart data object, and judge whether to return null or perform other processing according to the specific situation of the data.

[0050] The page automatic rendering module is used to automatically render charts and texts on the page according to the generated chart data and response text data, including simulating typing effects for output after encapsulating data through specific rules, and selecting appropriate chart types for rendering according to the array quantity and specific content of the chart data object; it also includes a dynamic rendering function, which is used to monitor the data returned by the back end after the front end sends a request, and judge the start and end of rendering according to the textFlag value of the data. The module also includes chart rendering rules, which are used to select appropriate chart types for rendering according to the array quantity and specific content of the chart data object, and use Y-axis data and X-axis data to combine and display table functions.

[0051] Although embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions and variations may be made to the embodiments without departing from the principles and spirit of the present invention, and that the scope of the present invention is defined by the appended claims and their equivalents.

Claims

1. A method for automatically realizing a visual data graph based on a question-and-answer BI system front end, characterized in that: The method comprises the following steps: Create a new session. The user fills in the session content to be queried on the interface and submits it, or obtains the historical sessions that the current user has queried by calling the historical session interface and displays the historical query results on the page; After the query is made by the question-and-answer BI system, the query results are analyzed, including recursive filtering of duplicate, non-standard, invalid, erroneous, incomplete, harmful, and personal privacy data, and the data is transformed into data suitable for analysis through smoothing, aggregation, generalization, and normalization. Automatically generate corresponding charts based on the analysis results, including encapsulating standard text data into question-and-answer data, and encapsulating non-standard text data into chart data. Chart data encapsulation includes determining whether the data supports pie charts, and giving priority to processing multiple key:value data and assembling them into new chart data objects. The page is automatically rendered, rendering the answer text data according to the question-and-answer mode, and rendering the chart data according to specific rules.

2. The method for automatically realizing visual data graph based on the question-answer BI system front end according to claim 1, characterized in that: The user clicks the Add Session button to fill in the session content in the text box, clicks Send or presses the Enter key on the computer to submit the session content; or clicks on a specific historical session, the page will display the historical query results on the page, and the user can make a new session query under the current session or select the Result Analysis button for analysis.

3. The method for automatically realizing a visual data graph based on a question-and-answer BI system front end according to claim 1, characterized in that: Recursive filtering of data includes using various algorithms for different processes, such as redundancy removal, quality filtering, word segmentation, and privacy elimination, to specifically split and reorganize the data to ensure data accuracy and privacy protection.

4. The method for automatically realizing visual data graph based on the question-answer BI system front end according to claim 1, characterized in that: Chart data encapsulation includes specific rules for determining whether the data supports pie charts. For example, if the value array corresponding to the key in the chart object contains CPI month-on-month data containing %, or there are multiple different array values ​​in the value corresponding to a key (x), and the string units corresponding to all y:[] are inconsistent, a pie chart cannot be used; and data with multiple key:value pairs are processed first, including assembling _x, _y, and _z arrays, and determining whether to return null or perform other processing based on the specific circumstances of the data.

5. The method for automatically realizing visual data graph based on the question-answer BI system front end according to claim 4, characterized in that: Automatic page rendering includes rendering the answer text data according to the question-and-answer mode, and simulating the typing effect of a GPT printer for output after encapsulating the data through specific rules; and selecting the appropriate chart type, such as pie charts, line charts, and bar charts, for rendering according to the number and specific content of the _x, _y, and _z arrays of the chart data object. If the page is displayed in a table, the Y-axis data and the X-axis data are combined for display.

6. A system for automatically realizing a visualized data graph based on a question-and-answer BI system front end, applied to the method for automatically realizing a visualized data graph based on a question-and-answer BI system front end according to any one of claims 1 to 5, characterized in that: The system comprises: Create a new session module to receive the session content filled in and submitted by the user on the interface, or call the historical session interface to obtain the historical sessions that the current user has queried, and display the historical query results on the page; The data query and analysis module is used to query and return large quantities of data through the question-and-answer BI system, and recursively filter the data, including redundancy removal, quality filtering, word segmentation, and privacy elimination. The filtered data is then transformed into data suitable for analysis through smoothing, aggregation, generalization, and normalization. The chart automatic generation module is used to automatically generate corresponding charts according to the analysis results, including encapsulating standard text data into question and answer data, encapsulating non-standard text data into chart data, judging whether the data supports pie charts, and giving priority to processing multiple key:value data and assembling them into new chart data objects; The page automatic rendering module is used to automatically render charts and text on the page according to the generated chart data and response text data, including simulating typing effects for output after encapsulating data through specific rules, and selecting appropriate chart types for rendering according to the array quantity and specific content of the chart data object.

7. A system for automatically realizing visual data graph based on the question-answer BI system front end according to claim 6, characterized in that: The new session module also includes a session management function for obtaining a session ID and allowing the user to conduct a new session inquiry under the current session or select a result analysis button for analysis of a given answer.

8. The system for automatically realizing visual data graph based on the question-answer BI system front end according to claim 6, characterized in that: The data query and analysis module also includes a data quality monitoring function, which is used to monitor the quality of data during data filtering and conversion, and issue warnings or take other measures when the data quality does not meet the requirements.

9. The system for automatically realizing visual data graph based on the question-answer BI system front end according to claim 6, characterized in that: The chart automatic generation module also includes a chart type judgment function, which is used to judge the most suitable chart type according to the characteristics of the data and user needs, and generate the corresponding chart data object. The module also includes a data assembly function, which is used to assemble multiple key:value data into a new chart data object, and determine whether to return null or perform other processing according to the specific situation of the data.

10. The system for automatically realizing visual data graph based on the question-answer BI system front end according to claim 6, characterized in that: The page automatic rendering module also includes a dynamic rendering function, which is used to monitor the data returned by the backend after the frontend sends a request, and determine the start and end of rendering based on the textFlag value of the data. The module also includes chart rendering rules, which are used to select the appropriate chart type for rendering based on the array quantity and specific content of the chart data object, as well as the use of Y-axis data and X-axis data to combine and display the table function.