An ai high-availability evaluation method for metallographic structure data and a related system

By employing an AI-based high-availability assessment method for metallographic data, and utilizing the Embedding model and VGG16 network, the system addresses the issues of insufficient expertise and data privacy in the field of metallography. This enables accurate material information retrieval and image display, thereby enhancing the system's professional accuracy and data privacy protection.

CN121765324BActive Publication Date: 2026-05-01NORTHEASTERN UNIV CHINA
View PDF 4 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
NORTHEASTERN UNIV CHINA
Filing Date
2026-02-28
Publication Date
2026-05-01

AI Technical Summary

Technical Problem

Existing general-purpose large models suffer from insufficient expertise in metallography, difficulty in protecting data privacy, low accuracy in similar image retrieval, and poor linkage between material information query and image display.

Method used

By acquiring user request information, splitting and sorting it using the Embedding and Reranker models, extracting feature vectors using the VGG16 network, and constructing an AI high-availability evaluation system for metallographic data through cosine similarity calculation and high availability confidence interval assessment, the system achieves professional accuracy and data privacy protection.

Benefits of technology

It achieves professional precision in the field of metallography using general-purpose large models, outputs accurate and standardized results, solves the problems of insufficient professionalism and difficulty in protecting data privacy, and improves the linkage between material information query and image display.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121765324B_ABST
    Figure CN121765324B_ABST
Patent Text Reader

Abstract

The application discloses a kind of AI high availability evaluation methods and related systems for metallographic structure data, method includes: determining the request type of user request information;If request type is question type, user request information is split, and subproblem is obtained, and mapping is carried out through Embedding model, and question vector is obtained;The context data of question vector in the preset knowledge base is determined by parent-child paragraph retrieval strategy;Extract context data as prompt word, to output reply information according to prompt word;If request type is analysis type, extract the high-dimensional feature vector of user request information, and the high-dimensional feature vector is normalized, to obtain target feature vector;The cosine similarity of target feature vector and each preset metallographic image in preset knowledge base is calculated, to determine target metallographic image in preset knowledge base;Process metadata of target metallographic image is inquired in preset knowledge base, and AI availability of corresponding data is evaluated according to analysis result.
Need to check novelty before this filing date? Find Prior Art

Description

A High Availability Assessment Method and Related System for Metallographic Data Technical Field

[0001] This invention relates to the field of data interaction technology, and in particular to an AI-based high-availability evaluation method and related system for metallographic data. Background Technology

[0002] Existing general-purpose large models suffer from several drawbacks, including insufficient expertise in metallography, difficulty in protecting data privacy, low accuracy in similarity spectrum retrieval, and poor integration between material information query and image display. For example, application number CN120708781A describes a method for generating material formulations, target materials, automotive structural parts, vehicles, devices, media, and electronic equipment. It utilizes a large-scale material model to reverse-engineer the formulation and process data of the preparation method based on the target material's required performance data. While introducing a large-scale model into the field of materials science and providing a "target performance-driven" reverse material formulation generation method, it does not address issues related to large-scale model-based methods. The text describes a question-and-answer format and metallographic image analysis process. A method for identifying proto-austenite grain boundaries in martensitic metallographic structures, with application number CN113256582A, firstly, preprocesses the initial grain boundary image by cropping and scaling, and then performs data enhancement processing such as random elastic deformation. Next, an improved U-Net network is used to perform image recognition processing on the sample data for different grain boundary structures. Finally, the output images are stitched together to complete the recognition process. However, this method does not associate text data with metallographic images, and still suffers from problems such as difficulty in ensuring data privacy, low accuracy of similar image retrieval, and poor linkage between material information query and image display. Summary of the Invention

[0003] In view of this, the present invention provides an AI high availability evaluation method and related system for metallographic data, to address the problems in existing general-purpose large models such as insufficient professionalism in the metallographic field, difficulty in ensuring data privacy, low accuracy of similar image retrieval, and poor linkage between material information query and image display. To achieve one or more of the above objectives, or other objectives, the present invention proposes an AI high availability evaluation method for metallographic data, comprising:

[0004] Obtain user request information for metallographic structure image data, and determine the request type of the user request information;

[0005] If the request type is a question type for metallographic information Q&A, then under the React mechanism, the user request information is split into at least two sub-questions; each sub-question is mapped to the same high-dimensional space through an embedding model to obtain a question vector for each sub-question; the context data for the question vector in the preset knowledge base is determined through a parent-child paragraph retrieval strategy to obtain a context dataset; the context data in the context dataset is sorted through a Reranker model, and at least two of the top-ranked context data in the context dataset are extracted in descending order as prompt words for the preset question-answering model, so that the preset question-answering model outputs response information for the user request information based on the prompt words;

