A method, device, medium and equipment for determining merchant tags

By modal segmentation and text conversion of merchant data, and using large language models to generate meta description information, the problems of attenuation and high maintenance costs of merchant tag identification results are solved, and comprehensive and accurate marking of merchant tags is achieved.

CN119293241BActive Publication Date: 2025-08-05ANT ZHIXIN HANGZHOU INFORMATION TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411830666.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-12-12
Publication Date
2025-08-05
Estimated Expiration
2044-12-12

AI Technical Summary

Technical Problem

In the prior art, different elements of merchants need to be trained to identify the models separately, resulting in fast attenuation of model identification results and high maintenance costs, and the lack of information of single data leads to inaccurate marking.

Method used

By splitting merchant data in modalities, converting text and aligning them uniformly, using a large language model to generate meta description information, combining the encoding and decoding process to determine merchant tags, and integrating structured and unstructured data.

Benefits of technology

It improves the richness and accuracy of merchant marking data, reduces model maintenance costs, and realizes a comprehensive and objective description of merchants and multi-category label marking.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119293241B_ABST
    Figure CN119293241B_ABST
Patent Text Reader

Abstract

The embodiments of this specification disclose a method, apparatus, storage medium and equipment for determining merchant tags, which divides merchant data by modality, performs text conversion separately, uses text as an intermediate state, aligns the data of different modalities in a unified format, inputs the comprehensive, objective and meaningful text content of the merchant through a large language model, i.e., meta description information, and finally obtains the merchant tag of the merchant through an encoding and decoding process. On the one hand, the collection of structured data and unstructured data improves the richness of the data required for merchant tagging. On the other hand, by converting it into text form, the alignment of data of different modalities is guaranteed, so that a comprehensive and objective description of the merchant can be achieved later. Based on the integrated and unified meta description information, merchants are tagged with multiple categories of tags, which also avoids the problem of inaccurate tagging caused by missing information of a single data.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to computer technology, and in particular to a method, device, medium and equipment for determining a merchant tag. Background Art

[0002] With the development of the internet and the rapid expansion of e-commerce and online service platforms, the number of merchants on these platforms has increased dramatically. To ensure the healthy operation of these platforms and the protection of consumer rights, continuous status monitoring and risk assessment of merchants has become crucial. This process can also be called the merchant recognition process.

[0003] In the existing technology, since the states that need to be monitored on the merchant side are diverse and there is no clear connection between different states, it is generally necessary to first separate the merchant elements that the platform needs to recognize in order to monitor these merchant elements. Among them, merchant recognition can be separated into merchant elements such as the merchant's industry, the merchant's business form, the commodity form, and so on. For the identification of each merchant element, it is necessary to train the corresponding classification model of the merchant element, and by inputting the preset type of merchant data, obtain the merchant's recognition result for the merchant element, that is, the merchant label. For example, the merchant's sales data is input into the classifier, and the classification result of the merchant's business form output by the classifier is a combination of online and offline, then the label for the merchant's business form is determined to be online + online. By determining the label of the merchant corresponding to each merchant element, the effect of identifying the merchant status can be achieved.

[0004] However, this approach of using different models for different merchant elements still presents certain issues. As business conditions evolve and other objective conditions change, model recognition results can degrade, and retraining the model incurs high maintenance costs. To address these issues, this specification provides a method, apparatus, medium, and device for determining merchant tags. Summary of the Invention

[0005] The embodiments of this specification provide a method for determining merchant tags, which is to divide merchant data by modality, perform text conversion separately, use text as an intermediate state, align the data of different modalities in a unified format, input the comprehensive, objective and meaningful text content of the merchant through a large language model, that is, meta description information, and finally obtain the merchant tag of the merchant through the encoding and decoding process. On the one hand, the collection of structured data and unstructured data improves the richness of the data required for merchant tagging. On the other hand, by converting it into text form, the alignment of data of different modalities is guaranteed, so that a comprehensive and objective description of the merchant can be achieved later. Based on the fusion of unified meta description information, multi-category tagging of merchants is carried out, which also avoids the problem of inaccurate tagging caused by missing information of a single data. The method includes:

[0006] Acquire merchant data of target merchants in different modalities, wherein the merchant data includes structured data and unstructured data;

[0007] For each modality of merchant data, the merchant data of the modality is input into a trained data encoder of the modality to determine text information describing the merchant data of the modality;

[0008] Combine the text information of each modality and the preset first prompt text as the description text of the target merchant, and input the description text into

[0009] A large language model to determine meta description information of the target merchant;

[0010] The meta description information is input into a trained text encoder to determine the characteristics of the target merchant, and then the merchant tag of the target merchant is determined through a tag decoder.

[0011] Furthermore, in some embodiments,

[0012] Obtain merchant data of target merchants in different modes, including:

[0013] According to the identifier of the target merchant, obtaining merchant data of the target merchant throughout its entire life cycle from a database;

[0014] Dividing the merchant data to determine merchant data of the target merchant belonging to different modalities;

[0015] The modality includes at least one of text data, image data, operation sequence data, table data, and merchant graph relationship data.

[0016] Furthermore, in some embodiments, the data encoder of the modality is trained using the following method, wherein:

[0017] Obtain merchant data of training merchants for training;

[0018] For each training merchant, the merchant data of the training merchant in the modality is used as a training sample for the data encoder of the modality, and based on the merchant data of the training merchant in the modality, text information describing the merchant data of the modality is obtained as a label for the training sample;

