Laser cladding knowledge base construction method based on large model

By building a large model-based laser cladding knowledge base, the problem of parameter optimization and knowledge update lag in traditional laser cladding technology is solved, and high-precision parameter recommendation and defect detection are automated, which improves the intelligence and real-time nature of the system.

CN120373435APending Publication Date: 2025-07-25SOUTHEAST UNIV

Patent Information

Application Number
CN202510435321.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-08
Publication Date
2025-07-25

AI Technical Summary

Technical Problem

Traditional laser cladding technology has complex nonlinear relationships in parameter optimization and knowledge acquisition, empirical formulas are difficult to meet high-precision requirements, knowledge updates are lagging, causal reasoning capabilities are lacking, and defect detection relies on artificial efficiency and strong subjectivity.

Method used

Build a laser cladding knowledge base based on large models, and realize causal reasoning and dynamic updates through multimodal data processing and structured transformation, combining knowledge graphs and large model fine-tuning, and integrate the YOLO model for defect identification.

Benefits of technology

It realizes intelligent recommendation and efficient update of laser cladding parameters, improves the integrity and scalability of the knowledge base, improves the automation level of defect detection, and provides end-to-end integrated services.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120373435A_ABST
    Figure CN120373435A_ABST
Patent Text Reader

Abstract

The invention belongs to the crossing field of artificial intelligence and laser cladding technologies, and particularly discloses a laser cladding knowledge base construction method based on a large model. According to the method, laser cladding knowledge dispersed in patent, literature and enterprise process parameter tables is collected by means of a multi-modal data processing technology, and unstructured data is converted into structured JSON format data by means of technologies such as HTML conversion, OCR recognition and YOLO defect detection. A constructed training set comprises mapping relations among application objects, effect labels and technical features, and a large model has a certain causal reasoning ability through QLoRA adapter injection and a three-stage fine tuning strategy. The system continuously updates the knowledge base through a dynamic optimization mechanism, and realizes the functions of intelligent recommendation of process parameters, defect image recognition, technical trend analysis and the like. Compared with a traditional method, a multi-modal knowledge base is constructed, and deep association and intelligent reasoning of domain knowledge are achieved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of laser cladding big data in artificial intelligence, and particularly relates to a system and method for constructing a laser cladding knowledge base based on large model fine-tuning. Background Art

[0002] As an advanced surface engineering technology, laser cladding technology realizes material surface modification and repair through high-energy laser beams, and is widely used in high-end manufacturing, energy equipment, aerospace and other fields. This process involves a multi-physical field coupling process, and there is a complex non-linear relationship between key parameters such as laser power and scanning speed and the quality indicators of the cladding layer. Traditional parameter optimization methods based on empirical formulas are difficult to meet the requirements of modern industry for high precision and high reliability.

[0003] In terms of knowledge acquisition, the number of newly added patents in the global laser cladding field is large every year, and most of the knowledge exists in unstructured forms in patent texts, experimental reports and enterprise technical manuals. Traditional retrieval methods are difficult to effectively extract knowledge associations; at the intelligent decision-making level, existing systems rely on expert experience databases and lack causal reasoning capabilities; in the dynamic update link, due to the long diffusion cycle of new technologies, the traditional database update mechanism leads to a significant time difference in enterprise technology applications. In view of the above technical pain points, the present invention proposes a knowledge engineering solution based on large models, and realizes in-depth association and intelligent reasoning of domain knowledge by constructing a multi-modal knowledge base, breaking through the limitations of traditional methods. Summary of the Invention

[0004] Object of the Invention: In order to solve the problems existing in the above background art, the present invention provides a method for constructing a laser cladding knowledge base based on a large model.

[0005] In order to achieve the above object, the present invention adopts the following technical solutions: A method for constructing a laser cladding knowledge base based on a large model, comprising the following steps:

[0006] Step 1: Collect data from data sources related to laser cladding and preprocess the data. After preprocessing, the data includes text data, table data, and picture data, and different data adopts different processing strategies;

[0007] Step 2: Construct a training set according to the structured database composed of multi-source data sources, and classify and identify workpiece defect pictures in the picture processing module;

