Data detection method and device, computer equipment, readable storage medium and program product

By fusing image and text features from the input and output data of a large language model and using a second large language model for risk detection, the problem of low efficiency in content supervision generated by the large language model is solved, and efficient and accurate data detection and real-time review are achieved.

CN121614932APending Publication Date: 2026-03-06CHINA TELECOM CLOUD TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511753955.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-11-26
Publication Date
2026-03-06

AI Technical Summary

Technical Problem

In existing technologies, the content generated by large language models lacks effective supervision, resulting in low data detection efficiency, high false positive and false negative rates, heavy burden on manual review, and poor real-time performance.

Method used

By acquiring the input and output data of a large language model, image and text features are extracted and fused. A second large language model is used for risk detection. Multimodal fusion and dynamic weight adjustment are adopted, combined with deep learning and adaptive transfer learning frameworks to improve the accuracy of feature extraction and recognition.

Benefits of technology

It enables fast and accurate detection of large language model data, reduces false alarm and false negative rates, reduces the burden of manual review, and improves the real-time performance and adaptability of the system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121614932A_ABST
    Figure CN121614932A_ABST
Patent Text Reader

Abstract

The invention relates to a data detection method and device, computer equipment, a computer readable storage medium and a computer program product. The method comprises the steps of obtaining to-be-detected data corresponding to a first large language model, extracting image features of image data and text features of text data, fusing the image features and the text features to obtain fused features, and inputting the fused features into a second large language model to obtain a second large language model; and obtaining a risk detection result of the to-be-detected data output by the second large language model. By adopting the method, the data detection efficiency for the large language model can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of data processing technology, and in particular to a data detection method, apparatus, computer equipment, computer-readable storage medium, and computer program product. Background Technology

[0002] With the continuous development of the Internet and the continuous improvement of artificial intelligence technology, the amount of user-generated content is gradually increasing. Users can interact with large language models to obtain various types of data generated by the large language models, such as image data and / or video data. Users can publish the data generated by the large language models on various social media platforms. However, there is currently a lack of regulation for the content generated by large language models.

[0003] In existing technologies, user-generated content is monitored through manual review, which can be done by manually reviewing the user input and the output of the large language model. However, this method is inefficient. Summary of the Invention

[0004] Therefore, it is necessary to provide a data detection method, apparatus, computer equipment, computer-readable storage medium, and computer program product that can improve the data detection efficiency for large language models in response to the above-mentioned technical problems.

[0005] In a first aspect, this application provides a data detection method, comprising: acquiring the data to be detected corresponding to a first large language model; the data to be detected includes image data and text data, and the data to be detected includes input data and / or output data of the first large language model; extracting image features from the image data and text features from the text data, and fusing the image features and text features to obtain fused features; inputting the fused features into a second large language model to obtain the risk detection result of the data to be detected output by the second large language model.

[0006] In one embodiment, fusing image features and text features to obtain fused features includes: determining a first fusion weight for the image features and a second fusion weight for the text features based on the image features and text features; and performing weighted fusion processing on the image features and text features based on the image features, the first fusion weight, the text features, and the second fusion weight to obtain fused features.

[0007] In one embodiment, determining a first fusion weight for image features and a second fusion weight for text features based on image features and text features includes: determining a first attention score for image features relative to text features and determining a second attention score for text features relative to image features; determining a first fusion weight based on the first attention score and determining a second fusion weight based on the second attention score.

[0008] In one embodiment, determining a first fusion weight for image features and a second fusion weight for text features based on image features and text features includes: determining the feature similarity between image features and text features; determining the first fusion weight based on the feature similarity; and determining the second fusion weight based on the feature similarity.

[0009] In one embodiment, the fused features are input into the second largest language model to obtain the risk detection result of the data to be detected output by the second largest language model, including: inputting the fused features into the second largest language model, performing risk detection on the fused features through the second largest language model to obtain a risk detection value; and outputting the risk detection result based on the risk detection value through the second largest language model.

[0010] In one embodiment, extracting image features from image data and text features from text data includes: performing image enhancement on image data to obtain enhanced image data, and performing text preprocessing on text data to obtain enhanced text data; inputting the enhanced image data into an image encoder to obtain image features output by the image encoder, and inputting the enhanced text data into a text encoder to obtain text features output by the text encoder.

[0011] In one embodiment, image enhancement of image data to obtain enhanced image data includes: adjusting the size of the image data according to a preset image size to obtain first image data; performing color space conversion on the first image data to obtain second image data; and performing edge enhancement on the second image data to obtain enhanced image data.

[0012] In one embodiment, text preprocessing is performed on the text data to obtain enhanced text data, including: segmenting the text data into words to obtain multiple segmented texts; removing stop words from each segmented text to obtain multiple first segmented texts; and extracting entities from each first segmented text to obtain enhanced text data.

[0013] In one embodiment, the risk detection result includes a first risk detection result of the input data, and the method further includes: if the first risk detection result is not passed, generating a risk reminder message and displaying the risk reminder message on the interactive page of the first language model; the risk reminder message includes an appeal interface.

[0014] In one embodiment, the method further includes: obtaining an appeal instruction, which is obtained after detecting that the appeal interface has been triggered; sending input data to the review system; and after receiving the approval instruction sent by the review system, generating an approval message and displaying the approval message on the interactive page.

[0015] In one embodiment, the risk detection result also includes a second risk detection result of the output data, and the method further includes: if the second risk detection result is not passed, generating an audit reminder message and displaying the audit reminder message on the interactive page of the first language model, and displaying the output data on the interactive page after receiving the pass instruction sent by the audit system.

[0016] Secondly, this application also provides a data detection device, comprising: a data acquisition module for acquiring data to be detected corresponding to a first language model; the data to be detected includes image data and text data, including input data and / or output data of the first language model; a feature fusion module for extracting image features from the image data and text features from the text data, and fusing the image features and text features to obtain fused features; and a detection module for inputting the fused features into a second language model to obtain the risk detection result of the data to be detected output by the second language model.

[0017] Thirdly, this application also provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps of the method described in the first aspect.

[0018] Fourthly, this application also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the method described in the first aspect.

[0019] Fifthly, this application also provides a computer program product, including a computer program that, when executed by a processor, implements the steps of the method described in the first aspect above.

[0020] The aforementioned data detection method, apparatus, computer equipment, computer-readable storage medium, and computer program product, during the process of a user generating content using a first large language model, acquire input data or output data of the first large language model. The input and output data are the data to be detected, which includes image data and text data. Image features of the image data and text features of the text data are extracted, and the image features and text features are fused to obtain fused features. By fusing image features and text features, the data detection efficiency is improved. Furthermore, the fused features are input into a second large language model to obtain the risk detection result of the data to be detected output by the second large language model. Through the large language model, the fused features are detected quickly and accurately, thereby improving the data detection efficiency for the large language model. Attached Figure Description

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

[0022] Figure 1 This is a diagram illustrating the application environment of a data detection method in one embodiment;

[0023] Figure 2 This is a flowchart illustrating a data detection method in one embodiment;

[0024] Figure 3 This is a flowchart illustrating the steps of fusing image features and text features to obtain fused features in one embodiment.

