A data construction method and device, electronic equipment and storage medium

By generating chart understanding instruction data, a multimodal large language model is used to generate code programs for each chart type and perform augmentation processing. This solves the problems of class imbalance and limited scale of training data for chart understanding models, and achieves efficient generation of chart understanding instruction data.

CN119829603BActive Publication Date: 2025-11-21BEIJING MIANBI INTELLIGENT TECH CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202411889150.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-12-20
Publication Date
2025-11-21
Estimated Expiration
2044-12-20

AI Technical Summary

Technical Problem

In existing technologies, the data used to train graph understanding models suffers from class imbalance and limited scale, and manual annotation is inefficient.

Method used

By acquiring raw chart datasets of multiple chart types, a multimodal large language model is used to generate code programs for each chart image. These programs are then modified and expanded to generate new chart images, which are added to the original dataset until the required quantity threshold is reached. Finally, a multimodal large language model is used to construct chart understanding instruction data.

Benefits of technology

It solves the problem of insufficient chart images, achieves balanced classification and large-scale generation of chart understanding instruction data, and improves data generation efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119829603B_ABST
    Figure CN119829603B_ABST
Patent Text Reader

Abstract

The application discloses a data construction method and device, electronic equipment and storage medium, and relates to the technical field of artificial intelligence. The method comprises the following steps: constructing an original chart data set for each chart type; constructing a code program for generating a chart picture for each chart picture in the original chart data set; modifying and amplifying each code program, and generating a new chart picture based on the modified and amplified code program; updating the original chart data set according to the new chart picture, so that the number of chart pictures in the updated original chart data set is equal to a preset chart quantity requirement threshold; and constructing chart understanding instruction data for training a model chart understanding ability through a multi-modal large language model according to the chart pictures in the updated original chart data set. The application improves the construction efficiency of the chart understanding instruction data, and balances the quantity of various types of chart understanding instruction data.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of artificial intelligence technology, and in particular to a data construction method, apparatus, electronic device, and storage medium. Background Technology

[0002] In the modern information age, the forms of data visualization are becoming increasingly diverse. Charts (such as pie charts, bar charts, or line charts) play an important role in various documents and reports as tools for efficient information transmission. To extract key information from charts, a trained model with chart understanding capabilities is typically used. However, training such a model requires first constructing chart understanding instruction data for its training.

[0003] Currently, the common method for constructing chart understanding instruction data for training models involves collecting chart images from the internet and then manually annotating them. This method has several drawbacks: since images are primarily sourced from the internet, there is an inherent imbalance in image categories, with one or more chart types dominating the images, leading to an unbalanced distribution of chart understanding instruction data. Furthermore, the limited number of chart images available online restricts the scale of the constructed data. Finally, manual annotation results in low efficiency in constructing this data. Therefore, a new method for constructing chart understanding instruction data is urgently needed. Summary of the Invention

[0004] This invention provides a data construction method, apparatus, electronic device, storage medium, and computer program product.

[0005] According to one aspect of the present invention, a data construction method is provided, comprising:

[0006] Obtain multiple pre-determined chart types and construct an original chart dataset for each chart type; wherein each original chart dataset includes the same number of chart images;

[0007] For any given original chart dataset, construct a separate code program to generate a chart image for each chart image in the original chart dataset.

[0008] Each code program is modified and expanded, and new charts and images are generated based on the modified and expanded code programs;

[0009] Update the original chart dataset with new chart images so that the number of chart images in the updated original chart dataset is equal to a predetermined threshold for the number of charts required.

[0010] Using a multimodal large language model, chart understanding instruction data is constructed based on chart images in the updated original chart dataset to train the model's chart understanding ability.

[0011] Optionally, a separate original chart dataset can be built for each chart type, including:

[0012] For any given chart type, retrieve multiple chart images belonging to that chart type;

[0013] Based on the difficulty of understanding each chart image, multiple chart images are divided into multiple chart image sets;

