Question and answer method and device, electronic equipment and storage medium

CN116955564BActive Publication Date: 2026-11-03BAIDU INT TECH (SHENZHEN) CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310930178.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-07-27
Publication Date
2026-11-03
Estimated Expiration
2043-07-27

AI Technical Summary

Technical Problem

When searching for personnel or project information within an enterprise, existing technologies are inefficient and costly, and outdated or missing information in the database leads to users obtaining outdated information.

Method used

This paper presents a question-answering method that retrieves project text information from a database, extracts the relationship between object information and project text information based on project-related documents, and directly integrates effective information without relying on graphs for information retrieval. It utilizes deep learning models and search engine technology for information retrieval and ranking.

Benefits of technology

It improves information retrieval efficiency, reduces users' time costs, ensures the timeliness and accuracy of information, and avoids the inefficiency of manual information retrieval.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116955564B_ABST
    Figure CN116955564B_ABST
Patent Text Reader

Abstract

The present disclosure provides a question and answer method and device, electronic equipment and storage medium, relates to the technical field of artificial intelligence, in particular to the field of natural language processing. The specific implementation scheme is: in response to receiving original query information, recalling a plurality of item text information from the database according to the original query information; determining a plurality of target text information in the plurality of item text information according to the evaluation value of the plurality of item text information in the recall stage; and determining the response information for the original query information according to the plurality of target text information and the object information of the object having an association relationship with each target text information; wherein the association relationship is obtained based on the relationship between the object information of the object and the item text information of the item in the project related document.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This disclosure relates to the field of artificial intelligence technology, and more particularly to the field of natural language processing. More specifically, this disclosure provides a question-answering method, apparatus, electronic device, storage medium, and computer program product. Background Technology

[0002] Within a company, users sometimes need to query personnel or project information, such as which employees are responsible for a particular project, or which projects a specific employee is responsible for. However, currently, the efficiency of information retrieval is low, and the cost is high. Summary of the Invention

[0003] This disclosure provides a question-answering method, apparatus, electronic device, storage medium, and computer program product.

[0004] According to one aspect of this disclosure, a question-answering method is provided, comprising: in response to receiving original query information, retrieving multiple project text information from a database based on the original query information; determining multiple target text information among the multiple project text information based on the evaluation values ​​of the multiple project text information in the retrieval phase; and determining response information for the original query information based on the multiple target text information and object information having an association relationship with each target text information; wherein the association relationship is obtained by extracting the relationship between object information of the object and project text information of the project based on project-related documents.

[0005] According to another aspect of this disclosure, a question-answering apparatus is provided, comprising: a recall module, a target text information determination module, and a response information determination module. The recall module is used to, in response to receiving original query information, recall multiple item text information from a database based on the original query information. The target text information determination module is used to determine multiple target text information among the multiple item text information based on the evaluation values ​​of the multiple item text information during the recall phase. The response information determination module is used to determine response information for the original query information based on the multiple target text information and object information having a relationship with each target text information; wherein the relationship is obtained by extracting the relationship between object information of the object and item text information of the project based on project-related documents.

[0006] According to another aspect of this disclosure, an electronic device is provided, comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to perform the methods provided in this disclosure.

[0007] According to another aspect of this disclosure, a non-transitory computer-readable storage medium is provided storing computer instructions, wherein the computer instructions are used to cause a computer to perform the methods provided in this disclosure.

[0008] According to another aspect of this disclosure, a computer program product is provided, including a computer program that, when executed by a processor, implements the methods provided in this disclosure.

[0009] It should be understood that the description in this section is not intended to identify key or essential features of the embodiments of this disclosure, nor is it intended to limit the scope of this disclosure. Other features of this disclosure will become readily apparent from the following description. Attached Figure Description

[0010] The accompanying drawings are provided to better understand this solution and do not constitute a limitation of this disclosure. Wherein:

[0011] Figure 1 This is a schematic diagram illustrating an application scenario of the question-and-answer method and apparatus according to embodiments of this disclosure;

[0012] Figure 2 This is a schematic flowchart of a question-and-answer method according to an embodiment of the present disclosure;

