Intelligent question and answer method and device, electronic equipment and storage medium

By building an entity feature vector library, parsing and generating reply text, the problem of poor reply text accuracy under multiple entity objects in intelligent question and answer is solved, and more accurate reply text generation is achieved.

CN120596594APending Publication Date: 2025-09-05BEIJING ZITIAO NETWORK TECH CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202410232407.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-02-29
Publication Date
2025-09-05

AI Technical Summary

Technical Problem

When multiple entity objects are involved, the existing intelligent question-and-answer function cannot accurately locate the entity object indicated by the query text, resulting in poor accuracy and low accuracy of the reply text.

Method used

By acquiring at least two entity objects in the interaction process, parsing to obtain the corresponding first feature vector, and constructing an entity feature vector library, the vector library is used to generate a reply text to achieve accurate judgment of the query request.

Benefits of technology

Improved the accuracy and precision of response text in multi-entity object scenarios, ensuring that the response text matches the query request.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120596594A_ABST
    Figure CN120596594A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides an intelligent question and answer method and device, electronic equipment and a storage medium, and the method comprises the steps: obtaining at least two entity objects in an interaction process after a query request in the interaction process is received; the method comprises the steps that entity objects are analyzed to obtain corresponding first feature vectors, an entity feature vector library is constructed based on the first feature vectors, and the first feature vectors represent content features of the entity objects; and based on the entity feature vector library, generating a reply text corresponding to the query request in the interaction process. According to the embodiment of the invention, the at least two entity objects before the query request are analyzed, the entity feature vector library is constructed, then the entity feature vector library is used for recall, and the reply text matched with the query request is generated, so that the entity objects indicated by the query request are accurately judged in a multi-entity object scene, and the query efficiency is improved. Therefore, the accuracy and precision of the finally generated reply text are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present disclosure relate to the field of artificial intelligence technology, and in particular to an intelligent question-answering method, device, electronic device, and storage medium. Background Art

[0002] In the intelligent question-and-answer function, users can ask questions or make requests to the intelligent assistant through natural language during the interaction process. After analyzing the requirements raised by the user, the intelligent assistant implemented based on the language model will give corresponding replies or perform corresponding actions.

[0003] However, in the existing technology, when the application process of the intelligent question-and-answer function involves physical objects such as documents and media, there is a problem that the reply text generated by the intelligent assistant is poorly accurate and has a low accuracy rate, which affects the quality of the question-and-answer response. Summary of the Invention

[0004] The embodiments of the present disclosure provide an intelligent question-answering method, device, electronic device, and storage medium to overcome the problem of poor accuracy and low correctness of reply texts generated by intelligent assistants.

[0005] In a first aspect, an embodiment of the present disclosure provides an intelligent question-answering method, comprising:

[0006] In response to receiving a query request during an interaction process, at least two entity objects in the interaction process are obtained; by parsing the entity objects, corresponding first feature vectors are obtained, and based on the first feature vectors, an entity feature vector library is constructed, wherein the first feature vector represents the content features of the entity objects; based on the entity feature vector library, a reply text corresponding to the query request is generated during the interaction process.

[0007] In a second aspect, an embodiment of the present disclosure provides an intelligent question-answering device, comprising:

[0008] an acquisition module, configured to acquire at least two entity objects in the interaction process in response to receiving a query request in the interaction process;

[0009] a parsing module, configured to parse the entity object to obtain a corresponding first feature vector, and construct an entity feature vector library based on the first feature vector, wherein the first feature vector represents a content feature of the entity object;

[0010] A generation module is used to generate a reply text corresponding to the query request during the interaction process based on the entity feature vector library.

[0011] In a third aspect, an embodiment of the present disclosure provides an electronic device, including: a processor and a memory;

[0012] The memory stores computer-executable instructions;

[0013] The processor executes the computer-executable instructions stored in the memory, so that the at least one processor executes the intelligent question-answering method described in the first aspect and various possible designs of the first aspect.

[0014] In a fourth aspect, an embodiment of the present disclosure provides a computer-readable storage medium, in which computer-executable instructions are stored. When a processor executes the computer-executable instructions, the intelligent question-answering method described in the first aspect and various possible designs of the first aspect is implemented.

[0015] In a fifth aspect, an embodiment of the present disclosure provides a computer program product, including a computer program, which, when executed by a processor, implements the intelligent question-answering method described in the first aspect and various possible designs of the first aspect.

[0016] The intelligent question-answering method, device, electronic device, and storage medium provided in this embodiment obtain at least two entity objects in the interaction process in response to a query request received during the interaction process; obtain a corresponding first feature vector by parsing the entity object, and construct an entity feature vector library based on the first feature vector, wherein the first feature vector represents the content feature of the entity object; and generate a reply text corresponding to the query request during the interaction process based on the entity feature vector library. By parsing at least two entity objects before the query request and constructing an entity feature vector library, and then using the entity feature vector library for recall, and then generating a reply text that matches the query request, accurate judgment of the entity object indicated by the query request is achieved in a multi-entity object scenario, thereby improving the accuracy and precision of the ultimately generated reply text. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] In order to more clearly illustrate the embodiments of the present disclosure or the technical solutions in the prior art, a brief introduction will be given below to the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are some embodiments of the present disclosure. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

[0018] Figure 1 A diagram of an application scenario of the intelligent question-answering method provided in an embodiment of the present disclosure;

[0019] Figure 2 Schematic diagram of the process of the intelligent question-answering method provided in the embodiment of the present disclosure Figure 1 ;

[0020] Figure 3 for Figure 2 A flowchart of a specific implementation method of step S101 in the embodiment shown;

[0021] Figure 4 A schematic diagram of a process for generating an entity feature vector library provided in an embodiment of the present disclosure;

[0022] Figure 5 for Figure 2 A flowchart of a specific implementation method of step S102 in the embodiment shown;

[0023] Figure 6 for Figure 5 A flowchart of a specific implementation method of step S1023 in the embodiment shown;

[0024] Figure 7 for Figure 2 A flowchart of a specific implementation method of step S103 in the embodiment shown;

[0025] Figure 8 A schematic diagram of generating a reply text during an interaction process provided by an embodiment of the present disclosure;

[0026] Figure 9 Schematic diagram of the process of the intelligent question-answering method provided in the embodiment of the present disclosure Figure 2 ;