[0006] If the request type is an analysis class for metallographic image analysis, then a high-dimensional feature vector of the user request information is extracted using a preset VGG16 network, and the high-dimensional feature vector is subjected to L2 normalization to obtain the target feature vector of the user request information; the cosine similarity between the target feature vector and the standard feature vector of each preset metallographic image in the preset knowledge base is calculated, and the preset metallographic image corresponding to the user request information is selected as the target metallographic image in the preset knowledge base in descending order of the cosine similarity; the structured process metadata of the target metallographic image is queried in the preset knowledge base, and the target metallographic image and the structured process metadata are displayed; a high availability confidence interval is constructed based on the cosine similarity, and the availability classification evaluation of the target metallographic image is performed according to the high availability confidence interval to obtain a highly available target metallographic image with a cosine similarity greater than a first preset threshold and a low availability target metallographic image with a cosine similarity less than or equal to a second preset threshold.

[0007] Optionally, before the step of obtaining user request information for metallographic image data and determining the request type of the user request information, the method further includes:

[0008] Collect end-to-end data in the field of steel metallography, including at least microstructure classification standards, heat treatment process parameters, professional Q&A pairs, and metallographic atlases with preset annotation information;

[0009] The text data in the full-link data is preprocessed to obtain the raw data. The preprocessing includes at least redundancy cleaning and synonym normalization. The text data includes organizational classification standards, heat treatment process parameters and professional question-and-answer pairs.

[0010] The original data is structurally transformed according to a preset hierarchical logic to obtain structured data;

[0011] The image data in the full-link data is standardized to obtain a preset metallographic image, and the standard feature vector of the preset metallographic image is obtained. The image data includes a metallographic atlas with preset annotation information.

[0012] Based on the identity information of the preset metallographic image, the structured data, the preset metallographic image, and the standard feature vector are associated to build a preset knowledge base on the Dify platform.

[0013] Optionally, before the step of obtaining user request information for metallographic image data and determining the request type of the user request information, the method further includes:

[0014] Using LoRA technology, the initial question-answering model is trained based on the preset knowledge base to obtain the preset question-answering model;

[0015] The step of training the initial question-answering model based on the preset knowledge base includes:

[0016] The initial question-answering model is trained based on the preset knowledge base according to the cross-entropy loss function and the preset consistency loss function.

[0017] The preset question-answering model is deployed using the Ollam tool, and a communication connection is established between the Ollam tool and the Dify platform.

[0018] Optionally, the step of determining the context data for the question vector in the preset knowledge base through a parent-child paragraph retrieval strategy to obtain the context dataset includes:

[0019] The structured data in the preset knowledge base is divided into parent and child segments based on the parent-child segment retrieval strategy.

[0020] Calculate the matching degree between the sub-segment and the question vector, and take the sub-segment with the highest matching degree with the question vector as the target sub-segment;

[0021] The parent segment corresponding to the target sub-segment is used as context data for the question vector.

[0022] Optionally, the method further includes:

[0023] Principal component analysis (PCA) is used to map the high-dimensional feature vector and the standard feature vector to the same two-dimensional plane. The points corresponding to the high-dimensional feature vector and the points corresponding to the standard feature vector are rendered in different colors in the two-dimensional plane to obtain a two-dimensional scatter projection map of the feature space, which is then displayed.

[0024] Optionally, the preset VGG16 network is a VGG16 model that uses average pooling and does not have a top-level classifier.

[0025] Optionally, the method further includes:

[0026] Obtain the attribute information of the target feature vector, and display the attribute information and the cosine similarity.

[0027] Secondly, this application provides an AI-based high-availability evaluation system for metallographic data, including:

[0028] The request processing module is used to obtain user request information for metallographic structure image data and determine the request type of the user request information.

[0029] The question-and-answer module is used to, if the request type is a question type for metallographic information question-and-answer, then, under the React mechanism, split the user request information into at least two sub-questions; map each sub-question to the same high-dimensional space through an embedding model to obtain a question vector for each sub-question; determine the context data for the question vector in a preset knowledge base through a parent-child paragraph retrieval strategy to obtain a context dataset; sort the context data in the context dataset through a Reranker model, and extract at least two of the top-ranked context data in the context dataset in descending order as prompt words for a preset question-and-answer model, so that the preset question-and-answer model outputs response information for the user request information based on the prompt words;

[0030] The analysis module is configured to: extract high-dimensional feature vectors of the user request information using a preset VGG16 network if the request type is an analysis class for metallographic image analysis; perform L2 normalization on the high-dimensional feature vectors to obtain the target feature vectors of the user request information; calculate the cosine similarity between the target feature vectors and the standard feature vectors of each preset metallographic image in the preset knowledge base; select the preset metallographic image corresponding to the user request information as the target metallographic image in the preset knowledge base in descending order of the cosine similarity; query the structured process metadata of the target metallographic image in the preset knowledge base and display the target metallographic image and the structured process metadata; construct a high availability confidence interval based on the cosine similarity; and perform availability classification evaluation on the target metallographic image according to the high availability confidence interval to obtain highly available target metallographic images with cosine similarity greater than a first preset threshold and low availability target metallographic images with cosine similarity less than or equal to a second preset threshold.