[0013] Figure 3A This is a schematic flowchart of a question-and-answer method according to another embodiment of the present disclosure;

[0014] Figure 3B This is a schematic diagram illustrating the principle of a question-and-answer method according to an embodiment of the present disclosure;

[0015] Figure 4 This is a schematic structural block diagram of a question-and-answer device according to embodiments of the present disclosure; and

[0016] Figure 5 This is a structural block diagram of an electronic device used to implement the question-and-answer method of the embodiments of this disclosure. Detailed Implementation

[0017] The exemplary embodiments of this disclosure are described below with reference to the accompanying drawings, including various details of the embodiments to aid understanding, and should be considered merely exemplary. Therefore, those skilled in the art will recognize that various changes and modifications can be made to the embodiments described herein without departing from the scope and spirit of this disclosure. Similarly, for clarity and brevity, descriptions of well-known functions and structures are omitted in the following description.

[0018] Within an enterprise, users sometimes need to query personnel or project information, such as which employees are responsible for a certain project, or which projects a particular employee is responsible for.

[0019] In some embodiments, basic employee information, resumes, project information, etc., can be mined from massive amounts of data. This information is then linked to a graph, and information can be queried based on the graph. It is understandable that the graph needs to be built based on data, and it is not updated in real time. Therefore, if the graph is not updated promptly, users will receive outdated information. Furthermore, if the graph lacks relevant information, users need to manually search for project-related personnel and other information from a large amount of data, resulting in inefficiency and high time costs.

[0020] This disclosure aims to propose a question-and-answer method for enterprise office scenarios. This method does not rely on graph content for information retrieval, and therefore does not require the construction of a graph. This method can directly integrate effective information based on the user's question (original query information), without requiring the user to manually search for information, thereby improving information retrieval efficiency and reducing the user's time cost.

[0021] The method provided in this embodiment is applicable to enterprise internal knowledge management, and can help users find information such as project leaders and the project experience of relevant personnel within the enterprise. Some technical solutions can also serve as auxiliary tools for writing personnel introductions, helping users quickly obtain personnel information.

[0022] The technical solutions provided in this disclosure will be described in detail below with reference to the accompanying drawings and specific embodiments.

[0023] Figure 1 This is a schematic diagram illustrating an application scenario of the question-and-answer method and apparatus according to embodiments of this disclosure.

[0024] It is important to note that Figure 1 The examples shown are merely examples of system architectures that can be applied to the embodiments of this disclosure, in order to help those skilled in the art understand the technical content of this disclosure, but do not mean that the embodiments of this disclosure cannot be used in other devices, systems, environments or scenarios.

[0025] like Figure 1 As shown, the system architecture 100 according to this embodiment may include terminal devices 101, 102, and 103, a network 104, and a server 105. The network 104 serves as a medium for providing a communication link between the terminal devices 101, 102, and 103 and the server 105. The network 104 may include various connection types, such as wired and / or wireless communication links, etc.

[0026] Users can use terminal devices 101, 102, and 103 to interact with server 105 via network 104 to receive or send messages, etc. Terminal devices 101, 102, and 103 can be various electronic devices with displays and web browsing capabilities, including but not limited to smartphones, tablets, laptops, and desktop computers.

[0027] Server 105 can be a server that provides various services, such as a backend management server that supports websites browsed by users using terminal devices 101, 102, and 103 (for example only). The backend management server can analyze and process data such as received user requests, and feed back the processing results (such as response information determined based on the original query information entered by the user) to the terminal devices.

[0028] It should be noted that the question-and-answer method provided in this embodiment can generally be executed by server 105. Correspondingly, the question-and-answer device provided in this embodiment can generally be located in server 105. The question-and-answer method provided in this embodiment can also be executed by a server or server cluster that is different from server 105 and capable of communicating with terminal devices 101, 102, 103 and / or server 105. Correspondingly, the question-and-answer device provided in this embodiment can also be located in a server or server cluster that is different from server 105 and capable of communicating with terminal devices 101, 102, 103 and / or server 105.

