Commodity recommendation method and system based on multi-dimensional entity analysis and mixed retrieval
By employing a product recommendation method that combines multi-dimensional entity analysis and hybrid retrieval, this approach addresses the issues of insufficient user demand assessment and inaccurate search results in existing technologies, thereby achieving personalized recommendations and efficient information presentation.
Patent Information
- Application Number
- CN202511118134.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-08-11
- Publication Date
- 2025-11-07
AI Technical Summary
Existing intelligent product recommendation technologies suffer from insufficient judgment of user needs based on a single dimension, neglecting historical browsing and location data. This results in recommendations lacking personalization and accuracy, incomplete search results, and a monotonous presentation format, leading to a poor user experience.
Multi-dimensional entity analysis is used to extract key entities from user questions. Combined with user behavior records to analyze preferences, historical recommendation results are matched through semantic and full-text hybrid retrieval, and recommendation key sentences are generated in a specified format.
It improves the accuracy and personalization of product recommendations, enhances the user experience, ensures that the recommendation results closely match the user's actual needs, and improves the efficiency of information acquisition and system intelligence.
Smart Images

Figure CN120912299A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of natural language processing, and particularly relates to a commodity recommendation method and system based on multi-dimensional entity analysis and mixed retrieval. BACKGROUND
[0002] RAG retrieves relevant information from external knowledge bases in real time and integrates it into the generation task, ensuring that the generated text is both contextually coherent and contains accurate knowledge. This architecture performs particularly well in intelligent question answering, information retrieval and reasoning, and domain-specific content generation scenarios.
[0003] RAG consists of a retriever and a generator. First, the retriever retrieves relevant content snippets from external knowledge bases or document sets based on user queries; then the generator generates natural language output based on these retrieved content, ensuring that the generated content is both informative and highly relevant and accurate.
[0004] However, the existing intelligent commodity recommendation technology has many shortcomings. In the problem screening stage, due to the use of single-dimensional judgment, it is difficult to fully grasp the user's demand, resulting in poor screening accuracy, and key problems are easily missed or misjudged; analysis of user preferences relies only on surface information, ignoring historical browsing, shopping records and current location data, resulting in a lack of personalization in recommendations and a large deviation from the user's actual needs; in the retrieval stage, pure semantic understanding or text matching cannot balance semantics and accuracy, and the retrieval results are not comprehensive and accurate; moreover, the presentation form of the recommendation results is single, and the format and word count are not optimized, making it difficult for users to quickly obtain key information, greatly reducing the practicality of the recommendation system. SUMMARY
[0005] To solve the above problems, the present application provides a commodity recommendation method and system based on multi-dimensional entity analysis and mixed retrieval, which extracts key entities of user questions to determine relevance, analyzes commodity preferences based on user behavior records, expands the semantics of key and preference entities, and then matches historical recommendation results using mixed retrieval after splicing and reorganizing the expanded entities. Finally, the results are aggregated to generate recommendation points in a specified format and word count, thereby improving the efficiency and quality of commodity recommendations in multiple stages.
[0006] To achieve the above purpose, the present application adopts the following technical solutions: In a first aspect, the present application provides a commodity recommendation method based on multi-dimensional entity analysis and mixed retrieval, comprising: Obtaining a user question, preprocessing it to obtain a preliminary user optimized question, and obtaining general recommendations based on the preliminary user optimized question; The key entities of the preliminary user optimization question are extracted, the relevance of the user question to the commodity recommendation is judged based on entity matching, and the commodity recommendation related question is screened; the key entities include time entity, subject entity, activity entity, target entity and recommendation willingness entity; Based on the user behavior record, the user commodity preference is analyzed to obtain the preference entity; The key entities and the preference entity of the commodity recommendation related question are semantically extended to obtain the extended entity; The extended entity is spliced and reorganized, input into a pre-constructed knowledge base, and the historical recommendation result is matched based on the mixed retrieval of semantic retrieval and full-text retrieval; the pre-constructed knowledge base includes historical commodity recommendation questions and corresponding historical recommendation results; The historical recommendation result is aggregated, the commodity recommendation point sentence is generated based on the specified format and the number of words, and the commodity recommendation point sentence and the general suggestion are output.
[0007] In a second aspect, the present application provides a commodity recommendation system based on multi-dimensional entity analysis and mixed retrieval, comprising: A preprocessing module is configured to obtain a user question, perform preprocessing to obtain a preliminary user optimization question, and obtain a general suggestion based on the preliminary user optimization question; An entity extraction module is configured to extract key entities of the preliminary user optimization question, judge the relevance of the user question to the commodity recommendation based on entity matching, and screen the commodity recommendation related question; the key entities include time entity, subject entity, activity entity, target entity and recommendation willingness entity; A preference analysis module is configured to analyze user commodity preference based on user behavior record to obtain the preference entity; An entity extension module is configured to perform semantic extension on the key entities and the preference entity of the commodity recommendation related question to obtain the extended entity; A suggestion acquisition module is configured to splice and reorganize the extended entity, input into a pre-constructed knowledge base, and match the historical recommendation result based on the mixed retrieval of semantic retrieval and full-text retrieval; the pre-constructed knowledge base includes historical commodity recommendation questions and corresponding historical recommendation results; An output module is configured to aggregate the historical recommendation result, generate a commodity recommendation point sentence based on a specified format and a number of words, and output the commodity recommendation point sentence and the general suggestion.
[0008] In a third aspect, the present application provides a computer readable storage medium having a computer program stored thereon, the program being executed by a processor to implement the steps of the commodity recommendation method based on multi-dimensional entity analysis and mixed retrieval of the first aspect.
[0009] In a fourth aspect, the present application provides a computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the commodity recommendation method based on multi-dimensional entity analysis and mixed retrieval of the first aspect when executing the program.
[0010] Compared with the prior art, the present application has the following beneficial effects: (1) The present application first optimizes the user question and generates a general suggestion, extracts multi-dimensional key entities such as time and subject from the user question, and combines entity matching to filter related questions, solving the recommendation direction deviation caused by single-dimensional judgment; then, the preference entity obtained by user behavior analysis is fused, the retrieval dimension is enriched by semantic expansion, the deficiency of relying only on surface information is made up, and personalization is enhanced; then, through semantic and full-text mixed retrieval, both semantic association and accurate matching are considered, the one-sidedness of single retrieval is avoided, and the comprehensiveness and accuracy of historical result matching are improved; finally, the retrieval results are aggregated and key sentences are generated according to the format and the number of words, which are matched with the general suggestion, so as to conveniently and quickly obtain key information and provide scenario reference, solve the single problem of result presentation, and comprehensively optimize the user experience.
[0011] (2) Conventional technologies often cause key information to be missed due to single-dimensional judgment of user demand, for example, only paying attention to the type of goods while ignoring the use time or scene, resulting in recommendation deviation. The present application extracts time, subject, activity, target and recommendation willingness entities as multi-dimensional features for comprehensively capturing user demand: the time entity clarifies the timeliness of demand, the subject entity locks the use object, the activity entity associates the scene, the target entity defines the core demand, and the recommendation willingness entity confirms the user intention, so that through multi-dimensional entity matching, related questions can be accurately filtered, irrelevant recommendations can be avoided, and the recommendation result can be highly matched with the actual scene of the user, improving the recommendation accuracy.
[0012] (3) Conventional technologies often rely on surface information of user questions and ignore implicit preferences, such as brands or consumption levels that the user may not mention but often buys, resulting in a lack of personalization in recommendations. The present application introduces preference entities and fuses them with key entities, effectively excavating potential user demand, making the expanded entities more accurate, avoiding generalization caused by incomplete information, and making the recommendation result not only meet the explicit demand but also meet the implicit preference of the user, enhancing the personalized experience.
[0013] (4) In conventional technology, semantic retrieval may miss accurate matching content due to vector conversion bias, and full-text retrieval is limited to lexical surface matching and cannot understand semantic association, resulting in one-sided search results. The present application adopts a hybrid mode combining semantic retrieval and full-text retrieval, semantic retrieval captures deep semantic association through vector similarity, and full-text retrieval ensures that key information is not lost through keyword exact matching. The fusion of the two can cover both semantic similarity and lexical matching scenarios, avoiding the blind spot of single retrieval, making the matching historical recommendation results more comprehensive and accurate, and improving the retrieval efficiency and result relevance.
[0014] (5) Conventional technology recommendation results often have the problem of disordered form or single content, and users need to sort out the key information themselves, which is not a good experience. The present application outputs structured commodity recommendation point sentences after aggregation and more general suggestions, the former facilitates users to quickly obtain accurate recommendations, and the latter provides scene knowledge. The combination of the two kinds of suggestions not only solves the problem of chaotic result presentation, but also makes up for the defects of single recommendation information deficiency, serves users from two dimensions of specific commodities and scene guidance, improves information acquisition efficiency and use experience.
[0015] The advantages of the additional aspects of the present application will be partially given in the following description, partially become obvious from the following description, or be understood through the practice of the present application. BRIEF DESCRIPTION OF DRAWINGS
[0016] The drawings accompanying the specification of this application form a part thereof, serve to provide further understanding of the application, and together with the description of the exemplary embodiments of the application and its description serve to explain the application. The present application is not limited by the exemplary embodiments of the application.
[0017] Figure 1 A main flowchart of a commodity recommendation method based on multi-dimensional entity analysis and hybrid retrieval provided for an embodiment of the present application; Figure 2 A detailed flowchart of a commodity recommendation method based on multi-dimensional entity analysis and hybrid retrieval provided for an embodiment of the present application. DETAILED DESCRIPTION
[0018] Explanation of technical terms RAG: Retrieval-Augmented Generation, is a model combining retrieval and generation technology. It generates answers or content by referencing information from an external knowledge base, has strong explainability and customization ability, and is suitable for multiple natural language processing tasks such as question and answer systems, document generation, intelligent assistants, etc. The advantage of RAG model is strong universality, instant knowledge update, and more efficient and accurate information service through end-to-end evaluation method.
[0019] A knowledge base is a collection of closely related and constantly updated knowledge. This knowledge base can be represented as a structured database (such as MySQL), an unstructured document system (such as files, images, audio, and video), or even a combination of both.
[0020] Large Language Models (LLMs) are deep learning models trained on large amounts of text data that can generate natural language text or understand the meaning of language text. LLMs can handle various natural language tasks, such as text classification, question answering, and dialogue, and are an important pathway to artificial intelligence.
[0021] Retrieval model: Retrieves the most relevant content to the input query from an external knowledge base or document set.
[0022] Semantic retrieval: This involves transforming documents and queries into representations in a vector space and using similarity calculations for matching. Its advantage lies in its ability to better capture semantic similarity, rather than relying solely on word-for-word matching.
[0023] Full-text search: A technique for retrieving documents from an unstructured document library in text format. It primarily assists in the retrieval process by comparing the content of documents in the library with the input search keywords.
[0024] The present invention will be further described below with reference to the accompanying drawings and embodiments.
[0025] Example 1 like Figure 1 As shown in the figure, this embodiment discloses a product recommendation method based on multi-dimensional entity analysis and hybrid retrieval, including the following steps: S1: Obtain user issues, perform preprocessing to obtain preliminary user optimization issues, and derive general suggestions based on the preliminary user optimization issues; S2: Extract key entities from the initial user optimization questions, and determine the relevance of user questions to product recommendations based on entity matching, and filter product recommendation-related questions; the key entities include time entities, subject entities, activity entities, target entities, and recommendation intent entities; S3: Based on user behavior records, analyze user product preferences to obtain preference entities; S4: Semantically expand the key entities and preference entities related to product recommendation issues to obtain extended entities; S5: The extended entities are concatenated and recombined, input into a pre-built knowledge base, and a hybrid retrieval based on semantic retrieval and full-text retrieval is performed to match historical recommendation results; the pre-built knowledge base includes historical product recommendation questions and corresponding historical recommendation results; S6: aggregate the historical recommendation results, generate a product recommendation key point sentence based on a specified format and a word count, and output the product recommendation key point sentence and the general suggestion.
[0026] There are various consumption scenarios, covering different types such as direct search for goods, consultation of usage knowledge, and seeking for recommendation suggestions. Among them, the embodiment focuses on the scenario where the user initiates an explicit recommendation demand, that is, when the user's question contains expressions such as "recommendation", "which is good", "what to choose" and other explicit expressions of recommendation intention, the embodiment accurately identifies such demand by extracting "recommendation intention entity", and only provides product recommendation services for users who actively seek comparison or suggestions. Thus, it effectively avoids forcibly pushing goods to search behaviors without recommendation demand, reduces the user's perception of "advertising harassment", and ensures that the recommendation behavior matches the user's actual demand. At the same time, in view of the dynamic changes of consumption preferences, the preference entity is adjusted by updating the user behavior record (such as the latest browsing and purchase data) in real time, and combined with semantic expansion to include short-term interest features, improving the ability to capture recent preferences and adapting to the user's short-term decision-making tendency.
[0027] Next, in combination with Figure 2 A product recommendation method based on multi-dimensional entity analysis and mixed retrieval disclosed in the embodiment is described in detail.
[0028] In S1, the input user question is obtained, preprocessed, and questions that violate public order and good customs, such as questions containing abusive, discriminatory, and pornographic words, and ambiguous and vague descriptions, are removed, to obtain a preliminary user optimized question.
[0029] It should be understood that the pre-processing method can be rule matching filtering, with the help of a natural language processing model, etc., which can be selected and implemented by a person skilled in the art according to the actual situation.
[0030] The preliminary user optimized question is input into a natural language processing large model to generate a general suggestion. The general suggestion is more extensive and comprehensive information output from multiple dimensions around the core demand of the preliminary user optimized question. For example, the user proposes "tent recommendation suitable for camping", which not only lists specific models, but also explains the requirements of different camping environments for tents, setup and storage skills, and interpretation of core selection indicators, etc.
[0031] In S2, further, the key entity of the user question is extracted based on the preliminary user optimized question.
[0032] Specifically, the key entity is compared with the entities in the pre-set product recommendation related entity library, and the similarity is calculated based on entity matching; if the similarity exceeds a pre-set threshold, it is determined to be related to product recommendation, and the user question is retained as a product recommendation related question; otherwise, it is deleted, and the recommendation consultation is ended.
[0033] The key entities include a time entity, a subject entity, an activity entity, a target entity, and a recommendation intention entity. Various entities are extracted from the input user question by using natural language processing techniques, such as a named entity recognition (NER) tool.
[0034] It should be understood that the embodiments assume that the user question sentence input by the user is a complete inquiry sentence containing rich information, and the sentence that can be judged as a product recommendation related question contains a time entity, a subject entity, an activity entity, a target entity, and a recommendation intention entity.
[0035] In the embodiments, a time description word in the user question is taken as a time entity, an executor of a behavior action or an object of a demand direction is taken as a subject entity, a word describing an activity, an event, or a scene is taken as an activity entity, a thing that is demanded or recommended is taken as a target entity, and a word expressing a recommendation intention is taken as a recommendation intention entity.
[0036] For example, the time entity includes words such as season, festival, special time period (school season, promotion season, and tourism peak season); the subject entity includes different age groups, different professions, and different interest groups; the activity entity includes leisure scenes (vacation, party, and movie watching), work scenes (business meeting and office daily work), and learning scenes (classroom learning, examination, and preparation for examination); the target entity includes all kinds of product names; and the behavior intention entity includes selection, purchase, recommendation, and demand. Those skilled in the art can determine the entity selection range according to actual needs, and the present application will not be described again.
[0037] For example, if the user question is “What do you need to prepare for a family self-driving tour on the beach in summer?”, “summer” is extracted as the time entity, “the whole family” is extracted as the subject entity, “self-driving tour on the beach” is extracted as the activity entity, “articles” is extracted as the target entity, and “need to prepare” is extracted as the recommendation intention entity.
[0038] For another example, for the user question “My son is ten years old, and I want to buy a book as a birthday gift for him. What do you recommend?”, “ten years old” is extracted as the time entity, “son” is extracted as the subject entity, “birthday” is extracted as the activity entity, “book” is extracted as the target entity, and “recommend” is extracted as the recommendation intention entity.
[0039] Further, the preset product recommendation related entity library is constructed based on historical product recommendation questions and user feedback data, and the entity range covered by the library can comprehensively include various key entities such as time entities, subject entities, activity entities, target entities, and recommendation intention entities that may appear in user questions.
[0040] After key entity matching, the user question containing time entity, subject entity, activity entity, target entity and recommendation intention entity is reserved as a commodity recommendation related question, other non-commodity recommendation related questions are deleted, and the user is prompted to re-input the user question.
[0041] The embodiment first optimizes the input user question, eliminates irregular and unclear content, and guarantees the quality of the question. Then, by using natural language processing technology, key entities such as time, subject, activity, target and recommendation intention are extracted, and the similarity is compared with the preset entity library, which not only improves the processing efficiency and accuracy, but also accurately determines whether the question is related to commodity recommendation, avoids misjudgment, and lays a solid foundation for the subsequent process. At the same time, the clear question and its key entities obtained after preliminary optimization provide high-quality materials for subsequent secondary optimization combined with preference entities, making the question more suitable for user needs; the generated general suggestions also guarantee the content quality due to preliminary optimization, which can cooperate with accurate commodity recommendation information in the final output, from the broad scene and specific recommendation dimension, to provide users with more comprehensive and easy-to-understand services, making the entire recommendation process efficient and accurate.
[0042] In S3, based on the user behavior record, the user commodity preference is analyzed to obtain the preference entity.
[0043] The user behavior record includes historical browsing record, historical shopping record and current location record; the preference entity includes user brand preference, user consumption level preference and current location preference.
[0044] Specifically, by analyzing the user's historical browsing record, the user's brand preference is obtained. By collecting the user's historical browsing record, the brand is counted, and the number of times each brand is browsed is calculated. According to the brand browsing frequency from high to low, the brand with higher frequency is the brand that the user may prefer.
[0045] By analyzing the user's historical shopping record, the user's consumption level preference is obtained. By extracting the price information and purchase quantity of the goods in the user's historical shopping record, the consumption amount and average consumption amount are calculated to obtain the user's consumption level preference.
[0046] By analyzing the current location record, the current location preference is obtained. The current location record of the user is obtained as the current location preference, which is used to locate the nearest mall from the user.
[0047] It should be understood that the user behavior records (including historical browsing, shopping records, location information, etc.) involved in the embodiments are all obtained based on explicit authorization and legal channels: when the user uses the system for the first time, the user actively agrees to the data collection agreement and explicitly authorizes the scope and purpose; the system only calls the behavior data that the user has authorized to open, and stores personal information through encryption technology, strictly in accordance with relevant regulations; for sensitive data such as location information, fuzzy processing is adopted (such as only obtaining regional information instead of accurate coordinates), and the user can view, modify or withdraw the authorization at any time to ensure the legality and transparency of data collection and use.
[0048] The embodiment obtains user brand preferences, consumption level preferences, and current location preferences and other implicit factors that are not directly reflected in the user's question by analyzing the user's historical browsing records, historical shopping records, and current location records. These preferences are not directly derived from the user's question, but can greatly enrich the dimensions of semantic analysis. When dealing with user product recommendation problems, combined with these preferences, the user's potential needs can be better understood, the possible shortcomings in the user's question expression can be made up, the semantic analysis can be more comprehensive and accurate, and a more accurate and effective recommendation can be provided for subsequent recommendations, improving the accuracy and effectiveness of the recommendation.
[0049] In S4, the key entities and preference entities of the product recommendation related question are optimized again, that is, semantic expansion, to obtain expanded entities.
[0050] In view of the differences in the names of entities in the expressions of different users, in order to comprehensively cover all kinds of entities and avoid recommendation deviation caused by information omission, the embodiment expands the entities by combining the key entities and the preference entities, supplements the related entities, and provides more abundant reference basis for the model to generate answers.
[0051] Specifically, the semantic expansion includes expansion based on the type of question, expansion based on the expected answer, and expansion based on the knowledge field.
[0052] The method of performing semantic expansion includes keyword synonym replacement, introduction of related context information, and use of user historical data.
[0053] Wherein, for introducing relevant context, context annotation can be performed according to key entities and preference entities to add context information; when performing semantic expansion, the context information is introduced into the structured query statement. Wherein, the context annotation is to add necessary context information to the question, including: time context, place context, field / theme context, situation context, user intention context. According to the set requirements, the large language model can automatically add relevant context annotation when performing operation according to the type and mode of the question. The context information added by the context annotation operation can add necessary details and depth to the explanatory text in the answer, so that the explanation is more comprehensive and accurate, in order to improve the accuracy of the large language model when processing complex queries and reduce the occurrence of illusion phenomenon.
[0054] In S5, the expansion entity contains multiple key entities and preference entities, and the expansion entity is randomly recombined to obtain an expansion entity group. When the expansion entity group is input into the pre-constructed knowledge base, the following mixed retrieval process is performed: (1) Semantic retrieval First, the expansion entity group is subjected to semantic understanding and analysis, and natural language processing techniques such as word vector models (e.g. Word2Vec, GloVe, etc.) are used to convert the words in the entity group into vector representations, thereby digitizing their semantic information.
[0055] In the knowledge base, the text in the historical commodity recommendation question is also converted into vector form. By calculating the cosine similarity, Euclidean distance, etc. between the expansion entity group vector and the historical commodity recommendation question vector, historical commodity recommendation questions with similar semantics are found. This approach can understand the meaning behind the words, and even if the expressions are different but the semantics are similar, they can still be retrieved, such as "mobile phone" and "mobile phone", and semantic retrieval can recognize their association.
[0056] (2) Full-text retrieval For specific words in the expansion entity group, perform precise text matching in the knowledge base. Each word in the expansion entity group is used as a search keyword to search the text of the historical commodity recommendation question, and find historical commodity recommendation questions that contain these keywords. For example, if the expansion entity group contains "sports shoes", search for the word "sports shoes" in the historical question text in the knowledge base to ensure that the question that accurately mentions the entity can be retrieved.
[0057] Through the mixed retrieval of the above semantic retrieval and full-text retrieval, the historical recommendation result is matched. The pre-constructed knowledge base includes historical commodity recommendation questions and corresponding historical recommendation results. Through similarity calculation, the historical commodity recommendation question containing the expansion entity group is found based on the expansion entity group, and the corresponding historical recommendation result is obtained based on the historical commodity recommendation question.
[0058] In S6, in the intelligent commodity recommendation process, multiple historical recommendation results will be obtained, and these results often provide suggestions from different dimensions. In order to facilitate user reading and understanding, it is necessary to aggregate the results.
[0059] The multiple historical recommendation results are preliminarily classified according to the recommended categories, for example, classified according to the dimensions of commodity brand, commodity function, commodity application scene, etc.
[0060] For example, for the question of "what items are needed for a family self-driving tour on the beach in summer", the historical recommendation results may include sunscreens of different brands, sun hats of various functions, and waterproof backpacks suitable for the beach, etc. These recommendations are classified by brand, function, and application scene, respectively.
[0061] For the same category, repeat the same word or similar word. For example, if multiple recommendations mention "large capacity backpack" and "ultra-large capacity backpack", they can be merged into "large capacity backpack". At the same time, remove redundant and low-value words. For example, when describing sunscreen, if "ordinary sunscreen" and "basic sunscreen" appear at the same time, and there is no essential difference between them, one of them can be deleted. In addition, when there are multiple similar but different quality, evaluation, etc. recommendations in the same category, select the word with higher comprehensive evaluation and more representative. For example, when recommending swimwear, "ordinary brand swimwear" and "well-known brand swimwear" are selected.
[0062] According to the logic of commodity recommendation, add conjunctions, qualifiers, etc. in appropriate places to make the integrated content logical and smooth. For example, when describing self-driving tour items, add "first", "second", "in addition", etc. conjunctions to sequentially link different types of item recommendations. For different types of recommended content, arrange them in a reasonable order, such as first introducing important protective items, and then introducing other auxiliary items.
[0063] Count the number of words in the integrated content. If it exceeds the preset number of words, further simplify the language and remove unnecessary adjectives, but make sure that the key information is not lost. If it does not reach the preset number of words, some necessary explanatory words can be added to make the recommended points more complete and easy to understand. Finally, generate a commodity recommendation point sentence that meets the specified format and word count requirements.
[0064] The embodiment can systematically sort complex information and avoid confusion by classifying multiple historical recommendation results in multiple dimensions. The same type of words are merged, redundant information is removed, and high-quality information is selected to effectively simplify the content and highlight the key recommendations. By adding conjunctions and determiners and arranging the content reasonably, the recommendation logic is coherent and consistent with the user's understanding habits. Finally, the output is adjusted according to the preset number of words to ensure the completeness of the key information and meet the display needs in different scenarios, greatly reducing the difficulty for users to obtain useful information, improving the accuracy and practicality of the recommendations, and enhancing the user experience.
[0065] Finally, the general recommendations generated by S1 and the product recommendation key sentence generated by S5 are output.
[0066] The embodiment simultaneously outputs the product recommendation key sentence and the general recommendations. From the user experience perspective, the product recommendation key sentence focuses on accurate needs and quickly provides matching products and core advantages to meet the demand for efficient decision-making. The general recommendations expand the knowledge dimension and cover content such as scenario adaptation, selection techniques, and usage experience to help users comprehensively understand the correlation between the demand and the product. For example, when recommending a camping tent, specific models and waterproof and portable features are provided, as well as tent selection and storage methods in different environments. From the service logic perspective, the combination of the two makes the recommendations more hierarchical and adaptable to various needs. Users can choose general recommendations or key points to assist decision-making. Additionally, relying on the preliminary optimization of key entities and the secondary optimization process, the output content is accurate and comprehensive, filling the information gap of single recommendations and improving the service professionalism and user satisfaction.
[0067] In the problem screening stage, the embodiment extracts multiple-dimensional key entities such as time, subject, activity, target, and recommendation willingness to accurately determine the relevance of the user's problem and product recommendations. Compared to traditional single-dimensional judgment methods, this greatly improves the accuracy and comprehensiveness of the screening. When analyzing user preferences, preference entities are obtained based on historical browsing, shopping, and current location records to uncover potential user needs and provide personalized recommendations, overcoming the limitations of traditional methods that rely solely on surface information of user problems. In the semantic expansion and hybrid retrieval stage, the key entities and preference entities are expanded and matched with historical recommendation results through semantic retrieval and full-text retrieval, taking into account semantic understanding and accurate text matching. This innovative approach solves the problem of incomplete and inaccurate information retrieval. Finally, by aggregating historical recommendation results and generating key sentences in the specified format and word count, the information presentation is optimized to meet the user's demand for quickly obtaining key recommendations, improving the intelligence and practicality of the recommendation system.
[0068] Embodiment Two The embodiment provides a product recommendation system based on multi-dimensional entity analysis and hybrid retrieval, comprising: The preprocessing module is configured to obtain a user problem, perform preprocessing to obtain a preliminary user optimized problem, and obtain general recommendations based on the preliminary user optimized problem. The entity extraction module is configured to extract key entities of the preliminary user optimization question, make a product recommendation relevance judgment on the user question based on the entity matching, and screen product recommendation relevant questions; the key entities include time entities, subject entities, activity entities, target entities, and recommendation willingness entities. The preference analysis module is configured to analyze user product preferences based on user behavior records to obtain preference entities. The entity expansion module is configured to perform semantic expansion on the key entities and the preference entities of the product recommendation relevant questions to obtain expanded entities. The suggestion acquisition module is configured to splice and reorganize the expanded entities, input a pre-constructed knowledge base, match historical recommendation results based on hybrid retrieval of semantic retrieval and full-text retrieval, and the pre-constructed knowledge base includes historical product recommendation questions and corresponding historical recommendation results. The output module is configured to aggregate the historical recommendation results, generate product recommendation point sentences based on a specified format and a word count, and output the product recommendation point sentences and the general suggestions.
[0069] Embodiment three The embodiment provides a computer readable storage medium, which stores a computer program, and the program is executed by a processor to implement steps in a product recommendation method based on multi-dimensional entity analysis and hybrid retrieval.
[0070] Embodiment four The embodiment provides a computer device, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, and the processor implements steps in a product recommendation method based on multi-dimensional entity analysis and hybrid retrieval when executing the program.
[0071] The steps or modules involved in the above embodiments two to four correspond to the embodiment one, and the specific embodiments can refer to the related description part of the embodiment one. The term "computer readable storage medium" should be understood as including a single medium or multiple media of one or more instruction sets; it should also be understood as including any medium capable of storing, encoding, or carrying instruction sets for execution by a processor and causing the processor to perform any method in the present application.
[0072] The above only describes the preferred embodiments of the present application and is not used to limit the present application. For those skilled in the art, the present application can have various changes and modifications. Any modification, equivalent replacement, improvement, etc. made within the spirit and principles of the present application shall be included in the protection scope of the present application.
Claims
1. A commodity recommendation method based on multi-dimensional entity analysis and mixed search, characterized in that, The method comprises the following steps: acquiring a user question, preprocessing the user question to obtain a preliminary user optimization question, and obtaining a general suggestion based on the preliminary user optimization question; extracting key entities of the preliminary user optimization question, judging the relevance of the user question to commodity recommendation based on entity matching, and screening commodity recommendation related questions; the key entities include time entities, subject entities, activity entities, target entities, and recommendation willingness entities; analyzing user commodity preferences based on user behavior records to obtain preference entities; performing semantic expansion on the key entities and the preference entities of the commodity recommendation related questions to obtain expanded entities; recombining the expanded entities, inputting the recombined expanded entities into a pre-constructed knowledge base, performing hybrid retrieval based on semantic retrieval and full-text retrieval, and matching historical recommendation results; the pre-constructed knowledge base includes historical commodity recommendation questions and corresponding historical recommendation results; aggregating the historical recommendation results, generating commodity recommendation point sentences based on a specified format and a word count, and outputting the commodity recommendation point sentences and the general suggestion.
2. The method of claim 1, wherein the method comprises: The time description words in the user question are taken as time entities; the performer of a behavior action or the object of a demand is taken as a subject entity; the words describing an activity, an event, or a scene are taken as activity entities; the thing being demanded or recommended is taken as a target entity; and the words expressing a recommendation willingness are taken as recommendation willingness entities.
3. The method of claim 1, wherein the method further comprises: The method of extracting key entities of the user question, judging the relevance of the user question to commodity recommendation based on entity matching, and screening commodity recommendation related questions comprises the following steps: calculating the similarity of the key entities and the entities in a pre-set commodity recommendation related entity library; if the similarity exceeds a pre-set threshold, it is determined that the user question is related to commodity recommendation, and the user question is retained as a commodity recommendation related question; otherwise, the user question is deleted, and the recommendation consultation is ended; the pre-set commodity recommendation related entity library is constructed based on historical commodity recommendation questions and user feedback data.
4. The method of claim 1, wherein the method is characterized by, The method of analyzing user commodity preferences based on user behavior records to obtain preference entities comprises the following steps: the user behavior records include historical browsing records, historical shopping records, and current location records; the preference entities include user brand preferences, user consumption level preferences, and current location preferences; user brand preferences are obtained by analyzing user historical browsing records; user consumption level preferences are obtained by analyzing user historical shopping records; current location preferences are obtained by analyzing current location records.
5. The method of claim 1, wherein the method further comprises: determining a plurality of dimensions of the product; and determining a plurality of entities of the product. The method of performing semantic expansion on the key entities and the preference entities of the commodity recommendation related questions comprises keyword synonym replacement, introduction of related context information, and utilization of user historical data.
6. The method of claim 1, wherein the method further comprises: The method of recombining the expanded entities, inputting the recombined expanded entities into a pre-constructed knowledge base, performing hybrid retrieval based on semantic retrieval and full-text retrieval, and matching historical recommendation results comprises the following steps: the expanded entities include multiple key entities and preference entities; the expanded entities are randomly recombined to obtain an expanded entity group; vector conversion is performed on the expanded entity group, and historical commodity recommendation question texts in the knowledge base are converted into vectors to calculate semantic similarity and complete semantic retrieval; The extended entity group vocabulary is used as a keyword for accurate full-text matching in the knowledge base historical commodity recommendation question text to complete full-text retrieval; The semantic retrieval and full-text retrieval results are fused, de-duplicated, and sorted according to the similarity scores; the corresponding historical recommendation results are selected as a guide to the historical commodity recommendation questions.
7. The method of claim 1, wherein the method further comprises: determining a plurality of dimensions of the product; and determining a plurality of entities of the product. The historical recommendation results are aggregated to generate commodity recommendation point statements based on a specified format and a word count, specifically including: Classifying multiple historical recommendation results according to recommendation categories; For the same type of vocabulary, performing operations such as merging duplicates, deleting redundancies, and selecting high-quality vocabulary; According to the commodity recommendation logic, adding conjunctions and qualifiers, and arranging the order of different types of recommendation content; According to the preset word count requirement, adjusting the statement to generate a commodity recommendation point statement that meets the specified format and word count.
8. A commodity recommendation system based on multi-dimensional entity analysis and mixed search, characterized in that, It includes: The preprocessing module is configured to obtain a user question, perform preprocessing to obtain a preliminary user optimization question, and obtain a general suggestion based on the preliminary user optimization question; The entity extraction module is configured to extract key entities of the preliminary user optimization question, judge the relevance of the user question based on entity matching, and filter commodity recommendation related questions; the key entities include time entities, subject entities, activity entities, target entities, and recommendation willingness entities; The preference analysis module is configured to analyze user commodity preferences based on user behavior records to obtain preference entities; The entity expansion module is configured to perform semantic expansion on the key entities and preference entities of the commodity recommendation related questions to obtain expanded entities; The suggestion acquisition module is configured to splice and reorganize the expanded entities, input a pre-constructed knowledge base, perform hybrid retrieval based on semantic retrieval and full-text retrieval, and match historical recommendation results; the pre-constructed knowledge base includes historical commodity recommendation questions and corresponding historical recommendation results; The output module is configured to aggregate the historical recommendation results, generate commodity recommendation point statements based on a specified format and a word count, and output commodity recommendation point statements and the general suggestion.
9. A computer readable storage medium having stored thereon a computer program, characterized in that, The program is executed by the processor to implement the steps of the commodity recommendation method based on multi-dimensional entity analysis and hybrid retrieval according to any one of claims 1-7.
10. A computer device comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, characterized in that, The processor executes the program to implement the steps of the commodity recommendation method based on multi-dimensional entity analysis and hybrid retrieval according to any one of claims 1-7.