[0027] Figure 10 A structural block diagram of the intelligent question-answering device provided in an embodiment of the present disclosure;

[0028] Figure 11 A schematic structural diagram of an electronic device provided in an embodiment of the present disclosure;

[0029] Figure 12 A schematic diagram of the hardware structure of an electronic device provided in an embodiment of the present disclosure. DETAILED DESCRIPTION

[0030] To make the objectives, technical solutions, and advantages of the embodiments of the present disclosure more clear, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present disclosure, not all of the embodiments. All other embodiments obtained by ordinary technicians in this field based on the embodiments of the present disclosure without making any creative efforts shall fall within the scope of protection of the present disclosure.

[0031] It should be noted that 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 disclosure 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.

[0032] The following explains the application scenarios of the embodiments of the present disclosure:

[0033] Figure 1 This is an application scenario diagram of the intelligent question-answering method provided by the embodiment of the present disclosure. The intelligent question-answering method provided by the embodiment of the present disclosure can be applied to applications with intelligent assistant functions based on language models. More specifically, it can be applied to intelligent question-answering application scenarios containing physical objects in office scenarios. The execution subject of this embodiment can be a terminal device running the above-mentioned application with intelligent assistant functions, or a server that deploys the service end corresponding to the above-mentioned application, or other electronic devices that perform similar functions. Figure 1 As shown in , taking a terminal device as an example, an intelligent assistant plug-in or function is provided in the instant messaging software running on the terminal device. When the intelligent assistant is enabled, the current user (shown as user #1 in the figure) can input entity objects in the dialogue window during the dialogue with other users (shown as user #2 and user #3 in the figure) through the instant messaging software, that is, input entity objects in the interaction process. For example, documents, network links, videos, etc. are input in the dialogue window. Afterwards, the user can call up the intelligent assistant by inputting a specified identifier (shown as @ in the figure) and input a query request related to the above entity object. For example, the query request is "Summarize the content of the above video". Afterwards, the intelligent assistant generates a reply text based on the query text input by the user and the entity object input in the interaction process. The content of the reply text is a summary of the content of the video (that is, the entity object previously input by the user in the interaction process).

[0034] In existing technologies, in intelligent question-and-answer scenarios involving multiple entity objects, the entity object closest to the query text entered by the current user is typically defaulted to the target object. This target object is then processed and manipulated to generate a response text corresponding to the query text, completing the intelligent question-and-answer process for the actual entity object. However, in actual applications, when there are multiple entity objects, the query text entered by the current user does not necessarily indicate the view object closest to it. Therefore, existing solutions cannot accurately locate the entity object indicated by the query text and also cannot accurately determine the user's intent, resulting in poor response text accuracy and low accuracy, affecting the quality of question-and-answer responses.

[0035] The embodiments of the present disclosure provide an intelligent question-answering method to solve the above problems.

[0036] refer to Figure 2 , Figure 2 Schematic diagram of the process of the intelligent question-answering method provided in the embodiment of the present disclosure Figure 1 The method of this embodiment can be applied in a terminal device or a server. The intelligent question-answering method includes:

[0037] Step S101: in response to receiving a query request in an interaction process, obtaining at least two entity objects in the interaction process.

[0038] refer to Figure 1In the application scenario diagram shown, the entity object can be a non-text information object such as a video, document, link, etc. input by the user during the interaction with the instant messaging software, for example, a video, document, link input in a dialogue window. The user who inputs the above-mentioned view object can be the current user (i.e., the user who operates the terminal device that serves as the execution subject of this embodiment) or another user (i.e., the user who chats with the current user during the above-mentioned interaction process in the instant messaging software). After the current user and / or other users input the above-mentioned entity object, the terminal device continues to receive the query request input by the current user during the interaction process by responding to the operation of the current user, that is, the user's question (query) statement in the intelligent question and answer function. The query request can be a text, that is, a query request text. In one possible implementation method, after detecting that the text input by the user contains a wake-up identifier, the terminal device determines the text as a query request. For example, the format of the wake-up identifier is: "@XX". Among them, "@" is the trigger symbol, and "XX" is the wake-up word. A specific implementation method is, for example, "@smart assistant". Afterwards, the other text content in the input text containing the wake-up mark will be used as a query request. For example, the terminal device receives the text input by the user during the interaction as "@smart assistant help me see the content of the video above". Since it contains the wake-up mark "@smart assistant", the terminal device determines it as a query request and uses the other text content except the wake-up mark as the actual text content of the query request, such as "help me see the content of the video above" in the above example.

[0039] Furthermore, after the terminal device receives the query request, it obtains at least two entity objects input by the user before the query request during the interaction process. Specifically, after the current user or other users input conversation information into the interaction process, the application will synchronize the conversation information to the server. Afterwards, the terminal device can obtain and display the conversation information by accessing the server or receiving a push from the server. The conversation information includes text and entity objects. Afterwards, the terminal device can further download the data corresponding to the entity object from the server to obtain the entity object. Figure 3 As shown, in a possible implementation, the specific implementation of step S101 includes:

[0040] Step S1011: Acquire the conversation information that meets the target condition before the query request.

[0041] Step S1012: Retrieve the information format of the dialogue information that meets the target condition and obtain the entity object.

[0042] Exemplarily, the terminal device can save conversation information prior to a query request locally by periodically accessing the server or receiving push notifications from the server. Subsequently, the terminal device retrieves conversation information prior to the query request that meets target criteria based on the timestamp of the conversation information. The target criteria include a predetermined target time interval and / or a target number. For example, the terminal device retrieves 20 conversation messages prior to the query request, or retrieves conversation information within one minute prior to the query request, thereby improving the timeliness of the conversation information. The terminal device then searches for conversation information that meets the target criteria. The conversation information includes both text-formatted and non-text-formatted information. Text-formatted information is information composed of characters, numbers, symbols, etc. Non-text-formatted information is entity objects. When the terminal device retrieves conversation information in non-text format, it identifies it as an entity object. In this embodiment, at least two entity objects can be obtained based on the information format of the conversation information. Furthermore, exemplary, the entity object includes at least one of the following: a media file, a data link, or a tool component. Specifically, media files include video files, audio files, and document files; data links include web links and program links; and tool components include various plug-ins, such as special effects tools and business cards. The specific implementation of entity objects depends on the information formats supported by the application and will not be explained here.

[0043] Of course, it is understandable that when only one entity object is included before the above query request, the only entity object can be directly processed to generate a reply text, or, if no entity object is included, the reply text can be directly generated based on the preset prompt text, such as "Not found..., please re-enter".

[0044] Step S102: Obtain a corresponding first feature vector by parsing the entity object, and construct an entity feature vector library based on the first feature vector, wherein the first feature vector represents the content feature of the entity object.

[0045] Exemplarily, after obtaining the at least two entity objects, vector sum processing is performed on the entity objects to obtain a vector representing the content features of the entity objects, namely, a first feature vector. Each entity object corresponds to at least one first feature vector. Subsequently, the first feature vectors corresponding to each entity object are combined to obtain a set containing the first feature vectors corresponding to each entity object, namely, an entity feature vector library. Figure 4 A schematic diagram of the generation process of an entity feature vector library provided in an embodiment of the present disclosure is shown as follows: Figure 4As shown, exemplarily, the terminal device obtains two entity objects located before the query request by detecting the conversation information in the conversation window, which are the video #1 and document #2 shown in the figure. Afterwards, the terminal device performs content analysis on video #1 and document #2, and vectorizes the results of the content analysis to obtain the corresponding first feature vector F1 and first feature vector F2. Among them, the first feature vector F1 represents the video content of video #1; the first feature vector F2 represents the document content of document #2. Afterwards, the first feature vector F1 and the first feature vector F2 are combined to obtain an entity feature vector library. Thereafter, the entity feature vector library composed of the first feature vector F1 and the first feature vector F2 can be used to recall the query request, and then generate a reply text related to video #1 and document #2.

[0046] In a possible implementation, after obtaining the above entity object, the entity object is further sliced ​​based on the content feature, and the sliced ​​result is vectorized to obtain the first feature vector corresponding to the slice. For example, Figure 5 As shown, the specific implementation of step S102 includes:

[0047] Step S1021: Obtain the object type corresponding to the entity object.

[0048] Step S1022: calling a parsing tool corresponding to the object type to parse the entity object and obtain the content text corresponding to the entity object.

[0049] Step S1023: Slice the content text to obtain at least one content text segment, and perform vectorization processing on the content text segment to obtain a first feature vector corresponding to the content text segment.

[0050] Exemplarily, first, based on the information format of the entity object, the object type corresponding to the entity object is obtained. Object types include, for example, media files, data links, and tool components. Next, a parsing tool for object type matching is called to perform content parsing on the entity object to obtain the corresponding content text. The content text is used to describe the content of the entity object. For example, if the entity object is "video," the content text may be text describing the video content of the video. Next, the content text is sliced ​​to obtain at least one content text segment, and the content text segment is vectorized to obtain a first feature vector corresponding to the content text segment.

[0051] Furthermore, in the process of slicing the content text, the content text is segmented based on the semantics of the content text. Specifically, Figure 6 As shown, the specific implementation of step S1023 includes:

[0052] Step S1023A: Perform semantic analysis on the content text to obtain semantic segmentation information corresponding to the content text. The semantic segmentation information is used to indicate at least one text segment with complete semantics in the content text.

[0053] Step S1023B: Segment the content text based on the semantic segmentation information to obtain content text segments.

[0054] Step S1023C: vectorize the content text segment to obtain a first feature vector corresponding to the content text segment.

[0055] Exemplarily, first, based on the semantic analysis tool (model), a semantic analysis is performed on the content text to obtain semantic segmentation information corresponding to the content text. The speech segmentation information is used to segment the text content and can be information used to indicate the segmentation position. Specifically, the semantic analysis tool can convert each text segment of the input content text into a semantic vector, and then judge the semantic integrity of the text segment based on the vector distance between the semantic vectors, and then use the text segment with complete semantics as the segmentation target, that is, to obtain semantic segmentation information. Afterwards, based on the semantic segmentation information, the content text is segmented to obtain content text fragments, which are the above-mentioned text segments with complete semantics. Finally, the content text fragments are vectorized (embedding), for example, by calling a vector model service to obtain the first feature vector corresponding to the content text fragment.

[0056] Step S103: Based on the entity feature vector library, a reply text corresponding to the query request is generated during the interaction process.

[0057] For example, after obtaining the entity feature vector library, a query is retrieved based on the object content of each entity object represented by the entity feature vector library, thereby determining at least one target entity object that best matches the query and the content of that target entity object. This target entity object is the estimated result of the entity object indicated by the query, and this process is equivalent to estimating the intent of the query. The retrieved result and the query are then input into a question-and-answer language model to obtain the corresponding reply text, which is then displayed during the interaction as an "intelligent assistant" speech.

[0058] In one possible implementation, Figure 7 As shown, the specific implementation steps of step S103 include:

[0059] Step S1031: Obtain a query feature vector corresponding to the query request.

[0060] Step S1032: obtaining feature similarities between the query feature vector and each feature vector in the entity feature vector library, and determining a target feature vector in the entity feature vector library based on the feature similarities.

[0061] Step S1033: generating a reply text based on the content text segment corresponding to the target feature vector during the interaction process, or generating the reply text and the object identifier of the entity object corresponding to the target feature vector during the interaction process.

[0062] For example, the query request is first vectorized to obtain a query feature vector. Next, the query feature vector is compared with the first feature vectors in the entity feature vector library obtained in the previous step for feature similarity. Specifically, the similarity between the query request and the entity object's content text segments after segmentation is determined. The specific similarity can be a similarity value, with a larger similarity value indicating greater content similarity between the two. The first feature vector with the greatest feature similarity is then used as the target feature vector. The content text segment corresponding to the target feature vector is determined as the recall result, input into the question-answering language model, and the corresponding response text is generated, which is then displayed during the interaction.

[0063] Since the reply text is generated based on the query request and the recall results (target entity objects) of the entity feature vector library, when the query request and the recall results are used as input information to call the question-answering language model, the user's query request intention can be described more clearly and accurately, making the reply text output by the question-answering language model more accurate.

[0064] Furthermore, in another possible implementation, generating a reply text corresponding to the query request during the interaction in step S103 includes generating the reply text and an object identifier of an entity object corresponding to the target entity object indicated by the query request during the interaction. Specifically, when the terminal device generates the reply text corresponding to the query request during the interaction, it simultaneously generates the reply text and the target entity object corresponding to the reply text, thereby displaying the intent estimation result for the query request and allowing the user to verify the correctness of the reply text.

[0065] Figure 8 A schematic diagram of generating a reply text during an interaction process provided by an embodiment of the present disclosure is shown in FIG. Figure 8As shown, the conversation window exemplifies two entity objects, Video #1 and Document #2. Upon receiving a query request (e.g., "@Smart Assistant, summarize the content of the above video"), the terminal device generates a reply based on the above steps. The reply is, for example, a summary of the content of Video #1. The terminal then displays the reply within the conversation window, along with the object identifier of the target entity object indicated by the query, i.e., "Video #1." Specifically, the terminal displays the text "Generated based on Video #1" below the reply. This means that the terminal device displays the object identifier of the target entity object during the interaction.

[0066] In this embodiment, after receiving a query request during an interaction, at least two entity objects in the interaction are obtained; corresponding first feature vectors are obtained by parsing the entity objects, and an entity feature vector library is constructed based on the first feature vectors, wherein the first feature vector represents the content characteristics of the entity objects; and based on the entity feature vector library, a reply text corresponding to the query request is generated during the interaction. By parsing at least two entity objects preceding the query request and constructing the entity feature vector library, the entity feature vector library is then used for recall to generate a reply text matching the query request. This achieves accurate determination of the entity objects indicated by the query request in a multi-entity object scenario, thereby improving the accuracy and precision of the ultimately generated reply text.

[0067] refer to Figure 9 , Figure 9 Schematic diagram of the process of the intelligent question-answering method provided in the embodiment of the present disclosure Figure 2 In this embodiment Figure 2 Based on the embodiment shown, step S103 is further refined, and the intelligent question-answering method includes:

[0068] Step S201: in response to receiving a query request in an interaction process, obtaining at least two entity objects in the interaction process.

[0069] Step S202: parse each entity object to obtain at least one content text segment corresponding to each entity object, and perform vectorization processing on the content text segment to obtain a first feature vector corresponding to the content text segment.

[0070] Step S203: Acquire domain data, and obtain a corresponding second feature vector based on the domain data, where the domain data is used to define at least one domain knowledge.

[0071] Step S204: constructing an entity feature vector library based on the first feature vector and the second feature vector.

[0072] Exemplarily, the terminal device obtains the corresponding first feature vector by acquiring at least two entity objects in the interaction process. Figure 2 The implementation method of generating the first feature vector in steps S101-S102 in the embodiment shown is the same, which can be seen in Figure 2 The relevant introduction in the illustrated embodiment will not be repeated here.

[0073] Afterwards, the terminal device obtains preset domain data. The domain data is used to define at least one domain knowledge. The domain data can also be called industry data, including relevant concepts, rules, definitions, and names customized by users based on experience and needs. More specifically, for example, it includes name abbreviations, abbreviations, customized names, etc. Afterwards, the terminal device vectorizes the domain data to obtain the corresponding second feature vector. This step is similar to the process of generating the first feature vector, for example, including semantic recognition, segmentation, vectorization, etc. of the domain data. The specific implementation process can be referred to Figure 2 The process of generating the first feature vector in the illustrated embodiment will not be further described here. Subsequently, the second feature vector is merged with the first feature vector to construct an entity feature vector library. In this embodiment, by generating a second feature vector based on domain data and jointly constructing an entity feature vector library based on the second feature vector and the first feature vector, the content of the entity feature vector library is expanded. This further improves the recognition range of query requests and the accuracy of understanding the intent of the query requests when processing query requests based on the entity feature vector library.

[0074] Step S205: Obtain the query feature vector corresponding to the query request.

[0075] Step S206: obtaining feature similarities between the query feature vector and each feature vector in the entity feature vector library, and determining a target feature vector in the entity feature vector library based on the feature similarities.

[0076] Exemplarily, the terminal device vectorizes the query request to obtain a query feature vector, and performs a special effect similarity comparison based on the query feature vector and the feature similarity of each feature vector in the entity feature vector library to determine the target feature vector with the largest feature similarity. Figure 2 Step S103 in the illustrated embodiment has been described in detail and will not be repeated here. It should be noted that, in this embodiment, since the entity feature vector library is constructed based on the second feature vector and the first feature vector, when the entity feature vector library is recalled based on the query feature vector, the target feature vector obtained may be the first feature vector or the second feature vector. When the target feature vector is the second feature vector, the content text segment corresponding to the second feature vector is obtained through the domain data.

[0077] Optionally, after step S206, the method further includes:

[0078] Step S207 , performing intent recognition on the content text segment and the query request corresponding to the target feature vector, respectively, to obtain first intent information corresponding to the content text segment and second intent information corresponding to the query request.

[0079] Step S208: Obtain the similarity between the first intent information and the second intent information.

[0080] Step S209: If the similarity is greater than the intention similarity threshold, the content text segment is processed based on the question-answering language model to generate a reply text during the interaction process.

[0081] Exemplarily, after determining the target feature vector, in order to further improve the accuracy of the generated reply text, the content text segment corresponding to the target feature vector can be further detected to determine whether the intent it represents is consistent with the intent of the query request. Specifically, the content text segment and the query request corresponding to the target feature vector can be obtained respectively, and the intent recognition can be performed on the two separately. The specific implementation method can be achieved through a pre-trained language model, which will not be repeated here. The result of intent recognition includes the first intent information corresponding to the content text segment and the second intent information corresponding to the query request. More specifically, the first intent information and the second intent information are, for example, intent identifiers representing intent categories, or feature vectors representing intent; then the similarity of the first intent information and the second intent information is compared, that is, the similarity is obtained based on the consistency of the intent identifiers, or based on the distance between the feature vectors.

[0082] Afterwards, exemplarily, based on the similarity obtained in the above steps, if the similarity is greater than or equal to the preset intent similarity threshold, it means that the recall result (target feature vector) corresponding to the entity feature vector library is accurate. In this case, the content text fragment corresponding to the target feature vector is processed based on the question-answering language model to generate a reply text, which is displayed in the dialogue window (during the interaction process).

[0083] Furthermore, when the similarity is greater than the intent similarity threshold, the specific implementation steps of processing the content text fragment based on the question-answering language model to generate a reply text during the interaction process include:

[0084] Step S2091: Constructing a target prompt word based on the content text segment and the query request, wherein the target prompt word includes a first field and a second field. The first field is generated based on the query request and is used to represent the question content. The second field is generated based on the content text segment and is used to explain the domain knowledge in the question content.

[0085] Step S2092: Process the target prompt word based on the question-answering language model and generate a reply text during the interaction process.

[0086] Exemplarily, when the similarity is greater than the intent similarity threshold, a preset prompt word template is used to convert the content text fragment and the query request into a corresponding target prompt word. The target prompt word includes multiple text segments or fields. Taking the case of fields as an example, the target prompt word includes, for example, a first field and a second field. The field content of the first field is generated based on the query request and is used to represent the question content. Specifically, for example, the field content of the first field can be the query request itself, or it can be the query request's main sentence or content summary obtained after processing the query request. The field content of the second field is generated based on the content text fragment and is used to explain the domain knowledge in the question content, namely, the relevant concepts, rules, and definitions in the domain data based on user experience and customization needs. Through the first and second fields, the generation requirements of the concepts, rules, and definitions in the user's query and related to certain specific domains can be fully and clearly described, thereby guiding the question-answering language model implemented based on the language model to output more accurate response text.

[0087] In step S210 , if the similarity is less than the intention similarity threshold, the query request is processed based on the question-answering language model, and a reply text is generated during the interaction process.

[0088] In another case, if the similarity is less than or equal to the preset intent similarity threshold, it means that the recall result (target feature vector) corresponding to the entity feature vector library is inaccurate. In this case, based on the free dialogue capability (general processing capability) of the question-answering language model, the query request is processed by calling public network processing and other methods to obtain a general reply text.

[0089] In this embodiment, after obtaining the target feature vector, the target feature vector is further compared with the intent to ensure the accuracy of the entity feature vector library recall result, so that the final generated reply text is more consistent with the query request, thereby improving the reply accuracy.

[0090] Corresponding to the intelligent question-answering method of the above embodiment, Figure 10 This is a structural block diagram of the intelligent question-answering device provided by an embodiment of the present disclosure. For ease of explanation, only the parts related to the embodiment of the present disclosure are shown.

[0091] Reference Figure 10 , the intelligent question-answering device 3 includes:

[0092] The acquisition module 31 is configured to acquire at least two entity objects in the interaction process in response to receiving a query request in the interaction process.

[0093] The parsing module 32 is configured to parse the entity object to obtain a corresponding first feature vector, and construct an entity feature vector library based on the first feature vector, wherein the first feature vector represents content features of the entity object.

[0094] The generation module 33 is used to generate a reply text corresponding to the query request during the interaction process based on the entity feature vector library.

[0095] In one embodiment of the present disclosure, when the parsing module 32 obtains the corresponding first feature vector by parsing the entity object, it is specifically used to: obtain the object type corresponding to the entity object; call the parsing tool corresponding to the object type to parse the entity object to obtain the content text corresponding to the entity object; slice the content text to obtain at least one content text segment, and vectorize the content text segment to obtain the first feature vector corresponding to the content text segment.

[0096] In one embodiment of the present disclosure, when the parsing module 32 slices the content text to obtain at least one content text fragment, it is specifically used to: perform semantic analysis on the content text to obtain semantic segmentation information corresponding to the content text, where the semantic segmentation information is used to indicate at least one text segment with complete semantics in the content text; and segment the content text based on the semantic segmentation information to obtain content text fragments.

[0097] In one embodiment of the present disclosure, the generation module 33 is specifically used to: obtain a query feature vector corresponding to a query request; obtain feature similarity between the query feature vector and each feature vector in the entity feature vector library, and determine a target feature vector in the entity feature vector library based on the feature similarity; generate a reply text during the interaction process based on a content text segment corresponding to the target feature vector, or generate an object identifier of an entity object corresponding to the reply text and the target feature vector during the interaction process.

[0098] In one embodiment of the present disclosure, before generating a reply text during the interaction process based on the content text segment corresponding to the target feature vector, the generation module 33 is further used to: perform intent recognition on the content text segment and the query request corresponding to the target feature vector respectively, to obtain first intent information corresponding to the content text segment and second intent information corresponding to the query request; obtain the similarity between the first intent information and the second intent information; when the generation module 33 generates a reply text during the interaction process based on the content text segment corresponding to the target feature vector, the generation module 33 is specifically used to: if the similarity is greater than the intent similarity threshold, process the content text segment based on the question-answering language model to generate a reply text during the interaction process.

[0099] In one embodiment of the present disclosure, when generating a reply text during an interaction based on a content text segment corresponding to a target feature vector, the generation module 33 is further used to: if the similarity is less than the intention similarity threshold, process the query request based on the question-answering language model and generate a reply text during the interaction.

[0100] In one embodiment of the present disclosure, when generating a reply text during an interaction based on a content text segment corresponding to a target feature vector, the generation module 33 is specifically used to: construct a target prompt word according to the content text segment and a query request, wherein the target prompt word includes a first field and a second field, the first field is generated based on the query request and is used to characterize the question content; the second field is generated based on the content text segment and is used to explain the domain knowledge in the question content; the target prompt word is processed based on a question-answering language model to generate a reply text during the interaction.

[0101] In one embodiment of the present disclosure, the acquisition module 31 is further used to: acquire domain data, which is used to define at least one domain knowledge; and obtain a corresponding second feature vector based on the domain data; when the parsing module 33 constructs an entity feature vector library based on the first feature vector, it is specifically used to: construct an entity feature vector library based on the first feature vector and the second feature vector.

[0102] In one embodiment of the present disclosure, the acquisition module 31 is specifically used to: obtain conversation information that meets the target conditions before the query request, wherein the target conditions include a predetermined target time interval and / or a target quantity; retrieve the information format of the conversation information that meets the target conditions to obtain an entity object; wherein the entity object includes at least one of the following: a media file, a data link, and a tool component.

[0103] The acquisition module 31, analysis module 32 and generation module 33 are connected in sequence. The intelligent question-answering device 3 provided in this embodiment can implement the technical solution of the above method embodiment, and its implementation principle and technical effect are similar, which will not be repeated in this embodiment.

[0104] Figure 11 A schematic diagram of the structure of an electronic device provided in an embodiment of the present disclosure is shown in FIG. Figure 11 As shown, the electronic device 4 includes:

[0105] A processor 41, and a memory 42 communicatively connected to the processor 41;

[0106] Memory 42 stores computer-executable instructions;

[0107] The processor 41 executes the computer execution instructions stored in the memory 42 to implement the following Figure 2-Figure 9 The intelligent question-answering method in the illustrated embodiment.

[0108] Optionally, the processor 41 and the memory 42 are connected via a bus 43 .

[0109] For related instructions, please refer to Figure 2-Figure 9 The relevant descriptions and effects corresponding to the steps in the corresponding embodiments can be understood, and no further details are given here.

[0110] The present invention provides a computer-readable storage medium that stores computer-executable instructions. When the computer-executable instructions are executed by a processor, the computer-executable instructions are used to implement the present invention. Figure 2-Figure 9 The intelligent question-answering method provided in any one of the corresponding embodiments.

[0111] The present invention provides a computer program product, including a computer program, which implements the present invention when executed by a processor. Figure 2-Figure 9 The intelligent question-answering method provided in any one of the corresponding embodiments.

[0112] In order to implement the above embodiment, the embodiment of the present disclosure further provides an electronic device.

[0113] refer to Figure 12 , which shows a schematic structural diagram of an electronic device 900 suitable for implementing the embodiments of the present disclosure. The electronic device 900 may be a terminal device or a server. The terminal device may include, but is not limited to, mobile terminals such as mobile phones, laptop computers, digital broadcast receivers, personal digital assistants (PDAs), tablet computers (Portable Android Devices, PADs), portable multimedia players (PMPs), in-vehicle terminals (e.g., in-vehicle navigation terminals), and fixed terminals such as digital TVs and desktop computers. Figure 12 The electronic device shown is only an example and should not limit the functions and scope of use of the embodiments of the present disclosure.

[0114] like Figure 12As shown, the electronic device 900 may include a processing device (e.g., a central processing unit, a graphics processing unit, etc.) 901, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 902 or a program loaded from a storage device 908 into a random access memory (RAM) 903. Various programs and data required for the operation of the electronic device 900 are also stored in the RAM 903. The processing device 901, the ROM 902, and the RAM 903 are connected to each other via a bus 904. An input / output (I / O) interface 905 is also connected to the bus 904.

[0115] Typically, the following devices may be connected to the I / O interface 905: an input device 906 including, for example, a touch screen, a touchpad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; an output device 907 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; a storage device 908 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 909. The communication device 909 may allow the electronic device 900 to communicate with other devices wirelessly or by wire to exchange data. Although Figure 12 The electronic device 900 is shown with various devices, but it should be understood that it is not required to implement or possess all of the devices shown. More or fewer devices may be implemented or possessed instead.

[0116] In particular, according to an embodiment of the present disclosure, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present disclosure includes a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network via the communication device 909, or installed from the storage device 908, or installed from the ROM 902. When the computer program is executed by the processing device 901, the above-mentioned functions defined in the method of the embodiment of the present disclosure are performed.

[0117] It should be noted that the computer-readable medium mentioned above in the present disclosure may be a computer-readable signal medium or a computer-readable storage medium, or any combination of the two. A computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or component, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present disclosure, a computer-readable storage medium may be any tangible medium that contains or stores a program that can be used by or in conjunction with an instruction execution system, device, or component. In the present disclosure, a computer-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave, which carries computer-readable program code. Such a propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. A computer-readable signal medium may also be any computer-readable medium other than a computer-readable storage medium that can transmit, propagate, or transport a program for use by or in conjunction with an instruction execution system, apparatus, or device. The program code contained on the computer-readable medium may be transmitted using any suitable medium, including but not limited to wires, optical cables, RF (radio frequency), etc., or any suitable combination thereof.

[0118] The computer-readable medium may be included in the electronic device, or may exist independently without being incorporated into the electronic device.

[0119] The computer-readable medium carries one or more programs. When the one or more programs are executed by the electronic device, the electronic device executes the method shown in the above embodiment.

[0120] Computer program code for performing the operations of the present disclosure may be written in one or more programming languages ​​or a combination thereof, including object-oriented programming languages ​​such as Java, Smalltalk, C++, and conventional procedural programming languages ​​such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving a remote computer, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0121] The flowcharts and block diagrams in the accompanying drawings illustrate the possible implementation architecture, functions and operations of the systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each box in the flowchart or block diagram can represent a module, program segment, or a part of code, and the module, program segment, or a part of code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order than that marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or flowchart, and the combination of the boxes in the block diagram and / or flowchart, can be implemented with a dedicated hardware-based system that performs the specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0122] The units or modules involved in the embodiments described in this disclosure may be implemented in software or hardware, wherein the name of a unit or module does not, in some cases, limit the unit itself.