[0014] A predetermined number of chart images are extracted from each chart image set to form the original chart dataset.

[0015] Optionally, for any given original chart dataset, a separate code program is built for each chart image in the original chart dataset to generate the chart image, including:

[0016] For any given original chart dataset, a multimodal large language model is used to generate a separate code program for drawing the chart image for each chart image in the original chart dataset.

[0017] The code program must include at least the text, data points, styles, and drawing tools required to create the chart image.

[0018] Optionally, each code program is modified and amplified, and new charts and images are generated based on the modified and amplified code programs, including:

[0019] For any given code program, the text, data points, or styles included in the code program are modified using a large language model to obtain multiple modified and expanded code programs.

[0020] For any modified amplification code program, execute the modified amplification code program. If the execution is successful, the generated chart image will be used as the new chart image; if the execution fails, the modified amplification code program will be discarded.

[0021] Optionally, using a multimodal large language model, chart understanding instruction data is constructed based on the chart images in the updated original chart dataset to train the model's chart understanding ability, including:

[0022] For any chart image in the updated original chart dataset, key information is extracted and interpreted using a multimodal large language model.

[0023] Based on the chart images, extracted key information, and interpretation results, construct chart comprehension instruction data.

[0024] Optionally, the method also includes:

[0025] By understanding instruction data through graphs, a newly constructed lightweight model or an existing model lacking graph understanding capabilities can be trained to obtain a model for performing graph understanding tasks.

[0026] According to another aspect of the present invention, a data construction apparatus is provided, comprising:

[0027] The dataset construction module is used to obtain multiple pre-determined chart types and construct an original chart dataset for each chart type; wherein each original chart dataset includes the same number of chart images;

[0028] The code generation module is used to build a code program to generate chart images for each chart image in any original chart dataset.

[0029] The amplification module is used to modify and amplify each code program, and generate new charts and images based on the modified and amplified code program;

[0030] The dataset update module is used to update the original chart dataset based on the new chart images, so that the number of chart images in the updated original chart dataset is equal to the predetermined chart quantity requirement threshold.

[0031] The data generation module is used to construct chart understanding instruction data for training the model's chart understanding ability based on the chart images in the updated original chart dataset using a multimodal large language model.

[0032] Optionally, the dataset building module is specifically used for:

[0033] For any given chart type, retrieve multiple chart images belonging to that chart type;

[0034] Based on the difficulty of understanding each chart image, multiple chart images are divided into multiple chart image sets;

[0035] A predetermined number of chart images are extracted from each chart image set to form the original chart dataset.

[0036] Optionally, the code generation module is specifically used for:

[0037] For any given original chart dataset, a multimodal large language model is used to generate a separate code program for drawing the chart image for each chart image in the original chart dataset.

[0038] The code program must include at least the text, data points, styles, and drawing tools required to create the chart image.

[0039] Optionally, the amplification module is specifically used for:

[0040] For any given code program, the text, data points, or styles included in the code program are modified using a large language model to obtain multiple modified and expanded code programs.

[0041] For any modified amplification code program, execute the modified amplification code program. If the execution is successful, the generated chart image will be used as the new chart image; if the execution fails, the modified amplification code program will be discarded.

[0042] Optionally, the data generation module is specifically used for:

[0043] For any chart image in the updated original chart dataset, key information is extracted and interpreted using a multimodal large language model.

[0044] Based on the chart images, extracted key information, and interpretation results, construct chart comprehension instruction data.

[0045] Optionally, the data construction apparatus also includes:

[0046] The training module is used to train newly built lightweight models or existing models that lack chart understanding capabilities by understanding instruction data through charts, so as to obtain models that can perform chart understanding tasks.

[0047] According to another aspect of the present invention, an electronic device is provided, the electronic device comprising:

[0048] At least one processor; and

[0049] A memory that is communicatively connected to at least one processor; wherein,