[0029] It should be understood that Figure 1 The number of terminal devices, networks, and servers shown is merely illustrative. Depending on implementation needs, any number of terminal devices, networks, and servers can be included.

[0030] Figure 2 This is a schematic flowchart of a question-and-answer method according to an embodiment of the present disclosure.

[0031] like Figure 2 As shown, the question-and-answer method 200 may include operations S210 to S230.

[0032] In operation S210, in response to receiving the original query information, multiple item text information is retrieved from the database based on the original query information.

[0033] For example, users can enter raw query information through the front-end page. The raw query information can be text information, such as "Who is the person in charge of the XX project?" or "What project has colleague XX been in charge of in the past month?"

[0034] For example, a database can store multiple item text information. It can determine the similarity between the original query information and the item text information, or determine the similarity between the vector of the original query information and the vector of the item text information. Then, based on the similarity ranking, multiple item text information can be retrieved from the data.

[0035] In operation S220, based on the evaluation values ​​of multiple project text information during the recall phase, multiple target text information are identified from the multiple project text information.

[0036] For example, during the recall process, the project text information corresponds to an evaluation value, which can be the aforementioned similarity or other confidence level. For instance, the evaluation values ​​can be sorted, and a predetermined number of text information items at the top of the sorted list can be used as the target text information. Alternatively, a predetermined sorting algorithm can be used to process the evaluation values, obtain the sorting information, and determine the target text information based on the sorting. This embodiment does not limit the sorting algorithm.

[0037] In operation S230, response information for the original query information is determined based on multiple target text information and object information that is associated with each target text information.

[0038] For example, project-related documents are internal enterprise resources. These documents can be records of information related to the project, such as meeting minutes, knowledge base documents, weekly reports, work cards, and employee resumes. The relationship between object information and project text information can be extracted from these project-related documents. The association between object information and project text information indicates that the object information indicates that the object participated in the project indicated by the project text information.

[0039] For example, the response information can be text information, such as the question and answer information such as "The person in charge of the XX project is colleague XX" or "Colleague XX participated in the work of XX during this period".

[0040] The technical solution provided in this disclosure recalls original query information input by the user, then determines target text information from the recalled item text information, and finally determines response information based on the target text information and associated object information. It can be seen that the above technical solution does not rely on graph content for information retrieval, and therefore does not require the construction of a graph. This technical solution method can directly integrate effective information based on the user's original query information, eliminating the need for users to manually search for information, thereby improving information retrieval efficiency and reducing user time costs.

[0041] Figure 3A This is a schematic flowchart of a question-and-answer method according to another embodiment of the present disclosure.

[0042] like Figure 3A As shown, in this embodiment, the question-and-answer method 300 may include operations S340 to S350, operations S311 to S314, operations S321 to S322, and operations S331 to S332.

[0043] In operation S340, the relationship between object information of objects and project text information of projects is extracted based on project-related documents.

[0044] For example, object information can include author information for project-related documents. The relationship between object information and project text information can be determined based on the authors of project-related documents. For instance, if a project document contains at least one piece of project text information describing a project, and an object edits, writes, or processes this project-related document, then a relationship can be established between the project text information and the object information of that object.

[0045] For example, the object information of an object may include the project manager's information. The association between object information and project text information can be determined based on the content of project-related documents. For instance, a project document may include at least one piece of project text information describing a project, which may describe which employees are responsible for the project. A deep learning model can be used to process project-related documents to obtain the association between object information and project text information. The deep learning model can be a model for extracting triples; this embodiment does not limit the deep learning model. In other embodiments, the association between object information and project text information can also be determined based on regular expression matching. For example, a pre-defined regular expression rule could be: "Project Name" is responsible for "Person Name". When content related to this regular expression rule appears in project-related documents, it is determined that the "Person Name" in that content is associated with the "Project Name".

[0046] When operating S350, a database is built based on project-related documents.