[0031] Thirdly, this application provides an electronic device including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the computer program, implements the AI ​​high-availability evaluation method for metallographic data as described above.

[0032] Fourthly, this application provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the AI ​​high-availability evaluation method for metallographic data as described above.

[0033] Implementing the embodiments of the present invention will have the following beneficial effects:

[0034] By deeply integrating large-scale modeling technology with the field of metallography, and through training with metallography-specific corpora, LoRA fine-tuning, and RAG retrieval enhancement, it achieves a level of professional accuracy unattainable by general-purpose large-scale models. It can analyze problems from a professional metallographic perspective, outputting accurate and standardized results, thus addressing the core shortcoming of general-purpose large-scale models—their broad but not specialized nature. It transforms unstructured metallographic microscopic images into highly usable data assets with semantic understanding capabilities. Attached Figure Description

[0035] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the 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.

[0036] in:

[0037] Figure 1 is a flowchart illustrating an AI high availability assessment method for metallographic data provided in an embodiment of this application;

[0038] Figure 2 is a flowchart illustrating an AI high availability assessment method for metallographic data provided in an embodiment of this application;

[0039] Figure 3 is a schematic diagram of the RAG retrieval process in an AI high availability evaluation method for metallographic data provided in an embodiment of this application;

[0040] Figure 4 is a schematic diagram of the parent-child paragraph retrieval process in an AI high availability evaluation method for metallographic data provided in an embodiment of this application.

[0041] Figure 5 is a schematic diagram of the structure of an AI high-availability evaluation device for metallographic data provided in an embodiment of this application;

[0042] Figure 6 is a schematic diagram of the structure of a terminal device provided in an embodiment of this application;

[0043] Figure 7 is a schematic diagram of the structure of a computer-readable storage medium provided in an embodiment of this application. Detailed Implementation

[0044] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. 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 are within the scope of protection of the present invention.

[0045] In the description of this invention, it should be noted that the terms "center," "upper," "lower," "left," "right," "vertical," "horizontal," "inner," and "outer," etc., indicating orientation or positional relationships, are based on the orientation or positional relationships shown in the accompanying drawings and are only for the convenience of describing the invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of the invention. Furthermore, the terms "first," "second," and "third" are used for descriptive purposes only and should not be construed as indicating or implying relative importance. In the description of this invention, it should be noted that unless otherwise explicitly specified and limited, the terms "installed," "connected," and "linked" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; and they can refer to the internal communication of two components. Those skilled in the art can understand the specific meaning of the above terms in this invention based on the specific circumstances.

[0046] As shown in Figure 1, this application provides an AI high availability assessment method for metallographic data, including:

[0047] S110. Obtain user request information for metallographic image data, and determine the request type of the user request information;

[0048] S120. If the request type is a question type for metallographic information Q&A, then under the React mechanism, the user request information is split into at least two sub-questions; each sub-question is mapped to the same high-dimensional space through an Embedding model to obtain a question vector for each sub-question; the context data for the question vector in the preset knowledge base is determined through a parent-child paragraph retrieval strategy to obtain a context dataset; the context data in the context dataset is sorted through a Reranker model, and at least two of the top-ranked context data in the context dataset are extracted in descending order as prompt words for the preset question-answering model, so that the preset question-answering model outputs response information for the user request information based on the prompt words;

[0049] S130. If the request type is an analysis class for metallographic image analysis, then a high-dimensional feature vector of the user request information is extracted using a preset VGG16 network, and the high-dimensional feature vector is subjected to L2 normalization to obtain the target feature vector of the user request information; the cosine similarity between the target feature vector and the standard feature vector of each preset metallographic image in the preset knowledge base is calculated, and the preset metallographic image corresponding to the user request information is selected as the target metallographic image in the preset knowledge base in descending order of the cosine similarity; the structured process metadata of the target metallographic image is queried in the preset knowledge base, and the target metallographic image and the structured process metadata are displayed; a high availability confidence interval is constructed based on the cosine similarity, and the availability classification evaluation of the target metallographic image is performed according to the high availability confidence interval to obtain a highly available target metallographic image with a cosine similarity greater than a first preset threshold and a low availability target metallographic image with a cosine similarity less than or equal to a second preset threshold.