[0123] The functions described above herein may be performed, at least in part, by one or more hardware logic components. For example, and without limitation, exemplary types of hardware logic components that may be used include: field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chip (SOCs), complex programmable logic devices (CPLDs), and the like.

[0124] In the context of the present disclosure, a machine-readable medium can be a tangible medium that can contain or store a program for use by or in conjunction with an instruction execution system, device or equipment. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium can include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0125] In a first aspect, according to one or more embodiments of the present disclosure, an intelligent question-answering method is provided, comprising:

[0126] In response to receiving a query request during an interaction process, at least two entity objects in the interaction process are obtained; by parsing the entity objects, corresponding first feature vectors are obtained, and based on the first feature vectors, an entity feature vector library is constructed, wherein the first feature vector represents the content features of the entity objects; based on the entity feature vector library, a reply text corresponding to the query request is generated during the interaction process.

[0127] According to one or more embodiments of the present disclosure, parsing the entity object to obtain the corresponding first feature vector includes: obtaining the object type corresponding to the entity object; calling the parsing tool corresponding to the object type to parse the entity object to obtain the content text corresponding to the entity object; slicing the content text to obtain at least one content text segment, and vectorizing the content text segment to obtain the first feature vector corresponding to the content text segment.

[0128] According to one or more embodiments of the present disclosure, slicing the content text to obtain at least one content text fragment includes: performing semantic analysis on the content text to obtain semantic segmentation information corresponding to the content text, the semantic segmentation information being used to indicate at least one text segment in the content text with complete semantics; and segmenting the content text based on the semantic segmentation information to obtain the content text fragments.