[0050] The memory stores a computer program that can be executed by at least one processor, such that the at least one processor is able to perform the data construction method of the embodiments of the present invention.

[0051] According to another aspect of the present invention, a computer-readable storage medium is provided, which stores computer instructions for causing a processor to execute and implement the data construction method of the embodiments of the present invention.

[0052] According to another aspect of the present invention, a computer program product is provided, comprising a computer program that, when executed by a processor, implements the steps in the above-described method.

[0053] The technical solution of this invention involves acquiring a small number of chart images to form an original chart dataset for each chart type. For each chart type's original chart dataset, a separate code program is built for each chart image in the original dataset to generate that image. This code expansion generates a large number of new chart images, which are then added to the original chart data, solving the problem of a limited number of chart images on the internet. Furthermore, each supplemented original chart dataset contains the same number of chart images, ensuring a balanced number of chart images across different types. Based on this, a multimodal large language model can generate large-scale and balanced chart understanding instruction data based on various chart images, improving the efficiency of chart understanding instruction data generation compared to manual annotation.

[0054] It should be understood that the description in this section is not intended to identify key or essential features of the embodiments of the present invention, nor is it intended to limit the scope of the invention. Other features of the invention will become readily apparent from the following description. Attached Figure Description

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

[0056] Figure 1 This is a flowchart illustrating a data construction method provided in an embodiment of the present invention;

[0057] Figure 2 This is a flowchart illustrating another data construction method provided in an embodiment of the present invention;

[0058] Figure 3 This is a schematic diagram of the structure of a data construction device provided in an embodiment of the present invention;

[0059] Figure 4 This is a schematic diagram of the structure of an electronic device that implements the data construction method of the present invention. Detailed Implementation

[0060] To enable those skilled in the art to better understand the present invention, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of the present invention.

[0061] Example 1

[0062] Figure 1 This is a flowchart of a data construction method provided in an embodiment of the present invention. This embodiment can be applied to scenarios of constructing chart understanding instruction data for training a model's chart understanding ability. The method can be executed by a data construction device, which can be implemented in hardware and / or software and can be configured in an electronic device.

[0063] like Figure 1 As shown, the data construction method includes:

[0064] S101. Obtain multiple pre-determined chart types and construct an original chart dataset for each chart type.

[0065] In this embodiment of the invention, the chart type includes at least one of the following: bar chart, column chart, line chart, pie chart, scatter plot, box plot, radar chart, and table. The chart type can be determined by the user according to actual needs, and the user-determined chart types can be obtained through human-computer interaction.

[0066] In this embodiment of the invention, an original chart dataset is constructed for each chart type, including: First, determining the data source of the chart images; wherein, the data source may include public dataset websites, search engines, and professional domain databases. Further, for any chart type, a preset number of chart images belonging to that chart type are obtained from at least one data source, wherein the preset number can be a small value set in advance, for example, a preset number of 9. It should be noted that the reason for setting the preset number to a small value is to consider that the number of chart images of each chart type at the data source may be uneven; setting it too large may result in insufficient chart images for some chart types. Further, based on the obtained chart images of each chart type, an original chart dataset is constructed for each; wherein, each original chart dataset includes the same number of chart images, thus ensuring a balanced number of chart images in each original chart dataset. It should be noted that the various chart images involved in this invention are image data fully authorized by all parties (e.g., image authors or owners), and the collection, storage, use, processing, transmission, provision, publication, and application of the relevant chart images all comply with the relevant laws, regulations, and standards of the relevant countries and regions, and necessary confidentiality measures have been taken, without violating public order and good morals.

[0067] S102. For any original chart dataset, construct a code program to generate a chart image for each chart image in the original chart dataset.