[0047] The database can include a primary database, which may include Elastic Search or other search engines. The search engine can store data using an inverted index. For example, project text information can be extracted from project-related documents based on tag extraction, allowing for subsequent retrieval of useful project text information from the database. For instance, the text content in project-related documents can be divided into at least one paragraph, with each paragraph representing a piece of project text. Keywords can be extracted from the project text information, and an inverted index can be built representing the mapping relationship between keywords and project text information.

[0048] The database may include a second database, which can store vector information for project text information. For example, after obtaining project text information based on project-related documents, the project text information can be converted into vectors.

[0049] It should be noted that the database may include a first database and a second database, and during the subsequent recall process, retrieval can be performed from both databases separately, thereby ensuring the completeness of the retrieved project text information. In other embodiments, the database may include either the first database or the second database. It should also be noted that incremental data can be added to the database at regular intervals to update the database.

[0050] In operation S311, the target query information is determined based on the original query information.

[0051] For example, the original query information may include text information entered by the user, and the original query information can be identified as the target query information.

[0052] For example, the original query information can be rewritten to obtain the rewritten query information. The rewriting operation may include extracting keywords from the original query information; for example, it may include segmenting the original query information into words and using the segmented keywords as the rewritten query information. The rewriting operation may also include processing such as synonym conversion of the keywords. The rewritten query information can then be used as the target query information. The rewriting operation can extract effective information from the original query information, thereby improving the accuracy and effectiveness of the retrieval.

[0053] For example, both the original query information and the rewritten query information can be identified as target query information, thereby increasing the amount of retrieved item text information by performing recall based on the original query information and the rewritten query information respectively.

[0054] In operation S312, based on the target query information, multiple first item text information are retrieved from the first database.

[0055] For example, the first database uses an inverted index to store keywords and item text information. It can determine the similarity between the target query information and the keywords, and then recall the item text information corresponding to the keywords with a similarity greater than or equal to the threshold. This item text information is called the first item text information.

[0056] In operation S313, based on the target query information, multiple vector information are retrieved from the second database.

[0057] For example, the target query information can be converted into a vector, and then the similarity between the vector of the target query information and each vector in the second database can be determined. Vectors with similarity greater than or equal to a threshold can be recalled. These recalled vectors correspond to item text information, which is called the second item text information.

[0058] In operation S314, multiple item text information is determined based on multiple first item text information and multiple second item text information corresponding to multiple vector information.

[0059] For example, multiple first-item text messages and multiple second-item text messages can be deduplicated, and the deduplicated information can be used as multiple item text messages.

[0060] In operation S321, based on the target query information, multiple first item text information, multiple second item text information, the evaluation values ​​of multiple first item information during the recall phase, and the evaluation values ​​of multiple second item information during the recall phase, the multiple first item text information and the multiple second item text information are sorted to obtain sorting information.

[0061] For example, during the recall process in the first and second databases, the evaluation value of each recalled item's text information can be determined. The items can then be sorted based on their evaluation values ​​from the recall phase.

[0062] For example, a dataset can be constructed, and a ranking model can be trained based on this dataset. Each training sample in the dataset could include target query information, item text information, and recall evaluation values ​​for the item text information, with the sample labels indicating order. Then, the target query information, multiple first item text messages, multiple second item text messages, the recall evaluation values ​​of the first item messages, and the recall evaluation values ​​of the second item messages are input into the trained ranking model, which outputs ranking information. Using a ranking model can reduce ranking time and initially filter relevant information, ensuring that the information length is within the prompt length required by the question-answering model. For example, the ranking model could be XGBoost (Extreme Gradient Boosting).

[0063] For example, a ranking can be performed without using a model. For instance, a first weight can be configured for the first item text information and a second weight for the second item text information. Then, the product of the first weight of the first item text information and the evaluation value in the recall phase can be used as the ranking evaluation value for the first item text information. The product of the second weight of the second item text information and the evaluation value in the recall phase can be used as the ranking evaluation value for the second item text information. Finally, the ranking evaluation values ​​can be sorted to obtain the ranking information.

[0064] In operation S322, multiple target item information is determined from multiple first item information and multiple second item information based on the sorting information.

[0065] For example, based on sorting information, a predetermined number of items that rank highly can be selected as target items.