[0129] According to one or more embodiments of the present disclosure, generating a reply text corresponding to the query request during the interaction based on the entity feature vector library includes: obtaining a query feature vector corresponding to the query request; obtaining feature similarity between the query feature vector and each feature vector in the entity feature vector library, and determining a target feature vector in the entity feature vector library based on the feature similarity; generating the reply text during the interaction based on a content text segment corresponding to the target feature vector, or generating an object identifier of the entity object corresponding to the reply text and the target feature vector during the interaction.

[0130] According to one or more embodiments of the present disclosure, before generating the reply text in the interaction process based on the content text segment corresponding to the target feature vector, the method further includes: performing intent recognition on the content text segment corresponding to the target feature vector and the query request respectively to obtain first intent information corresponding to the content text segment and second intent information corresponding to the query request; obtaining the similarity between the first intent information and the second intent information; generating the reply text in the interaction process based on the content text segment corresponding to the target feature vector, including: if the similarity is greater than an intent similarity threshold, processing the content text segment based on a question-answering language model to generate the reply text in the interaction process.

[0131] According to one or more embodiments of the present disclosure, the generating of the reply text during the interaction process based on the content text segment corresponding to the target feature vector also includes: if the similarity is less than the intention similarity threshold, processing the query request based on the question-answering language model, and generating the reply text during the interaction process.