[0025] Figure 4 This is a flowchart illustrating step 301 in one embodiment;

[0026] Figure 5 This is a flowchart illustrating step 301 in another embodiment;

[0027] Figure 6 This is a flowchart illustrating step 203 in one embodiment;

[0028] Figure 7 This is a flowchart illustrating the feature extraction steps in one embodiment;

[0029] Figure 8 This is a flowchart illustrating the steps of image enhancement to obtain enhanced image data in one embodiment.

[0030] Figure 9 This is a flowchart illustrating the steps of preprocessing text data to obtain enhanced text data in one embodiment.

[0031] Figure 10 This is a flowchart illustrating the steps in one embodiment when the first risk detection result is not passed;

[0032] Figure 11 This is a flowchart illustrating the appeal steps in one embodiment;

[0033] Figure 12 This is a flowchart illustrating the steps in one embodiment when the second risk detection result is not passed;

[0034] Figure 13 This is a flowchart illustrating the data detection method in another embodiment;

[0035] Figure 14 This is a structural block diagram of a data detection device in one embodiment;

[0036] Figure 15 This is an internal structural diagram of a computer device in one embodiment. Detailed Implementation

[0037] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.

[0038] It should be noted that the terms "first," "second," etc., used in this application can be used to describe various elements, but these elements are not limited by these terms. These terms are only used to distinguish the first element from the second element. The terms "comprising" and "having," and any variations thereof, used in this application, are intended to cover non-exclusive inclusion. The term "multiple" used in this application refers to two or more. The term "and / or" used in this application refers to one of the embodiments, or any combination of multiple embodiments.

[0039] The data detection method provided in this application embodiment can be applied to, for example... Figure 1 The application environment shown includes at least a terminal 101, a first server 102, and a second server 103. The first server 102 can deploy a first large language model 102-1, and the second server 103 can deploy a second large language model 103-1.

[0040] The terminal 101 can generate input data based on user input and send the input data to the first server 102 to input the input data into the first large language model 102-1. The terminal 101 can also receive and display the output data of the first large language model 102-1 sent by the first server 102. Furthermore, the terminal 101 can receive and display risk warning messages sent by the first server 102. The terminal 101 can be, but is not limited to, various personal computers, laptops, smartphones, tablets, drones, low-altitude aircraft, IoT devices, and portable wearable devices. IoT devices can include smart speakers, smart TVs, smart air conditioners, smart in-vehicle devices, projection devices, etc. Portable wearable devices can include smartwatches, smart bracelets, head-mounted devices, etc. Head-mounted devices can include virtual reality (VR) devices, augmented reality (AR) devices, smart glasses, etc.

[0041] The first server 102 receives input data from the terminal 101 and sends the input data to the second server 103. After the second server 103 performs a risk detection and passes the test, the input data is transmitted to the first large language model 102-1 to obtain output data, which is then sent to the second server 103. After the second server 103 performs a risk detection and passes the test, the output data is sent back to the terminal 101. The first large language model 102-1 can be deployed within the first server 102. The first server 102 can be an independent physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing cloud computing services.

[0042] The second server 103 receives the data to be detected from the first large language model 102-1 sent by the first server 102, inputs the data to be detected into the second large language model 103-1, and obtains the risk detection result output by the second large language model 103-1. The data to be detected includes the input data and output data of the first large language model 102-1. Furthermore, if the risk detection result is a failure, a risk detection message is sent to the first server 102; if the risk detection result is a success, a success message is sent to the first server 102.

[0043] With the rapid development of internet technology, the amount of user-generated content (UGC) has exploded. Online communities such as social media, forums, and live streaming platforms see massive amounts of content uploaded daily, much of which contains harmful information. This harmful content not only negatively impacts users' physical and mental health but may also trigger legal and social problems. Therefore, real-time image content security review has become particularly important. Effective content security review not only protects users from harmful information but also maintains the platform's reputation and compliance. In recent years, the development of deep learning and large-scale model technology has provided new solutions for content security review. In particular, multimodal large-scale models, through joint training of image and text data, can achieve deeper semantic understanding and feature extraction, significantly improving the accuracy and efficiency of review.

[0044] However, existing content security review systems still face numerous challenges. First, single-modal recognition is insufficient: existing systems primarily rely on image recognition technology, lacking comprehensive utilization of textual information, resulting in poor performance when recognizing complex content (such as images containing text, mixed text and images, etc.). Second, false positive and false negative rates are high; traditional methods are prone to false positives or false negatives when processing blurry or obscured content, especially when dealing with sensitive content, where the risk is even higher. Furthermore, the workload for manual review is heavy; although automated tools are widely used, issues with accuracy and reliability still necessitate extensive manual review, increasing operational costs and workload. Finally, real-time performance is poor; existing content security review systems often experience delays when processing large-scale data streams, failing to achieve real-time review and impacting user experience and platform security. These limitations restrict the practical application of existing systems, necessitating new technologies and methods to address these issues.

[0045] To address this, this application employs a large language model for data detection, simultaneously processing image and text information through multimodal fusion. Joint training enables deeper semantic understanding and feature extraction, improving recognition accuracy and robustness. This results in better performance when handling complex content, particularly images containing text and mixed image-text content. Furthermore, a dynamic weight-adjusted multimodal fusion approach dynamically adjusts the fusion weights of image and text features based on the complexity of the input content and the correlation between modalities. This method better adapts to different types of content, improving the flexibility and accuracy of feature fusion. In addition, a multi-layered interaction mechanism is introduced, dynamically adjusting the importance of different modal features by calculating the interaction score between image and text features. This mechanism better captures the correlation information between different modalities, improving the comprehensive representation capability of features and thus enhancing the model's recognition accuracy. A deep learning architecture can also be employed, automatically learning robust and rich feature representations from large amounts of data, reducing false positives and false negatives. This contributes to improving the overall performance and reliability of the system. For training large language models, an adaptive transfer learning framework can be used to dynamically adjust the transfer learning strategy based on the data characteristics and model performance of new tasks. This approach can improve the model's generalization ability and adaptability on new tasks, reduce dependence on large-scale labeled data, lower the cost of data collection and labeling, and enable the system to adapt more quickly to constantly changing content types and review standards.

[0046] In one exemplary embodiment, such as Figure 2 As shown, a data detection method is provided, which can be applied to... Figure 1 The second server in the example is used to illustrate the process, which includes the following steps 201 to 203.

[0047] Step 201: Obtain the detection data corresponding to the first major language model.

[0048] In this application, the data to be detected refers to data that requires risk detection, and is data related to the first large language model. The data to be detected includes the input data and / or output data of the first large language model; wherein, the first large language model can be a large language model that generates text and / or images, and the input data and output data of the first large language model can be text data and / or image data. The data to be detected includes image data and text data.

[0049] During implementation, the second server obtains the data to be detected corresponding to the first large language model. During the acquisition process, the second server can receive the data to be detected sent by the first server to which the first large language model belongs, and the first server can call the risk detection interface corresponding to the second server to send the data to be detected.