[0008] Step 3: Fine-tune the large model, including model initialization, adapter injection, and training execution. The training data is a training set containing the mapping relationship between application objects, effect annotations and technical features, so that the large model masters certain causal reasoning capabilities;

[0009] Step 4: Repeat Steps 1 to 3 to dynamically update the database to build a training set. When the new training set accumulates to a certain number, fine-tune the large model. The large model has the functions of semantic retrieval, relationship reasoning, and image defect recognition until the knowledge base of the built large model can meet the user's question requirements.

[0010] Further, in Step 1, data is collected from laser cladding-related data sources and preprocessed; the preprocessed data includes text data, table data, and image data; different data adopts different processing strategies; the specific implementation is as follows:

[0011] (11) The multi-modal data in the laser cladding field is obtained through multi-source collection, including collecting public patent data and collecting the original literature PDF / Word / PPT documents related to laser cladding in the literature database; collecting the original table Excel data from the process parameter tables of laser cladding processing enterprises.

[0012] (12) The data is preprocessed, including uniformly converting the laser cladding Word / PDF / PPT / Excel document data collected from multiple sources into HTML format, and separating text data, image data, and table data from the HTML.

[0013] (13) Different data adopts different processing strategies, including converting text data and table data into structured data, inputting the defective workpiece images in the image data into the image processing module, and converting the text and table screenshot image data into structured data for storage.

[0014] (14) The structured data storage includes the JSON dataset format as

[0015]

[0016] Further, in Step 2, the training set construction module constructs a training set based on the structured database composed of multi-source data sources, and classifies and identifies the defective workpiece images in the image processing module. The specific implementation is as follows:

[0017] (21) The training set construction module includes a data parsing and standardization sub-module, a dialogue sample generation sub-module, a quality verification and control sub-module, and a dynamic optimization sub-module. The data parsing and standardization sub-module converts multi-source heterogeneous laser cladding structured data into a unified knowledge representation, including a knowledge triple mapping unit and a missing value reasoning unit; the dialogue sample generation sub-module converts the standardized structured data into dialogue format training samples that meet the requirements of large model fine-tuning, including a question generation unit, an answer construction unit, and a diversity enhancement unit; the quality verification and control sub-module ensures that the generated training samples comply with technical specifications and domain knowledge constraints, including a format inspection unit and a semantic integrity detection unit; the dynamic optimization sub-module realizes the continuous iteration and adaptive optimization of the knowledge base, constructs a user feedback index system, and optimizes the answer results.

[0018] (22) The knowledge triple mapping unit and the missing value reasoning unit are included in the data parsing and standardization sub-module. Specifically, the knowledge triple mapping unit establishes a mapping rule library from JSON fields to knowledge triples, and the missing value reasoning unit fills in default values based on the material knowledge graph.

[0019] (23) The question generation unit, the answer construction unit, and the diversity enhancement unit are included in the dialogue sample generation sub-module. Specifically, the question generation unit generates different questions by setting a multi-mode question template library, the answer construction unit structures the answer template of "application object - application reason - parameter design", and the diversity enhancement unit establishes a domain synonym library ""laser power"":["laser energy output","beam power"], "cladding speed"":["scanning rate","processing moving speed"]";

[0020] (24) The format inspection unit and the semantic integrity detection unit are included in the quality verification and control sub-module. Specifically, the format inspection unit checks whether the generated training set conforms to the following format, and the semantic integrity detection unit detects the relevance of laser parameters in the statement.

[0021]

[0022]

[0023] (25) The image processing module consists of the following sub-modules, including: a front-end interaction sub-module, a preprocessing sub-module, a defect detection sub-module, a data conversion sub-module, and a transmission interface sub-module; the front-end interaction sub-module is used to receive the workpiece images uploaded by the user (supporting JPG / PNG formats) and transmit them to the back-end processing system; the preprocessing sub-module normalizes the image size (adjusted to 640×640 pixels), corrects the grayscale, and filters the noise to ensure that the input data meets the model requirements of the defect detection sub-module; the defect detection sub-module locates and classifies the weld defects based on the YOLO model and outputs the structured detection results. The data conversion sub-module: converts the defect information into a standardized format (JSON) that can be parsed by the large model; the transmission interface sub-module: pushes the data to the large model interaction through the RESTful API or message queue (such as RabbitMQ).

