Method, computing program product and device for identifying specific type of user address

Through the combination of large language model and RAG technology, the user address is identified using a pre-built knowledge base, which solves the problem of inefficient user address recognition in the existing technology, and achieves more efficient and accurate address recognition, improving the efficiency and user experience of logistics distribution.

CN120499150APending Publication Date: 2025-08-15RAJAX NETWORK &TECHNOLOGY (SHANGHAI) CO LTD

Patent Information

Application Number
CN202510840011.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-06-20
Publication Date
2025-08-15

AI Technical Summary

Technical Problem

In the prior art, user address identification is inefficient and prone to errors, especially in the field of logistics and distribution, resulting in delivery delays and increased costs.

Method used

Using the large language model combined with RAG technology, we use pre-construction of knowledge bases, including positive and negative sample addresses, searching the associated sample addresses and building prompt words, to guide the large language model to determine whether the user address is a specific type.

Benefits of technology

It improves the accuracy and efficiency of user address recognition, reduces manual intervention, and improves delivery efficiency and user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120499150A_ABST
    Figure CN120499150A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a method for identifying a specific type of user address, a computing program product and equipment. A knowledge base can be constructed in advance, the knowledge base can comprise positive and negative sample addresses corresponding to different geographic space entities, the positive and negative sample addresses are address information describing the geographic space entities, the positive sample addresses are user addresses not belonging to the specific type, and the negative sample addresses are user addresses belonging to the specific type. When the to-be-recognized user address is recognized, the associated sample address related to the to-be-recognized user address can be retrieved from the knowledge base, and then the cue word is constructed by using the associated sample address, so that the large language model is guided to judge the to-be-recognized user address, and whether the to-be-recognized user address is a specific type of user address or not is determined. Through the combination of the large language model and the RAG technology, the accuracy of the recognition result of the user address can be improved, and meanwhile, the method is relatively simple and easy to implement because a special training model is not needed.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of this specification relate to the field of artificial intelligence technology, and more particularly to a method, computer program product, and device for identifying a specific type of user address. Background Art

[0002] In some scenarios, it is necessary to identify whether the user address is a specific type of address to facilitate subsequent applications. For example, in the field of logistics and distribution, an accurate delivery address is crucial to ensure timely and accurate delivery of goods. However, there may be various problems with the addresses provided by users, such as ambiguous addresses, invalid addresses, or wrong addresses. These problematic addresses may cause delivery delays or even failures, increase logistics costs and user dissatisfaction. In related technologies, when determining whether a user address is a specific type of address, it mainly relies on manual review and simple rule matching, which is inefficient and prone to errors. Therefore, it is necessary to provide a solution that is more efficient and accurate in identifying specific types of user addresses. Summary of the Invention

[0003] To overcome the problems existing in the related art, the embodiments of this specification provide a method, a computer program product, and a device for identifying a specific type of user address.

[0004] According to a first aspect of an embodiment of this specification, a method for identifying a specific type of user address is provided, the method comprising:

[0005] Get the address of the user to be identified;

[0006] Querying a pre-built knowledge base for associated sample addresses related to the user address to be identified, wherein the knowledge base stores positive sample addresses and / or negative sample addresses corresponding to different geographic spatial entities, the positive sample addresses do not belong to the specific type of user address, and the negative sample addresses belong to the specific type of user address;

[0007] Constructing a prompt word based on the associated sample address;

[0008] The prompt word is input into a large language model, so that the large language model determines whether the user address to be identified is a user address of the specific type based on the prompt word.

[0009] According to a second aspect of the embodiments of this specification, a computer program product is provided, comprising a computer program, wherein when the computer program is executed by a processor, the method mentioned in the first aspect is implemented.

[0010] According to a third aspect of the embodiments of this specification, an electronic device is provided, comprising a processor, a memory, and a computer program stored in the memory and executable by the processor, wherein the computer program implements the method mentioned in the first aspect above when executed.

[0011] According to a fourth aspect of the embodiments of this specification, a computer storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the method mentioned in the first aspect is implemented.

[0012] Beneficial effects of the embodiments of this specification: The embodiments of this specification can pre-construct a knowledge base, which can include positive and negative sample addresses corresponding to different geographic spatial entities, and the positive and negative sample addresses are address information describing the geographic spatial entity, wherein the positive sample address is a user address that does not belong to the specific type, and the negative sample address is a user address that belongs to the specific type. When identifying the user address to be identified, the associated sample address related to the user address to be identified can be retrieved from the knowledge base first, and then the associated sample address can be used to construct a prompt word to guide the large language model to judge the user address to be identified and determine whether it is a user address of a specific type. By combining the large language model and RAG technology, the accuracy of the user address recognition result can be improved, and at the same time, since there is no need to specially train the model, it is relatively simple and easy to implement.

[0013] It should be understood that the foregoing general description and the following detailed description are merely exemplary and explanatory and are not restrictive of the embodiments of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS

[0014] The accompanying drawings herein are incorporated in and constitute a part of the embodiments of this specification, illustrate embodiments consistent with the embodiments of this specification, and together with the description, serve to explain the principles of the embodiments of this specification.

[0015] Figure 1 This is a schematic diagram of an application scenario shown in an exemplary embodiment of this specification;

[0016] Figure 2 A flowchart illustrating a method of identifying a specific type of user address according to an exemplary embodiment of this specification;

[0017] Figure 3 This is a schematic diagram showing prompt information displayed on a rider client according to an exemplary embodiment of this specification;

[0018] Figure 4 This is a schematic diagram of notifying a user to modify a delivery address according to an exemplary embodiment of this specification;