[0050] During execution, after receiving input data from the terminal, the first server sends the input data to the second server for risk detection. If the risk detection passes, the first server transmits the input data to the first large language model. Conversely, after receiving output data from the first large language model, the first server sends the input data to the second server for risk detection. If the risk detection passes, the first server sends the output data to the terminal. The risk detection process performed by the second server can be described in this embodiment and the embodiments described below.

[0051] Step 202: Extract image features from image data and text features from text data, and fuse the image features and text features to obtain fused features.

[0052] During implementation, the second server extracts image features from the image data and text features from the text data in the data to be detected, and performs fusion processing on the image features and text features to obtain fused features.

[0053] During feature extraction, the second server can first preprocess the image and text data. For image data, noise can be removed; for text data, proofreading can be performed. After preprocessing, feature extraction is then performed on the image and text data to obtain image features and text features. During extraction, multiple features can be extracted from the image data, and high-dimensional image features can be constructed based on these features. Similarly, multiple features can be extracted from the text data, and high-dimensional text features can be constructed based on these features. Image features may include at least one of feature maps, attention features, global features, and local features; text features may include at least one of word vectors, sentiment features, attention features, and syntactic tree features.

[0054] During feature fusion, the second server can perform fusion processing on image features and text features, or it can perform concatenation processing on image features and text features to obtain fused features. Alternatively, the second server can also perform weighted fusion on image features and text features to obtain fused features.

[0055] Step 203: Input the fused features into the second language model to obtain the risk detection results of the data to be detected output by the second language model.

[0056] During implementation, the second server inputs the fused features into a pre-trained second language model for risk detection processing, obtaining the risk detection results of the data to be detected from the output of the second language model. During the risk detection processing of the second language model, it can perform mapping processing based on the fused features to obtain the risk detection results corresponding to the fused features. In the detection process, the second language model can generate probabilities for "harmful content" and "non-harmful content." The risk score is based on the category with the higher probability. For example, if the probability of "harmful content" is 0.85, the risk score is 85. Based on a set threshold (0.55), it is determined whether the content passes the review. If the risk score is below the threshold, the content passes the review; if the risk score is above or equal to the threshold, the content is marked as high-risk content.

[0057] The second language model can be pre-trained. A training dataset can be pre-set, and the sample fusion features in the training dataset can be input into the initial large language model to obtain the mapping result. The loss is calculated based on the mapping result and the labels in the training dataset to obtain the loss value. The parameters of the initial large language model are adjusted based on the loss value until the loss value converges. The training of the second language model can be carried out on a cloud server or an offline server.

[0058] It should be noted that the second language model can also perform step 202, that is: the second language model can input the data to be detected into the second language model to obtain the risk detection result of the data to be detected output by the second language model; extract the image features of the image data and the text features of the text data through the second language model, fuse the image features and text features to obtain fused features, and determine the risk detection result based on the fused features.

[0059] In this application, the second major language model can include multiple hierarchical structures, such as feature extraction layers, feature fusion layers, mapping layers, and output layers. Alternatively, it can be configured as an input layer, hidden layers, and output layer. The model can be trained using transfer learning, primarily focusing on training the mapping layer. The training framework for the second major language model can be configured as an adaptive transfer learning framework: Adaptive Strategy Module: Dynamically adjusts the transfer learning strategy based on the data characteristics and model performance of the new task; Performance Monitoring: Monitors the model's performance on the new task and dynamically adjusts the learning rate, regularization parameters, and data augmentation strategies; Learning Rate Adjustment: Dynamically adjusts the learning rate based on the loss changes on the validation set. When the loss no longer decreases, the learning rate is appropriately reduced to avoid overfitting; when the loss decreases rapidly, the learning rate is appropriately increased to accelerate convergence; Regularization Parameter Adjustment: Dynamically adjusts the regularization parameters based on the model's performance on the new task to prevent overfitting and improve the model's generalization ability; Data Augmentation Strategy: Dynamically adjusts the data augmentation strategy based on the data characteristics of the new task to increase data diversity and representativeness. This adaptive transfer learning framework can improve the model's generalization ability and adaptability on new tasks, reduce dependence on large-scale labeled data, and lower the cost of data collection and labeling. The loss function can be the cross-entropy loss function, the optimizer can be Adam, the initial learning rate is 0.001, the batch size can be 32, the number of training epochs can be 10, L2 regularization can be used to prevent overfitting, early stopping can be set, and training can be stopped when the loss on the validation set no longer decreases. The learning rate can be dynamically adjusted by monitoring the loss changes and performance metrics on the validation set during training to balance training speed and model performance. Mixed precision training can also be used to further accelerate the training process.

[0060] For transfer learning strategies, the top-level network of a specific task can be fine-tuned based on the pre-trained model to adapt it to the new task; furthermore, based on the pre-trained model, some of the lower-level networks can be frozen, and only the top-level network can be trained to reduce training time and computational resource requirements; and joint training can also be performed on multiple related tasks to share the lower-level feature extraction network and improve the model's generalization ability.

[0061] For the mapping / hidden layers, they can be set as classifiers, using deep neural networks (DNNs) as classifiers, with fused features as input. For the network structure, the input layer can be set to 2816 dimensions (2048 + 768); the hidden layers are two fully connected layers, each with 512 neurons, and the activation function is ReLU; the output layer is a fully connected layer with an output dimension of 2 (for binary classification tasks), and the activation function is Softmax.

[0062] In the aforementioned data detection method, during the process of content generation using the first large language model, the input data or output data of the first large language model is obtained. The input data and output data are the data to be detected, which includes image data and text data. Image features of the image data and text features of the text data are extracted. The image features and text features are fused to obtain fused features. By fusing image features and text features, the data detection efficiency is improved. The fused features are then input into the second large language model to obtain the risk detection results of the data to be detected output by the second large language model. The large language model enables fast and accurate detection of the fused features, thereby improving the data detection efficiency for the large language model.

[0063] Based on the above exemplary embodiment, the following provides a data detection method in one or more exemplary embodiments, which is applied to... Figure 1 Taking the second server in the example, the following content will be included.

[0064] In the feature fusion process, image features and text features can be fused into a single feature. The weights of image features and text features in the fusion process can be determined, and fusion processing is performed based on these weights to improve the usability of the fused feature. One optional implementation method provided in this application is as follows: Figure 3 As shown, the image features and text features are fused to obtain the fused features, including steps 301 to 302:

[0065] Step 301: Determine the first fusion weight of the image features and the second fusion weight of the text features based on the image features and text features.

[0066] During implementation, the second server determines the first fusion weight of the image features based on the feature values ​​of the image features and the feature values ​​of the text features, and determines the second fusion weight of the text features based on the feature values ​​of the image features and the feature values ​​of the text features.

[0067] Step 302: Based on image features, the first fusion weight, text features, and the second fusion weight, perform weighted fusion processing on the image features and text features to obtain fused features.

[0068] During implementation, the second server multiplies the image features and the first fused features to obtain weighted image features, and multiplies the text features and the second fused features to obtain weighted text features. The weighted image features and the weighted text features are then fused to obtain fused features.