[0019] Based on the training samples and annotations, the data encoder of the modality is trained.

[0020] Furthermore, in some embodiments,

[0021] The text information of each modality and the preset prompt text are combined as the description text of the target merchant, specifically including:

[0022] Determine the labeling requirements of the target merchant;

[0023] According to the marking requirements, determine the key mode from each mode;

[0024] Determining, from a plurality of preset prompt texts, a prompt text containing the focus mode as the first prompt text;

[0025] The text information of each modality and the determined first prompt text are combined as a description text of the target merchant.

[0026] Furthermore, in some embodiments,

[0027] Determining the merchant tag of the target merchant through a tag decoder specifically includes:

[0028] The characteristics of the target merchant are input into each label classification layer of the label decoder, and the merchant label of the target merchant output by each label classification layer is determined.

[0029] Furthermore, in some embodiments,

[0030] Determining the merchant tag of the target merchant through a tag decoder specifically includes:

[0031] Obtaining historical merchant tagging information and inputting it into the retrieval enhancement generation network of the tag decoder to obtain a second prompt text for assisting the tag decoder in tagging;

[0032] The second prompt text and the features of the target merchant are combined and input into the large language network of the label decoder to obtain a merchant label of the target merchant.

[0033] Furthermore, in some embodiments,

[0034] Get the historical merchant tagging information, including:

[0035] Obtain historical labeling results for different merchants and / or obtain pre-set expert labeling rules as labeling information.

[0036] Furthermore, in some embodiments,

[0037] The method further comprises:

[0038] Determine the target merchant's historical label change frequency and / or the target merchant's historical business change frequency, and determine the target merchant's stability, where the stability is negatively correlated with the label change frequency and the stability is negatively correlated with the business change frequency;

[0039] Determining the labeling frequency of the target merchant according to the stability, wherein the higher the stability, the lower the labeling frequency;

[0040] The time for re-marking the target merchant is determined based on the last marking time of the target merchant and the determined marking frequency.

[0041] The embodiments of this specification also provide a device for determining a merchant tag, the device comprising:

[0042] An acquisition module, which acquires merchant data of target merchants in different modalities, wherein the merchant data includes structured data and unstructured data;

[0043] An encoding module, for each modality of merchant data, inputs the merchant data of the modality into a trained data encoder of the modality to determine text information describing the merchant data of the modality;

[0044] An extraction module combines the text information of each modality and a preset first prompt text as a description text of the target merchant, and inputs the description text into a large language model to determine meta description information of the target merchant;

[0045] The tagging module inputs the meta description information into the trained text encoder to determine the characteristics of the target merchant, and then determines the merchant label of the target merchant through the label decoder.

[0046] An embodiment of this specification also provides a computer program product, which stores at least one instruction, and the at least one instruction is suitable for being loaded by a processor and executing the above method steps.

[0047] An embodiment of this specification further provides a storage medium, wherein the storage medium stores a computer program, and the computer program is suitable for being loaded by a processor and executing the steps of the above method.

[0048] An embodiment of this specification further provides an electronic device, comprising: a processor and a memory; wherein the memory stores a computer program, and the computer program is suitable for being loaded by the processor and executing the steps of the above method.

[0049] In the embodiments of this specification, the merchant data is segmented by modality, and text conversion is performed separately. By using text as an intermediate state, the data of different modalities are aligned in a unified format. The comprehensive, objective and meaningful text content of the merchant, namely the meta description information, is input through a large language model, and finally the merchant tag of the merchant is obtained through the encoding and decoding process. On the one hand, the collection of structured data and unstructured data increases the richness of the data required for merchant labeling. On the other hand, by converting it into text form, the alignment of data of different modalities is guaranteed, so that a comprehensive and objective description of the merchant can be achieved later. Based on the integrated and unified meta description information, the merchant is labeled with multiple categories of labels, which also avoids the problem of inaccurate labeling caused by the lack of information of a single data. BRIEF DESCRIPTION OF THE DRAWINGS

[0050] Figure 1 A flowchart for determining a merchant tag is provided for the embodiments of this specification.

[0051] Figure 2 This is a schematic diagram of the merchant recognition process provided in the embodiments of this specification.

[0052] Figure 3 This is a schematic diagram of the process of obtaining a merchant tag from meta description information provided in the embodiments of this specification.

[0053] Figure 4 This is a structural diagram of a device for determining a merchant tag provided in an embodiment of this specification.

[0054] Figure 5 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this specification. DETAILED DESCRIPTION

[0055] To make the objectives, technical solutions, and advantages of this specification more clear, the following will clearly and completely describe the technical solutions of this specification in conjunction with the specific embodiments of this specification and the corresponding drawings. Obviously, the embodiments described are only part of the embodiments of this specification, not all of the embodiments. Based on the embodiments in this specification, all other embodiments obtained by ordinary technicians in this field without making any creative efforts are within the scope of protection of this specification.

[0056] Currently, the common approach to merchant recognition is to first break down the merchant elements to be recognized based on a pre-set strategy. For each merchant element, separate individual recognition models are constructed, such as the Merchant Category Code (MCC) model, the merchant business model, and the merchant closeness model. Alternatively, comprehensive models such as the merchant health model can be used for user recommendations and risk detection. Subsequently, the merchant's merchant label and confidence score are derived based on the prediction results of multiple individual recognition models.