[0068] In this embodiment of the invention, for any original chart dataset, a multimodal large language model is used to generate a code program for drawing each chart image in the original chart dataset. Here, the multimodal large language model refers to a large, high-performance model with chart understanding capabilities. Specifically, for any original chart dataset corresponding to any chart type, the chart images of the original chart dataset are used as input to the multimodal large language model, which is then instructed to generate a code program capable of constructing the chart image based on the input chart image. The code program can be constructed using the Python language and includes at least the text, data points, chart style, and drawing tools required for drawing the chart image identified by the multimodal large language model from the chart image. It is understood that the text can be the chart title, legend, annotations, etc., present in the chart image; the data points can be the numerical points in the chart image, such as the horizontal and vertical coordinates corresponding to each vertices in a line chart; and the chart style can include chart color, shape, line thickness, font format, etc.

[0069] S103. Modify and amplify each code program, and generate new charts and images based on the modified and amplified code programs.

[0070] In one optional implementation, for any given code program, the text, data points, or chart styles included in the code program are modified using a large language model, resulting in multiple modified and expanded code programs. For example, a generic code modification instruction is constructed; for each code program used to draw chart images, this code program and the generic code modification instruction are input into the large language model. Based on the output of the large language model, a code program capable of drawing new chart images is obtained. The generic code modification instruction can be, for example,: "This code's function is to draw charts. Your task is to modify the text, data points, and chart styles in the code. You can modify all text content in the chart, the values ​​and distribution of data points, and the chart's color, thickness, direction, etc. Please note that the modified content should be logically consistent overall; for example, the numerical range and chart format should match the theme expressed in the text."

[0071] By modifying and expanding the code program corresponding to each chart image in the above manner, numerous new code programs capable of drawing chart images can be obtained. It should be noted that the number of new code programs obtained can be greater than or equal to the user-defined threshold. For any modified and expanded code program, execute it. If execution is successful, the generated chart image is used as the new chart image; if execution fails, the modified and expanded code program is discarded. In this way, through the above process, each chart type can obtain numerous chart images, thus avoiding the problem of insufficient chart images from the data source.

[0072] It should be noted that if a multimodal large language model is used for code modification and amplification, the input can include not only the code and modification instructions, but also the corresponding charts and images.

[0073] S104. Update the original chart dataset based on the new chart images, so that the number of chart images in the updated original chart dataset is equal to the predetermined chart quantity requirement threshold.

[0074] In this embodiment of the invention, for any chart type, new chart images belonging to that type are sequentially added to the original chart dataset corresponding to that chart type until the number of chart images in the original chart dataset equals a predetermined threshold for the number of charts required. Through this operation, the updated original chart dataset for each chart type includes the same number of chart images, achieving a balanced number of images for each chart type, thereby ensuring a balanced distribution of chart interpretation instruction data for different chart types generated subsequently.

[0075] S105. Using a multimodal large language model, construct chart understanding instruction data for training the model's chart understanding ability based on the chart images in the updated original chart dataset.

[0076] In this embodiment of the invention, for any chart image in the updated original chart dataset, key information is extracted and interpreted from the chart image using a multimodal large language model; based on the chart image, the extracted key information, and the interpretation results, chart understanding instruction data is constructed.

[0077] In this embodiment of the invention, for each chart type, a small number of chart images are obtained to form an original chart dataset. For each chart type's original chart dataset, a code program is constructed for each chart image in the original chart dataset to generate that chart image. Then, through code expansion, a large number of new chart images are generated and added to the original chart data, solving the problem of the limited number of chart images on the Internet. Moreover, the number of chart images included in each of the supplemented original chart datasets is the same, ensuring a balanced number of chart images of each type. Based on this, a multimodal large language model can generate large-scale and categorized balanced chart understanding instruction data according to various types of chart images, and compared with manual annotation, the efficiency of generating chart understanding instruction data is improved.

[0078] Example 2

[0079] Figure 2 A flowchart of a data construction method is provided for an embodiment of the present invention. See also... Figure 2 The method includes the following steps:

[0080] S201. Obtain multiple pre-determined chart types, and for any given chart type, obtain multiple chart images belonging to that chart type.