[0069] During the fusion process, the second server can use the first fusion weight and the second fusion weight to perform a weighted average of the image features and text features; for example, see formula (1):

[0070] Formula (1);

[0071] Where img_feature is the image feature, w img The first fusion weight is txt_feature, where w is the text feature. txt This is the second fusion feature.

[0072] During the fusion process, the second server can also concatenate image features and text features into a high-dimensional vector; for example, see formula (2):

[0073] Formula (2);

[0074] Among them, conbined_feature is the concatenated feature.

[0075] Furthermore, weighted enhancement can be performed first, and the weighted enhanced image features and text features can be concatenated to obtain a fusion vector; for example, see formula (3):

[0076] Formula (3);

[0077] Where interacted_img_feature is the weighted enhanced image feature, and interacted_txt_feature is the weighted enhanced text feature.

[0078] One optional implementation provided in this application performs feature fusion by weighted fusion of image features and text features, thereby achieving risk detection for both images and text simultaneously, improving risk detection efficiency. At the same time, the accuracy of risk detection is ensured by using a large language model.

[0079] In determining the fusion weights, the second server can determine the first fusion weight and the second fusion weight based on the attention score; in one optional implementation provided by this application, such as Figure 4 As shown, step 301 includes steps 401 to 402:

[0080] Step 401: Determine the first attention score of the image features relative to the text features, and determine the second attention score of the text features relative to the image features.

[0081] During implementation, the second server uses a multi-head attention mechanism to calculate the first attention score of image features relative to text features, and also uses a multi-head attention mechanism to calculate the second attention score of text features relative to image features.

[0082] For example, see formula (4):

[0083] Formula (4);

[0084] Here, (Q) and (K) are the query and key, respectively, which can be obtained from image features and text features through linear transformation.

[0085] Step 402: Determine the first fusion weight based on the first attention score, and determine the second fusion weight based on the second attention score.

[0086] During implementation, the second server determines the first fusion weight based on the first attention score, that is: the first attention score is used as the first fusion weight, and the second attention score is used as the second fusion weight.

[0087] Furthermore, during feature fusion, a multi-layer interactive network can be constructed, with each layer containing an attention mechanism and a feed-forward network. Through this multi-layer interactive network, the interaction between image and text features is enhanced layer by layer, capturing deeper semantic information. The output of the l-th layer can be referenced in formula (5):

[0088] Formula (5);

[0089] Among them, input l This represents the input features of the previous layer.

[0090] One optional implementation provided in this application determines the fusion weights of image features and text features through a cross-modal interaction enhancement network, thereby better capturing the correlation information between different modalities, improving the comprehensive representation ability of features, and thus improving the recognition accuracy of the second language model.

[0091] In determining the fusion weights, the second server can also determine the fusion weights of the image features and the text features based on the feature similarity between the image features and the text features; in one optional implementation provided by this application, such as Figure 5 As shown, step 301 includes steps 501 to 502:

[0092] Step 501: Determine the feature similarity between image features and text features.

[0093] During implementation, the second server uses cosine similarity or Euclidean distance to calculate the similarity between image features and text features, generating a similarity score between image features and text features.

[0094] For example, refer to formula (6):

[0095] Formula (6);

[0096] Where img_feature is the image feature and txt_feature is the text feature.

[0097] Step 502: Determine the first fusion weight based on feature similarity, and determine the second fusion weight based on feature similarity.

[0098] During implementation, the second server dynamically adjusts the weights of image features and text features based on the similarity score, determines the first fusion weight of image features based on feature similarity, and determines the second fusion weight of text features based on feature similarity.

[0099] For example, the process of determining the first fusion weight and the second fusion weight refers to formula (7):

[0100] Formula (7);

[0101] Among them, S img S represents the feature similarity of image features. txt This represents the feature similarity of text features.

[0102] One optional implementation provided in this application dynamically adjusts the fusion weights of image features and text features based on the complexity of the input content and the correlation between modalities, which can better adapt to different types of content and improve the flexibility and accuracy of feature fusion.

[0103] In the process of risk detection, a risk detection value can be calculated first using a second language model, and then the risk detection result can be determined based on the risk detection value; in one optional implementation method provided in this application, such as Figure 6 As shown, step 203 includes steps 601 to 602:

[0104] Step 601: Input the fused features into the second language model, and perform risk detection on the fused features through the second language model to obtain the risk detection value.

[0105] During implementation, the second server can input the fused features into the second largest language model. The second largest language model performs prediction or mapping processing based on the fused features to obtain the risk detection value corresponding to the fused features.

[0106] Step 602: Output the risk detection result based on the risk detection value using the second language model.

[0107] During implementation, the second language model determines the relationship between the risk detection value and the risk detection value threshold based on the risk detection value and the risk detection value threshold. If the risk detection value is less than the risk detection value threshold, it indicates that the data to be detected is safe data, and the risk detection result is that the detection passes. If the risk detection value is greater than or equal to the risk detection value threshold, it indicates that the data to be detected is risky data, and the risk detection result is that the detection fails.

[0108] One optional implementation method provided in this application performs risk detection based on the fusion features of the second major language model, which improves the accuracy and reliability of risk detection, while also increasing the efficiency of risk detection.

[0109] In the feature extraction process, the data can be preprocessed and enhanced before extracting the features of the enhanced data; in one optional implementation provided in this application, such as Figure 7 As shown, feature extraction includes steps 701 to 702:

[0110] Step 701: Image enhancement is performed on the image data to obtain enhanced image data, and text preprocessing is performed on the text data to obtain enhanced text data.

[0111] During implementation, the second server first performs image enhancement processing on the image data to obtain enhanced image data, and the second server also performs text enhancement processing on the text data to obtain enhanced text data.

[0112] In the process of enhancing image data, image enhancement can be performed based on one or more methods, such as size adjustment, pixel normalization, random flipping, color space conversion, and edge enhancement.

[0113] In the process of text data enhancement, one or more of the following methods can be used: image text recognition, word segmentation, stop word removal, sentiment analysis, spell correction, stemming, and entity recognition.

[0114] Step 702: Input the enhanced image data into the image encoder to obtain the image features output by the image encoder, and input the enhanced text data into the text encoder to obtain the text features output by the text encoder.

[0115] During implementation, the second server can input the enhanced image data into the image encoder to obtain the image features output by the image encoder, and input the enhanced text data into the text encoder to obtain the text features output by the text encoder.

[0116] During execution, the encoder can extract features in multiple dimensions. For image data, image features may include at least one of feature maps, global features, local features, and attention features. For text data, text features may include at least one of word vectors, sentiment features, context features, topic features, and syntax trees.

[0117] In addition, corresponding algorithms can be used to extract response features individually. For example, image features of enhanced image data can be extracted using feature map extraction algorithms; text features of enhanced text data can be extracted using sentiment feature extraction algorithms; and other feature extraction methods can be referred to the above examples, which will not be elaborated here.

[0118] One optional implementation method provided in this application involves first preprocessing and enhancing the data, then extracting features from the enhanced data to improve the usability of the features, thereby enhancing the reliability and accuracy of the risk detection results.