[0057] However, unimodal cognitive models typically focus on fitting a specific label and are unable to effectively integrate and align multimodal merchant information with other single-item related data. Furthermore, as merchants grow, the model's accuracy declines, necessitating retraining of the single-item model.

[0058] Furthermore, the process of labeling merchants involves numerous individual models, and some labeling classification standards frequently change. For example, industry classification standards may change, and the evaluation criteria for indicators within the same industry may also be updated. Whenever these changes occur, individual models need to be retrained, resulting in high maintenance costs.

[0059] The present invention provides a flowchart of a method for determining a merchant tag according to an embodiment of the present invention to solve the above problem.

[0060] Based on this, see Figure 1 , the following will focus on Figure 1 The process shown is described in detail, and the method may specifically include the following steps:

[0061] S100: Acquire merchant data of different modalities of a target merchant, wherein the merchant data includes structured data and unstructured data.

[0062] Generally speaking, e-commerce and online service platforms require merchant tagging. Therefore, in one or more embodiments of this specification, the method for determining merchant tags can be performed by a server on the platform that requires merchant tagging. For ease of description, this specification also uses the example of a server performing the merchant tagging process. The server can be a single device or a distributed server composed of multiple devices. This specification does not impose any restrictions and can be configured as needed.

[0063] Specifically, the server may determine a target merchant based on a user-initiated merchant tagging request and execute the merchant tagging process. Of course, the server may also determine a merchant to be tagged from among various merchants based on pre-set rules as the target merchant. This specification does not limit when the server determines the target merchant and executes subsequent steps.

[0064] First, the server can determine the target merchant's identifier and, based on the identifier, retrieve multimodal data related to the identifier from the data as the merchant data of the target merchant. The merchant data retrieved by the server may include structured data and unstructured data. For example, images such as store photos, screenshots of online store homepages, and images of merchant products are unstructured data, while transaction data, transaction details, and backend operation data are structured data.

[0065] Secondly, the server can filter out text data related to the merchant from the merchant data as text modal data. Filter out image data from the merchant data as image modal data. Filter out the merchant's table data from the merchant data as table modal data. Filter out sequence data of the merchant's operating operations from the merchant data as action modal data. From the database, determine the graph data containing the merchant's identification, and use the obtained graph data as relationship graph modal data. Of course, the above-mentioned modalities are only examples mentioned in the embodiments of this specification. How to subdivide or merge the data modalities can be set as needed, and this specification does not limit it. That is to say, in one or more embodiments of this specification, the various modalities of the merchant data include at least one of: text modality, image modality, table modality, action modality and relationship graph modality, and this will be used as an example for explanation later.

[0066] In this specification, there is no restriction on the form of the target merchant's data to be obtained. We try to minimize restrictions from the source of the data to reduce the problem of inaccurate labeling due to missing data. Therefore, this specification does not differentiate between unstructured data and structured data.

[0067] It should be noted that the segmentation of merchant data of different modalities in this manual is not based solely on whether the data is structured or unstructured. This is only one of the judgment criteria.

[0068] S102: For each modality of merchant data, the merchant data of the modality is input into a trained data encoder of the modality to determine text information describing the merchant data of the modality.

[0069] In one or more embodiments of the present specification, after determining the merchant data of each modality, the server can encode the merchant data of each modality separately and determine the text information corresponding to the modality data to facilitate the subsequent fusion of different modality data.

[0070] Since risk control, recommendations, and other services are generally performed based on structured data as the data source for commercial scenarios, especially merchant scenarios, there is no "unification" problem between structured and unstructured data. However, this also leads to data loss, which may actually result in defects in the merchant labels determined. For example, for merchants across multiple business fields, they may provide both consumer-end electronic products and industrial-end algorithm services. In this case, labeling the merchant based solely on data from a certain modality will be insufficient.

[0071] To address the aforementioned issues, the embodiments of this specification capture both structured and unstructured data and tag target merchants. This presents a new challenge: how to align the data for subsequent unified processing. If this is still handled separately, the aforementioned issues will arise. To address this, this specification creatively employs a text-based approach to address the "alignment" between structured and unstructured data, as well as data of different modalities.

[0072] Specifically, the server determines a pre-trained data encoder for each modality of merchant data. The server then inputs the merchant data for that modality into the data encoder for that modality, obtaining text information output by the data encoder for that modality. Because the data encoder is used to convert the data for the corresponding modality into meaningful text information, the resulting text information can explain, illustrate, and describe the modality data at a textual level.

[0073] For example, let's assume that a table contains detailed transaction data for a target merchant over the past month. If we feed this table into a trained table-based data encoder, we'll get the following text: Over the past month, 10% of transactions for this merchant occurred between 4 and 5 pm, 15% between 5 and 6 pm, 20% between 6 and 7 pm, 25% between 7 and 8 pm, and the remainder after 8 pm. Less than 1% occurred after 1 pm. Transaction amounts were less than 100 yuan (20%), 10% between 100 and 200 yuan (30%), 20% between 200 and 300 yuan (35%), and less than 2% above 500 yuan (500 yuan). The maximum transaction amount is X yuan, and the minimum is Y yuan. The number of transactions in the past week decreased by 20% compared to the previous week, and the transaction amount decreased by 10%.