[0066] In operation S331, target prompt information is constructed based on the original query information, multiple target text information, object information related to each target text information, attribute information for each target text information, and initial prompt information.

[0067] For example, the initial prompt can be a piece of natural language text that represents the task the question-answering model needs to complete. For instance, the initial prompt could be: "Answer based on the provided content to identify the person related to the project, or identify the project that the person is responsible for. If the user's question cannot be answered based on the provided content, output a pre-defined message indicating that the question cannot be answered temporarily. The provided content is as follows: 《》".

[0068] For example, attribute information can include time information, which represents the time when the target text information was generated. The current time, the time requested by the user, and the time when the target text information was generated can be input into the question-answering model so that the model can filter information based on the time information, making the timeliness of the response information output by the question-answering model better.

[0069] For example, attribute information can include source information, which can include database source, indicating whether the target text information originates from a first database or a second database. Source information can also include document source, indicating which project-related document the target text information originates from.

[0070] For example, attribute information may include at least one of the target text information's evaluation value during the recall phase and ranking information.

[0071] When operating S332, the target prompt information is input into the question-and-answer model, and the question-and-answer model outputs the response information.

[0072] For example, a question-answering model can be a Large Language Model (LLM). Leveraging the understanding and summarizing capabilities of the question-answering model, it can provide users with more relevant results. During processing, the model is provided not only with textual information such as the original query and multiple target texts, but also with attribute information such as recall evaluation values, source information, and time information. This allows the large model to obtain sufficient information and summarize based on this information, thereby determining a more accurate response. The response can be a text segment that answers the user's original query.

[0073] The instruction manual requires that operations S340 to S350 can be processed offline, while the remaining operations can be processed online. Operation S340 can be completed before operation S331, and operation S350 can be completed before operation S311.

[0074] Figure 3B This is a schematic diagram illustrating the question-and-answer method according to an embodiment of the present disclosure.

[0075] like Figure 3B As shown, in the offline phase, the relationship between object information 309 and project text information can be extracted based on project-related documents 301, and tags can be extracted from project-related documents 301 to obtain project text information, thereby constructing a first database. The first database can be an index library 302, which stores an inverted index between keywords and project text information. The project text information can also be converted into vectors to construct a second database, which can be a vector library 303.

[0076] During the online phase, after obtaining the original query information 304 input by the user, the original query information 304 can be rewritten to obtain the rewritten query information 305. Next, based on each query information in the original query information 304 and the rewritten query information 305, first item text information is retrieved from the index 302, and some vectors corresponding to second item text information are retrieved from the vector library 303. The first item text information and the second item text information are merged into multiple item text information 306. Next, the multiple item text information 306 are sorted, and a predetermined number of information at the top of the sorted list are selected as target text information 307.

[0077] Next, target prompt information can be constructed based on the original query message 304, target text information 307, attribute information 308, object information 309 associated with the target text information 307, and initial prompt information 310. The target prompt information is then input into the question-answering model 311, and the question-answering model 311 outputs response information 312.

[0078] Figure 4 This is a schematic structural block diagram of a question-and-answer device according to an embodiment of the present disclosure.

[0079] like Figure 4 As shown, the question-and-answer device 400 may include a recall module 410, a target text information determination module 420, and a response information determination module 430.

[0080] The recall module 410 is used to respond to the received original query information and recall multiple item text information from the database based on the original query information.

[0081] The target text information determination module 420 is used to determine multiple target text information from multiple project text information based on the evaluation values ​​of multiple project text information in the recall phase.

[0082] The response information determination module 430 is used to determine the response information for the original query information based on multiple target text information and object information that has a relationship with each target text information; wherein, the relationship is obtained by extracting the relationship between the object information of the object and the project text information of the project based on the project-related documents.

[0083] According to another embodiment of this disclosure, the recall module includes: a first determination submodule, a first recall submodule, a second recall submodule, and a second determination submodule. The first determination submodule is used to determine target query information based on the original query information. The first recall submodule is used to recall multiple first item text information in a first database based on the target query information, the first database storing the mapping relationship between keywords and item text information. The second recall submodule is used to recall multiple vector information in a second database based on the target query information, the second database storing vector information for item text information. The second determination submodule is used to determine multiple item text information based on the multiple first item text information and multiple second item text information corresponding to the multiple vector information.