[0119] In the process of image data enhancement, the image data can first be resized, then color space transformed, and then edge enhancement performed to obtain enhanced image data; in one optional implementation provided in this application, such as Figure 8 As shown, image enhancement is performed on the image data to obtain enhanced image data, including steps 801 to 803:

[0120] Step 801: Adjust the image data according to the preset image size to obtain the first image data.

[0121] During implementation, the second server can adjust the image data according to the preset image size to obtain the adjusted first image data; during execution, the second server can adjust the image to a fixed size (e.g., 224x224) to ensure the consistency of input.

[0122] Furthermore, the second server can also normalize, augment, and filter noise in the first image data. During execution, the second server can normalize the pixel values ​​of the first image data to a range between 0 and 1, and / or perform random rotation, scaling, and horizontal flipping operations on the first image data to increase data diversity, and / or use noise filtering techniques to remove noise from the first image data and improve image quality. It should be noted that the above normalization, data augmentation, and noise filtering operations can be performed sequentially, i.e., normalization is performed first, data augmentation is performed on the normalized image data, and noise filtering is performed on the augmented data.

[0123] Step 802: Perform color space conversion on the first image data to obtain the second image data.

[0124] During the implementation process, the second server can perform color space conversion on the first image data to obtain the second image data after color space conversion; during the execution process, the second server can convert the image from the RGB color space to grayscale or other color spaces to reduce the data dimension and computational complexity.

[0125] Step 803: Perform edge enhancement on the second image data to obtain enhanced image data.

[0126] During the implementation process, the second server can perform edge enhancement on the second image data to obtain the enhanced image data after edge enhancement; during the execution process, the second server can use an edge detection algorithm to extract the edge information in the image and enhance the expression ability of features.

[0127] An optional implementation manner provided by this application improves the reliability of the image data through multiple rounds of image enhancement of the image data, thereby improving the reliability and accuracy of subsequent risk detection.

[0128] During the process of enhancing the text data, word segmentation processing, stop word removal, and entity extraction processing can be performed on the text data to obtain enhanced text data; in an optional implementation manner provided by this application, as Figure 9 shown, performing text preprocessing on the text data to obtain enhanced text data includes steps 901 to 903:

[0129] Step 901: Perform word segmentation processing on the text data to obtain multiple segmented text.

[0130] During the implementation process, the second server performs word segmentation processing on the text data to obtain multiple segmented text after word segmentation processing; during the execution process, the second server can use Jieba or other word segmentation tools to split the text into words.

[0131] In addition, there may also be risks when there is text in the image data. In response to this, the text in the image data can be extracted, and the second server can extract the text in the image data and write it into the text data; the second server can use Tesseract OCR or other mature tools to extract the text in the image.

[0132] Step 902: Remove stop words from each segmented text to obtain multiple first segmented text.

[0133] During the implementation process, the second server can remove stop words from each segmented text to obtain multiple first segmented text after stop word removal; during the execution process, the second server can remove common stop words, such as "de", "he", etc.

[0134] Furthermore, the second server can perform sentiment analysis, spell correction, and / or stemming on multiple first-segmented texts respectively. The second server can use a pre-trained sentiment analysis model to perform sentiment annotation on multiple first-segmented texts. The second server can also use a spell correction tool to correct spelling errors in multiple first-segmented texts. The second server can also use a stemming tool to restore multiple first-segmented texts to their basic form.

[0135] It should be noted that the above-mentioned sentiment analysis, spell correction and stemming operations can be performed in sequence, that is: first perform sentiment analysis, then perform spell correction on the sentiment analysis results, and then perform stemming on the spell correction results.

[0136] Step 903: Entity extraction is performed on each of the first segmented texts to obtain enhanced text data.

[0137] During implementation, the second server can extract entities from each of the first segmented texts to obtain the extracted enhanced text data. During execution, the second server uses Named Entity Recognition (NER) technology to extract key entity information from the text and uses the key entity information as enhanced text data.

[0138] One optional implementation provided in this application amplifies the features of text data by performing multiple rounds of enhancement, thereby improving the reliability and usability of text features.

[0139] In real-world scenarios, there may be situations where user-submitted input data is risky. Optionally, the risk detection result includes the initial risk detection result of the input data. There may also be situations where the risk detection result is inaccurate; an appeal interface can be set up on the interactive page of the first large language model. Optionally, the risk alert message includes the appeal interface. In one optional implementation provided by this application, such as... Figure 10 As shown, the method further includes step 1001:

[0140] Step 1001: If the first risk detection result is not passed, generate a risk warning message and display the risk warning message on the interactive page of the first language model.

[0141] During implementation, if the first risk detection fails, indicating that the user-submitted input data poses a risk, the second server can generate a risk warning message and send it to the first server for display on the interactive page of the first language model. This serves to remind the user that the submitted input data may be risky.

[0142] For example, a trained model can be used to perform initial screening of content, quickly filtering out obviously harmless content. Then, a risk assessment can be performed on the high-risk content that has been initially screened, generating a risk score. If the risk score is high, a risk warning message can be generated and displayed to the user.

[0143] One optional implementation provided in this application generates a risk warning message to remind the user when the input data is detected to be risky, and provides the user with an appeal interface so that the user can appeal, thereby improving the user interaction experience and adding an appeal function for risk detection.

[0144] Furthermore, after a user submits an appeal, the input data can be sent to the review system for a second review by manual verification; in one optional implementation provided by this application, such as Figure 11 As shown, the method further includes steps 1101 to 1102:

[0145] Step 1101: Obtain the appeal instruction.

[0146] The appeal instruction refers to the instruction generated and submitted by the terminal after the user triggers the appeal interface carried in the risk alert message, which is used to indicate that the user has an appeal need; the appeal instruction is obtained after the appeal interface is detected to be triggered.

[0147] During implementation, the first server receives the appeal instruction submitted by the terminal and forwards it to the second server. This is used to send content with high risk scores to human reviewers for further review.

[0148] Step 1102: Send the input data to the review system. After receiving the approval instruction from the review system, generate an approval message and display the approval message on the interactive page.

[0149] During implementation, the second server sends the input data to the review system for manual review. After the manual review is completed, the second server receives the review message sent by the review system. The review message includes a pass message and a fail message. If the review message is a pass message, it indicates that the input data is safe. The second server can then generate a pass message and send it to the first server to display the pass message on the interactive page.

[0150] In addition, if the review message is a "review failed" message, the second server can generate a "review failed" message and send it to the first server to display the "review failed" message on the interactive page.

[0151] Furthermore, the second server can also feed back the results of manual review to the model to continuously optimize model performance, or record the process and results of manual review for subsequent auditing and analysis.

[0152] One optional implementation method provided in this application improves the reliability of risk detection by combining large language model review with manual review. At the same time, it provides a remedy, which can be carried out through manual review, thereby improving the user's interactive experience.

[0153] In real-world scenarios, there are situations where the output of the primary language model contains risky content. In such cases, users can wait for the manual review results from the review system. Optionally, the risk detection results may also include a second risk detection result of the output data. In one optional implementation provided in this application, such as... Figure 12 As shown, the method also includes step 1201:

[0154] Step 1201: If the second risk detection result is not passed, generate an audit reminder message and display the audit reminder message on the interactive page of the first language model. After receiving the pass instruction sent by the audit system, display the output data on the interactive page.

[0155] During implementation, if the second risk detection result is unsuccessful, the second server generates an audit reminder message and sends it to the first language model to display the audit reminder message on the interactive page of the first language model. At the same time, the second server sends output data to the audit system. After receiving the approval instruction from the audit system, the second server displays the output data on the interactive page. In addition, after receiving the disapproval instruction from the audit system, the second server displays the audit failure message on the interactive page.

[0156] One optional implementation method provided in this application improves the reliability of risk detection by combining large language model review with manual review. At the same time, the manual review enhances the user's interactive experience.

[0157] In addition, the review system can recommend suitable human reviewers for review based on content type and risk level, thereby improving review efficiency and accuracy. The intelligent recommendation system can optimize the allocation of human review resources, improve review efficiency and accuracy, and reduce the workload of human reviewers.

[0158] In one embodiment, see Figure 13 The document illustrates a flowchart of a data detection method provided in an embodiment of this application, which can be applied to... Figure 1 In the second server shown. For example... Figure 13 As shown, the data detection method may include the following steps:

[0159] Step 1301: Obtain the detection data corresponding to the first large language model.

[0160] Optionally, the data to be detected includes image data and text data, including the input data and / or output data of the first language model.

[0161] Step 1302: Perform data augmentation on the image data to obtain augmented image data, and perform text preprocessing on the text data to obtain augmented text data.

[0162] Step 1303: Input the enhanced image data into the image encoder to obtain the image features output by the image encoder, and input the enhanced text data into the text encoder to obtain the text features output by the text encoder.

[0163] Step 1304: Determine the first fusion weight of the image features and the second fusion weight of the text features based on the image features and text features.

[0164] Step 1305: Based on image features, the first fusion weight, text features, and the second fusion weight, perform weighted fusion processing on image features and text features to obtain fused features.

[0165] Step 1306: Input the fused features into the second language model, perform risk detection on the fused features through the second language model to obtain risk detection values, and output the risk detection results based on the risk detection values ​​through the second language model.

[0166] Step 1307: If the first risk detection result is not passed, generate a risk warning message and send the risk warning message to the first server to which the first large language model belongs.

[0167] Optionally, the first server sends a risk warning message to the terminal; after receiving the risk warning message, the terminal displays the risk warning message on the interactive page of the first language model.

[0168] It should be noted that any one or more of steps 1301 to 1307 can be combined to form a new implementation method according to the needs of implementation and deployment. Furthermore, any one or more technical features in the technical solution composed of steps 1301 to 1307 can also be combined to form a new implementation method according to the actual deployment needs, or technical features in one or more optional implementation methods provided by one or more of the above embodiments can be combined to form a new implementation method. These will not be elaborated on here.

[0169] It should be understood that although the steps in the flowcharts of the embodiments described above are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the embodiments described above may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages in other steps. It is understood that the steps in different embodiments can be freely combined as needed, and all non-contradictory solutions formed by such combinations are within the scope of protection of this application.

[0170] Based on the same inventive concept, this application also provides a data detection apparatus for implementing the data detection method described above. The solution provided by this apparatus is similar to the implementation scheme described in the above method; therefore, the specific limitations in one or more data detection apparatus embodiments provided below can be found in the limitations of the data detection method described above, and will not be repeated here.

[0171] In one exemplary embodiment, such as Figure 14 As shown, a data detection device is provided, including: a data acquisition module 1401, a feature fusion module 1402, and a detection module 1403, wherein: the data acquisition module 1401 is used to acquire the data to be detected corresponding to a first large language model; the data to be detected includes image data and text data, and the data to be detected includes input data and / or output data of the first large language model; the feature fusion module 1402 is used to extract image features from the image data and text features from the text data, and fuse the image features and text features to obtain fused features; the detection module 1403 is used to input the fused features into a second large language model to obtain the risk detection result of the data to be detected output by the second large language model.

[0172] In one embodiment, the feature fusion module 1402 includes a weight determination unit and a fusion unit, wherein: the weight determination unit is used to determine a first fusion weight of the image features and a second fusion weight of the text features based on the image features and the text features; the fusion unit is used to perform weighted fusion processing on the image features and the text features based on the image features, the first fusion weight, the text features, and the second fusion weight to obtain fused features.

[0173] In one embodiment, the weight determination unit includes an attention score determination unit and a first weight transformation unit, wherein: the attention score determination unit is used to determine a first attention score of image features relative to text features, and to determine a second attention score of text features relative to image features; the first weight transformation unit is used to determine a first fusion weight based on the first attention score, and to determine a second fusion weight based on the second attention score.

[0174] In one embodiment, the weight determination unit includes a similarity determination unit and a second weight conversion unit, wherein: the similarity determination unit is used to determine the feature similarity between image features and text features; the second weight conversion unit is used to determine a first fusion weight based on the feature similarity and to determine a second fusion weight based on the feature similarity.

[0175] In one embodiment, the detection module 1403 includes a risk detection unit and a result output unit, wherein: the risk detection unit is used to input the fused features into the second language model, and perform risk detection on the fused features through the second language model to obtain a risk detection value; the result output unit is used to output the risk detection result based on the risk detection value through the second language model.

[0176] In one embodiment, the feature fusion module 1402 includes a data enhancement unit and a feature extraction unit, wherein: the data enhancement unit is used to perform image enhancement on image data to obtain enhanced image data, and to perform text preprocessing on text data to obtain enhanced text data; the feature enhancement unit is used to input the enhanced image data into an image encoder to obtain image features output by the image encoder, and to input the enhanced text data into a text encoder to obtain text features output by the text encoder.

[0177] In one embodiment, the data enhancement unit includes a size adjustment unit, a color conversion unit, and an edge enhancement unit, wherein: the size adjustment unit is used to adjust the size of the image data according to a preset image size to obtain first image data; the color conversion unit is used to perform color space conversion on the first image data to obtain second image data; and the edge enhancement unit is used to perform edge enhancement on the second image data to obtain enhanced image data.

[0178] In one embodiment, the data augmentation unit further includes a word segmentation unit, a word removal unit, and an entity extraction unit, wherein: the word segmentation unit is used to perform word segmentation processing on the text data to obtain multiple word segmented texts; the word removal unit is used to remove stop words from each word segmented text to obtain multiple first word segmented texts; and the entity extraction unit is used to extract entities from each first word segmented text to obtain augmented text data.

[0179] In one embodiment, the device further includes a risk alert message generation module, wherein: the risk alert message generation module is used to generate a risk alert message when the first risk detection result is unsuccessful, and display the risk alert message on the interactive page of the first large language model; the risk alert message includes an appeal interface.

[0180] In one embodiment, the device further includes an appeal instruction acquisition module and an audit message display module, wherein: the appeal instruction acquisition module is used to acquire appeal instructions, which are acquired after the appeal interface is detected to be triggered; the audit message display module is used to send input data to the audit system, and after receiving the approval instruction sent by the audit system, generate an audit approval message and display the audit approval message on the interactive page.