[0050] For example, as shown in Figure 2, targeted data on the entire chain of "composition-process-structure-property" in the steel industry is collected, including microstructure classification standards, heat treatment process parameters, professional Q&A pairs, and metallographic atlases with expert annotations (covering typical, abnormal, and defective microstructures). For text data, a redundancy cleaning, synonym normalization, and hierarchical structuring process are implemented. First, redundant information such as repeated descriptions and special symbols are removed from the text. Then, synonymous professional terms such as austenitic steel and austenitic stainless steel are uniformly labeled. Finally, the data is structured according to the hierarchical logic of material category, microstructure subcategory, and core attributes. The principle is to adapt the knowledge structure of different alloy systems through standardized hierarchical classification, thereby improving the accuracy of subsequent searches. For the processing of spectral data, the focus is on unified and standardized preprocessing. Gaussian filtering is used to remove random noise from the spectral data (while preserving common morphological features such as grain boundaries and particles). An adaptive threshold segmentation algorithm is used to extract the tissue regions and grain boundary contours. A pre-trained feature extraction model is used to extract metallographic-specific features and convert them into high-dimensional vectors. This lays the mathematical foundation for evaluating the high availability of data in the subsequent retrieval stage by using vector distance.

[0051] The selection of the base model is based on the computing power requirements of localized deployment and the guarantee of inference efficiency. An open-source base model with a moderate number of parameters and strong generalization ability is selected to balance performance and deployment cost.

[0052] For model fine-tuning, specialized question-and-answer pairs, structured material information, and spectral feature correlation data were employed. Training was implemented based on LoRA technology, freezing over 98% of the original parameters of the base model. Targeted enhancement of low-rank matrix parameters was performed solely for materials science knowledge. A cross-entropy loss function was introduced during training, and the model accuracy was evaluated after each training round using a validation set containing multiple material types. The final result is a large-scale vertical model with the ability to recognize multiple alloy systems and steel knowledge at its core. This model architecture supports incremental training on other alloy data in the future without requiring network reconstruction.

[0053] The fine-tuned model weights are converted to a lightweight deployment format. Inference parameters are configured using the Ollam tool, including setting appropriate inference thread counts, context window size, and temperature parameters. It's important to note that the temperature parameter should be set to a low value to reduce generation randomness and ensure the rigor of professional answers. The local inference service is started, and intranet access is restricted. The Dify platform is deployed and integrated with the local Ollam model, configuring a dedicated API interface and key verification mechanism. The interaction flow is designed through the Dify visual interface, constructing a general logical chain of "input parsing—knowledge retrieval—model inference—formatted output."

[0054] A scalable hierarchical knowledge base is constructed. Preprocessed structured text data and material association information are imported into the knowledge base. A directory tree is built according to "material system - material category - microstructure category" to achieve logical isolation and unified management of steel data and future expansion data. At the same time, the association mapping between text information, graph features and material properties is established.

[0055] For example, as shown in Figure 3, combining Retrieval Enhancement (RAG) technology with a similarity calculation model improves the accuracy of information retrieval and similar content matching. By combining the retrieved information with the generation model, more accurate, richer, and contextualized text can be generated. This technology not only utilizes information from external knowledge bases but also updates data in a timely manner, provides highly customized services, and has cost advantages.

[0056] Search optimization employs an embedding model adapted to Chinese technical terminology, uniformly mapping text and atlas feature vectors from different materials to the same high-dimensional space. A Reranker model is introduced to perform a secondary sorting of the initial search results, filtering out content most relevant to the query intent and eliminating low-relevance information. Cosine similarity calculation rules are configured, and reasonable similarity thresholds are set. Three modes are provided: keyword search, hierarchical navigation search, and natural language question answering. Intent parsing technology distinguishes user query types to accurately identify user needs and match corresponding search or reasoning logic. Simultaneously, a contextual association mechanism is enabled to record multi-round interaction information, supporting continuous follow-up questions without requiring users to repeat descriptions, thus improving interaction fluency. In the image interaction stage, after users upload metallographic atlases, the system automatically executes a denoising and feature extraction process consistent with the dataset preprocessing, ensuring a unified search benchmark and avoiding search biases caused by differences in atlas preprocessing. Query results simultaneously display material text information and associated atlases, supporting functions such as atlas zoom, paginated carousel, and detailed annotation viewing.

[0057] To help users intuitively understand the matching logic of the algorithm, the system incorporates principal component analysis (PCA). The system combines the feature vectors of the uploaded image with the feature vectors of all images in the database to calculate their projected coordinates in a two-dimensional plane. The front-end interface uses a charting library to create a two-dimensional scatter plot of the feature space, where the user-uploaded image is marked with blue highlighted nodes, and similar images in the database are marked with gray nodes. The Euclidean distance between nodes visually reflects the similarity of metallographic structures in the feature space. Furthermore, the system dynamically displays bar charts of the first 32 feature values ​​and feature statistics on the interface, providing a transparent view of the calculation process. The system uses a cosine similarity algorithm to calculate the cosine of the angle between the feature vector of the uploaded image and the feature vector of each image in the knowledge base. Based on the calculation results, the system sorts the images from highest to lowest similarity and sets a threshold to filter out the Top-N most similar images.