[0084] According to another embodiment of this disclosure, the target text information determination module includes a sorting submodule and a third determination submodule. The sorting submodule is used to sort the multiple first item text information and multiple second item text information according to target query information, multiple first item text information, multiple second item text information, the evaluation values ​​of the multiple first item text information during the recall phase, and the evaluation values ​​of the multiple second item text information during the recall phase, to obtain sorting information. The third determination submodule is used to determine multiple target item information from the multiple first item information and multiple second item information based on the sorting information.

[0085] According to another embodiment of this disclosure, the first determining submodule includes a rewriting unit and a determining unit. The rewriting unit is used to rewrite the original query information to obtain the rewritten query information. The determining unit is used to determine the original query information and the rewritten query information as target query information, respectively.

[0086] According to another embodiment of this disclosure, the response information determination module includes a construction submodule and an input submodule. The construction submodule is used to construct target prompt information based on the original query information, multiple target text information, object information associated with each target text information, attribute information for each target text information, and initial prompt information. The input submodule is used to input the target prompt information into the question-answering model, and the question-answering model outputs response information.

[0087] According to another embodiment of this disclosure, the attribute information for each target text information includes at least one of the following: the evaluation value, sorting information, time information, and source information for each target text information during the recall phase.

[0088] According to another embodiment of this disclosure, the object information associated with the project text information includes at least one of the following: the person in charge of the project leader, and the author information of the authors of the project-related documents.

[0089] According to embodiments of this disclosure, this disclosure also provides an electronic device, including at least one processor; and a memory communicatively connected to the at least one processor; the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to perform the above-described question-and-answer method.

[0090] According to embodiments of this disclosure, this disclosure also provides a non-transitory computer-readable storage medium storing computer instructions, wherein the computer instructions are used to cause a computer to perform the above-described question-and-answer method.

[0091] According to embodiments of this disclosure, this disclosure also provides a computer program product, including a computer program that implements the above-described question-and-answer method when executed by a processor.

[0092] Figure 5 This is a structural block diagram of an electronic device used to implement the question-and-answer method of embodiments of the present disclosure. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device may also represent various forms of mobile devices, such as personal digital processors, cellular phones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the present disclosure described and / or claimed herein.

[0093] like Figure 5 As shown, device 500 includes a computing unit 501, which can perform various appropriate actions and processes based on a computer program stored in read-only memory (ROM) 502 or a computer program loaded from storage unit 508 into random access memory (RAM) 503. RAM 503 may also store various programs and data required for the operation of device 500. The computing unit 501, ROM 502, and RAM 503 are interconnected via bus 504. Input / output (I / O) interface 505 is also connected to bus 504.

[0094] Multiple components in device 500 are connected to I / O interface 505, including: input unit 506, such as keyboard, mouse, etc.; output unit 507, such as various types of monitors, speakers, etc.; storage unit 508, such as disk, optical disk, etc.; and communication unit 509, such as network card, modem, wireless transceiver, etc. Communication unit 509 allows device 500 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks.

[0095] The computing unit 501 can be a variety of general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of the computing unit 501 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. The computing unit 501 performs the various methods and processes described above, such as question-and-answer methods. For example, in some embodiments, the question-and-answer method may be implemented as a computer software program tangibly contained in a machine-readable medium, such as storage unit 508. In some embodiments, part or all of the computer program may be loaded and / or installed on device 500 via ROM 502 and / or communication unit 509. When the computer program is loaded into RAM 503 and executed by the computing unit 501, one or more steps of the question-and-answer method described above may be performed. Alternatively, in other embodiments, the computing unit 501 may be configured to perform question-and-answer methods by any other suitable means (e.g., by means of firmware).