[0074] For example, let's assume the image is a menu image for a business. By feeding this environmental image data into the trained image modality data encoder, we obtain the following textual information: "This business operates in the restaurant industry, and its menu contents are as follows: A, B, C, ...." Of course, since a business's image data typically includes more than just menu images, feeding all image data into the image modality data encoder yields richer textual information.

[0075] The above example demonstrates that, through the encoding process, the server can unify merchant data in different modalities into text. Furthermore, this text is not simply a copy of the original data, but rather a statistically processed, high-density text. This compresses the data while achieving the effect of "aligning" data in different modalities.

[0076] S104: combining the text information of each modality and the preset first prompt text as a description text of the target merchant, and inputting the description text into a large language model to determine the meta description information of the target merchant.

[0077] In one or more embodiments of this specification, after the server obtains the text information corresponding to each modality, it can combine the text information of each modality and the preset first question text to obtain the description text of the target merchant. Then, through the large language model, the comprehensive description text of the target merchant, that is, the meta description information, is obtained. The process of the above steps S100~S104 can be regarded as a process of comprehensive cognition of the target merchant, and the meta description information finally obtained is also output through the large language model, so the user can clearly understand it, and in fact realizes the cognition of the merchant, such as Figure 2 As shown. Based on this comprehensive and clear understanding, you can then proceed with other operations. While meta descriptions are textual and therefore have a high information density, the absolute amount of data is still quite large. To facilitate quick identification of merchant status, you can proceed to determine the target merchant's merchant tag through subsequent steps.

[0078] Figure 2 This is a diagram of the merchant recognition process provided by the embodiment of this specification. In it, it can be seen that the input merchant data is divided into different modes. Through the corresponding data encoders, the output is the description data of text information, that is, text information A~E. After that, it is combined and input into the large language model to obtain the output meta description information, that is, Figure 2 "The merchant ID is XXX, the name is XX Catering, and the address is located in XXXX. There is a catering street near the address, where the catering industry is concentrated. The merchant's transaction time is concentrated from X p.m. to X midnight, and 80% of the transaction amount is distributed in the range of ZZ-ZZZ. The merchant has historically provided a business license and storefront photo, indicating that the business scope is catering. The currently signed acquiring products include XXX. The system has been labeled as a catering-fast food snack category. The association relationship shows that there have been two same-device relationships with the merchant ID XXXX in the past 7 days, and the association relationship between the two shows that the legal person is the same." Figure 2 The thick line surrounds the model structure, and the thin line surrounds the input and output data.

[0079] Specifically, this step is similar to the process of conventionally applying a large language model to summarize and unify data. By adding a preset first prompt text, the large language model determines the text to output. Combined with the text information from each modality determined in the previous step, the large language model can generate a meta description that is as comprehensive as possible, encompassing all objective factual information about the target merchant, and in a coherent and meaningful summary format. For example, the first prompt text might read: "Please help me consolidate all objective information about this merchant, keeping the description as concise as possible."

[0080] It should be noted that the large language model can directly adopt a mature general-purpose large language model, such as the GPT series model. Alternatively, the server can fine-tune a general-purpose large language model to obtain a model specifically used for determining meta description information. Of course, this manual does not limit the specific method of adjusting the large language model, and it can be configured as needed. For example, it may be necessary to provide minimal meta description information, or to provide structured meta description information, etc.

[0081] S106: Input the meta description information into the trained text encoder to determine the characteristics of the target merchant, and then use the label decoder to determine the merchant label of the target merchant.

[0082] In one or more embodiments of this specification, as described above, after determining the meta description information of the target merchant, the server can determine the corresponding merchant tags for the target merchant based on the meta description information. Because the meta description information is determined based on the entire amount of merchant data, it is not only highly information-dense but also complete and in a unified text format. Therefore, more accurate merchant tags can be determined based on the meta description information.

[0083] Specifically, the server may first input the meta description information into a trained text encoder to determine the characteristics of the target merchant. The text encoder can be a commonly used text encoder, such as the Bidirectional Encoder Representations from Transformers (BRET), the Electra model, or the Text-to-Text Transfer Transformer (T5). This specification does not impose any restrictions on this model and can be configured as needed.

[0084] The server then inputs the feature into a label decoder to determine the target merchant's merchant label. The label decoder can be a neural network structure. By inputting the feature into the label decoder, the feature is fed into different label classification layers, resulting in the merchant label of the target merchant output by each label classification layer. The classification labels can be manually pre-set. Of course, the text encoder and label decoder can be considered a codec structure, obtained through end-to-end training.

[0085] Alternatively, in one or more embodiments of this specification, the server may also incorporate a Retrieval-Augmented Generation (RAG) network into the tag decoder, generating merchant tags for target merchants using a large language model. This eliminates the need for users to manually set new tags; the powerful summarization capabilities of the large language model can be leveraged to generate new tags. The tag decoder is effectively a combination of the RAG and the large language model.

[0086] Specifically, first, the server needs to obtain the appropriate second prompt text through RAG, so the server can first obtain the marking information of the historical merchants.

[0087] Afterwards, the labeling information is input into the retrieval enhancement generation network of the label decoder to obtain a second prompt text for assisting the label decoder in labeling.

[0088] Finally, the server can combine the second prompt text and the target merchant's features and input them into the large language network of the label decoder to obtain the merchant label for the target merchant. The large language network is the large language model included in the label decoder. This large language model can be the same as the large language model used in the previous step, or a different large language model. This specification does not limit this and can be set as needed.