[0058] High availability criteria based on similarity: The standard graph in the database is considered the "high availability benchmark," and the system sets a "high availability confidence interval." Specifically, when the first preset threshold is set to 80% and the second preset threshold is set to 50%...

[0059] High availability (similarity > 80%): If the uploaded image is clear and represents a typical tissue, the system will directly output the matching material information and process parameters.

[0060] Medium availability / requires manual review (50% < similarity < 80%): The system determines that the image may have slight blurring or atypical features, outputs the closest reference image, and marks it with the message "Similarity is average, for reference only".

[0061] Low-availability / Unreliable data (similarity <50%): The uploaded image is determined to be of low quality (e.g., severely out of focus, artifacts) or belongs to an unknown material system not yet covered by the system. The system refuses to give misleading conclusions and reports "Image features deviate too much from the baseline, no effective metallographic features were detected, it belongs to low-availability data or unknown material, it is recommended to re-collect", prompting the user to retake the photo or for manual intervention.

[0062] It adopts a B / S architecture, with the backend based on Flask and the frontend based on HTML5 / JS. The interface design clearly divides the "Large Model Question and Answer" and "Image Analysis" functional areas, using a top navigation bar and tab switching pages.

[0063] In one possible implementation, prior to the steps of acquiring user request information regarding metallographic image data and determining the request type of the user request information, the method further includes:

[0064] Collect end-to-end data in the field of steel metallography, including at least microstructure classification standards, heat treatment process parameters, professional Q&A pairs, and metallographic atlases with preset annotation information;

[0065] The text data in the full-link data is preprocessed to obtain the raw data. The preprocessing includes at least redundancy cleaning and synonym normalization. The text data includes organizational classification standards, heat treatment process parameters and professional question-and-answer pairs.

[0066] The original data is structurally transformed according to a preset hierarchical logic to obtain structured data;

[0067] The image data in the full-link data is standardized to obtain a preset metallographic image, and the standard feature vector of the preset metallographic image is obtained. The image data includes a metallographic atlas with preset annotation information.

[0068] Based on the identity information of the preset metallographic image, the structured data, the preset metallographic image, and the standard feature vector are associated to build a preset knowledge base on the Dify platform.

[0069] For example, specific data in the field of steel metallography is collected, including metallographic classification standards for cast iron, low-carbon steel, and alloy steel, heat treatment process parameters, metallographic atlases, correlation patterns between "composition-process-structure-property," and professional Q&A pairs within the field. Secondly, basic material information is organized to form a raw dataset. The raw data undergoes standardization processing; for example, redundant and erroneous content is removed from text data, which is then converted into a structured format and categorized hierarchically according to "material category—structure type—core attributes." Atlas data undergoes uniform size cropping, sharpness optimization, and noise removal to ensure consistent image quality. Finally, professional feature preprocessing of the metallographic atlases is performed, extracting features including grain boundary contours, grain morphology and distribution density, defect morphology, and grayscale gradient characteristics, which are then converted into high-dimensional feature vectors, laying the data foundation for subsequent similar atlas retrieval.

[0070] In one possible implementation, prior to the steps of acquiring user request information regarding metallographic image data and determining the request type of the user request information, the method further includes:

[0071] Using LoRA technology, the initial question-answering model is trained based on the preset knowledge base to obtain the preset question-answering model;

[0072] The step of training the initial question-answering model based on the preset knowledge base includes:

[0073] The initial question-answering model is trained based on the preset knowledge base according to the cross-entropy loss function and the preset consistency loss function.

[0074] The preset question-answering model is deployed using the Ollam tool, and a communication connection is established between the Ollam tool and the Dify platform.

[0075] For example, based on the enterprise's local capabilities, a suitable basic large model (such as Deepseek, Qwen series models) is selected to ensure that model training and subsequent inference can run efficiently in the local hardware environment. The highly available dedicated question-and-answer pairs, structured material information and spectral feature association data cleaned in step (1) are fine-tuned: the model parameters are optimized through LoRA technology, and targeted reinforcement is carried out only for knowledge related to the metallographic field to reduce computing power consumption; during the training process, the cross-entropy loss function and the domain-specific consistency loss function are introduced to ensure the professionalism and accuracy of the model output results. Finally, through evaluation by experts in the field and verification with test datasets, the effect of the fine-tuned model is iterated until the model can accurately answer professional questions in the metallographic field, accurately associate material information and organizational features, and form a metallographic organization-specific vertical large model (the preset question-and-answer model).