[0096] Various embodiments of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems-on-a-chip (SoCs), complex programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include implementations in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a dedicated or general-purpose programmable processor, capable of receiving data and instructions from a storage system, at least one input device, and at least one output device, and transmitting data and instructions to the storage system, the at least one input device, and the at least one output device.

[0097] The program code used to implement the methods of this disclosure may be written in any combination of one or more programming languages. This program code may be provided to a processor or controller of a general-purpose computer, special-purpose computer, or other programmable data processing apparatus, such that when executed by the processor or controller, the program code causes the functions / operations specified in the flowcharts and / or block diagrams to be implemented. The program code may be executed entirely on a machine, partially on a machine, as a standalone software package partially on a machine and partially on a remote machine, or entirely on a remote machine or server.

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

[0099] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device for displaying information to the user (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor); and a keyboard and pointing device (e.g., a mouse or trackball) through which the user provides input to the computer. Other types of devices can also be used to provide interaction with the user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including sound input, voice input, or tactile input).

[0100] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as a data server), or computing systems that include middleware components (e.g., an application server), or computing systems that include frontend components (e.g., a user computer with a graphical user interface or web browser through which a user can interact with embodiments of the systems and technologies described herein), or any combination of such backend, middleware, or frontend components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., a communication network). Examples of communication networks include local area networks (LANs), wide area networks (WANs), and the Internet.

[0101] Computer systems can include clients and servers. Clients and servers are generally located far apart and typically interact through communication networks. Client-server relationships are created by computer programs running on the respective computers and having a client-server relationship with each other.

[0102] It should be understood that the various forms of processes shown above can be used to rearrange, add, or delete steps. For example, the steps described in this disclosure can be executed in parallel, sequentially, or in different orders, as long as the desired result of the technical solution disclosed in this disclosure can be achieved, and this is not limited herein.

[0103] The collection, storage, use, processing, transmission, provision, and disclosure of user personal information involved in the technical solution disclosed herein comply with the provisions of relevant laws and regulations and do not violate public order and good morals.

[0104] In the technical solution disclosed herein, the user's authorization or consent is obtained before acquiring or collecting the user's personal information.

[0105] The specific embodiments described above do not constitute a limitation on the scope of protection of this disclosure. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this disclosure should be included within the scope of protection of this disclosure.

Claims

1. A question-and-answer method, comprising: In response to receiving the original query information, multiple item text information are retrieved from the database based on the original query information; The multiple project text information is sorted according to the evaluation value of the multiple project text information in the recall phase, and multiple target text information is determined from the sorted multiple project text information. as well as Based on the plurality of target text information and object information associated with each target text information, response information is determined for the original query information, wherein the response information includes at least one of the following: object information associated with the item indicated by the original query information in the plurality of target text information, and item text information associated with the object indicated by the original query information in the plurality of target text information; The aforementioned relationship is derived from the relationship between object information and project text information extracted from project-related documents. The project-related documents are documents that record information related to the project, and include at least one of the following: meeting documents, knowledge base documents, weekly reports, work cards, and employee resumes. Among them, the object information and the project text information have a relationship: the object information indicates that the object participated in the project indicated by the project text information, and... The object information includes at least one of the following: the project leader's information, and the author information of the authors of the project-related documents.

2. The method according to claim 1, wherein, The step of retrieving multiple project text information from the database based on the original query information includes: Based on the original query information, determine the target query information; Based on the target query information, multiple first item text information are retrieved from the first database, where the first database stores the mapping relationship between keywords and item text information; Based on the target query information, multiple vector information items are retrieved from a second database, which stores vector information specific to the project text information; and The multiple item text information is determined based on the multiple first item text information and the multiple second item text information corresponding to the multiple vector information.

3. The method according to claim 2, wherein, The step of sorting the multiple project text information according to the evaluation values ​​of the multiple project text information in the recall phase, and determining multiple target text information from the sorted multiple project text information includes: Based on the target query information, the plurality of first item text information, the plurality of second item text information, the evaluation values ​​of the plurality of first item text information during the recall phase, and the evaluation values ​​of the plurality of second item text information during the recall phase, the plurality of first item text information and the plurality of second item text information are sorted to obtain sorting information; and Based on the sorting information, the plurality of target text information is determined from the plurality of first item text information and the plurality of second item text information.