[0132] According to one or more embodiments of the present disclosure, generating the reply text during the interaction based on the content text segment corresponding to the target feature vector includes: constructing a target prompt word based on the content text segment and the query request, wherein the target prompt word includes a first field and a second field, the first field being generated based on the query request and used to characterize the question content; the second field being generated based on the content text segment and used to explain the domain knowledge in the question content; and processing the target prompt word based on a question-answering language model to generate the reply text during the interaction.

[0133] According to one or more embodiments of the present disclosure, the method further includes: acquiring domain data, wherein the domain data is used to define at least one domain knowledge; obtaining a corresponding second feature vector based on the domain data; and constructing an entity feature vector library based on the first feature vector, including: constructing the entity feature vector library based on the first feature vector and the second feature vector.

[0134] According to one or more embodiments of the present disclosure, obtaining at least two entity objects in the interaction process includes: obtaining conversation information that meets target conditions before the query request, wherein the target conditions include a predetermined target time interval and / or a target quantity; retrieving the information format of the conversation information that meets the target conditions to obtain the entity objects; wherein the entity objects include at least one of the following: a media file, a data link, and a tool component.

[0135] In a second aspect, according to one or more embodiments of the present disclosure, an intelligent question-answering device is provided, comprising:

[0136] The acquisition module is configured to acquire at least two entity objects in the interaction process in response to receiving a query request in the interaction process.