[0076] In one possible implementation, as shown in Figure 4, the step of determining the context data for the question vector in the preset knowledge base through a parent-child paragraph retrieval strategy to obtain the context dataset includes:

[0077] The structured data in the preset knowledge base is divided into parent and child segments based on the parent-child segment retrieval strategy.

[0078] Calculate the matching degree between the sub-segment and the question vector, and take the sub-segment with the highest matching degree with the question vector as the target sub-segment;

[0079] The parent segment corresponding to the target sub-segment is used as context data for the question vector.

[0080] In one possible implementation, the method further includes:

[0081] Principal component analysis (PCA) is used to map the high-dimensional feature vector and the standard feature vector to the same two-dimensional plane. The points corresponding to the high-dimensional feature vector and the points corresponding to the standard feature vector are rendered in different colors in the two-dimensional plane to obtain a two-dimensional scatter projection map of the feature space, which is then displayed.

[0082] For example, principal component analysis (PCA) is introduced to draw a two-dimensional scatter plot in the feature space. If a user-uploaded image (blue node) falls within the tightly bounded area of ​​similar images (gray node clusters) in the benchmark library, it visually confirms that it is "highly available data"; if it is outside the node clusters, it visually indicates that it is "low-availability anomalous data".

[0083] In one possible implementation, the preset VGG16 network is a VGG16 model that uses average pooling and does not have a top-level classifier.

[0084] In one possible implementation, the method further includes:

[0085] Obtain the attribute information of the target feature vector, and display the attribute information and the cosine similarity.

[0086] In one possible implementation, as shown in Figure 5, this application provides an AI-based high-availability evaluation device for metallographic data, comprising:

[0087] The request processing module 201 is used to obtain user request information for metallographic structure image data and determine the request type of the user request information.

[0088] The question-answering module 202 is used to, if the request type is a question type for metallographic information question-answering, split the user request information under the React mechanism to obtain at least two sub-questions; map each sub-question to the same high-dimensional space through an embedding model to obtain a question vector for each sub-question; determine the context data for the question vector in the preset knowledge base through a parent-child paragraph retrieval strategy to obtain a context dataset; sort the context data in the context dataset through a Reranker model, and extract at least two of the top-ranked context data in the context dataset in descending order as prompt words for the preset question-answering model, so that the preset question-answering model outputs response information for the user request information based on the prompt words;

[0089] Analysis module 203 is configured to: if the request type is an analysis class for metallographic image analysis, extract a high-dimensional feature vector of the user request information using a preset VGG16 network, and perform L2 normalization on the high-dimensional feature vector to obtain a target feature vector of the user request information; calculate the cosine similarity between the target feature vector and the standard feature vectors of each preset metallographic image in the preset knowledge base, and select a preset metallographic image corresponding to the user request information as the target metallographic image in the preset knowledge base in descending order of the cosine similarity; query the structured process metadata of the target metallographic image in the preset knowledge base and display the target metallographic image and the structured process metadata; construct a high availability confidence interval based on the cosine similarity, and perform availability classification evaluation on the target metallographic image according to the high availability confidence interval, to obtain a highly available target metallographic image with a cosine similarity greater than a first preset threshold and a low-availability target metallographic image with a cosine similarity less than or equal to a second preset threshold.

[0090] In one possible implementation, as shown in FIG6, this application embodiment provides a terminal device 300, including: a memory 310, a processor 320, and a first computer program 311 stored on the memory 310 and executable on the processor 320. When the processor 320 executes the first computer program 311, it acquires user request information for metallographic image data and determines the request type of the user request information; if the request type is a question type for metallographic information Q&A, then under the React mechanism, the user request information is split into at least two sub-questions; each sub-question is mapped to the same high-dimensional space through an Embedding model to obtain a question vector for each sub-question; context data for the question vector in a preset knowledge base is determined through a parent-child paragraph retrieval strategy to obtain a context dataset; the context data in the context dataset is sorted through a Reranker model, and at least two context data items ranked first in the context dataset are extracted in descending order as prompt words for a preset question-answering model, so that the... A pre-defined question-answering model outputs a response to the user's request based on the prompt words. If the request type is an analysis class for metallographic image analysis, a pre-defined VGG16 network is used to extract the high-dimensional feature vector of the user's request, and L2 normalization is performed on the high-dimensional feature vector to obtain the target feature vector of the user's request. The cosine similarity between the target feature vector and the standard feature vectors of each pre-defined metallographic image in the pre-defined knowledge base is calculated, and the pre-defined metallographic image corresponding to the user's request is selected as the target metallographic image in the pre-defined knowledge base in descending order of the cosine similarity. The structured process metadata of the target metallographic image is queried in the pre-defined knowledge base, and the target metallographic image and the structured process metadata are displayed. A high availability confidence interval is constructed based on the cosine similarity, and the availability of the target metallographic image is graded and evaluated according to the high availability confidence interval to obtain a highly available target metallographic image with a cosine similarity greater than a first pre-defined threshold and a low-availability target metallographic image with a cosine similarity less than or equal to a second pre-defined threshold.