[0024] Further, in step 3, fine-tuning the large model includes model initialization, adapter injection, and training execution. The training data is a training set containing the mapping relationship between application objects, effect annotations, and technical features, enabling the large model to master causal reasoning capabilities. The specific implementation is as follows:

[0025] (31) The model initialization includes loading the base large model (Llama-3-8B) and injecting a term-enhanced tokenizer for the laser cladding field. The injection of the term-enhanced tokenizer for the laser cladding field performs tokenization on the stored structured data, including loading the basic vocabulary of the original tokenizer of the large model, detecting domain keywords in the structured data (such as "cladding layer", "coaxial powder feeding", etc.), and if the keywords are hit, dynamically loading the extended vocabulary and preferentially segmenting according to domain terms.

[0026] (32) The adapter injection includes injecting the QloRA adapter at the key layer and setting the low-quality dimension and scaling factor to keep the adapter matrix stable.

[0027] (33) The training execution link of the large model based on the training set includes the configuration of key parameters. The training key parameters include the learning rate, batch size, number of training rounds, and sequence length, which are selected based on the deployment configuration. The training execution link includes fine-tuning based on the Chinese dialogue training set to enable the large model to have the ability of Chinese dialogue, and fine-tuning the large model based on the constructed laser cladding training set to enable the large model to have retrieval and causal reasoning capabilities.

[0028] Further, in step 4, repeat steps 1 to 3 to dynamically update the database and fine-tune the large model with the training set. The large model has semantic retrieval, relationship reasoning, and image defect recognition functions until the constructed large model knowledge base can meet the user's question requirements. The specific implementation is as follows:

[0029] (41) The semantic retrieval and relationship reasoning functions include similarity matching and reasoning.

[0030] (42) The image defect recognition function includes identifying defects in the input workpiece image and outputting the recognition results to the large model.

[0031] (43) The large model knowledge base meets user needs and performs accuracy, integrity and stability assessments on its output results.

[0032] Compared with the prior art, the advantages of the present invention are as follows:

[0033] (1) Multimodal data fusion and structured processing capabilities. This invention uses multimodal data processing technology (HTML conversion, OCR recognition, YOLO defect detection) to uniformly convert unstructured data such as patent texts, process tables and defect images in the field of laser cladding into a structured JSON format, solving the problems of data dispersion and format incompatibility in traditional methods. Combined with the knowledge graph to complete missing values (such as deriving powder feeding rate based on material properties), the integrity and scalability of the knowledge base are significantly improved, supporting the efficient parsing and association of subsequent large models.

[0034] (2) Large model fine-tuning and causal reasoning capabilities. The QLoRA adapter injection and three-stage fine-tuning strategy (pre-training → knowledge transfer → causal reasoning enhancement) are used to inject laser cladding domain knowledge (such as the complex nonlinear relationship between "laser power" and "cladding speed") while retaining the general capabilities of the large model, so that it has causal reasoning capabilities (such as deriving parameter recommended values).

[0035] (3) Dynamic optimization and real-time update mechanism. The traditional knowledge base has a long update cycle and the application of new technologies lags behind. Through the online learning framework and incremental training set, combined with user feedback indicators, the system can dynamically update the knowledge base. When the new process data accumulates to the threshold, it automatically triggers lightweight fine-tuning to ensure the timeliness of the knowledge base. Compared with traditional manual updates, the new technology diffusion cycle is shortened, solving the problem of lagging traditional database updates.

[0036] (4) Intelligent integration of image defect recognition. Existing systems mostly rely on manual defect detection, which is inefficient and highly subjective. The present invention integrates the YOLO model to automatically locate and classify workpiece defect images (such as cracks and pores), and outputs structured detection results (JSON format) to interact directly with the large model.