[0081] For example, for any chart type, multiple chart images belonging to that chart type are obtained from at least one predetermined data source (e.g., public dataset websites, search engines, professional databases).

[0082] S202. Based on the difficulty of understanding each chart image, divide the multiple chart images into multiple chart image sets.

[0083] In this embodiment of the invention, the process of determining the comprehension difficulty of each chart image includes: First, for any chart image, determining the comprehension difficulty assessment index; wherein, the comprehension difficulty assessment index includes the number of data points in the chart image, the diversity of data types, the complexity of the chart structure, the clarity of the title, the rationality of color matching, the clarity of element layout, etc.; based on the determined comprehension difficulty assessment index value and the pre-specified classification standard, determining the comprehension difficulty of each chart image. For example, if the number of data points in a chart image is greater than a first threshold (e.g., 50), then the comprehension difficulty level of the chart image is considered high; if the number of data points in a chart image is greater than a second threshold (e.g., 20) and less than the first threshold (e.g., 50), then the comprehension difficulty level of the chart image is considered medium; if the number of data points in a chart image is less than the second threshold (e.g., 20), then the comprehension difficulty level of the chart image is considered low.

[0084] Based on the above, the charts are divided into multiple sets according to their level of comprehension difficulty. The charts in each set have different levels of comprehension difficulty. For example, charts with low comprehension difficulty are grouped into one set, those with medium comprehension difficulty into another set, and those with high comprehension difficulty into a third set.

[0085] S203. Extract a preset number of chart images from each chart image set to form the original chart dataset.

[0086] Optionally, an equal number of chart images can be extracted from each chart image set to form the original chart dataset. For example, three images can be extracted from each of the different chart image sets to form the original chart dataset. It is understood that because the original chart dataset includes chart images of varying difficulty levels, the final constructed chart understanding instruction data also includes chart images of varying difficulty levels. Therefore, when training the model using this chart understanding instruction data, the model can better handle chart understanding tasks in various real-world scenarios, improving its generalization ability and enabling it to perform well when faced with new charts of varying difficulty.

[0087] S204. For any given original chart dataset, construct a separate code program to generate a chart image for each chart image in the original chart dataset.

[0088] Optionally, for any original chart dataset, a code program for drawing each chart image in the original chart dataset is generated using a multimodal large language model; wherein the code program includes at least the text, data points, styles, and drawing tools required to draw the chart image.

[0089] S205. Modify and amplify each code program, and generate new charts and images based on the modified and amplified code programs.

[0090] Optionally, for any given code program, the text, data points, or styles included in the code program can be modified using a large language model to obtain multiple modified and amplified code programs. For any modified and amplified code program, the modified and amplified code program can be executed. If the execution is successful, the generated chart image is used as the new chart image; if the execution fails, the modified and amplified code program is discarded.

[0091] S206. Update the original chart dataset based on the new chart images, so that the number of chart images in the updated original chart dataset is equal to the predetermined chart quantity requirement threshold.

[0092] S207. Using a multimodal large language model, construct chart understanding instruction data for training the model's chart understanding ability based on the chart images in the updated original chart dataset.

[0093] The implementation process of steps S206-S207 can be found in the description of the above embodiments.

[0094] S208. By understanding the instruction data through charts, train the newly constructed lightweight model or the existing model that lacks chart understanding capabilities to obtain a model for performing chart understanding tasks.

[0095] In this embodiment of the invention, after obtaining the chart understanding instruction data through steps S201-S207, the chart understanding instruction data can be used as training samples to train the newly constructed lightweight model or the existing model that lacks chart understanding capabilities, thereby obtaining a model for performing chart understanding tasks; wherein, the lightweight model can be a model that can be deployed on a mobile terminal.