[0091] In one possible implementation, as shown in FIG7, this embodiment of the application provides a computer-readable storage medium 400, on which a second computer program 411 is stored. When the second computer program 411 is executed by a processor, it acquires user request information for metallographic image data and determines the request type of the user request information. If the request type is a question type for metallographic information Q&A, then under the React mechanism, the user request information is split into at least two sub-questions. Each sub-question is mapped to the same high-dimensional space through an Embedding model to obtain a question vector for each sub-question. The context data for the question vector in the preset knowledge base is determined through a parent-child paragraph retrieval strategy to obtain a context dataset. The context data in the context dataset is sorted through a Reranker model, and at least two of the top-ranked context data in the context dataset are extracted in descending order as prompt words for the preset question-answering model, so that the preset question-answering model outputs a prompt word for the user based on the prompt word. The system provides the response information for the user's request. If the request type is an analysis class for metallographic image analysis, a high-dimensional feature vector of the user's request information is extracted using a preset VGG16 network, and L2 normalization is performed on the high-dimensional feature vector to obtain the target feature vector of the user's request information. The cosine similarity between the target feature vector and the standard feature vectors of each preset metallographic image in the preset knowledge base is calculated, and preset metallographic images corresponding to the user's request information are selected as target metallographic images in the preset knowledge base in descending order of cosine similarity. The system queries the structured process metadata of the target metallographic image in the preset knowledge base and displays the target metallographic image and the structured process metadata. A high availability confidence interval is constructed based on the cosine similarity, and the availability is graded and evaluated based on the high availability confidence interval to obtain highly available target metallographic images with a cosine similarity greater than a first preset threshold and low availability target metallographic images with a cosine similarity less than or equal to a second preset threshold.

[0092] Note that the above description is merely a preferred embodiment of the present invention and the technical principles employed. Those skilled in the art will understand that the present invention is not limited to the specific embodiments described herein, and various obvious changes, readjustments, and substitutions can be made without departing from the scope of protection of the present invention. Therefore, although the present invention has been described in detail through the above embodiments, the present invention is not limited to the above embodiments, and may include many other equivalent embodiments without departing from the concept of the present invention, the scope of which is determined by the scope of the appended claims.

[0093] The above description discloses only preferred embodiments of the present invention and should not be construed as limiting the scope of the present invention. Therefore, equivalent variations made in accordance with the claims of the present invention are still within the scope of the present invention.

Claims

1. A high-availability evaluation method for AI based on metallographic data, characterized in that, include: Obtain user request information for metallographic structure image data, and determine the request type of the user request information; If the request type is a question type for metallographic information Q&A, then under the React mechanism, the user request information is split into at least two sub-questions; each sub-question is mapped to the same high-dimensional space through an embedding model to obtain a question vector for each sub-question; the context data for the question vector in the preset knowledge base is determined through a parent-child paragraph retrieval strategy to obtain a context dataset; the context data in the context dataset is sorted through a Reranker model, and at least two of the top-ranked context data in the context dataset are extracted in descending order as prompt words for the preset question-answering model, so that the preset question-answering model outputs response information for the user request information based on the prompt words; If the request type is an analysis class for metallographic image analysis, then a high-dimensional feature vector of the user request information is extracted using a preset VGG16 network, and the high-dimensional feature vector is subjected to L2 normalization to obtain the target feature vector of the user request information; the cosine similarity between the target feature vector and the standard feature vector of each preset metallographic image in the preset knowledge base is calculated, and the preset metallographic image corresponding to the user request information is selected as the target metallographic image in the preset knowledge base in descending order of the cosine similarity; The structured process metadata of the target metallographic image is queried in the preset knowledge base, and the target metallographic image and the structured process metadata are displayed. A high availability confidence interval is constructed based on the cosine similarity, and the availability classification assessment of the target metallographic image is performed according to the high availability confidence interval to obtain a highly available target metallographic image with a cosine similarity greater than a first preset threshold and a low availability target metallographic image with a cosine similarity less than or equal to a second preset threshold.