[0037] (5) End-to-end integrated system architecture. Existing solutions are mostly limited to a single function (such as retrieval or detection). The present invention realizes an integrated service of process parameter recommendation, defect identification, and technology trend analysis through modular design (data collection → processing → training → application). For example, users can query parameters and upload defect images at the same time through the dialogue interface, and the system will output a comprehensive solution in a linked manner. Brief Description of the Drawings

[0038] Figure 1 It is a schematic diagram of the process for constructing a laser cladding knowledge base based on a large model of the present invention;

[0039] Figure 2 It is a schematic diagram of the collection, processing, and storage of multi-source data sources;

[0040] Figure 3 It is a flow chart for the formation of a training set and fine-tuning of a large model;

[0041] Figure 4 It is a schematic diagram of the large model knowledge base for user applications. Detailed Description of the Invention

[0042] The present invention will be described in detail below with reference to specific embodiments. The following embodiments will help those skilled in the art to further understand the present invention, but do not limit the present invention in any form.

[0043] Embodiment:

[0044] As Figure 1 shown, a method for constructing a laser cladding knowledge base based on a large model includes the following steps:

[0045] (1) Collect data from laser cladding-related data sources and preprocess the data; the preprocessed data includes text data, table data, and picture data; different data adopts different processing strategies;

[0046] (2) The training set construction module constructs a training set based on the structured database composed of multi-source data sources, and classifies and identifies workpiece defect pictures in the picture processing module;

[0047] (3) Fine-tune the large model, including model initialization, adapter injection, and training execution. The training data is a training set containing the mapping relationship between application objects, effect annotations, and technical features, enabling the large model to master causal reasoning capabilities;

[0048] (4) Repeat steps (1) to (3) to dynamically update the database and fine-tune the training set for the large model. The large model has semantic retrieval, relationship reasoning, and picture defect recognition functions until the constructed large model knowledge base can meet the user's question requirements.

[0049] Furthermore, in step (1), data is collected from laser cladding-related data sources and preprocessed. The preprocessed data includes text data, table data, and picture data, and different data adopts different processing strategies. As Figure 2 shown, the specific implementation is as follows:

[0050] (11) The multi-modal data in the field of laser cladding are obtained through multi-source acquisition, including the acquisition of CNIPA public patent data in the field of laser cladding, the acquisition of original literature PDF / Word / PPT documents related to laser cladding from the Google Scholar database, the Web of Science database, the Scopus database, etc.; the acquisition of process parameter tables of laser cladding processing enterprises to obtain original table Excel data. The collected document data includes multiple types of laser cladding usage methods, including: application objects of laser cladding, basic properties of application objects (materials, processing methods, dimensional parameters), types and contents of cladding materials, and process parameter designs for laser cladding applications such as surface modification, laser additive manufacturing, and product surface repair.

[0051] Build a literature data crawling pipeline. Use the Scrapy framework to build a directional crawler, call Serp API, WoS API, Elsevier API, etc., retrieve laser cladding keywords from Google Scholar database, Web of Science database, Scopus database, etc. to download the full text of the literature.

[0052] (12) The data preprocessing includes converting the laser cladding Word / PDF / PPT / Excel document data collected from multiple data sources into HTML format, and separating text data, image data, and table data from HTML.

[0053] In (11), multiple PDF / Word / PPT / Excel file data containing laser cladding knowledge are collected through directional collection, and different processing methods are used for different document formats. For PDF files, Apache PDFBox is used to convert them into HTML format files. Similarly, for Word / PPT / Excel files, python-docx / python-pptx / pandas.read_excel tools are used to convert them into HTML format. The converted multiple HTML files are data sets containing text data, image data, and table data. The Beautiful Soup 4 parsing tool is used to extract HTML files into text data, table data, and image data and store them separately.

[0054] (13) Different processing strategies are adopted for the different data, including converting text data and table data into structured data, inputting defective workpiece images in the image data into an image processing module, and converting text and table screenshot image data into structured data storage.