[0019] Figure 5This is a schematic diagram of retrieving associated sample addresses from a knowledge base according to an exemplary embodiment of this specification;

[0020] Figure 6 This is a schematic diagram of a method for identifying whether a delivery address is an ambiguous address according to an exemplary embodiment of this specification;

[0021] Figure 7 This is a schematic diagram of building a knowledge base according to an exemplary embodiment of this specification;

[0022] Figure 8 This is a logic block diagram of an electronic device according to an exemplary embodiment of this specification. DETAILED DESCRIPTION

[0023] Exemplary embodiments will be described in detail herein, with examples illustrated in the accompanying drawings. In the following description, when referring to the drawings, identical numerals in different figures represent identical or similar elements, unless otherwise indicated. The embodiments described in the following exemplary embodiments are not intended to represent all possible implementations consistent with the embodiments of this specification. Rather, they are merely examples of apparatuses and methods consistent with certain aspects of the embodiments of this specification, as detailed in the appended claims.

[0024] The terms used in the embodiments of this specification are for the purpose of describing specific embodiments only and are not intended to limit the embodiments of this specification. The singular forms "a," "the," and "the" used in the embodiments of this specification and the appended claims are also intended to include plural forms unless the context clearly indicates otherwise. It should also be understood that the term "and / or" used herein refers to and includes any or all possible combinations of one or more of the associated listed items.

[0025] It should be understood that although the terms first, second, third, etc. may be used to describe various information in the embodiments of this specification, such information should not be limited to these terms. These terms are only used to distinguish the same type of information from each other. For example, without departing from the scope of the embodiments of this specification, the first information may also be referred to as the second information, and similarly, the second information may also be referred to as the first information. Depending on the context, the word "if" as used herein can be interpreted as "when..." or "when..." or "in response to determining."

[0026] In many scenarios, users are required to fill in their addresses. In some scenarios, the addresses filled in by users may not meet the requirements, for example, the addresses may be incorrect, unclear, invalid, or false. For these scenarios, it is usually necessary to use some detection methods to identify such user addresses for subsequent processing, such as reminding users to fill in their addresses again.

[0027] Taking the field of logistics and distribution as an example, both merchants and users need to fill in their own addresses in the distribution system. Accurate addresses help distribution capacity to pick up or deliver goods in a timely manner, thereby improving distribution efficiency. For example, taking the delivery address as an example, an accurate delivery address is crucial to ensuring that goods are delivered in a timely and accurate manner. However, there may be various problems with the addresses provided by users, such as ambiguous addresses, invalid addresses, or wrong addresses. These problematic addresses may cause delivery delays or even failures, increase logistics costs, and user dissatisfaction. In related technologies, when determining whether a user address is of a specific type of address, it mainly relies on manual review and simple rule matching, which is inefficient and prone to errors.

[0028] With the development of artificial intelligence, models have been widely applied in various fields. Some technologies can also use pre-trained models to predict whether a user's address is a specific type of address. For example, a large number of training samples can be obtained to train a model specifically for identifying specific types of user addresses. However, this approach often requires a large amount of training data, which is cumbersome, and the model training process is time-consuming and computationally resource-intensive.

[0029] At present, various open source large language models have been widely used. Large language models refer to deep learning models trained with large amounts of text data, which enable the model to generate natural language text or understand the meaning of language text. Given that large language models have better performance in understanding natural language, and user addresses are actually text information, the applicant has thought of using open source large language models to realize the recognition of specific types of user addresses. Furthermore, in order to improve the accuracy and precision of the recognition results of large language models, the applicant has thought of combining RAG (Retrieval-Augmented Generation) technology to pre-build a knowledge base. The knowledge base can include positive and negative sample addresses corresponding to different geographic spatial entities. The positive and negative sample addresses are address information describing the geographic spatial entity, where the positive sample address is a user address that does not belong to the specific type, and the negative sample address is a user address that belongs to the specific type. When identifying the user address to be identified, the associated sample addresses related to the user address to be identified can be retrieved from the knowledge base first, and then the associated sample addresses can be used to construct prompt words to guide the large language model to judge the user address to be identified and determine whether it is a user address of a specific type. By combining a large language model with RAG technology, the accuracy of user address recognition results can be improved. At the same time, since no special model training is required, it is relatively simple and easy to implement.

[0030] The specific type of user address recognition method provided in the embodiments of this specification can be executed by various electronic devices. The electronic device can call the interface provided by the large language model to input prompt words to the large language model to guide the large language model to recognize the user address to be recognized, and obtain the recognition result output by the large language model. The electronic device can be a mobile phone, a computer, a cloud server, a server cluster, etc., and the embodiments of this specification are not limited thereto.

[0031] In the embodiments of this specification, the specific type of user address can be a user-defined user address that conforms to certain rules or characteristics, and can be flexibly set based on actual needs. The user address can be the address of an individual, organization, company, or merchant. For example, in some embodiments, the specific type of user address can be one or more of an ambiguous user address, an invalid user address, an erroneous user address, and a false user address. An ambiguous address can be an address whose location cannot be accurately determined due to missing or inaccurate information.