[0096] In this embodiment of the invention, an original chart dataset is composed of chart images with different levels of comprehension difficulty. After the lightweight model or existing model is tested with chart comprehension instruction data generated based on chart images with different levels of comprehension difficulty, the lightweight model or existing model can better cope with chart comprehension tasks in various real-world scenarios, improve the model's generalization ability, and enable it to perform well when faced with new charts of different difficulties.

[0097] Example 3

[0098] Figure 3 This is a schematic diagram of a data construction apparatus provided in an embodiment of the present invention. This embodiment is applicable to scenarios involving the construction of chart understanding instruction data for training a model's chart understanding capabilities. Figure 3 As shown, the data construction apparatus includes:

[0099] The dataset construction module 301 is used to obtain multiple predetermined chart types and construct an original chart dataset for each chart type; wherein, each original chart dataset includes the same number of chart images;

[0100] The code generation module 302 is used to build a code program for generating chart images for each chart image in any original chart dataset.

[0101] The amplification module 303 is used to modify and amplify each code program, and generate new chart images based on the modified and amplified code program;

[0102] The dataset update module 304 is used to update the original chart dataset based on the new chart images, so that the number of chart images in the updated original chart dataset is equal to the predetermined chart number requirement threshold.

[0103] The data generation module 305 is used to construct chart understanding instruction data for training the model's chart understanding ability based on the chart images in the updated original chart dataset using a multimodal large language model.

[0104] Optionally, the dataset construction module 301 is specifically used for:

[0105] For any given chart type, retrieve multiple chart images belonging to that chart type;

[0106] Based on the difficulty of understanding each chart image, multiple chart images are divided into multiple chart image sets;

[0107] A predetermined number of chart images are extracted from each chart image set to form the original chart dataset.

[0108] Optionally, the code generation module 302 is specifically used for:

[0109] For any given original chart dataset, a multimodal large language model is used to generate a separate code program for drawing the chart image for each chart image in the original chart dataset.

[0110] The code program must include at least the text, data points, styles, and drawing tools required to create the chart image.

[0111] Optionally, the amplification module 303 is specifically used for:

[0112] For any given code program, the text, data points, or styles included in the code program are modified using a large language model to obtain multiple modified and expanded code programs.

[0113] For any modified amplification code program, execute the modified amplification code program. If the execution is successful, the generated chart image will be used as the new chart image; if the execution fails, the modified amplification code program will be discarded.

[0114] Optionally, the data generation module 305 is specifically used for:

[0115] For any chart image in the updated original chart dataset, key information is extracted and interpreted using a multimodal large language model.

[0116] Based on the chart images, extracted key information, and interpretation results, construct chart comprehension instruction data.

[0117] Optionally, the data construction apparatus also includes:

[0118] The training module is used to train newly built lightweight models or existing models that lack chart understanding capabilities by understanding instruction data through charts, so as to obtain models that can perform chart understanding tasks.

[0119] The data construction apparatus provided in the embodiments of the present invention can execute the data construction method provided in any embodiment of the present invention, and has the corresponding functional modules and beneficial effects of the execution method.

[0120] According to embodiments of the present invention, the present invention also provides an electronic device, a readable storage medium, and a computer program product.

[0121] Example 4

[0122] Figure 4 A schematic diagram of the structure of an electronic device 10 that can be used to implement embodiments of the present invention is shown. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the invention described and / or claimed herein.

[0123] like Figure 4 As shown, the electronic device 10 includes at least one processor 11 and a memory, such as a read-only memory (ROM) 12 or a random access memory (RAM) 13, communicatively connected to the at least one processor 11. The memory stores computer programs executable by the at least one processor. The processor 11 can perform various appropriate actions and processes based on the computer program stored in the ROM 12 or loaded from storage unit 18 into the RAM 13. The RAM 13 may also store various programs and data required for the operation of the electronic device 10. The processor 11, ROM 12, and RAM 13 are interconnected via a bus 14. An input / output (I / O) interface 15 is also connected to the bus 14.