2. The AI ​​high availability evaluation method for metallographic data as described in claim 1, characterized in that, Before the steps of obtaining user request information for metallographic image data and determining the request type of the user request information, the method further includes: collecting end-to-end data in the field of steel metallography, wherein the end-to-end data includes at least microstructure classification standards, heat treatment process parameters, professional question-and-answer pairs, and metallographic atlases with preset annotation information; preprocessing the text data in the end-to-end data to obtain raw data, wherein the preprocessing includes at least redundancy cleaning and synonym normalization, and the text data includes microstructure classification standards, heat treatment process parameters, and professional question-and-answer pairs; performing structured transformation on the raw data according to preset hierarchical logic to obtain structured data; performing standardization processing on the image data in the end-to-end data to obtain preset metallographic images, and obtaining the standard feature vector of the preset metallographic images, wherein the image data includes metallographic atlases with preset annotation information; and associating the structured data, the preset metallographic images, and the standard feature vectors based on the identity information of the preset metallographic images to build a preset knowledge base on the Dify platform.

3. The AI ​​high availability evaluation method for metallographic data as described in claim 2, characterized in that, Before the steps of obtaining user request information for metallographic image data and determining the request type of the user request information, the method further includes: training an initial question-answering model based on the preset knowledge base using LoRA technology to obtain a preset question-answering model; the step of training the initial question-answering model based on the preset knowledge base includes: training the initial question-answering model based on the preset knowledge base according to the cross-entropy loss function and the preset consistency loss function; deploying the preset question-answering model using the Ollam tool and establishing a communication connection between the Ollam tool and the Dify platform.

4. The AI ​​high availability evaluation method for metallographic data as described in claim 2, characterized in that, The step of determining the context data for the question vector in the preset knowledge base through the parent-child paragraph retrieval strategy to obtain the context dataset includes: dividing the structured data in the preset knowledge base into parent segments and child segments based on the parent-child paragraph retrieval strategy; calculating the matching degree between the child segment and the question vector, and taking the child segment with the highest matching degree with the question vector as the target child segment; and taking the parent segment corresponding to the target child segment as the context data for the question vector.

5. The AI ​​high availability evaluation method for metallographic data as described in claim 1, characterized in that, The method further includes: mapping the high-dimensional feature vector and the standard feature vector to the same two-dimensional plane using a principal component analysis algorithm, and rendering the points corresponding to the high-dimensional feature vector and the points corresponding to the standard feature vector in the two-dimensional plane with different colors to obtain a two-dimensional scatter projection map of the feature space, so as to display the two-dimensional scatter projection map of the feature space.

6. The AI ​​high availability evaluation method for metallographic data as described in claim 1, characterized in that, The preset VGG16 network is a VGG16 model that uses average pooling and does not have a top-level classifier.

7. The AI ​​high availability evaluation method for metallographic data as described in claim 1, characterized in that, The method further includes: obtaining attribute information of the target feature vector, displaying the attribute information and the cosine similarity, and generating an AI usability grading evaluation result.

8. A high-availability AI evaluation system for metallographic data, characterized in that, include: The request processing module is used to obtain user request information for metallographic structure image data and determine the request type of the user request information. The question-and-answer module is used to, if the request type is a question type for metallographic information question-and-answer, then, under the React mechanism, split the user request information into at least two sub-questions; map each sub-question to the same high-dimensional space through an embedding model to obtain a question vector for each sub-question; determine the context data for the question vector in a preset knowledge base through a parent-child paragraph retrieval strategy to obtain a context dataset; sort the context data in the context dataset through a Reranker model, and extract at least two of the top-ranked context data in the context dataset in descending order as prompt words for a preset question-and-answer model, so that the preset question-and-answer model outputs response information for the user request information based on the prompt words; The analysis module is configured to, if the request type is an analysis class for metallographic image analysis, extract a high-dimensional feature vector of the user request information using a preset VGG16 network, perform L2 normalization on the high-dimensional feature vector to obtain a target feature vector of the user request information; calculate the cosine similarity between the target feature vector and the standard feature vectors of each preset metallographic image in the preset knowledge base, and select the preset metallographic image corresponding to the user request information as the target metallographic image in the preset knowledge base in descending order of the cosine similarity; The structured process metadata of the target metallographic image is queried in the preset knowledge base, and the target metallographic image and the structured process metadata are displayed. A high availability confidence interval is constructed based on the cosine similarity, and the availability classification assessment of the target metallographic image is performed according to the high availability confidence interval to obtain a highly available target metallographic image with a cosine similarity greater than a first preset threshold and a low availability target metallographic image with a cosine similarity less than or equal to a second preset threshold.

9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the AI ​​high-availability evaluation method for metallographic data as described in any one of claims 1 to 7.

10. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by the processor, it implements the AI ​​high-availability evaluation method for metallographic data as described in any one of claims 1 to 7.

Citation Information

Patent Citations

  • Method for identifying original austenite grain boundary in martensite metallographic phase based on U-net network

    CN113256582A

  • Generation method, material, structural member, vehicle, device, medium and electronic equipment

    CN120708781A

  • Metallographic structure intelligent identification method based on neural network

    CN117523552A

  • AI-driven metallographic image analysis and classification system and method

    CN119206714A