[0032] For example, Figure 1 As shown, it is a schematic diagram of an application scenario of an embodiment of this specification. This embodiment uses a large language model to identify the user address in the delivery order and identify whether the user address is a specific type of address (for example, a fuzzy address). Usually, the instant delivery service scenario involves multi-party interaction between the server, merchants, delivery capacity and users. Among them, the service platform is equipped with a server and provides users with a user client, and users can use the services provided by the service platform through the user client; unlike the user client for users, the service platform also provides merchants with a merchant client for merchants, and merchants can use the services provided by the service platform through the merchant client. Delivery capacity refers to a party with delivery capabilities, including but not limited to delivery personnel, such as the so-called riders. Delivery capacity can communicate with the server through the delivery capacity client used for delivery capacity. In other examples, delivery capacity can also include unmanned delivery equipment, such as unmanned aerial vehicles, unmanned vehicles, etc. Among them, each user can trade with the merchant through the user client and can initiate a delivery order; the service party can allocate delivery capacity for the instant delivery order.

[0033] For example, a user selects a target product on the user client, places an order for the target product, and fills in the corresponding delivery address to generate a target order in the user client. The user client then sends the target order (including the delivery address) to the server. The server can then send the target order to the merchant client so that the merchant client can prepare the product. Simultaneously, the server can send the target order to the delivery carrier client. The delivery carrier obtains the target order through the delivery carrier client and decides whether to accept the order. Once the delivery carrier accepts the order, it can retrieve the target product from the merchant client and deliver it to the address entered by the user. If the address entered by the user is unclear, such as an ambiguous address, the delivery carrier may not be able to find the user's location based on the address information. To avoid delays in delivery efficiency and a reduced user experience due to ambiguous user addresses, after obtaining the target order, the server can query the knowledge base for related sample addresses based on the delivery address carried in the target order. It then constructs a prompt word based on the related sample addresses and calls the interface provided by the large language model to input the prompt word into the large language model so that the large language model can output a judgment result. Among them, if the server determines that the delivery address is ambiguous based on the judgment result of the big language, a prompt message can be displayed on the delivery capacity client to prompt the delivery capacity that the delivery address is ambiguous. The delivery capacity can then determine whether it is necessary to notify the user to modify the delivery address based on actual experience.

[0034] like Figure 2 As shown, the method for identifying a specific type of user address provided in the embodiment of this specification may include the following steps:

[0035] S202: Obtain the address of the user to be identified;

[0036] In step S202, the user address to be identified can be obtained. The user address to be identified can be any address whose type needs to be determined. For example, in the field of logistics and delivery, the user address to be identified can be the delivery address in a logistics order. Of course, in other scenarios, the user address to be identified can also be an address filled in by the user for other purposes, and the specific address can be flexibly set based on actual needs.

[0037] S204. Querying a pre-built knowledge base for associated sample addresses related to the user address to be identified, wherein the knowledge base stores positive sample addresses and / or negative sample addresses corresponding to different geographic spatial entities, the positive sample addresses do not belong to the specific type of user address, and the negative sample addresses belong to the specific type of user address;

[0038] Prompts are text input into a large language model to guide it to generate specific outputs. Designing effective prompts can significantly improve the performance and output quality of the large language model.

[0039] RAG technology is an AI technology that combines information retrieval and generative models (such as large language models) to improve the knowledge accuracy and contextual understanding capabilities of generative models. RAG technology first retrieves information relevant to the user's query from external knowledge bases (such as databases, documents, web pages, etc.). This information is then fed into the generative model, which then generates a natural language response based on the retrieved context. By searching external knowledge bases, RAG technology can provide more accurate information and avoid errors caused by traditional generative models due to outdated or incomplete knowledge.

[0040] In step S204, to improve the accuracy of the recognition results of the large language model, a knowledge base can be pre-built based on actual application scenarios. This knowledge base includes positive and / or negative sample addresses corresponding to different geospatial entities, where positive sample addresses do not belong to a specific type of user address, and negative sample addresses belong to that specific type of user address. The knowledge base can be built based on some historical service data. For example, to identify whether a delivery address in the logistics and distribution field is a specific type of address, the knowledge base can be built based on historical physical order information. A geospatial entity can be an AOI (Area of Interest) defined by a user in geospatial space, such as a campus, a building, or a unit within a building. For each geospatial entity, positive and negative sample addresses for that geospatial entity can be obtained based on historical service data. For example, if a specific type of user address is an ambiguous address and the geospatial entity is a building, addresses that clearly describe the building's location can be obtained as positive sample addresses for the building, and addresses that do not clearly describe the building's location can be obtained as negative sample addresses for the building.

[0041] After obtaining the address of the user to be identified, the knowledge base can be searched for sample addresses related to the address to be identified, hereinafter referred to as associated sample addresses. The associated sample addresses can belong to the same geographic spatial entity as the address to be identified, or to the same type of spatial geographic entity, or to a relatively close geographic spatial entity. The specific configuration can be flexibly determined based on actual needs.

[0042] S206, constructing a prompt word based on the associated sample address;

[0043] In step S206, after finding the sample addresses associated with the user address to be identified, a prompt word can be constructed based on the sample addresses. This prompt word is used to guide the large language model in identifying the address to be identified. The sample addresses can serve as historical cases for the large language model to learn from. By learning the sample addresses, the large language model can understand the characteristics of user addresses belonging to a specific type and those not belonging to a specific type, thereby assisting in the determination of the user address to be identified based on this learned knowledge.

[0044] Among them, in addition to the above-mentioned related samples, the prompt words can also include other content based on actual needs. For example, other content can be the role set for the large language model, the content specified for the large language model output, some judgment rules provided to the large language model, etc., which can be set based on actual needs.

[0045] S208: Input the prompt word into a large language model, so that the large language model determines whether the user address to be identified is a user address of the specific type based on the prompt word.