[0124] Multiple components in electronic device 10 are connected to I / O interface 15, including: input unit 16; output unit 17, such as various types of displays, speakers, etc.; storage unit 18, such as disks, optical disks, etc.; and communication unit 19, such as network cards, modems, wireless transceivers, etc. Communication unit 19 allows electronic device 10 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks.

[0125] Processor 11 can be a variety of general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of processor 11 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. Processor 11 performs the various methods and processes described above, such as performing data construction methods.

[0126] In some embodiments, the data construction method may be implemented as a computer program tangibly contained in a computer-readable storage medium, such as storage unit 18. In some embodiments, part or all of the computer program may be loaded and / or installed on electronic device 10 via ROM 12 and / or communication unit 19. When the computer program is loaded into RAM 13 and executed by processor 11, one or more steps of the data construction method described above may be performed. Alternatively, in other embodiments, processor 11 may be configured to execute the data construction method by any other suitable means (e.g., by means of firmware).

[0127] Various embodiments of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems-on-a-chip (SoCs), complex programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include implementations in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a dedicated or general-purpose programmable processor, capable of receiving data and instructions from a storage system, at least one input device, and at least one output device, and transmitting data and instructions to the storage system, the at least one input device, and the at least one output device.

[0128] Computer programs used to implement the methods of the present invention can be written in any combination of one or more programming languages. These computer programs can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data construction apparatus, such that when executed by the processor, the computer programs cause the functions / operations specified in the flowcharts and / or block diagrams to be implemented. The computer programs can be executed entirely on a machine, partially on a machine, as a standalone software package partially on a machine and partially on a remote machine, or entirely on a remote machine or server.

[0129] In the context of this invention, a computer-readable storage medium can be a tangible medium that may contain or store a computer program for use by or in conjunction with an instruction execution system, apparatus, or device. A computer-readable storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination thereof. Alternatively, a computer-readable storage medium may be a machine-readable signal medium. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fibers, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof.

[0130] To provide interaction with a user, the systems and techniques described herein can be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user provides input to the electronic device. Other types of devices can also be used to provide interaction with the user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including sound input, voice input, or tactile input).

[0131] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as data servers), or computing systems that include middleware components (e.g., application servers), or computing systems that include frontend components (e.g., user computers with graphical user interfaces or web browsers through which users can interact with implementations of the systems and technologies described herein), or any combination of such backend, middleware, or frontend components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., communication networks). Examples of communication networks include local area networks (LANs), wide area networks (WANs), blockchain networks, and the Internet.

[0132] A computing system can include clients and servers. Clients and servers are generally located far apart and typically interact through communication networks. The client-server relationship is created by computer programs running on the respective computers and having a client-server relationship with each other. The server can be a cloud server, also known as a cloud computing server or cloud host, which is a hosting product within the cloud computing service system to address the shortcomings of traditional physical hosts and VPS services, such as high management difficulty and weak business scalability.

[0133] It should be understood that the various forms of processes shown above can be used, with steps reordered, added, or deleted. For example, the steps described in this invention can be executed in parallel, sequentially, or in different orders, as long as the desired result of the technical solution of this invention can be achieved, and this is not limited herein.

[0134] The specific embodiments described above do not constitute a limitation on the scope of protection of this invention. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this invention should be included within the scope of protection of this invention.

Claims