[0089] Figure 3 This is a schematic diagram of the process of obtaining merchant tags from meta description information provided in this specification. It can be seen that the server can obtain the second prompt text through the RAG model, combine it with the feature vector encoded by the text encoder, and input it into the large language model to obtain the output of each merchant tag, that is, Figure 3 The symbols shown on the right side of the figure. Figure 3 The thick line surrounds the model structure, and the thin line surrounds the input and output data.

[0090] based on Figure 1The method for determining merchant tags shown in the figure divides merchant data by modality, performs text conversion on each modality, and uses text as an intermediate state to align the data of different modalities in a unified format. The merchant's comprehensive, objective, and meaningful text content, namely meta-description information, is then input through a large language model. Finally, the merchant tag is obtained through an encoding and decoding process. On the one hand, the collection of structured and unstructured data increases the richness of the data required for merchant tagging. On the other hand, the conversion to text form ensures the alignment of data of different modalities, enabling a comprehensive and objective description of the merchant to be achieved later. Based on the integrated and unified meta-description information, the merchant is labeled with multiple categories, which also avoids the problem of inaccurate labeling caused by missing information from a single data.

[0091] It should be further explained that the process of determining the household label described above in this manual relies on a large language model to align and integrate multimodal data from the entire merchant domain life cycle in the form of text descriptions, thereby improving the ability and effectiveness of merchant cognition. In addition, the RAG model can be used to integrate expert experience and historical precipitation labels, that is, the labeling information of historical merchants. The large model's parameter volume and understanding and reasoning capabilities can greatly improve the effectiveness of single-modal, small-parameter models.

[0092] pass Figure 2 as well as Figure 3 As can be seen, this specification provides a two-stage merchant recognition model. Subsequently, the focus is on maintaining the large meta description model. Based on the meta description information generated, a simple classification layer can be used to lightweightly output merchant tags. This reduces the need for model retraining due to category changes or new requirements, thus reducing model maintenance costs.

[0093] In addition, in one or more embodiments of the present specification, since the requirements for merchant labels of target merchants are different in different business scenarios, when determining the first prompt text, a prompt text that better meets the requirements can be provided to improve labeling efficiency.

[0094] Specifically, the server may first determine the labeling requirements for the target merchant. Specifically, the server may first determine the labeling requirements for the target merchant input by the user, and the user may be an employee in the platform who is in charge of monitoring the status of merchants. Of course, the labeling requirements are input by the user as needed and may be natural language text. Alternatively, the server may provide the user with various optional labeling options, and the user may select the required labeling options as the labeling requirements for the target merchant. These labeling options may be positive labeling requirements, such as requiring the summary of which types of data to be highlighted, or may be negative labeling options, such as requiring the summary of which types of data to be ignored. This manual does not limit how the labeling requirements are specifically determined. The labeling requirements are used for subsequent models to understand the directions that need to be summarized and the directions that need to be ignored.

[0095] For example, when the user is not sensitive to the transaction content of a merchant but is more concerned about the relationship between the target merchant and other merchants, the labeling requirement may be: reduce the transaction description and increase the object relationship description.

[0096] Afterwards, the server can determine the key mode from each mode according to the labeling requirement. Continuing with the above example, the key modal data is the graph data. Specifically, the server can determine the keywords in the labeling requirement, and determine the key mode in each mode according to the correspondence between the preset keywords and the modal data. Of course, in the aforementioned embodiment, the labeling requirement may include positive and negative requirements. In addition to determining the keywords, the server can also determine the positive words or negative words corresponding to the keywords according to the sentence order. The server can use the keywords corresponding to the positive words as the keywords for determining the key mode.

[0097] Then, the server may determine a prompt text containing the key mode from among the preset multiple prompt texts as the first prompt text. Of course, if there are multiple key modes corresponding to the keyword, the server may determine a prompt text containing all key modes. If there is no prompt text containing all key modes, the server may determine a prompt text containing some key modes, and determine multiple prompt texts that, when combined, can cover all key modes as the first prompt text.

[0098] Furthermore, since the aforementioned requirements for labeling may also include requirements that need to be ignored or simplified, when determining the key mode, the mode corresponding to the requirements to be ignored or simplified may also be determined as a non-key mode. Therefore, when determining the first prompt text, the corresponding ignored or simplified text may also be determined based on the non-key mode. Continuing with the above example, the server may set the key mode to be graph data and the non-key mode to be transaction data. The server may also determine the following prompt text: "Simplify the description of the transaction class and describe the relationship between different merchants, especially the relationship with the legal person, as extensively as possible."

[0099] Finally, the server may combine the text information of each modality and the determined first prompt text as a description text of the target merchant.

[0100] Furthermore, in this specification, when obtaining historical merchant tagging information for input into the RAG model, the server may obtain historical tagging results for different merchants as the tagging information. Alternatively, it may obtain pre-set expert tagging rules as the tagging information. Alternatively, both may be used as the tagging information.

[0101] Furthermore, as described in step S100, this specification does not limit when the server performs the process of determining the merchant tag. However, when the server monitors the merchant status according to a preset frequency, the server needs to be able to automatically and repeatedly determine the merchant tag of the target merchant. For different target merchants, the server may use different frequencies to perform tagging.