[0046] In step S208, after the prompt word is constructed, the prompt word can be input into the large language model so that the large language model can determine whether the user address to be identified is a specific type of user address based on the prompt word. The content output by the large language model can be set based on actual needs. For example, the output result can be a text description such as "the user address to be identified is a specific type of user address", "the user address to be identified is not a specific type of user address", or the output result can also be the probability that the user address to be identified is a specific type of user address. In addition, in addition to outputting the recognition result, the large language model can also output other content, such as the judgment basis for obtaining the judgment result, the reasoning process, etc. The large language model can be various open source large language models, or it can be a fine-tuned large language model specifically used to identify specific types of user addresses.

[0047] In some embodiments, the specific type of user address identification method can be applied to the field of logistics and distribution, and the user address to be identified can be the delivery address corresponding to the target logistics order. For this type of scenario, when building a knowledge base, multiple first logistics orders and multiple second logistics orders can be screened out from the historical logistics orders, wherein the delivery addresses of the multiple first logistics orders are reported as belonging to the specific type of address. For example, when the delivery capacity is delivering an order, if it is found that the delivery address is unclear, inaccurate or an incorrect address, it will usually report to the service platform the relevant information indicating that the delivery address is abnormal (for example, unclear, inaccurate, etc.). The service platform can record the reporting information and then determine whether the historical logistics order belongs to a specific type of address based on the reporting information. Among them, the multiple second logistics orders are logistics orders that have been successfully delivered and have not timed out. Usually, for orders that have been successfully delivered and have not timed out, their delivery addresses are often accurate and clear. Therefore, for such orders, it can be considered that their delivery addresses do not belong to a specific type of user address. After screening out the first logistics orders and the second logistics orders, the multiple first logistics orders can be clustered based on the spatial geographic entity to obtain the first logistics orders corresponding to different spatial geographic entities, that is, the spatial geographic entity corresponding to each category obtained by clustering can be used as the category label of the category. For example, taking the spatial geographic entity as a certain community, the first logistics orders whose delivery addresses belong to the same community can be clustered into one category. For each geographic spatial entity, the delivery address of the first logistics order corresponding to the geographic spatial entity can be used as the negative sample address of the geographic spatial entity, and the second logistics orders whose delivery addresses belong to the same geographic spatial entity as the geographic spatial entity can be obtained from multiple second logistics orders, and the delivery addresses of the obtained second logistics orders can be used as the positive sample addresses of the geographic spatial entity.

[0048] Taking into account the logistics and distribution scenario, for each historical logistics order, the order information of the historical logistics order will be stored in a wide table, namely the logistics order information table, which records at least the order identification, delivery address, and order status information of different historical logistics orders. The order status information may refer to the delivery status of the order, such as whether the order is successfully delivered, whether the delivery is timed out, and so on. At the same time, for the delivery address exception information reported by the delivery capacity (for example, the rider), a special delivery address exception reporting table can also be used to record it. The delivery address exception reporting table records at least the order identification of different historical orders and the description information of the delivery address exception, such as "the user address is unclear", "the user address cannot be delivered", and so on. Therefore, in some embodiments, when a plurality of first logistics orders and a plurality of second logistics orders are respectively filtered out from the historical logistics orders, the logistics order information table and the delivery address exception reporting table can be obtained, and the logistics order containing the target field in the delivery address exception description information is filtered out from the delivery address exception reporting table as the first logistics order, and the delivery address corresponding to the first logistics order is obtained from the logistics order information table based on the order identification of the first logistics order. The target field is used to indicate that the delivery address corresponding to the first historical logistics order belongs to a specific type of address. The target field can include one or more, for example, "customer|user|client," "address," and "inaccurate|fuzzy|imprecise|imprecise|undetailed|incomplete|incomplete|unreachable." Based on the order status information recorded in the logistics order information table, logistics orders that were successfully delivered and within the delivery timeout period can be selected as the second logistics order.

[0049] In some embodiments, the method for identifying a specific type of user address can be applied to the field of logistics and distribution, and the user address to be identified can be the delivery address corresponding to the target logistics order. After the prompt word is input into the large language model, the predicted probability that the user address to be identified output by the large language model is a user address of a specific type can also be obtained. If the predicted probability is greater than a preset probability threshold, a prompt message is displayed in the client of the delivery capacity that undertakes the target logistics order. The prompt message is used to prompt the delivery capacity that the delivery address corresponding to the target logistics order belongs to a specific type of address, so that the delivery capacity can determine whether to notify the user to modify the delivery address corresponding to the target logistics order based on the prompt message.

[0050] Considering that in some scenarios, the results output by the large language model may be provided to the device (for example, the service end of the logistics distribution system), in order for the device to better understand the judgment result, the large language model can directly output the predicted probability of whether the user address to be identified is a specific type of user address, and then the server can directly use the predicted probability to compare with the preset probability threshold to determine whether the user address to be identified is a specific type of user address. If so, a prompt message can be displayed on the client of the delivery capacity, prompting the delivery capacity that the user address may not be clear, so that the delivery capacity can determine whether it needs to notify the user to modify the delivery address based on its own experience. Taking into account that different riders may have different requirements for whether the delivery address is accurate or clear, for example, for the same delivery address, some riders are very familiar with the area, so even if the user address is written vaguely, they can accurately find the user's location. In this scenario, there is no need to remind the user to modify the delivery address to avoid interference with the user. Some riders may not be familiar with the area, so they may not be able to determine the user's location based on the address. In this case, the delivery address can be modified by the user. By sending the recognition results to the rider, who will make a secondary judgment on whether the delivery address is ambiguous and then decide whether to notify the user to modify the address, we can minimize interference to users and improve user experience while ensuring delivery efficiency.