[0181] In one embodiment, the device further includes an audit reminder message display module, wherein: the audit reminder message display module is used to generate an audit reminder message and display the audit reminder message on the interactive page of the first large language model when the second risk detection result is not passed, and to display the output data on the interactive page after receiving the pass instruction sent by the audit system.

[0182] Each module in the aforementioned data detection device can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in the processor of a computer device in hardware form or independent of it, or stored in the memory of a computer device in software form, so that the processor can call and execute the operations corresponding to each module.

[0183] In one exemplary embodiment, a computer device is provided, which may be a server, and its internal structure diagram may be as follows: Figure 15 As shown, this computer device includes a processor, memory, input / output interfaces (I / O), and a communication interface. The processor, memory, and I / O interfaces are connected via a system bus, and the communication interface is also connected to the system bus via the I / O interfaces. The processor provides computational and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system, computer programs, and a database. The internal memory provides the environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The database stores detection data for a second language model. The I / O interfaces are used for exchanging information between the processor and external devices. The communication interface is used for communication with external terminals via a network connection. When executed by the processor, the computer program implements a data detection method.

[0184] Those skilled in the art will understand that Figure 15 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.

[0185] In an exemplary embodiment, a computer device is provided, including a memory and a processor. The memory stores a computer program, and the processor executes the computer program to perform the following steps: acquiring detection data corresponding to a first large language model; the detection data includes image data and text data, and the detection data includes input data and / or output data of the first large language model; extracting image features from the image data and text features from the text data, and fusing the image features and text features to obtain fused features; inputting the fused features into a second large language model to obtain the risk detection result of the detection data output by the second large language model.

[0186] In one embodiment, when the processor executes the computer program, it further performs the following steps: determining a first fusion weight of the image features and a second fusion weight of the text features based on the image features and text features; and performing weighted fusion processing on the image features and text features based on the image features, the first fusion weight, the text features, and the second fusion weight to obtain fused features.

[0187] In one embodiment, when the processor executes the computer program, it further performs the following steps: determining a first attention score of image features relative to text features, and determining a second attention score of text features relative to image features; determining a first fusion weight based on the first attention score, and determining a second fusion weight based on the second attention score.

[0188] In one embodiment, when the processor executes the computer program, it further performs the following steps: determining the feature similarity between image features and text features; determining a first fusion weight based on the feature similarity; and determining a second fusion weight based on the feature similarity.

[0189] In one embodiment, when the processor executes the computer program, it further performs the following steps: inputting the fused features into a second language model, performing risk detection on the fused features through the second language model to obtain a risk detection value, and outputting a risk detection result based on the risk detection value through the second language model.

[0190] In one embodiment, when the processor executes the computer program, it further performs the following steps: performing image enhancement on the image data to obtain enhanced image data, and performing text preprocessing on the text data to obtain enhanced text data; inputting the enhanced image data into an image encoder to obtain image features output by the image encoder, and inputting the enhanced text data into a text encoder to obtain text features output by the text encoder.

[0191] In one embodiment, when the processor executes the computer program, it further performs the following steps: adjusting the size of the image data according to a preset image size to obtain first image data; performing color space conversion on the first image data to obtain second image data; and performing edge enhancement on the second image data to obtain enhanced image data.

[0192] In one embodiment, when the processor executes the computer program, it further performs the following steps: performing word segmentation on the text data to obtain multiple segmented texts; removing stop words from each segmented text to obtain multiple first segmented texts; and extracting entities from each first segmented text to obtain enhanced text data.

[0193] In one embodiment, when the processor executes the computer program, it further performs the following steps: if the first risk detection result is unsuccessful, it generates a risk warning message and displays the risk warning message on the interactive page of the first language model; the risk warning message includes an appeal interface.

[0194] In one embodiment, when the processor executes the computer program, it also performs the following steps: obtaining an appeal instruction, which is obtained after detecting that the appeal interface has been triggered; sending input data to the review system; and after receiving the approval instruction sent by the review system, generating an approval message and displaying the approval message on the interactive page.

[0195] In one embodiment, when the processor executes the computer program, it further performs the following steps: if the second risk detection result is not passed, it generates an audit reminder message and displays the audit reminder message on the interactive page of the first language model; after receiving the pass instruction sent by the audit system, it displays the output data on the interactive page.

[0196] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, it performs the following steps: acquiring detection data corresponding to a first language model; the detection data includes image data and text data, and the detection data includes input data and / or output data of the first language model; extracting image features from the image data and text features from the text data, and fusing the image features and text features to obtain fused features; inputting the fused features into a second language model to obtain the risk detection result of the detection data output by the second language model.

[0197] In one embodiment, when the processor executes the computer program, it further performs the following steps: determining a first fusion weight of the image features and a second fusion weight of the text features based on the image features and text features; and performing weighted fusion processing on the image features and text features based on the image features, the first fusion weight, the text features, and the second fusion weight to obtain fused features.

[0198] In one embodiment, when the processor executes the computer program, it further performs the following steps: determining a first attention score of image features relative to text features, and determining a second attention score of text features relative to image features; determining a first fusion weight based on the first attention score, and determining a second fusion weight based on the second attention score.

[0199] In one embodiment, when the processor executes the computer program, it further performs the following steps: determining the feature similarity between image features and text features; determining a first fusion weight based on the feature similarity; and determining a second fusion weight based on the feature similarity.

[0200] In one embodiment, when the processor executes the computer program, it further performs the following steps: inputting the fused features into a second language model, performing risk detection on the fused features through the second language model to obtain a risk detection value, and outputting a risk detection result based on the risk detection value through the second language model.

[0201] In one embodiment, when the processor executes the computer program, it further performs the following steps: performing image enhancement on the image data to obtain enhanced image data, and performing text preprocessing on the text data to obtain enhanced text data; inputting the enhanced image data into an image encoder to obtain image features output by the image encoder, and inputting the enhanced text data into a text encoder to obtain text features output by the text encoder.

[0202] In one embodiment, when the processor executes the computer program, it further performs the following steps: adjusting the size of the image data according to a preset image size to obtain first image data; performing color space conversion on the first image data to obtain second image data; and performing edge enhancement on the second image data to obtain enhanced image data.

[0203] In one embodiment, when the processor executes the computer program, it further performs the following steps: performing word segmentation on the text data to obtain multiple segmented texts; removing stop words from each segmented text to obtain multiple first segmented texts; and extracting entities from each first segmented text to obtain enhanced text data.

[0204] In one embodiment, when the processor executes the computer program, it further performs the following steps: if the first risk detection result is unsuccessful, it generates a risk warning message and displays the risk warning message on the interactive page of the first language model; the risk warning message includes an appeal interface.

[0205] In one embodiment, when the processor executes the computer program, it also performs the following steps: obtaining an appeal instruction, which is obtained after detecting that the appeal interface has been triggered; sending input data to the review system; and after receiving the approval instruction sent by the review system, generating an approval message and displaying the approval message on the interactive page.