[0102] Specifically, the server may determine the target merchant's historical label change frequency and / or the target merchant's historical business change frequency to determine the target merchant's stability, which is negatively correlated with the label change frequency and the business change frequency.

[0103] According to the stability, the labeling frequency of the target merchant is determined. The higher the stability, the lower the labeling frequency.

[0104] The time for re-marking the target merchant is determined based on the last marking time of the target merchant and the determined marking frequency.

[0105] In addition, in the embodiments of this specification, the data encoder is an encoder used to convert data of unintelligible modalities into text data, thereby achieving the effects of subsequent fusion and data alignment. Therefore, the encoder is not a common encoder that is only used for feature extraction. The output text information also needs to be a natural language that is easy for a large language model to understand. Therefore, the data encoder can be trained using the following method.

[0106] First, the server can obtain merchant data for training merchants. This merchant data is consistent with the merchant data requirements in step S100. However, because the data encoder requires pre-training, even if the training merchant is physically the same merchant as the target merchant, the corresponding merchant data is historical merchant data. Of course, the server can determine the merchant data of a large number of training merchants to train the data encoders of each modality to improve the effectiveness of the training data encoder.

[0107] Next, for each modality, the server needs to train the data encoder corresponding to that modality. For each training merchant, the server can use the merchant data for that modality as training samples for the data encoder for that modality. Based on the merchant data for that modality, the server can obtain textual information describing the merchant data for that modality as the annotation for the training sample. The annotations for each training sample can be manually annotated.

[0108] Finally, the server can train the data encoder of the modality based on the training samples and annotations, thereby obtaining the data encoder of each modality.

[0109] See Figure 4 , is a structural diagram of a device for determining a merchant tag provided in an embodiment of this specification. Figure 4 As shown, the device for determining the merchant tag can be implemented as all or part of the electronic device through software, hardware, or a combination of both. According to some embodiments, the device for determining the merchant tag includes an acquisition module 401, an encoding module 402, an extraction module 403, and a labeling module 404, specifically including:

[0110] An acquisition module 401 acquires merchant data of a target merchant in different modalities, wherein the merchant data includes structured data and unstructured data;

[0111] Encoding module 402, for each modality of merchant data, inputs the merchant data of the modality into a trained data encoder of the modality to determine text information describing the merchant data of the modality;

[0112] Extraction module 403 combines the text information of each modality and the preset first prompt text as a description text of the target merchant, and inputs the description text into a large language model to determine meta description information of the target merchant;

[0113] The tagging module 404 inputs the meta description information into the trained text encoder to determine the characteristics of the target merchant, and then determines the merchant tag of the target merchant through the tag decoder.

[0114] Optionally, the acquisition module 401 is used to obtain the merchant data of the target merchant throughout its entire life cycle from the database according to the identifier of the target merchant, divide the merchant data, and determine the merchant data of the target merchant belonging to different modalities, wherein the modality includes at least one of text data, image data, operation sequence data, table data, and merchant graph relationship data.

[0115] Optionally, the device also includes a training module 405, which is used to obtain merchant data of training merchants for training, and for each training merchant, use the merchant data of the training merchant in the modality as a training sample for the data encoder of the modality, and based on the merchant data of the training merchant in the modality, obtain text information used to describe the merchant data of the modality as an annotation of the training sample, and train the data encoder of the modality based on the training sample and the annotation.

[0116] Optionally, the extraction module 403 is used to determine the labeling requirements of the target merchant, determine the key mode from each mode based on the labeling requirements, determine the prompt text containing the key mode from the preset multiple prompt texts, as the first prompt text, and combine the text information of each mode and the determined first prompt text as the description text of the target merchant.

[0117] Optionally, the labeling module 404 is configured to input the features of the target merchant into each label classification layer of the label decoder, and determine the merchant label of the target merchant output by each label classification layer.

[0118] Optionally, the labeling module 404 obtains the labeling information of historical merchants and inputs it into the retrieval enhancement generation network of the label decoder to obtain a second prompt text for assisting the label decoder in labeling, combines the second prompt text and the features of the target merchant, inputs them into the large language network of the label decoder, and obtains the merchant label of the target merchant.

[0119] Optionally, the labeling module 404 obtains historical labeling results for different merchants and / or obtains pre-set expert labeling rules as labeling information.

[0120] Optionally, the acquisition module 401 determines the frequency of label changes in the history of the target merchant and / or the frequency of business changes in the history of the target merchant, determines the stability of the target merchant, the stability is negatively correlated with the frequency of label changes, and the stability is negatively correlated with the frequency of business changes. Based on the stability, the marking frequency of the target merchant is determined, the higher the stability, the lower the marking frequency. Based on the last marking time of the target merchant and the determined marking frequency, the time to re-mark the target merchant is determined.

[0121] The above-mentioned device embodiments correspond to the method embodiments. For detailed descriptions, please refer to the description of the method embodiments, which will not be repeated here. The device embodiments are obtained based on the corresponding method embodiments and have the same technical effects as the corresponding method embodiments. For detailed descriptions, please refer to the corresponding method embodiments.

[0122] The embodiment of this specification also provides a computer storage medium, which can store multiple instructions, and the instructions are suitable for being loaded and executed by a processor as described above. Figure 1 The method of the embodiment shown, the specific execution process can be found in Figure 1 The detailed description of the illustrated embodiment will not be repeated here.