[0055] Different processing methods are adopted for the text data, table data, and picture data stored by classification. For the original table data, it is first identified and classified. For regular tables, the Tabula parsing tool is used for automatic parsing, and for complex tables, a deep learning model is applied for parsing. After parsing, the two types of tables are uniformly converted into the CSV intermediate format and then into structured data; for the separated image data, the image category is first identified. After preprocessing the text and table screenshots, text area detection and OCR recognition methods are used to store it structurally, and the workpiece defect pictures are directly input into the image processing module; for the separated text data, the keyword table in the field of laser cladding is detected for intelligent word segmentation to ensure the integrity of professional terms. For example: coaxial powder feeding (process-related term), composite coating (material-related term), powder feeder (equipment-related term), bonding strength (performance detection-related term). After cutting the text, it is stored as structured data.

[0056] (14) After obtaining the JSON structured data stored uniformly, the data is standardized, and duplicate data is cleaned and removed; the unit identifiers (such as cm / mm) in the detection values of the laser cladding process parameter data units in the stored data are unified. For example, for process parameters such as laser power, spot diameter, and cladding speed, they are standardized according to the preset conversion coefficient (example: 1 cm → 10 mm). For unit formats that cannot be recognized, the manual review process is automatically triggered; the format of the stored structured data is changed and verified. The storage of the structured data includes the JSON dataset format as follows:

[0057]

[0058] Furthermore, in step (2), the training set construction module constructs a training set based on the structured database composed of multi-source data. The workpiece defect pictures are classified and recognized in the image processing module. The specific implementation is as follows:

[0059] (21) The training set construction module includes a data parsing and standardization sub-module, a dialogue sample generation sub-module, a quality verification and control sub-module, and a dynamic optimization sub-module.

[0060] The data parsing and standardization sub-module converts the multi-source heterogeneous laser cladding structured data into a unified knowledge representation, including a knowledge triple mapping unit and a missing value reasoning unit.

[0061] The dialogue sample generation sub-module converts the standardized structured data into a dialogue format training sample that meets the requirements of large model fine-tuning, including a question generation unit, an answer construction unit, and a diversity enhancement unit.

[0062] The quality verification and control sub-module ensures that the generated training samples meet the technical specifications and domain knowledge constraints, including a format inspection unit and a semantic integrity detection unit.

[0063] The dynamic optimization word module realizes the continuous iteration and adaptive optimization of the knowledge base, constructs a user feedback index system, and optimizes the answer results.

[0064] (22) The data parsing and standardization sub-module contains a knowledge triple mapping unit and a missing value reasoning unit. Specifically: the knowledge triple mapping unit establishes a mapping rule library from JSON fields to knowledge triples, and the missing value reasoning unit fills in the default values based on the material knowledge graph.

[0065] Use the Drools rule engine to establish a mapping rule library, realize the flattening of nested structures, automatically identify composite fields such as Object and Parameter settings, and establish a mapping rule library from JSON fields to knowledge triples: (subject object, use, parameter design), (axle of 40 steel with a diameter of 0.15 meters, enhance hardness, laser power 15000W, cladding speed 1mm / s). Supplement the default values based on material knowledge. For example: when the powder feeding rate is empty, calculate the recommended value according to the laser power and the cladding speed, powder feeding rate (g / min) = laser power (w) × 0.8 + cladding speed (mm / s) × 2.5.

[0066] (23) The dialogue sample generation sub-module contains a question generation unit, an answer construction unit, and a diversity enhancement unit. Specifically: the question generation unit generates different questions by setting a multi-mode question template library, the answer construction unit structures the answer template of "application object - application reason - parameter design", and the diversity enhancement unit establishes a domain synonym library.

[0067] Construct a multi-question template library, as shown in Table 1:

[0068]

[0069] The answer template of "application object - application reason - parameter design", the application object inputs the object name, size parameters, and materials used, the application reason inputs the purpose of applying laser cladding, and the parameter design inputs the cladding material name and ratio, and the laser instrument process parameter settings.

[0070] The diversity enhancement unit establishes a domain synonym library and randomly selects synonyms when generating questions to ensure sample diversity. For example: laser power can be replaced by laser energy output, beam power, and cladding speed can be replaced by scanning rate, processing moving speed.