[0051] For example, Figure 3 As shown, taking the instant delivery scenario as an example, if the delivery address corresponding to the order is determined to be an ambiguous address based on the recognition results of the large language model, a prompt message can be displayed near the user's address in the rider APP, such as "suspected inaccurate positioning" in the figure. After the rider sees the prompt message, he can determine whether it is necessary to notify the user to modify the address based on his own experience. For example, the rider can click on the control behind the words "suspected inaccurate positioning" (such as the question mark in the figure), and a pop-up window will appear. The pop-up window can display the prompt message "Do you need to remind the user to modify the delivery address?", as well as two options of "Yes" and "No". If the user clicks "Yes", a message can be automatically sent to the user client to notify the user to modify the address, such as Figure 4 shown.

[0052] In some embodiments, considering that the precise design of prompt words can improve the quality of the output results of the large language model, so that the large language model outputs content that meets user needs, a prompt word template can be designed based on the actual application scenario. The prompt word template can set the role of the large language model, set the rules to be followed in the judgment process of the large language model, set the type and format of the content output by the large language model, etc. When constructing a prompt word based on the associated sample address, a pre-set prompt word template can be obtained, and then the associated sample address can be filled into the prompt word template to obtain the prompt word. After the prompt word is input into the large language model, the judgment basis information output by the large language model can also be obtained, so that the user can adjust the prompt word template based on the judgment basis information, wherein the judgment basis information is used to indicate the judgment basis corresponding to the judgment result output by the large language model.

[0053] Among them, in order to facilitate users to trace back the basis of the large language model's judgment process (for example, the reason for judging the user address to be identified as a user address of a characteristic type), so that the prompt word template can be adjusted based on the judgment basis information of the large language model, for example, the judgment rules in the prompt word template are adjusted, or auxiliary judgment information is added to improve the quality of the output results of the large language model, and obtain output content that better meets user needs. For each user address to be identified, the large language model can output the judgment basis information (i.e., the reason for the judgment) while outputting the judgment result, so that the user can continuously optimize the prompt word template based on the judgment basis information output by the large language model. By obtaining the judgment basis information output by the large language model, the prompt word template can be continuously optimized to improve the output quality and accuracy of the model. This method not only improves the efficiency of address recognition, but also reduces manual intervention through automated prompts and modification suggestions, thereby improving the efficiency of logistics distribution and user experience.

[0054] In some embodiments, this specific type of user address recognition method can be applied to the field of logistics and distribution, and the user address to be identified can be the delivery address corresponding to the target logistics order. After the prompt word is input into the large language model, the modification prompt information output by the large language model can also be obtained, and the modification prompt is sent to the client of the distribution capacity, so that the distribution capacity sends the modification prompt information to the user, wherein the modification prompt information is used to guide the user to modify the user address to be identified so that the modified user address to be identified does not belong to this specific type of address. For example, in the case where the delivery address filled in by the user is an ambiguous address, the large language model can be used to output modification prompt information to provide the user with modification direction so that the user knows how to modify the delivery address to meet the needs.

[0055] For example, the modification prompt message output by the large language model might be: "Dear user, the delivery address you entered, 'Near Zhongguancun, XX District, XX City', is vague and may result in delivery delays or failure. To ensure your order is delivered accurately, please provide a more specific address, such as 'No. XX, Zhongguancun Street, XX District, XX City'. Thank you for your cooperation!"

[0056] In some embodiments, this specific type of user address recognition method can be applied to the field of logistics and delivery, where the user address to be identified can be the delivery address corresponding to a target logistics order. After inputting the prompt word into the large language model, modification prompt information output by the large language model can also be obtained and sent to the user client of the user who owns the target logistics order, so that the user client can display the modification prompt information to the user.

[0057] In some embodiments, when querying the associated sample addresses related to the user address to be identified from a pre-built knowledge base, the first vector corresponding to the user address to be identified can be determined, and then the second vectors corresponding to the positive and negative sample addresses in the knowledge base can be determined, and the similarity between the first vector and each second vector can be determined, and the associated sample addresses can be screened out from the positive and negative sample addresses based on the similarity. For example, each sample address (positive sample address or negative sample address) in the knowledge base can be represented as a vector (i.e., a second vector). Similarly, the user address to be identified can also be represented as a vector (i.e., a first vector), and then the TOP K second vectors with the highest similarity to the first vector can be selected, and the sample addresses corresponding to the TOP K second vectors can be used as the associated sample addresses of the user address to be identified. Among them, the vectors of the user address to be identified and the sample addresses in the knowledge base can be determined by various embedding models, and the embodiments of this specification are not limited. In some embodiments, the ops-text-embedding-001 model can be used to vectorize the sample addresses, and the vectorized data can be stored in the knowledge base.

[0058] For example, Figure 5As shown, based on the address of the user to be identified, addresses with a high correlation with the address of the user to be identified can be recalled from the knowledge base, wherein, during the recall, the vector corresponding to the address of the user to be identified and the vector corresponding to each sample address in the knowledge base can be determined, and then the similarity between the vector corresponding to the address of the user to be identified and the vector corresponding to each sample address can be determined, and then the recalled sample addresses are sorted in order of similarity from high to low, and then the top K sample addresses are selected to construct the prompt word. Alternatively, keywords can be extracted from the address of the user to be identified, the vector corresponding to the keyword and the vector corresponding to each sample address in the knowledge base can be determined, and then the similarity between the vector corresponding to the keyword and the vector corresponding to each sample address can be determined, and then the recalled sample addresses are sorted in order of similarity from high to low, and then the top K sample addresses are selected to construct the prompt word. For example, if the address of the user to be identified is "XX Zhongyuan Second District South District, Building 20, Unit 1, 104", the keyword "XX Zhongyuan Second District South District" can be extracted from it.