[0137] The parsing module is configured to parse the entity object to obtain a corresponding first feature vector, and construct an entity feature vector library based on the first feature vector, wherein the first feature vector represents a content feature of the entity object.

[0138] A generation module is used to generate a reply text corresponding to the query request during the interaction process based on the entity feature vector library.

[0139] According to one or more embodiments of the present disclosure, when the parsing module obtains the corresponding first feature vector by parsing the entity object, it is specifically used to: obtain the object type corresponding to the entity object; call the parsing tool corresponding to the object type to parse the entity object to obtain the content text corresponding to the entity object; slice the content text to obtain at least one content text segment, and vectorize the content text segment to obtain the first feature vector corresponding to the content text segment.

[0140] According to one or more embodiments of the present disclosure, when the parsing module slices the content text to obtain at least one content text fragment, it is specifically used to: perform semantic analysis on the content text to obtain semantic segmentation information corresponding to the content text, the semantic segmentation information is used to indicate at least one text segment with complete semantics in the content text; based on the semantic segmentation information, segment the content text to obtain the content text fragments.

[0141] According to one or more embodiments of the present disclosure, the generation module is specifically used to: obtain a query feature vector corresponding to the query request; obtain feature similarity between the query feature vector and each feature vector in the entity feature vector library, and determine a target feature vector in the entity feature vector library based on the feature similarity; generate the reply text during the interaction process based on the content text fragment corresponding to the target feature vector, or generate an object identifier of the entity object corresponding to the reply text and the target feature vector during the interaction process.