[0206] In one embodiment, when the processor executes the computer program, it further performs the following steps: if the second risk detection result is not passed, it generates an audit reminder message and displays the audit reminder message on the interactive page of the first language model; after receiving the pass instruction sent by the audit system, it displays the output data on the interactive page.

[0207] In one embodiment, a computer program product is provided, including a computer program that, when executed by a processor, performs the following steps: acquiring detection data corresponding to a first large language model; the detection data includes image data and text data, and the detection data includes input data and / or output data of the first large language model; extracting image features from the image data and text features from the text data, and fusing the image features and text features to obtain fused features; inputting the fused features into a second large language model to obtain the risk detection result of the detection data output by the second large language model.

[0208] In one embodiment, when the processor executes the computer program, it further performs the following steps: determining a first fusion weight of the image features and a second fusion weight of the text features based on the image features and text features; and performing weighted fusion processing on the image features and text features based on the image features, the first fusion weight, the text features, and the second fusion weight to obtain fused features.

[0209] In one embodiment, when the processor executes the computer program, it further performs the following steps: determining a first attention score of image features relative to text features, and determining a second attention score of text features relative to image features; determining a first fusion weight based on the first attention score, and determining a second fusion weight based on the second attention score.

[0210] In one embodiment, when the processor executes the computer program, it further performs the following steps: determining the feature similarity between image features and text features; determining a first fusion weight based on the feature similarity; and determining a second fusion weight based on the feature similarity.

[0211] In one embodiment, when the processor executes the computer program, it further performs the following steps: inputting the fused features into a second language model, performing risk detection on the fused features through the second language model to obtain a risk detection value, and outputting a risk detection result based on the risk detection value through the second language model.

[0212] In one embodiment, when the processor executes the computer program, it further performs the following steps: performing image enhancement on the image data to obtain enhanced image data, and performing text preprocessing on the text data to obtain enhanced text data; inputting the enhanced image data into an image encoder to obtain image features output by the image encoder, and inputting the enhanced text data into a text encoder to obtain text features output by the text encoder.

[0213] In one embodiment, when the processor executes the computer program, it further performs the following steps: adjusting the size of the image data according to a preset image size to obtain first image data; performing color space conversion on the first image data to obtain second image data; and performing edge enhancement on the second image data to obtain enhanced image data.

[0214] In one embodiment, when the processor executes the computer program, it further performs the following steps: performing word segmentation on the text data to obtain multiple segmented texts; removing stop words from each segmented text to obtain multiple first segmented texts; and extracting entities from each first segmented text to obtain enhanced text data.

[0215] In one embodiment, when the processor executes the computer program, it further performs the following steps: if the first risk detection result is unsuccessful, it generates a risk warning message and displays the risk warning message on the interactive page of the first language model; the risk warning message includes an appeal interface.

[0216] In one embodiment, when the processor executes the computer program, it also performs the following steps: obtaining an appeal instruction, which is obtained after detecting that the appeal interface has been triggered; sending input data to the review system; and after receiving the approval instruction sent by the review system, generating an approval message and displaying the approval message on the interactive page.

[0217] In one embodiment, when the processor executes the computer program, it further performs the following steps: if the second risk detection result is not passed, it generates an audit reminder message and displays the audit reminder message on the interactive page of the first language model; after receiving the pass instruction sent by the audit system, it displays the output data on the interactive page.

[0218] It should be noted that the user information (including but not limited to user device information, user personal information, user input data, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of related data must comply with relevant regulations.

[0219] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile memory and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM). The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, artificial intelligence (AI) processors, etc., and are not limited to these.

[0220] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this application.

[0221] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.

Claims

1. A data detection method characterized by, The method comprises: obtaining to-be-detected data corresponding to a first large language model; the to-be-detected data comprises image data and text data, and the to-be-detected data comprises input data and / or output data of the first large language model; extracting image features of the image data and text features of the text data, and fusing the image features and the text features to obtain fused features; inputting the fused features into a second large language model to obtain a risk detection result of the to-be-detected data output by the second large language model.

2. The method of claim 1, wherein, The method comprises: determining a first fusion weight of the image features and a second fusion weight of the text features according to the image features and the text features; performing weighted fusion processing on the image features and the text features according to the image features, the first fusion weight, the text features and the second fusion weight to obtain the fused features.

3. The method of claim 2, wherein, The method comprises: determining a first attention score of the image features relative to the text features and a second attention score of the text features relative to the image features; determining the first fusion weight based on the first attention score and determining the second fusion weight based on the second attention score.

4. The method of claim 2, wherein, The method comprises: determining a feature similarity between the image features and the text features; determining the first fusion weight according to the feature similarity and determining the second fusion weight according to the feature similarity.

5. The method of claim 1, wherein, The method comprises: performing image enhancement on the image data to obtain enhanced image data, and performing text preprocessing on the text data to obtain enhanced text data; inputting the enhanced image data into an image encoder to obtain the image features output by the image encoder, and inputting the enhanced text data into a text encoder to obtain the text features output by the text encoder.

6. The method of claim 5, wherein, The method comprises: adjusting the size of the image data according to a preset image size to obtain first image data; performing color space conversion on the first image data to obtain second image data; performing edge enhancement on the second image data to obtain the enhanced image data.

7. The method of claim 5, wherein, The method comprises: performing word segmentation processing on the text data to obtain a plurality of segmented texts; performing stop word removal on each of the segmented texts to obtain a plurality of first segmented texts; performing entity extraction on each of the first segmented texts to obtain the enhanced text data.

8. The method according to any one of claims 1 to 7, characterized in that, The method further comprises: In a case where the first risk detection result is failed, a risk reminding message is generated, and the risk reminding message is displayed on an interaction page of the first large language model; the risk reminding message comprises a complaint interface. The method further comprises:

9. The method of claim 1, wherein, An appeal instruction is obtained, and the appeal instruction is obtained after the complaint interface is detected to be triggered; The input data is sent to an audit system, and after a pass instruction sent by the audit system is received, an audit pass message is generated and displayed on the interaction page.

10. The method of claim 9, wherein, The risk detection result further comprises a second risk detection result of the output data, and the method further comprises: In a case where the second risk detection result is failed, an audit reminding message is generated and displayed on an interaction page of the first large language model, and after a pass instruction sent by an audit system is received, the output data is displayed on the interaction page. The apparatus comprises:

11. The method of claim 1, wherein, A data acquisition module configured to acquire data to be detected corresponding to a first large language model; the data to be detected comprises image data and text data, and the data to be detected comprises input data and / or output data of the first large language model; A feature fusion module configured to extract image features of the image data and text features of the text data, and fuse the image features and the text features to obtain fused features; 12. A data detection device, characterized by comprising: A detection module configured to input the fused features into a second large language model to obtain a risk detection result of the data to be detected output by the second large language model. The processor executes the computer program to implement the steps of the method of any one of claims 1 to 11. The computer program is executed by the processor to implement the steps of the method of any one of claims 1 to 11. The computer program is executed by the processor to implement the steps of the method of any one of claims 1 to 11.

13. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that, ​ 14. A computer readable storage medium having stored thereon a computer program, characterized in that, ​ 15. A computer program product comprising a computer program, characterized in that, ​