4. The method according to claim 2, wherein, The step of determining the target query information based on the original query information includes: The original query information is rewritten to obtain the rewritten query information; and The original query information and the rewritten query information are respectively determined as the target query information.

5. The method according to any one of claims 1 to 4, wherein, The step of determining the response information for the original query information based on the plurality of target text information and object information associated with each target text information includes: Based on the original query information, the multiple target text information, object information associated with each target text information, attribute information for each target text information, and initial prompt information, target prompt information is constructed; and The target prompt information is input into the question-answering model, and the question-answering model outputs the response information.

6. The method according to claim 5, wherein, The attribute information for each target text information includes at least one of the following: the evaluation value, ranking information, time information, and source information for each target text information during the recall phase.

7. A question-and-answer device, comprising: The recall module is used to respond to the receipt of original query information and recall multiple item text information from the database based on the original query information; The target text information determination module is used to sort the multiple project text information according to the evaluation value of the multiple project text information in the recall stage, and determine multiple target text information from the sorted multiple project text information; as well as The response information determination module is used to determine response information for the original query information based on the plurality of target text information and object information that is associated with each target text information. The response information includes at least one of the following: object information that is associated with the item indicated by the original query information in the plurality of target text information, and item text information that is associated with the object indicated by the original query information in the plurality of target text information. The aforementioned relationship is derived from the relationship between object information and project text information extracted from project-related documents. The project-related documents are documents that record information related to the project, and include at least one of the following: meeting documents, knowledge base documents, weekly reports, work cards, and employee resumes. Among them, the object information and the project text information have a relationship: the object information indicates that the object participated in the project indicated by the project text information, and... The object information includes at least one of the following: the project leader's information, and the author information of the authors of the project-related documents.

8. The apparatus according to claim 7, wherein, The recall module includes: The first determining submodule is used to determine the target query information based on the original query information; The first recall submodule is used to recall multiple first item text information in the first database according to the target query information. The first database stores the mapping relationship between keywords and item text information. The second recall submodule is used to recall multiple vector information items in a second database based on the target query information. The second database stores vector information specific to the project text information. The second determining submodule is used to determine the multiple item text information based on the multiple first item text information and the multiple second item text information corresponding to the multiple vector information.

9. The apparatus according to claim 8, wherein, The target text information determination module includes: The sorting submodule is used to sort the multiple first item text information and the multiple second item text information according to the target query information, the multiple first item text information, the multiple second item text information, the evaluation values ​​of the multiple first item text information in the recall phase, and the evaluation values ​​of the multiple second item text information in the recall phase, to obtain sorting information; and The third determining submodule is used to determine the plurality of target text information from the plurality of first item text information and the plurality of second item text information based on the sorting information.

10. The apparatus according to claim 8, wherein, The first determining submodule includes: The rewriting unit is used to rewrite the original query information to obtain the rewritten query information; and The determining unit is used to determine the original query information and the rewritten query information as the target query information, respectively.

11. The apparatus according to any one of claims 7 to 10, wherein, The response information determination module includes: The construction submodule is used to construct target prompt information based on the original query information, the multiple target text information, object information associated with each target text information, attribute information for each target text information, and initial prompt information; and The input submodule is used to input the target prompt information into the question-answering model, and the question-answering model outputs the response information.

12. The apparatus according to claim 11, wherein, The attribute information for each target text information includes at least one of the following: the evaluation value, ranking information, time information, and source information for each target text information during the recall phase.

13. An electronic device, comprising: At least one processor; as well as A memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor to enable the at least one processor to perform the method of any one of claims 1 to 6.

14. A non-transitory computer-readable storage medium storing computer instructions, wherein, The computer instructions are used to cause the computer to perform the method according to any one of claims 1 to 6.

15. A computer program product comprising a computer program that, when executed by a processor, implements the method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • Method for determining answers to questions and question-answering device

    CN110516060A

  • Method and device for sorting multiple recall results

    CN114595406A