[0142] According to one or more embodiments of the present disclosure, before generating the reply text in the interaction process based on the content text segment corresponding to the target feature vector, the generation module is further used to: perform intent recognition on the content text segment corresponding to the target feature vector and the query request respectively to obtain first intent information corresponding to the content text segment and second intent information corresponding to the query request; obtain the similarity between the first intent information and the second intent information; when the generation module generates the reply text in the interaction process based on the content text segment corresponding to the target feature vector, the generation module is specifically used to: if the similarity is greater than the intent similarity threshold, process the content text segment based on a question-answering language model to generate the reply text in the interaction process.

[0143] According to one or more embodiments of the present disclosure, when the generation module generates the reply text during the interaction based on the content text segment corresponding to the target feature vector, it is also used to: if the similarity is less than the intention similarity threshold, process the query request based on the question-answering language model and generate the reply text during the interaction.

[0144] According to one or more embodiments of the present disclosure, when the generation module generates the reply text in the interaction process based on the content text fragment corresponding to the target feature vector, it is specifically used to: construct a target prompt word based on the content text fragment and the query request, wherein the target prompt word includes a first field and a second field, the first field is generated based on the query request and is used to characterize the question content; the second field is generated based on the content text fragment and is used to explain the domain knowledge in the question content; the target prompt word is processed based on a question-answering language model to generate the reply text in the interaction process.

[0145] According to one or more embodiments of the present disclosure, the acquisition module is further used to: acquire domain data, the domain data is used to define at least one domain knowledge; based on the domain data, obtain a corresponding second feature vector; when the parsing module constructs an entity feature vector library based on the first feature vector, it is specifically used to: construct the entity feature vector library based on the first feature vector and the second feature vector.

[0146] According to one or more embodiments of the present disclosure, the acquisition module is specifically used to: obtain conversation information that meets the target conditions before the query request, wherein the target conditions include a predetermined target time interval and / or a target quantity; retrieve the information format of the conversation information that meets the target conditions to obtain the entity object; wherein the entity object includes at least one of the following: a media file, a data link, and a tool component.

[0147] In a third aspect, according to one or more embodiments of the present disclosure, there is provided an electronic device, comprising: at least one processor and a memory;

[0148] The memory stores computer-executable instructions;

[0149] The at least one processor executes the computer-executable instructions stored in the memory, so that the at least one processor executes the intelligent question-answering method described in the first aspect and various possible designs of the first aspect.