1. A data construction method, characterized in that, include: A plurality of pre-determined chart types are obtained, and an original chart dataset is constructed for each chart type. Constructing an original chart dataset for each chart type includes: for any given chart type, obtaining multiple chart images belonging to that chart type; for any given chart image, determining a difficulty assessment metric; the difficulty assessment metric includes the number of data points in the chart image, data type diversity, chart structure complexity, title clarity, color scheme rationality, and element layout clarity; determining the difficulty of understanding each chart image based on the determined difficulty assessment metric value and a pre-specified division standard; dividing the plurality of chart images into multiple chart image sets based on the difficulty of understanding each chart image; and extracting a predetermined number of chart images from each chart image set to form the original chart dataset; wherein each original chart dataset includes the same number of chart images. For any of the original chart datasets, a code program for generating the chart image is constructed for each chart image in the original chart dataset using a multimodal large language model; wherein the code program is constructed based on the Python language; wherein the code program includes at least the text, data points, styles contained in the chart image, and drawing tools required to draw the chart image; For any of the aforementioned code programs, the text, data points, or styles included in the code program are modified using a large language model and general code modification instructions to obtain multiple modified and amplified code programs; for any of the aforementioned modified and amplified code programs, the modified and amplified code program is executed; if the execution is successful, the generated chart image is used as the new chart image; if the execution fails, the modified and amplified code program is discarded. The original chart dataset is updated based on the new chart images, such that the number of chart images in the updated original chart dataset is equal to a predetermined threshold for the number of charts required. Using a multimodal large language model, chart understanding instruction data is constructed based on the chart images in the updated original chart dataset to train the model's chart understanding ability.

2. The method according to claim 1, characterized in that, The process involves constructing chart understanding instruction data for training the model's chart understanding ability using a multimodal large language model, based on chart images in the updated original chart dataset. This includes: For any chart image in the updated original chart dataset, key information is extracted and interpreted using a multimodal large language model. Based on the chart image, the extracted key information, and the interpretation results, construct the chart understanding instruction data.

3. The method according to claim 1, characterized in that, The method further includes: By understanding instruction data through graphs, a newly constructed lightweight model or an existing model lacking graph understanding capabilities can be trained to obtain a model for performing graph understanding tasks.

4. A data construction apparatus, characterized in that, include: A dataset construction module is used to acquire multiple predetermined chart types and construct an original chart dataset for each chart type. Constructing an original chart dataset for each chart type includes: acquiring multiple chart images belonging to any given chart type; determining a comprehension difficulty assessment index for any given chart image; the comprehension difficulty assessment index includes the number of data points in the chart image, data type diversity, chart structure complexity, title clarity, color matching rationality, and element layout clarity; determining the comprehension difficulty of each chart image based on the determined comprehension difficulty assessment index value and a pre-specified division standard; dividing the multiple chart images into multiple chart image sets based on the comprehension difficulty of each chart image; and extracting a predetermined number of chart images from each chart image set to form the original chart dataset; wherein each original chart dataset includes the same number of chart images. The code generation module is used to construct a code program for generating each chart image in any of the original chart datasets using a multimodal large language model; wherein the code program is constructed based on the Python language; the code program includes at least the text, data points, styles contained in the chart image, and drawing tools required to draw the chart image; The augmentation module is used to modify the text, data points, or styles of any of the code programs using a large language model and general code modification instructions, resulting in multiple modified and augmented code programs. For any of the modified and augmented code programs, the module executes the modified and augmented code program. If the execution is successful, the generated chart image is used as the new chart image. If the execution fails, the modified and augmented code program is discarded. The dataset update module is used to update the original chart dataset according to the new chart images, so that the number of chart images in the updated original chart dataset is equal to a predetermined chart quantity requirement threshold. The data generation module is used to construct chart understanding instruction data for training the model's chart understanding ability based on the chart images in the updated original chart dataset using a multimodal large language model.

5. 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 a computer program that can be executed by the at least one processor to enable the at least one processor to perform the method of any one of claims 1-3.

6. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions that are used to cause a processor to execute the method of any one of claims 1-3.

7. A computer program product comprising a computer program that, when executed by a processor, implements the method according to any one of claims 1-3.

Citation Information

Patent Citations

  • Multi-modal large language model training method and system based on multi-modal encoder

    CN117218498A

  • Data and sample construction method and device, large model fine tuning method and device and chart analysis method and device

    CN118799897A

  • Semiconductor data analysis and visualization method and device based on large model

    CN119149708A