[0071] (24) The quality verification and control sub-module contains a format inspection unit and a semantic integrity detection unit. Specifically: the format inspection unit inspects that the generated training set conforms to the following format, and the semantic integrity detection unit detects the relevance of laser parameters in the statement.

[0072] Define strict format specifications to verify the format of the training set through JSON Schema. The semantic integrity detection unit detects the existence of key fields such as role.system, and at the same time detects the relevance of laser cladding process parameters. For example, the spot diameter should be greater than one-fifth of the cladding speed. When laser cladding 40 steel, the laser power should be between 800 - 1500W, and the cladding speed should be between 5 - 12mm / s. Divide the training set into a large model training set and a large model test set according to the ratio of 9.5:0.5, and use the test set to evaluate the performance of the large model knowledge base.

[0073]

[0074] (25) The image processing module consists of the following sub-modules, including: a front-end interaction sub-module, a preprocessing sub-module, a defect detection sub-module, a data conversion sub-module, and a transmission interface sub-module; The front-end interaction sub-module is used to receive the workpiece pictures uploaded by the user (supporting JPG / PNG formats) and transmit them to the back-end processing system; The preprocessing sub-module normalizes the picture size (adjusts it to 640×640 pixels), corrects the grayscale, and filters out noise to ensure that the input data meets the model requirements of the defect detection sub-module; The defect detection sub-module locates and classifies weld defects based on the YOLO model and outputs structured detection results. Data conversion sub-module: Convert defect information into a standardized format (JSON) that can be parsed by the large model; Transmission interface sub-module: Push data to the large model interaction through RESTful API or message queue (such as RabbitMQ).

[0075] The front-end interaction sub-module accepts the workpiece pictures uploaded by the user from the large model dialogue interface. The system verifies the file format and size, and returns a prompt to upload again after exceeding the file size limit. The pictures that meet the requirements are transmitted to the preprocessing module.

[0076] The preprocessing sub-module calls the function library to correct the grayscale and filter out noise of the picture to eliminate the influence of ambient light. Then, the bilinear interpolation method is used to adjust the picture size, and the picture is normalized to keep the aspect ratio unchanged.

[0077] The defect detection sub-module loads the pre-trained YOLO model and performs inference on the input picture. Parse the structured data detection results of the defect type, the defect position with normalized coordinates, and the defect confidence level output by the model.

[0078] The data conversion sub-module encapsulates the detection results into a JSON structure, and the format is as follows:

[0079]

[0080] The data transmission sub-module sends JSON data to the large model interface via the HTTPS protocol, attaching the user session ID to enable multi-task concurrency support.

[0081] Furthermore, the fine-tuning of the large model in (3) includes model initialization, adapter injection, and training execution. The training data is a training set containing the mapping relationship of application objects, effect annotations, and technical features, enabling the large model to master causal reasoning capabilities. The specific implementation is as follows:

[0082] (31) Select the Llama3-8B model as the base large model, load the 4-bit quantization configuration, and inject the domain-enhanced tokenizer, including loading the basic vocabulary of the large model's original tokenizer, detecting domain keywords in the structured data, and if the keywords are hit, dynamically loading the extended vocabulary and preferentially segmenting by domain terms. Ensure that the large model correctly identifies and segments during the fine-tuning training process with the input training set.

[0083] (32) Insert the QLoRA adapter into the key layers of the initialized large model, and set the low-rank dimension and scaling factor to keep the adapter matrix stable.

[0084] (33) Use the training set to fine-tune the large model using the QLoRA method. As Figure 3 shown, the training process is divided into three stages, including general large model pre-training, knowledge transfer training, and causal reasoning reinforcement training. During the training process, parameters such as the learning rate, batch size, number of training epochs, and sequence length are dynamically adjusted. The large model pre-training is fine-tuned using open-source Chinese context training sets and logical reasoning training sets, enabling the large model to have the ability to conduct Chinese conversations; the knowledge transfer training is based on the constructed laser cladding training set to preliminarily fine-tune the large model, enabling the large model to have a retrieval function; the causal reasoning reinforcement training is based on the constructed laser cladding training set, and multiple large amounts of repeated training are carried out. The test set is used to evaluate the accuracy of the large model's answers, and the training parameters and training set size are dynamically adjusted until the large model knowledge base meets the requirements of domain knowledge retrieval and reasoning.