[0059] The following describes a specific type of user address identification method provided in the embodiments of this specification with reference to a specific example.

[0060] In the field of instant delivery, tens of millions of orders are generated every day. The successful delivery of these orders is inseparable from the rider's fulfillment operation. The rider has to complete the entire process from receiving the order to picking up the food and then delivering it. The fulfillment process of this order is completed, and this order will be successfully delivered. There are many problems in the entire rider's fulfillment process, such as long delivery time, inability to contact the user, slow food delivery by the merchant, and inability to find the user's address. These problems will seriously affect the user's dining experience and the rider's fulfillment experience. This embodiment is mainly aimed at scenarios where the user's address is vague. When the address information provided by the user is missing or the address is wrong, this will cause the rider to be unable to deliver the food smoothly, resulting in abnormal problems in the fulfillment process. When the rider cannot find the user's address, the rider will complain or report the problem to the platform, or initiate contact with the user himself. In any case, the overall fulfillment time will be greatly extended, resulting in an unpleasant experience for the rider's delivery and the user's dining. This implementation provides a method whereby, after a rider receives an order, the delivery system can automatically detect whether the user's address is ambiguous. If ambiguity is detected, an instant message can be sent to the user to inquire about the user's precise delivery address and the message can be notified to the rider.

[0061] This embodiment implements a method for determining whether a user's address is ambiguous based on a large language model and RAG search enhancement generation technology. It can automatically identify situations where a user's address is ambiguous, help riders deliver more smoothly, reduce the number of reports during the rider's fulfillment process, and improve the overall delivery rate of the market. The flowchart of the overall method is as follows: Figure 6As shown, the following steps may be specifically included:

[0062] 1. Scenario with ambiguous address

[0063] Common cases of ambiguous addresses include Building 13 of XX Apartment (missing the specific building and house number), the First Affiliated Hospital of XX University School of Medicine (missing the specific campus and outpatient department), and XX E-sports (missing the floor and specific seat). Most of these are caused by customers' unclear descriptions of their addresses, and this problem occurs in tens of thousands of orders every day.

[0064] 2. Construction of knowledge base

[0065] RAG retrieval enhancement generation technology requires the preparation of a knowledge base related to the content to be retrieved, such as Figure 7 As shown, using the historical logistics waybill table and the historical rider report and judgment information table as the base tables, we can further construct positive and negative samples for ambiguous user addresses. First, we extract data related to "customer|user|client," "address," and "inaccurate|fuzzy|imprecise|imprecise|incomplete|incompletely written|incompletely filled|unreachable" from the rider report and judgment table's note field. We then link this data with the logistics waybill table using the waybill ID to obtain the required waybill information related to ambiguous user address reports, which we use as negative samples. Next, we process the positive sample data and extract the waybill data with a successful delivery status and no timeout in the logistics waybill table. These are used as positive samples. We then perform data cleaning on both positive and negative samples, focusing on the negative sample data. We then aggregate the negative sample waybill data based on the user's Area of Interest (AOI) label and filter out data from the positive samples that share the same AOI as the negative sample user. This allows us to obtain data related to ambiguous and unambiguous user addresses within the same AOI. Next, we split the AOI data into 1000 parts, each containing several fuzzy-correlated positive and negative data points for the addresses within the AOI. This data will serve as the knowledge base data. Finally, we use the ops-text-embedding-001 model to vectorize the text data and store the vectorized data in the knowledge base.

[0066] The data positive and negative sample cases are as follows:

[0067] XX Jingyuan Building 1, 404$ is accurate

[0068] XX Jingyuan Building 1 Unit 1 502$ accurate

[0069] XX Jingyuan Building 2, Unit 1, 202$ accurate

[0070] XX First Flight International Building 6 $ is inaccurate

[0071] XX first international flight $ is inaccurate

[0072] 3. Use the LLM model to determine whether the user address is ambiguous

[0073] After preparing the knowledge base, we can proceed with building the large model. First, we can obtain the user address of the current waybill. After obtaining the user address, we can search the knowledge base to find positive and negative sample information related to the current user address. Based on this positive and negative sample information, we can construct the prompt word for the model request. The prompt word is constructed as follows, using "Building 16, District 2, Zhongyuan, XX" as the user address:

[0074] System prompt: You are a reviewer in a food delivery scenario responsible for determining whether the delivery address of the rider's complaint is accurate.

[0075] User prompt: In the food delivery scenario, the user's address may be incomplete or inaccurate, which may result in the rider being unable to deliver according to the address and causing complaints. Given a user's address of Building 16, XX Zhongyuan District 2, please carefully determine whether the user's address is accurate enough to help the rider find the specific location based on the service scenario, auxiliary judgment information, and historical case studies related to the address. Output it according to the output requirements. The auxiliary judgment information, historical cases, and output requirements are as follows:

[0076] Auxiliary information for judgment: The user's address is not strictly required to specify the city, district, or street. For small buildings, especially shops, a specific landmark building name or sign is sufficient for accuracy. For large buildings, it is necessary to be as specific as possible. For buildings, the specific floor and house number must be specified. Combining the floor with the business name, or specifying a specific location such as the front desk or a food counter for takeout delivery is also accurate. If the level of detail of the user's address differs significantly from the address detail of the accurate sample in the case, the address is judged to be inaccurate. If the difference in the address detail of the accurate sample is small, it is judged to be accurate. The historical cases of relevant addresses (i.e., positive and negative samples retrieved from the knowledge base) are as follows. They may include some irrelevant addresses. When making judgments, please rely on address information within the same AOI (Area of Interest). The case format is: {user address}${whether it is accurate (accurate / inaccurate)}. Empty case data indicates that there are no historical cases:

[0077] XX Zhongyuan District 2 South District Building 31 Unit 6 602$ accurate

[0078] XX Zhongyuan 2nd District South District (XX Science and Technology Park South New Community) Building 31 Unit 1 603-Just put it at the door $ Accurate

[0079] XX Zhongyuan District 2 South District Building 20 Unit 1 104$ accurate

[0080] XX Zhongyuan District 2 South District No. 30 Building 1 Unit 401$ accurate

[0081] XX Zhongyuan District 2 South District Building 30 Unit 1 402$ accurate

[0082] XX Zhongyuan Second District South District No. 30 Building 2 Unit 303 $ accurate

[0083] XX Zhongyuan Second District South District No. 32 Building 2 Unit 201$ accurate

[0084] XX Zhongyuan District 2 South District Building 32 Unit 4 502$ accurate

[0085] XX Zhongyuan Second District South District Building 32 Unit 5 601$ accurate

[0086] XX Garden (District 5) XX Garden District 5, Building 27, Unit 4, 202$ accurate

[0087] Building 10, District 5, XX Garden, Ground Floor, Building 10, District 5, XX Garden, XX South Street, XX District, XX City! Giant Store!! $ Accurate

[0088] Unit 1, Building 15, District 5, XX Garden, 502$ accurate

[0089] Unit 2, Building 22, District 5, XX Garden $ accurate

[0090] Unit 3, Building 1, District 5, XX Garden, 502$ accurate

[0091] XX Garden District 5, 28th Floor, Unit 1, 501$ accurate

[0092] Unit 3, Building 33, District 5, XX Garden, 601$ accurate

[0093] XX Garden District 5, Building 4, Unit 1, 902, put it at the door $ accurate

[0094] XX Garden District 5 Apartment Building 6 Unit 2 202$ accurate

[0095] Output requirements: Requires a JSON output, not Markdown format. It should contain two fields: score: the probability that the user's address is accurate. This variable is continuous and has a range of [0, 1]. Values closer to 1 indicate accuracy, while values closer to 0 indicate inaccuracy. reason: the reason for the determination. Additional information: Addresses are considered accurate if they include a specific location or require a phone call. Examples of locations include: downstairs, entrance, front desk, lobby, hall, shelf, security office, gatehouse, community gate, and campus gate. Small buildings include: middle schools, elementary schools, post stations, shops, community centers, kindergartens, and other educational and training centers, retail stores, restaurants, small clinics, fitness centers, small entertainment venues, service stations, billiard halls, express delivery stations, community entrance vendors, and repair shops. When the above empirical criteria cannot be used to determine whether an address is ambiguous, and historical case studies are available, historical case studies should be relied upon.

[0096] After the prompt word is constructed, the model can be requested, and the model request result can be obtained: According to the provided address 'Building No. 16, District 2, Zhongyuan, XX' and historical case analysis, the address only provides the community name and building number, but does not provide specific unit number, floor or house number and other information. Compared with historical cases within the same AOI, the accurate address usually contains more detailed positioning information, such as the specific unit number and room number, or a clear placement location (such as the door, front desk). Therefore, the amount of information at the current address is not enough for the rider to find the specific location directly, which increases the difficulty of delivery, and it can be obtained that the address of Building No. 16, District 2, Zhongyuan, XX is vague.

[0097] In this embodiment, a large amount of order logistics history data and rider judgment and reporting data are used as a data set to determine whether the user address is ambiguous in the field of instant delivery. For massive data sets, positive and negative samples can be extracted, and the sample data can be embedded and vectorized into the knowledge base for rapid retrieval of relevant positive and negative sample data before the model is called, which further improves the accuracy of the model judgment; based on large model technology, the overall system process is automated. After the rider accepts the order, the model is triggered to judge the user's address. If an ambiguous address is identified, IM (Instant Messaging) will be actively sent to the user, allowing the user to further improve the address, reducing rider complaints and communication costs with users, optimizing rider performance inspections, and improving user experience.

[0098] Corresponding to the method embodiments provided in the embodiments of this specification, the embodiments of this specification also provide a computer program product, including a computer program, which implements the method mentioned in any of the above embodiments when executed by a processor.

[0099] This embodiment of the present invention also provides an electronic device, such as Figure 8 The figure is a schematic diagram of the structure of the electronic device according to the embodiment of this specification, except Figure 8 In addition to the processor 82 and memory 84 shown, the device may also typically include other hardware, such as a forwarding chip responsible for message processing. From a hardware perspective, the device may also be distributed, potentially including multiple interface cards to enable hardware-level message processing expansion. The memory 84 stores computer instructions, and when the processor 82 executes these computer instructions, the method described in any of the above embodiments is implemented.