[0123] This specification also provides a computer program product, which stores at least one instruction, and the at least one instruction is loaded and executed by the processor as described above. Figure 1 The method of the embodiment shown, the specific execution process can be found in Figure 1 The detailed description of the illustrated embodiment will not be repeated here.

[0124] The embodiments of this specification also provide Figure 5 The structural diagram of the electronic device shown in FIG. Figure 5 At the hardware level, the electronic device includes a processor, an internal bus, a network interface, memory, and non-volatile storage, and may also include other hardware required for its operations. The processor reads the corresponding computer program from the non-volatile storage into the memory and then runs it to implement the above-mentioned data processing method.

[0125] Of course, in addition to software implementation, this specification does not exclude other implementation methods, such as logic devices or a combination of software and hardware, etc. That is to say, the execution subject of the following processing flow is not limited to each logic unit, but can also be hardware or logic devices.

[0126] In the 1990s, technological improvements could be clearly distinguished as either hardware improvements (for example, improvements to circuit structures like diodes, transistors, and switches) or software improvements (improvements to process flows). However, with the advancement of technology, many process flow improvements can now be considered direct improvements to hardware circuit structures. Designers almost always create the corresponding hardware circuit structure by programming the improved process flow into the hardware circuit. Therefore, it cannot be said that a process flow improvement cannot be implemented using physical hardware modules. For example, a programmable logic device (PLD), such as a field programmable gate array (FPGA), is an integrated circuit whose logical function is determined by user programming. Designers can "integrate" a digital system on a PLD by programming it themselves, without having to hire a chip manufacturer to design and manufacture a dedicated integrated circuit chip. Moreover, nowadays, instead of manually fabricating integrated circuit chips, this programming is mostly performed using software called a "logic compiler." This is similar to the software compilers used during program development. Before compilation, the original code must be written in a specific programming language, called a Hardware Description Language (HDL). There are many types of HDL, including ABEL (Advanced Boolean Expression Language), AHDL (Altera Hardware Description Language), Confluence, CUPL (Cornell University Programming Language), HDCal, JHDL (Java Hardware Description Language), Lava, Lola, MyHDL, PALASM, and RHDL (Ruby Hardware Description Language). Currently, the most commonly used are VHDL (Very-High-Speed Integrated Circuit Hardware Description Language) and Verilog. Those skilled in the art will also understand that simply by programming a method flow in one of these hardware description languages and then programming it into an integrated circuit, a hardware circuit that implements the logic method flow can be easily obtained.

[0127] The controller can be implemented in any suitable manner. For example, the controller can take the form of a microprocessor or processor and a computer-readable medium storing computer-readable program code (e.g., software or firmware) executable by the (micro)processor, logic gates, switches, an application-specific integrated circuit (ASIC), a programmable logic controller, and an embedded microcontroller. Examples of controllers include, but are not limited to, the following microcontrollers: ARC 625D, Atmel AT91SAM, Microchip PIC18F26K20, and Silicone Labs C8051F320. The memory controller can also be implemented as part of the memory control logic. Those skilled in the art will also appreciate that, in addition to implementing the controller purely in computer-readable program code, the controller can also be implemented in the form of logic gates, switches, an application-specific integrated circuit, a programmable logic controller, an embedded microcontroller, etc. by logically programming the method steps. Therefore, such a controller can be considered a hardware component, and the means for implementing the various functions included therein can also be considered as structures within the hardware component. Alternatively, the means for implementing the various functions can be considered both a software module implementing the method and a structure within the hardware component.

[0128] The systems, devices, modules, or units described in the above embodiments may be implemented by computer chips or entities, or by products having certain functions. A typical implementation device is a computer. Specifically, the computer may be, for example, a personal computer, a laptop computer, a cellular phone, a camera phone, a smartphone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or a combination of any of these devices.

[0129] For the convenience of description, the above devices are described as being divided into various units according to their functions. Of course, when implementing this specification, the functions of each unit can be implemented in the same or multiple software and / or hardware.

[0130] Those skilled in the art will appreciate that the embodiments of this specification may be provided as methods, systems, or computer program products. Thus, this specification may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware. Furthermore, this specification may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0131] This specification is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of this specification. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 a process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0132] These computer program instructions may also be stored in a computer readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 a process or multiple processes and / or boxes Figure 1 The function specified in one or more boxes.

[0133] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operational steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing the instructions executed on the computer or other programmable device for implementing the process. Figure 1 a process or multiple processes and / or boxes Figure 1 A step that specifies a function in one or more boxes.

[0134] In a typical configuration, a computing device includes one or more processors (CPUs), input / output interfaces, network interfaces, and memory.

[0135] Memory may include non-permanent storage in a computer-readable medium, random access memory (RAM) and / or non-volatile memory in the form of read-only memory (ROM) or flash RAM. Memory is an example of a computer-readable medium.

[0136] Computer-readable media includes permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology to store information. The information can be computer-readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disc read-only memory (CD-ROM), digital versatile disc (DVD) or other optical storage, magnetic cassettes, magnetic tape, magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer-readable media does not include transitory computer-readable media (transitory media), such as modulated data signals and carrier waves.

[0137] It should also be noted that the terms "comprises," "includes," or any other variations thereof are intended to encompass non-exclusive inclusion, such that a process, method, commodity, or apparatus that includes a series of elements includes not only those elements but also other elements not explicitly listed, or includes elements inherent to such process, method, commodity, or apparatus. In the absence of further limitations, an element defined by the phrase "comprises a ..." does not exclude the presence of other identical elements in the process, method, commodity, or apparatus that includes the element.