[0085] Furthermore, in (4), repeat (1) to (3) to dynamically update the database and training set to fine-tune the large model. The large model has semantic retrieval, relationship reasoning, and image defect recognition functions until the constructed large model knowledge base can meet the user's question requirements. The specific implementation is as follows:

[0086] (41) The semantic retrieval and relationship reasoning functions include similarity matching and reasoning.

[0087] (42) The image defect recognition function includes defect recognition of the input workpiece image and outputting the recognition result to the large model.

[0088] (43) The large model knowledge base meets the user's needs and conducts accuracy evaluation, integrity evaluation, and stability evaluation on its output results.

[0089] It should be noted that the above are only the preferred embodiments of the present invention and are not used to limit the protection scope of the present invention. For those of ordinary skill in the art, without departing from the concept of the present invention, several deformations and improvements can still be made. Therefore, any combination or equivalent transformation made on the basis of the above embodiments falls within the protection scope of the present invention.

Claims

1. A method for constructing a knowledge base of laser cladding based on a large model, characterized in that, The method includes the following steps: Step 1: Collect data from laser cladding - related data sources and pre - process the data. After pre - processing, the data includes text data, table data, and picture data, and different data adopts different processing strategies; Step 2: Construct a training set based on the structured database composed of multi - source data sources, and classify and identify workpiece defect pictures in the picture processing module; Step 3: Fine - tune the large model, including model initialization, adapter injection, and training execution. The training data is a training set containing the mapping relationship between application objects, effect annotations, and technical features, enabling the large model to master certain causal reasoning capabilities; Step 4: Repeat Step 1 to Step 3 to dynamically update the database and construct a training set. When the new training set accumulates to a certain number, fine - tune the large model. The large model has the functions of semantic retrieval, relationship reasoning, and picture defect recognition until the constructed large - model knowledge base can meet the user's question - answering needs.

2. The method for constructing a laser cladding knowledge base based on a large model according to claim 1, wherein The specific implementation of Step 1 is as follows: (11) Obtain multi - modal data in the field of laser cladding through multi - source collection, including collecting public patent data, and collecting original literature PDF / Word / PPT documents related to laser cladding in the literature database; collect the original table Excel data by collecting the process parameter tables of laser cladding processing enterprises, (12) Pre - process the data, including uniformly converting the laser cladding Word / PDF / PPT / Excel document data collected from multiple sources into HTML format, and separating text data, picture data, and table data from the HTML, (13) Adopt different processing strategies for different data, including converting text data and table data into structured data, inputting defect workpiece pictures in the picture data into the picture processing module, and converting text and table screenshot picture data into structured data for storage, (14) Store the structured data, including the JSON data set format as 3. The method for constructing a laser cladding knowledge base based on a large model according to claim 1, wherein The specific implementation of Step 2 is as follows: (21) The training set construction module includes a data parsing and standardization sub - module, a dialogue sample generation sub - module, a quality verification and control sub - module, and a dynamic optimization sub - module. The data parsing and standardization sub - module converts multi - source heterogeneous laser cladding structured data into a unified knowledge representation, including a knowledge triple mapping unit and a missing - value reasoning unit; The dialogue sample generation sub - module converts the standardized structured data into a dialogue - format training sample that meets the requirements of large - model fine - tuning, including a question generation unit, an answer construction unit, and a diversity enhancement unit; The quality verification and control sub - module ensures that the generated training samples comply with technical specifications and domain - knowledge constraints, including a format inspection unit and a semantic integrity detection unit; the dynamic optimization sub - module realizes the continuous iteration and adaptive optimization of the knowledge base, constructs a user - feedback index system, and optimizes the answer results, (22) The knowledge triple mapping unit and the missing - value reasoning unit are included in the data parsing and standardization sub - module. Specifically, the knowledge triple mapping unit establishes a mapping rule base from JSON fields to knowledge triples, and the missing - value reasoning unit fills in the default values based on the material knowledge graph. (23) The dialogue sample generation sub-module includes a question generation unit, an answer construction unit, and a diversity enhancement unit, specifically: the question generation unit generates different questions by setting a multi-mode question template library, the answer construction unit structures the answer template of "application object - application reason - parameter design", and the diversity enhancement unit establishes a domain synonym library "" laser power "":[" laser energy output ", " beam power "], " cladding speed "":[" scanning rate ", " processing moving speed "]"; (24) The quality verification and control sub-module includes a format inspection unit and a semantic integrity detection unit, specifically: the format inspection unit checks that the generated training set conforms to the following format, and the semantic integrity detection unit detects the relevance of laser parameters in the statement, (25) The image processing module consists of the following sub-modules, including: a front-end interaction sub-module, a preprocessing sub-module, a defect detection sub-module, a data conversion sub-module, and a transmission interface sub-module; the front-end interaction sub-module is used to receive the workpiece images uploaded by the user (supporting JPG / PNG formats) and transmit them to the back-end processing system; the preprocessing sub-module normalizes the image size (adjusted to 640×640 pixels), corrects the grayscale, and filters the noise to ensure that the input data meets the model requirements of the defect detection sub-module; the defect detection sub-module locates and classifies the weld defects based on the YOLO model and outputs the structured detection results, and the data conversion sub-module: converts the defect information into a standardized format (JSON) that can be parsed by the large model; the transmission interface sub-module: pushes the data to the large model interaction through RESTful API or message queue (such as RabbitMQ).