[0100] The user information (including but not limited to user device information, user personal information, 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 relevant data must comply with the relevant laws, regulations and standards of relevant countries and regions, and provide corresponding operation entrances for users to choose to authorize or refuse.

[0101] Since the portion of the embodiment of this specification that contributes to the prior art or the entire or partial technical solution can be embodied in the form of a software product, the computer software product is stored in a storage medium and includes a number of instructions for causing a terminal device to execute all or part of the steps of each method of the embodiment of this specification. The aforementioned storage medium includes: a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk, etc., various media that can store program code.

[0102] The above description is only a preferred embodiment of the embodiments of this specification and is not intended to limit the embodiments of this specification. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of the embodiments of this specification should be included in the scope of protection of the embodiments of this specification.

Claims

1. A method for identifying a specific type of user address, the method comprising: Get the address of the user to be identified; Querying a pre-built knowledge base for associated sample addresses related to the user address to be identified, wherein the knowledge base stores positive sample addresses and / or negative sample addresses corresponding to different geographic spatial entities, the positive sample addresses do not belong to the specific type of user address, and the negative sample addresses belong to the specific type of user address; Constructing a prompt word based on the associated sample address; The prompt word is input into a large language model, so that the large language model determines whether the user address to be identified is a user address of the specific type based on the prompt word.

2. The method according to claim 1, wherein the specific type of user address comprises one or more of the following: Ambiguous user address, invalid user address, wrong user address.

3. The method according to claim 1 or 2, wherein the user address to be identified includes a delivery address corresponding to a target logistics order, and the knowledge base is constructed based on the following method: Filter out multiple first logistics orders and multiple second logistics orders from historical logistics orders, among which, The delivery addresses of the plurality of first logistics orders are reported as user addresses belonging to the specific type, and the plurality of second logistics orders are logistics orders that are successfully delivered and have not been delivered within the time limit; Clustering the plurality of first logistics orders based on geographic space entities to obtain first logistics orders corresponding to different geographic space entities; For each geospatial entity, the delivery address of the first logistics order corresponding to the geospatial entity is used as the negative sample address of the geospatial entity, and a second logistics order whose delivery address belongs to the same geospatial entity as the geospatial entity is obtained from the multiple second logistics orders, and the obtained second logistics order is used as the positive sample address of the geospatial entity.

4. The method according to claim 3, wherein the plurality of first logistics orders and the plurality of second logistics orders are respectively selected from the historical logistics orders, comprising: Obtaining a logistics order information table and a delivery address exception reporting table, wherein the logistics order information table records at least order identifiers, delivery addresses, and order status information of different historical logistics orders, and the delivery address exception reporting table records order identifiers of different historical orders and delivery address exception description information; Filtering out, from the delivery address exception reporting table, a logistics order whose delivery address exception description information includes a target field, as the first logistics order, and obtaining, from the logistics order information table based on the order identifier of the first logistics order, the delivery address corresponding to the first logistics order, wherein the target field is used to indicate that the delivery address of the first logistics order belongs to the specific type of address; Based on the order status information recorded in the logistics order information table, the logistics orders that are successfully delivered and not timed out are screened out as the second logistics orders.

5. The method according to claim 1 or 2, wherein the user address to be identified includes a delivery address corresponding to a target logistics order, and after inputting the prompt word into the large language model, the method further comprises: Obtaining a predicted probability that the to-be-identified user address output by the large language model is a user address of a specific type; When the predicted probability is greater than the preset probability threshold, a prompt message is displayed in the client of the delivery capacity that undertakes the target logistics order, and the prompt message is used to prompt the delivery capacity that the delivery address corresponding to the target logistics order belongs to the specific type of address, so that the delivery capacity can determine whether to notify the user to modify the delivery address corresponding to the target logistics order based on the prompt information.

6. The method according to claim 1 or 2, wherein constructing a prompt word based on the associated sample address comprises: Get the preset prompt word template; Filling the associated sample address into the prompt word template to obtain the prompt word; After inputting the prompt word into the large language model, the method further includes: Obtaining decision basis information output by the large language model so that the user can optimize the prompt word template based on the decision basis information, wherein the decision basis information is used to indicate a decision basis corresponding to the decision result output by the large language model.

7. The method according to claim 1 or 2, wherein the user address to be identified includes a delivery address corresponding to a target logistics order, and after inputting the prompt word into the large language model, the method further comprises: Obtain modification prompt information output by the large language model, and send the modification prompt information to the client of the delivery capacity that undertakes the target logistics order, so that the delivery capacity sends the modification prompt information to the user, wherein the modification prompt information is used to guide the user to modify the user address to be identified so that the modified user address to be identified does not belong to the specific type of user address.

8. The method according to claim 1 or 2, wherein the user address to be identified includes a delivery address corresponding to a target logistics order, and after inputting the prompt word into the large language model, the method further comprises: Obtain modification prompt information output by the large language model, and send the modification prompt information to the user client of the user to whom the target logistics order belongs, so that the user client displays the modification prompt information, wherein the modification prompt information is used to guide the user to modify the user address to be identified so that the modified user address to be identified does not belong to the specific type of user address.

9. The method according to claim 1 or 2, wherein querying a pre-built knowledge base for associated sample addresses related to the address of the user to be identified comprises: Determine a first vector corresponding to the address of the user to be identified; Determine the second vectors corresponding to the positive and negative sample addresses in the knowledge base; The similarity between the first vector and each second vector is determined, and the associated sample addresses are filtered out from the positive and negative sample addresses based on the similarity.

10. A computer program product comprising a computer program, wherein when the computer program is executed by a processor, the method according to any one of claims 1 to 9 is implemented.

Citation Information

Patent Citations

  • Knowledge base construction method and device and computer equipment

    CN119577059A

  • Call-out report generation method and device, storage medium and electronic equipment

    CN119648362A

  • Fine tuning method of large language model, false address identification method, device and equipment

    CN119784440A

  • Resource auditing method, device and equipment based on large model and storage medium

    CN119988856A

  • Retrieval enhancement generation method and system based on large language model

    CN120045750A

Cited By

  • Address text correlation analysis method, system and equipment and storage medium

    CN120850955A