[0138] Those skilled in the art will appreciate that the embodiments of this specification may be provided as methods, systems, or computer program products. Therefore, this specification may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware. Furthermore, this specification may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0139] This specification may be described in the general context of computer-executable instructions, such as program modules, executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, and the like that perform specific tasks or implement specific abstract data types. This specification may also be practiced in distributed computing environments where tasks are performed by remote processing devices connected through a communications network. In a distributed computing environment, program modules may be located in both local and remote computer storage media, including storage devices.

[0140] The various embodiments in this specification are described in a progressive manner. Similar parts between the various embodiments can be referred to in conjunction with each other. Each embodiment focuses on the differences between the other embodiments. In particular, the system embodiments are generally similar to the method embodiments, so the description is relatively simple. For relevant parts, refer to the description of the method embodiments.

[0141] The foregoing is merely an example of the present invention and is not intended to limit the present invention. Various modifications and variations are possible for those skilled in the art. Any modifications, equivalent substitutions, or improvements made within the spirit and principles of the present invention are intended to be included within the scope of the claims of the present invention.

Claims

1. A method for determining a merchant tag, comprising: Acquire merchant data of target merchants in different modalities, wherein the merchant data includes structured data and unstructured data; For each modality of merchant data, the merchant data of the modality is input into a trained data encoder of the modality to determine text information describing the merchant data of the modality; Using the text information as an intermediate state, the data of different modalities are aligned in a unified format; Combining the text information of each modality and the preset first prompt text as the description text of the target merchant, and inputting the description text into the large language model to determine the meta description information of the target merchant; The meta description information is input into a trained text encoder to determine the characteristics of the target merchant, and then the merchant tag of the target merchant is determined through a tag decoder.

2. The method according to claim 1, wherein obtaining merchant data of a target merchant in different modalities comprises: According to the identifier of the target merchant, obtaining merchant data of the target merchant throughout its entire life cycle from a database; Dividing the merchant data to determine merchant data of the target merchant belonging to different modalities; The modality includes at least one of text data, image data, operation sequence data, table data, and merchant graph relationship data.

3. The method of claim 1 , wherein the data encoder of the modality is trained using the following method, wherein: Obtain merchant data of training merchants for training; For each training merchant, the merchant data of the training merchant in the modality is used as a training sample for the data encoder of the modality, and based on the merchant data of the training merchant in the modality, text information describing the merchant data of the modality is obtained as a label for the training sample; Based on the training samples and annotations, the data encoder of the modality is trained.

4. The method according to claim 1, wherein the text information of each modality and the preset prompt text are combined as the description text of the target merchant, specifically comprising: Determine the labeling requirements of the target merchant; According to the marking requirements, determine the key mode from each mode; Determining, from a plurality of preset prompt texts, a prompt text containing the focus mode as the first prompt text; The text information of each modality and the determined first prompt text are combined as a description text of the target merchant.

5. The method according to claim 1, wherein determining the merchant tag of the target merchant by a tag decoder specifically comprises: The characteristics of the target merchant are input into each label classification layer of the label decoder, and the merchant label of the target merchant output by each label classification layer is determined.

6. The method according to claim 1, wherein determining the merchant tag of the target merchant by a tag decoder specifically comprises: Obtaining historical merchant tagging information and inputting it into the retrieval enhancement generation network of the tag decoder to obtain a second prompt text for assisting the tag decoder in tagging; The second prompt text and the features of the target merchant are combined and input into the large language network of the label decoder to obtain a merchant label of the target merchant.

7. The method according to claim 6, wherein obtaining the historical merchant tagging information comprises: Obtain historical labeling results for different merchants and / or obtain pre-set expert labeling rules as labeling information.

8. The method according to any one of claims 1 to 7, further comprising: Determine the target merchant's historical label change frequency and / or the target merchant's historical business change frequency, and determine the target merchant's stability, where the stability is negatively correlated with the label change frequency and the stability is negatively correlated with the business change frequency; Determining the labeling frequency of the target merchant according to the stability, wherein the higher the stability, the lower the labeling frequency; The time for re-marking the target merchant is determined based on the last marking time of the target merchant and the determined marking frequency.

9. A device for determining a merchant tag, the device comprising: An acquisition module, which acquires merchant data of target merchants in different modalities, wherein the merchant data includes structured data and unstructured data; An encoding module, for each modality of merchant data, inputs the merchant data of the modality into a trained data encoder of the modality to determine text information describing the merchant data of the modality; The extraction module uses the text information as an intermediate state and aligns the data of different modalities in a unified format; combines the text information of each modality and the preset first prompt text as the description text of the target merchant, and inputs the description text into the large language model to determine the meta description information of the target merchant; The tagging module inputs the meta description information into the trained text encoder to determine the characteristics of the target merchant, and then determines the merchant label of the target merchant through the label decoder.

10. A storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 8 are implemented.

11. An electronic device, characterized in that: include: A processor and a memory; wherein the memory stores a computer program, and the computer program is suitable for being loaded by the processor and executing the steps of the method according to any one of claims 1 to 8.

12. A computer program product having at least one instruction stored thereon, characterized in that: When the at least one instruction is executed by the processor, the steps of the method according to any one of claims 1 to 8 are implemented.