4. The method for constructing a laser cladding knowledge base based on a large model according to claim 1, wherein, Step 3 is specifically implemented as follows: (31) Model initialization includes loading the base large model (Llama-3-8B) and injecting a laser cladding domain term enhanced tokenizer. The injection of the laser cladding domain term enhanced tokenizer in the model initialization performs tokenization on the stored structured data, including loading the basic vocabulary of the original tokenizer of the large model, detecting the domain keywords in the structured data, and if a keyword is hit, dynamically loading the extended vocabulary and preferentially segmenting according to the domain terms. (32) Adapter injection includes injecting the QloRA adapter at the key layer and setting the low-quality dimension and scaling factor to keep the adapter matrix stable. (33) The training execution link of the large model based on the training set includes the configuration of key parameters. The training key parameters include learning rate, batch size, number of training epochs, and sequence length. Based on the deployment configuration selection, the training execution link includes fine-tuning based on the Chinese dialogue training set to enable the large model to have the ability of Chinese dialogue, and fine-tuning the large model based on the constructed laser cladding training set to enable the large model to have the ability of retrieval and causal reasoning.

5. The method for constructing a laser cladding knowledge base based on a large model according to claim 1, wherein Step 4 is specifically implemented as follows: (41) The semantic retrieval and relationship reasoning function includes similarity matching and reasoning. (42) The image defect recognition function includes defect recognition of the input workpiece image and outputting the recognition result to the large model. (43) The large model knowledge base meets the user's needs and conducts accuracy evaluation, integrity evaluation, and stability evaluation on its output results.

6. An electronic device, comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the method for constructing a large model-based laser cladding knowledge base according to any one of the above-mentioned claims 1 to 5.

7. A computer-readable storage medium having computer instructions stored thereon, characterized in that, When the computer instruction is executed by the processor, it implements the method for constructing a large model-based laser cladding knowledge base according to any one of claims 1-5.

Citation Information

Patent Citations

  • Construction and operation and maintenance application method of multi-modal predictive maintenance large model

    CN118468025A

  • Large model-based main transformer defect risk identification method

    CN118916804A

  • Industrial large model platform and system thereof

    CN119443259A

  • Welding process parameter recommendation method for enhancing large model by using knowledge graph retrieval

    CN119578525A

  • Knowledge graph analysis and question answering method and device based on large language model

    CN119691243A

Cited By

  • Method and system for enhancing investment suggestion suitability review agent, equipment and storage medium

    CN121211016A

  • Metainformation-driven synthesis training method, system and device for traditional Chinese painting large model and storage medium

    CN121685749A