[0150] In a fourth aspect, according to one or more embodiments of the present disclosure, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores computer-executable instructions. When the processor executes the computer-executable instructions, the intelligent question-answering method described in the first aspect and various possible designs of the first aspect is implemented.

[0151] In a fifth aspect, according to one or more embodiments of the present disclosure, a computer program product is provided, comprising a computer program, which, when executed by a processor, implements the intelligent question-answering method as described in the first aspect and various possible designs of the first aspect.

[0152] The above description is merely a preferred embodiment of the present disclosure and an illustration of the technical principles employed. Those skilled in the art should understand that the scope of disclosure involved in the present disclosure is not limited to the technical solutions formed by the specific combination of the above-mentioned technical features, but also includes other technical solutions formed by any combination of the above-mentioned technical features or their equivalents without departing from the above-mentioned disclosed concepts. For example, a technical solution formed by replacing the above-mentioned features with (but not limited to) technical features with similar functions disclosed in this disclosure.

[0153] In addition, although each operation is described in a specific order, this should not be understood as requiring these operations to be performed in the specific order shown or in a sequential order. Under certain circumstances, multitasking and parallel processing may be advantageous. Similarly, although some specific implementation details have been included in the above discussion, these should not be interpreted as limiting the scope of the present disclosure. Some features described in the context of a separate embodiment can also be implemented in a single embodiment in combination. On the contrary, the various features described in the context of a single embodiment can also be implemented in multiple embodiments individually or in any suitable sub-combination mode.

[0154] Although the subject matter has been described in language specific to structural features and / or methodological logical acts, it should be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or acts described above. Rather, the specific features and acts described above are merely example forms of implementing the claims.

Claims

1. An intelligent question-answering method, characterized in that: include: After receiving a query request in the interaction process, obtaining at least two entity objects in the interaction process; Obtaining a corresponding first feature vector by parsing the entity object, and constructing an entity feature vector library based on the first feature vector, wherein the first feature vector represents a content feature of the entity object; Based on the entity feature vector library, a reply text corresponding to the query request is generated during the interaction process.

2. The method according to claim 1, characterized in that The obtaining of a corresponding first feature vector by parsing the entity object includes: Obtain the object type corresponding to the entity object; Invoke a parsing tool corresponding to the object type to parse the entity object and obtain the content text corresponding to the entity object; The content text is sliced ​​to obtain at least one content text segment, and the content text segment is vectorized to obtain a first feature vector corresponding to the content text segment.

3. The method according to claim 2, characterized in that The step of slicing the content text to obtain at least one content text segment includes: Performing semantic analysis on the content text to obtain semantic segmentation information corresponding to the content text, wherein the semantic segmentation information is used to indicate at least one text segment with complete semantics in the content text; The content text is segmented based on the semantic segmentation information to obtain the content text segments.

4. The method according to claim 1, wherein Generating a reply text corresponding to the query request based on the entity feature vector library during the interaction process includes: Obtaining a query feature vector corresponding to the query request; Obtaining feature similarities between the query feature vector and each feature vector in the entity feature vector library, and determining a target feature vector in the entity feature vector library based on the feature similarities; Based on the content text segment corresponding to the target feature vector, the reply text is generated during the interaction process, or the reply text and the object identifier of the entity object corresponding to the target feature vector are generated during the interaction process.

5. The method according to claim 4, characterized in that Before generating the reply text based on the content text segment corresponding to the target feature vector in the interaction process, the method further includes: Performing intent recognition on the content text segment and the query request corresponding to the target feature vector respectively to obtain first intent information corresponding to the content text segment and second intent information corresponding to the query request; Obtaining similarity between the first intent information and the second intent information; Generating the reply text during the interaction based on the content text segment corresponding to the target feature vector includes: If the similarity is greater than the intention similarity threshold, the content text segment is processed based on a question-answering language model to generate the reply text during the interaction.

6. The method according to claim 5, characterized in that Generating the reply text during the interaction based on the content text segment corresponding to the target feature vector further includes: If the similarity is less than the intention similarity threshold, the query request is processed based on the question-answering language model, and the reply text is generated during the interaction process.

7. The method according to claim 4, characterized in that Generating the reply text during the interaction based on the content text segment corresponding to the target feature vector includes: Constructing a target prompt word based on the content text segment and the query request, wherein the target prompt word includes a first field and a second field, the first field being generated based on the query request and used to represent the question content; the second field being generated based on the content text segment and used to explain the domain knowledge in the question content; The target prompt word is processed based on a question-answering language model, and the reply text is generated during the interaction.

8. The method according to claim 1, characterized in that The method further comprises: Acquire domain data, where the domain data is used to define at least one domain knowledge; Based on the domain data, obtaining a corresponding second eigenvector; The step of constructing an entity feature vector library based on the first feature vector includes: The entity feature vector library is constructed based on the first feature vector and the second feature vector.

9. The method according to claim 1, characterized in that The acquiring of at least two entity objects in the interaction process includes: Acquire conversation information that meets target conditions before the query request, where the target conditions include a predetermined target time interval and / or a target quantity; Retrieving the information format of the dialogue information that meets the target condition and obtaining the entity object; The entity object includes at least one of the following: Media files, data links, tool components.

10. An intelligent question-answering device, characterized in that: include: an acquisition module, configured to acquire at least two entity objects in the interaction process in response to receiving a query request in the interaction process; a parsing module, configured to parse the entity object to obtain a corresponding first feature vector, and construct an entity feature vector library based on the first feature vector, wherein the first feature vector represents a content feature of the entity object; A generation module is used to generate a reply text corresponding to the query request during the interaction process based on the entity feature vector library.

11. An electronic device, characterized in that: include: processor and memory; The memory stores computer-executable instructions; The processor executes the computer-executable instructions stored in the memory, so that the processor executes the intelligent question-answering method according to any one of claims 1 to 9.

12. A computer-readable storage medium, characterized in that The computer-readable storage medium stores computer-executable instructions. When the processor executes the computer-executable instructions, the intelligent question-answering method according to any one of claims 1 to 9 is implemented.

13. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the intelligent question-answering method according to any one of claims 1 to 9 is implemented.

Citation Information

Patent Citations

  • Intelligent question-answering method and device, computer equipment and storage medium

    CN111708873A

  • Multi-modal retrieval method and device based on specific range

    CN117033308A

  • Intelligent question and answer method, device and equipment and storage medium

    CN117591658A