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

By converting text information into feature vectors and generating unique strings through vector search technology, and combining this with database indexes, the efficiency and accuracy issues of real-time queries in multiple scenarios in medical question-and-answer systems are solved, enabling efficient question-and-answer data retrieval and automated updates.

CN116775826BActive Publication Date: 2026-05-29PING AN TECH (SHENZHEN) CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
PING AN TECH (SHENZHEN) CO LTD
Filing Date
2023-06-08
Publication Date
2026-05-29

AI Technical Summary

Technical Problem

Existing medical question-and-answer systems struggle to meet the performance requirements for large-scale real-time queries when faced with complex and ever-changing question-and-answer content across multiple scenarios, resulting in a poor user experience. Furthermore, traditional technologies cannot meet the needs for stable automated updates and real-time queries.

Method used

We employ a vector-based intelligent question-answering method. By converting textual information into feature vectors through a pre-trained keyword extraction model and semantic model, and generating unique strings using hash encoding, we combine vector clusters and a database to achieve efficient and accurate question-answering data retrieval.

Benefits of technology

It improves the efficiency and accuracy of the intelligent question-answering system in vector search, reduces the consumption of human and machine resources, supports automated updates of multiple business types and ever-changing content, and enhances the user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116775826B_ABST
    Figure CN116775826B_ABST
Patent Text Reader

Abstract

The application relates to the technical field of digital medical treatment and artificial intelligence, applies intelligent system technology, and relates to an intelligent question and answer method, device, equipment and storage medium. The method comprises the following steps: acquiring text information to be detected, and extracting key text information; the key text information is converted into a text feature vector through a preset semantic model; similarity calculation is performed on the text feature vector; text vectors with high similarity are collected from a preset vector cluster, and corresponding unique strings are taken out; corresponding question and answer data are taken out from a preset database according to the unique strings and are displayed. In the field of digital medical treatment, the accuracy of required data retrieval is important for an intelligent question and answer system. The application can improve the accuracy and efficiency of vector retrieval.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of artificial intelligence technology, and applies intelligent system technology, specifically to an intelligent question-answering method, apparatus, device, and storage medium. Background Technology

[0002] With the rapid development of information and short video traffic, technologies such as big data and artificial intelligence have been more widely applied. Among these, mainstream recommendation search technologies have extremely important application value in fields such as healthcare, finance, and information. For example, in medical research, using big data technology to filter and analyze various data can provide strong data analysis support for research work. In medical searches, user-friendly, efficient, and accurate search methods can significantly reduce workload. Therefore, how to efficiently and accurately process and analyze massive amounts of data and retrieve effective content has become a major challenge in the search field. When dealing with intelligent question answering in multiple scenarios, how to return reasonable and effective question-and-answer content based on the nearest neighbor search of vector search engines is particularly important.

[0003] Currently, in the field of medical question-and-answer systems, there is no mature solution for handling complex and ever-changing question-and-answer content across multiple scenarios. Traditional technologies cannot meet the performance requirements of large-scale real-time queries, and may require significant manpower and machine resources to meet the basic requirements of a question-and-answer system. The most common approach in the market is to develop separate vector search modules to meet the needs of multiple business responses to the same question in different scenarios. This requires a lot of repetitive work to satisfy applications in different scenarios. Furthermore, as the complexity of the question-and-answer content increases, real-time performance becomes difficult to meet, severely impacting user experience. It is also difficult to meet the requirements for stable automated updates and real-time queries when updating question-and-answer content. Traditional keyword and rule-based search technologies struggle to obtain effective responses to similar questions, resulting in users failing to find valid answers after multiple searches, easily leading to a poor user experience and customer churn. Summary of the Invention

[0004] In view of the above, the present invention provides a multi-scenario general intelligent question answering method, device, electronic device and storage medium based on vector search. Its main purpose is to improve the efficiency and accuracy of intelligent question answering systems in vector search in fields such as medical retrieval.

[0005] To achieve the above objectives, the present invention provides an intelligent question-answering method, which includes the following steps:

[0006] Receive the question text from the client, obtain the text information to be detected based on the question text, and input the text information to be detected into a pre-trained keyword extraction model to obtain key text information;

[0007] The key text information is converted into text feature vectors using a pre-defined semantic model;

[0008] Obtain text vectors from the preset vector cluster that meet the preset similarity conditions with the text feature vectors, and extract the unique string corresponding to the obtained text vectors;

[0009] Based on the unique string, the corresponding question and answer data is filtered from the preset database as the question and answer result.

[0010] Optionally, obtaining text vectors from a preset vector cluster that meet a preset similarity condition with the text feature vectors includes:

[0011] The similarity between each text vector in the preset vector cluster and the text feature vector is sorted from high to low. Then, the top M text vectors with the highest similarity are selected as the text vectors in the preset vector cluster with high similarity to the text feature vector, where M is a positive integer.

[0012] Optionally, obtaining text vectors from a preset vector cluster that meet a preset similarity condition with the text feature vectors includes:

[0013] Calculate the similarity between each text vector in the preset vector cluster and the text feature vector, compare the similarity of each text vector with a preset threshold, and take the text vectors with similarity higher than the preset threshold as the text vectors that meet the preset similarity conditions.

[0014] Optionally, before obtaining text vectors from a preset vector cluster that meet a preset similarity condition with the text feature vectors, and extracting the unique string corresponding to the obtained text vectors, the process includes:

[0015] The question-and-answer data to be stored in the preset database is converted into a unique string using hash encoding;

[0016] The text feature vectors of the question-and-answer data to be stored are extracted using a preset semantic model and used as the feature vectors to be stored.

[0017] The unique string and the feature vector to be stored are stored in the data table corresponding to the question and answer data to be stored in the preset vector cluster.

[0018] Optionally, before the step of retrieving the corresponding question-and-answer data from a preset database based on the unique string, the following steps are included:

[0019] The question-and-answer data to be stored in the preset database is converted into a unique string using hash encoding;

[0020] The text feature vector of the question-and-answer data to be stored is extracted using a preset semantic model;

[0021] The unique string and the preset vector cluster data table are concatenated to generate the database key value;

[0022] The key text information and various related information of the question and answer data to be stored are converted into strings and used as the value of the database.

[0023] The key and value are stored together in a preset database.

[0024] Optionally, the preset database and preset vector cluster periodically update the storage for newly added text content, including:

[0025] After the newly added text content is hashed to generate a unique string and concatenated with the data table to generate a new key value, a batch search is performed in the database to determine whether the new key value already exists.

[0026] If it exists, only the value corresponding to the newly added key in the preset database is updated, and the key and the value are stored together in the preset database.

[0027] Optionally, the preset database and preset vector cluster periodically delete expired text content, including:

[0028] For expired text content, the storage data corresponding to the expired text content in the preset vector cluster and the preset database are obtained through unique strings and data tables, and then deleted respectively.

[0029] Furthermore, to achieve the above objectives, the present invention also provides an intelligent question-and-answer device, characterized in that the device comprises:

[0030] The key text extraction module is used to receive the question text sent by the client, obtain the text information to be detected based on the question text, and input the text information to be detected into the pre-trained keyword extraction model to obtain the key text information.

[0031] The text feature extraction module is used to convert the key text information into text feature vectors through a preset semantic model;

[0032] The similarity calculation module is used to obtain text vectors from the preset vector cluster that meet the preset similarity conditions with the text feature vectors, and extract the unique string corresponding to the obtained text vectors;

[0033] The question and answer data extraction module is used to filter out the corresponding question and answer data from a preset database based on the unique string as the question and answer result.

[0034] Furthermore, to achieve the above objectives, the present invention also provides an electronic device, the electronic device comprising:

[0035] Memory, storing at least one computer program; and

[0036] The processor executes the program stored in the memory to implement the intelligent question-answering method described above.

[0037] In addition, to achieve the above objectives, the present invention also provides a computer-readable storage medium storing at least one computer program, which is executed by a processor in an electronic device to implement the intelligent question-answering method described above.

[0038] This invention combines retrieved text information with a unique string representing the index's uniqueness. A unique string is generated through hash encoding for index construction. Simultaneously, the table name of a preset vector cluster is applied to the creation of a preset database, ensuring a close connection between the preset vector cluster and the preset database. This allows for locating related content in the preset database based on vector search results, enabling question-and-answer functionality for relevant searches in any scenario. In fields such as high-performance medical retrieval, the intelligent question-and-answer system demonstrates high efficiency and accuracy in vector search, significantly reducing human development costs and machine resource consumption. Furthermore, the proposed data content stringification processing during preset database data storage can handle arbitrary additions and deletions of key text information in related searches, providing a universal solution for responses to varied content such as related questions and answers, multiple business types, and dates. This allows users to obtain arbitrary content related to text information and multiple types of question-and-answer in cases of semantic ambiguity, enhancing the service's intelligence and significantly reducing operating costs. This enables automated updates of content in multiple recommendation slots and efficient recommendations based on user clicks and searches. Attached Figure Description

[0039] Figure 1 This is a flowchart illustrating an intelligent question-answering method provided in an embodiment of the present invention;

[0040] Figure 2 This is a flowchart illustrating an intelligent question-answering device provided in an embodiment of the present invention;

[0041] Figure 3 An electronic device for implementing an intelligent question-answering method according to an embodiment of the present invention

[0042] Internal structure diagram;

[0043] The realization of the purpose, functional features and advantages of this application will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation

[0044] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the invention. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without inventive effort are within the scope of protection of this invention.

[0045] It should be noted that the descriptions involving "first," "second," etc., in this invention are for descriptive purposes only and should not be construed as indicating or implying their relative importance or implicitly specifying the number of technical features indicated. Therefore, a feature defined with "first" or "second" may explicitly or implicitly include at least one of that feature. Furthermore, the technical solutions of the various embodiments can be combined with each other, but this must be based on the ability of those skilled in the art to implement them. If the combination of technical solutions is contradictory or impossible to implement, it should be considered that such a combination of technical solutions does not exist and is not within the scope of protection claimed by this invention.

[0046] Reference Figure 1 The flowchart shown is a schematic diagram of an intelligent question-answering method provided in an embodiment of the present invention. In this embodiment, the intelligent question-answering method includes the following steps S1-S5:

[0047] S1. Receive the question text sent by the client, obtain the text information to be detected based on the question text, and input the text information to be detected into a pre-trained keyword extraction model to obtain key text information;

[0048] In this embodiment of the invention, the intelligent question-answering system obtains the question input by the user, extracts the text information in the question as the text information to be detected, and inputs the text information to be detected into a pre-trained keyword extraction model to obtain key text information. For example, in medical research retrieval, the user sends the question "Are children prone to G6PD deficiency?" to the intelligent question-answering system through the client. The key text information extracted by the keyword extraction model is "G6PD deficiency" and "children".

[0049] In one embodiment, the question text sent by the client can also be a voice message sent by the client. For example, if a user sends a voice message to the server with the content "I have a cold now, can I have milk for breakfast?", then this application uses a voice recognition model to obtain the question text "Can I drink milk when I have a cold?" from the voice message.

[0050] In one embodiment, this application can also receive an image sent by a client, use a preset image recognition model to obtain the image feature vector of the image, and then perform steps S3-S4. For example, if a user sends an orthopedic X-ray to the server through a client, this application can use an image recognition model to obtain the image feature vector of the X-ray from the image.

[0051] S2. Convert the key text information into text feature vectors using a preset semantic model;

[0052] In this embodiment of the invention, the preset semantic model is a pre-trained BERT semantic model, which is used to transform the key text information to generate the text feature vector. The key text information is obtained from the text information to be detected in step S1 through the keyword extraction model, such as "favism" and "child" in the above example.

[0053] S3. Obtain text vectors from the preset vector cluster that meet the preset similarity conditions with the text feature vectors, and extract the unique string corresponding to the obtained text vectors;

[0054] In this embodiment of the invention, the preset vector cluster is a vector search engine that has IDs that can be customized for search vectors and can distinguish patterns or table names of different business locations, such as a Milvus cluster.

[0055] Before the steps of querying highly similar text vectors in the preset vector cluster and retrieving the corresponding unique strings, the key text information of the question-and-answer data to be stored is converted into unique strings through hash encoding; the key text information is converted into feature vectors through semantic modeling; and the unique strings and feature vectors are stored in the data table corresponding to the question-and-answer data to be stored in the preset vector cluster.

[0056] The query for highly similar text vectors involves sorting all text vectors in the vector cluster by similarity from highest to lowest, and then taking the top M text vectors with the highest similarity. For example, in the sim_query_table table of the Milvus cluster, search for the 5 short text vectors that are closest to it and extract the corresponding 5 unique strings.

[0057] The query for highly similar text vectors can also be achieved by calculating the similarity between each text vector in a preset vector cluster and the text feature vector, comparing the similarity of each text vector with a preset threshold, and taking the text vectors with similarity higher than the preset threshold as the text vectors with high similarity to the text feature vector in the preset vector cluster. For example, if the preset threshold is [0.5], then the text vectors with similarity higher than [0.5] in the sim_query_table table in the milkvus cluster are taken as the text vectors with high similarity to the text feature vector, and the corresponding unique strings are removed.

[0058] S4. Based on the unique string, filter out the corresponding question and answer data from the preset database as the question and answer results;

[0059] In this embodiment of the invention, based on the extracted unique strings, corresponding question and answer data is extracted from a preset database. For example, based on the five unique strings, question and answer data corresponding to the questions "Can children get G6PD deficiency?", "Are children prone to G6PD deficiency?", "How can children avoid getting G6PD deficiency?", "Why are children prone to G6PD deficiency?", and "What should be paid attention to after a child gets G6PD deficiency?" are extracted from the preset database.

[0060] In this embodiment of the invention, the preset database is a Redis cluster. The question and answer data to be stored is hashed to generate a unique string, the text feature vector of the question and answer data is extracted, the unique string and the data table of the Milvus cluster are concatenated to generate the Redis key value, and the key text information and various related information are converted to generate strings as the Redis value value and jointly stored in the Redis cluster.

[0061] In this embodiment of the invention, for newly added or expired text content, storage updates are performed. For newly added content, a unique string is generated through hash encoding and concatenated into a data table. Then, a batch search is performed in the Redis cluster to determine whether it already exists. If it exists, only the value corresponding to the newly added key in the preset database is updated, and the newly added key and its corresponding value are jointly stored in the Redis cluster. For data that needs to be deleted, deletion is performed in both the Milvus cluster and the Redis cluster using the unique string and the data table.

[0062] This invention acquires the text information to be detected, extracts key text, converts the key text into text feature vectors using a semantic model, calculates the text feature vectors using a similarity algorithm, queries high-similarity text vectors from a Milvus cluster and extracts the corresponding unique strings, and then retrieves the corresponding question-and-answer data from Redis based on the unique strings and displays them. By combining the retrieved text information with the unique hash_id (i.e., the unique string) of the index during the storage stage, and generating the hash_id through hash encoding for index construction, while also combining it with the table name for Redis key creation, the Milvus and Redis data can be closely linked. This allows for locating related content in the Redis database based on vector search results, thereby achieving automated querying and data updates for related search content in any scenario. It enables multi-business, multi-scenario shared vector search services, improving the efficiency and accuracy of vector retrieval in intelligent question-and-answer systems.

[0063] like Figure 2 The diagram shown is a functional block diagram of the intelligent question-and-answer device of the present invention.

[0064] The intelligent question-answering system of this invention is housed in an intelligent question-answering device 100, which can be installed in an electronic device. Depending on the functions implemented, the intelligent question-answering device may include a keyword extraction module 101, a text feature extraction module 102, a similarity calculation module 103, a question-answer data extraction module 104, and a display module 105. The modules described in this invention can also be referred to as units, which are a series of computer program segments that can be executed by the processor of an electronic device and perform a fixed function, and are stored in the memory of the electronic device.

[0065] In this embodiment, the functions of each module / unit are as follows:

[0066] The keyword extraction module 101 is used to receive the question text sent by the client, obtain the text information to be detected based on the question text, and input the text information to be detected into the pre-trained keyword extraction model to obtain the key text information.

[0067] The text feature extraction module 102 is used to convert the key text information into text feature vectors through a preset semantic model;

[0068] The similarity calculation module 103 is used to obtain text vectors from the preset vector cluster that meet the preset similarity conditions with the text feature vectors, and extract the unique string corresponding to the obtained text vectors;

[0069] The question and answer data extraction module 104 is used to filter out the corresponding question and answer data from a preset database based on the unique string as the question and answer result.

[0070] In detail, each module in the intelligent question-answering device 100 described in this embodiment of the invention adopts the same characteristics as described above during use. Figure 1 The same technical means are used in the intelligent question-answering method described in the article, and it can produce the same technical effect, so it will not be elaborated here.

[0071] like Figure 3 The diagram shown is a structural schematic of the electronic device that implements the intelligent question-answering method of the present invention.

[0072] The electronic device may include a processor 10, a memory 11, a communication bus 12 and a communication interface 13, and may also include a computer program, such as an intelligent question-and-answer program, stored in the memory 11 and capable of running on the processor 10.

[0073] The memory 11 includes at least one type of readable storage medium, such as flash memory, portable hard drive, multimedia card, card-type memory (e.g., SD or DX memory), magnetic memory, magnetic disk, optical disk, etc. In some embodiments, the memory 11 can be an internal storage unit of an electronic device, such as a portable hard drive. In other embodiments, the memory 11 can be an external storage device of the electronic device, such as a plug-in portable hard drive, SmartMediaCard (SMC), SecureDigital (SD) card, or FlashCard. Furthermore, the memory 11 can include both internal and external storage units of the electronic device. The memory 11 can be used not only to store application software and various types of data installed on the electronic device, such as the code of a smart question-and-answer program, but also to temporarily store data that has been output or will be output.

[0074] In some embodiments, the processor 10 may be composed of integrated circuits, such as a single packaged integrated circuit or multiple integrated circuits with the same or different functions, including combinations of one or more central processing units (CPUs), microprocessors, digital processing chips, graphics processors, and various control chips. The processor 10 is the control unit of the electronic device, connecting various components of the entire electronic device through various interfaces and lines. It executes programs or modules (such as intelligent question-and-answer programs) stored in the memory 11, and calls data stored in the memory 11 to perform various functions of the electronic device and process data.

[0075] The communication bus 12 can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. This bus can be divided into an address bus, a data bus, a control bus, etc. The communication bus 12 is configured to enable communication between the memory 11 and at least one processor 10, etc. For ease of illustration, only one thick line is used in the figure, but this does not indicate that there is only one bus or one type of bus.

[0076] Figure 3 Only electronic devices with components are shown; it will be understood by those skilled in the art that... Figure 3 The structure shown does not constitute a limitation on the electronic device and may include fewer or more components than shown, or combine certain components, or have different component arrangements.

[0077] For example, although not shown, the electronic device may also include a power supply (such as a battery) to power the various components. Preferably, the power supply can be logically connected to the at least one processor 10 through a power management device, thereby enabling functions such as charging management, discharging management, and power consumption management. The power supply may also include one or more DC or AC power supplies, recharging devices, power fault classification circuits, power converters or inverters, power status indicators, and other arbitrary components. The electronic device may also include various sensors, Bluetooth modules, Wi-Fi modules, etc., which will not be described in detail here.

[0078] Optionally, the communication interface 13 may include a wired interface and / or a wireless interface (such as a Wi-Fi interface, a Bluetooth interface, etc.), which is typically used to establish communication connections between the electronic device and other electronic devices.

[0079] Optionally, the communication interface 13 may further include a user interface, which may be a display, an input unit (such as a keyboard), or, optionally, a standard wired or wireless interface. Optionally, in some embodiments, the display may be an LED display, a liquid crystal display, a touch-sensitive liquid crystal display, or an OLED (Organic Light-Emitting Diode) touchscreen, etc. The display may also be appropriately referred to as a screen or display unit, used to display information processed in the electronic device and to display a visual user interface.

[0080] It should be understood that the embodiments described are for illustrative purposes only and are not limited to this structure in the scope of the patent application.

[0081] The intelligent question-and-answer program stored in the memory 11 of the electronic device is a combination of multiple computer programs. When run in the processor 10, it can achieve the following:

[0082] Receive the question text sent by the client, obtain the text information to be detected based on the question text, and input the text information to be detected into a pre-trained keyword extraction model to obtain key text information;

[0083] The key text information is converted into text feature vectors using a pre-defined semantic model;

[0084] Obtain text vectors from the preset vector cluster that meet the preset similarity conditions with the text feature vectors, and extract the unique string corresponding to the obtained text vectors;

[0085] Based on the unique string, the corresponding question and answer data is filtered from the preset database as the question and answer result.

[0086] Specifically, the processor 10's implementation method of the above-mentioned computer program can be found in [reference needed]. Figure 1 The descriptions of the relevant steps in the corresponding embodiments are not repeated here.

[0087] Furthermore, if the modules / units integrated into the electronic device are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. The computer-readable medium can be non-volatile or volatile. The computer-readable medium may include: any entity or device capable of carrying the computer program code, a recording medium, a USB flash drive, a portable hard drive, a magnetic disk, an optical disk, a computer memory, or a read-only memory (ROM).

[0088] Embodiments of the present invention may also provide a computer-readable storage medium storing a computer program, which, when executed by a processor of an electronic device, can perform the following:

[0089] Receive the question text sent by the client, obtain the text information to be detected based on the question text, and input the text information to be detected into a pre-trained keyword extraction model to obtain key text information;

[0090] The key text information is converted into text feature vectors using a pre-defined semantic model;

[0091] Obtain text vectors from the preset vector cluster that meet the preset similarity conditions with the text feature vectors, and extract the unique string corresponding to the obtained text vectors;

[0092] Based on the unique string, the corresponding question and answer data is filtered from the preset database as the question and answer result.

[0093] Furthermore, the computer's usable storage medium may mainly include a program storage area and a data storage area, wherein the program storage area may store the operating system, applications required for at least one function, etc.; and the data storage area may store data created based on the use of blockchain nodes, etc.

[0094] In the several embodiments provided by this invention, it should be understood that the disclosed devices, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of modules is only a logical functional division, and other division methods may be used in actual implementation.

[0095] The modules described as separate components may or may not be physically separate. The components shown as modules may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs.

[0096] The embodiments of this application can acquire and process relevant data based on artificial intelligence technology. Artificial intelligence (AI) is the theory, method, technology, and application system that uses digital computers or machines controlled by digital computers to simulate, extend, and expand human intelligence, perceive the environment, acquire knowledge, and use that knowledge to obtain optimal results.

[0097] Furthermore, the functional modules in the various embodiments of the present invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or in the form of hardware plus software functional modules.

[0098] It will be apparent to those skilled in the art that the present invention is not limited to the details of the exemplary embodiments described above, and that the present invention can be implemented in other specific forms without departing from the spirit or essential characteristics of the present invention.

[0099] Therefore, the embodiments should be considered exemplary and non-limiting in all respects, and the scope of the invention is defined by the appended claims rather than the foregoing description. Thus, all variations falling within the meaning and scope of equivalents of the claims are intended to be embraced within the invention. No appended diagram markings in the claims should be construed as limiting the scope of the claims.

[0100] The blockchain referred to in this invention is a novel application model of computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanisms, and encryption algorithms. Essentially, a blockchain is a decentralized database, a chain of data blocks linked together using cryptographic methods. Each data block contains information about a batch of network transactions, used to verify the validity of the information (anti-counterfeiting) and generate the next block. A blockchain can include an underlying blockchain platform, a platform product service layer, and an application service layer.

[0101] Furthermore, it is clear that the word "comprising" does not exclude other units or steps, and the singular does not exclude the plural. Multiple units or devices recited in a system claim may also be implemented by a single unit or device through software or hardware. The term "second class" is used to indicate names and does not indicate any specific order.

[0102] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention.

Claims

1. An intelligent question-answering method, applied to an intelligent question-answering system, the method comprising the following steps: The system receives medical question text from the client, obtains text information to be detected based on the medical question text, and inputs the text information to be detected into a pre-trained keyword extraction model to obtain key text information. The key text information is converted into text feature vectors using a pre-defined semantic model; The question-and-answer data to be stored in the preset database is converted into a unique string through hash encoding. The unique string is concatenated with the data table of the preset vector cluster to generate the key value of the preset database. The key text information and various related information of the question-and-answer data to be stored are converted into a string as the value value of the preset database. The key value and the value value are jointly stored in the preset database. The unique string and the text feature vector corresponding to the question and answer data to be stored are stored in the data table corresponding to the question and answer data to be stored in the preset vector cluster; Obtaining text vectors from the preset vector cluster that have a similarity to the text feature vector that meets a preset similarity condition includes: sorting the similarity between each text vector in the preset vector cluster and the text feature vector in descending order, and taking the top M text vectors with the highest similarity as text vectors in the preset vector cluster that have a high similarity to the text feature vector, where M is a positive integer; or, calculating the similarity between each text vector in the preset vector cluster and the text feature vector, comparing the similarity of each text vector with a preset threshold, and taking the text vectors with similarity higher than the preset threshold as the text vectors that meet the preset similarity condition. Extract the unique string corresponding to the acquired text vector, and filter the corresponding question and answer data from the preset database based on the unique string corresponding to the text vector as the question and answer result; The preset database and the preset vector cluster periodically update the storage of newly added text content, including: after the newly added text content generates a corresponding unique string through hash encoding and concatenates it with a data table to generate a new key value, performing a batch search in the preset database to determine whether the new key value already exists. If it exists, only the value corresponding to the new key value in the preset database is updated, and the new key value and the corresponding value are jointly stored in the preset database.

2. The intelligent question-answering method as described in claim 1, characterized in that, Before storing the unique string and the text feature vector corresponding to the question-and-answer data to be stored into the data table corresponding to the question-and-answer data in the preset vector cluster, the method includes: The text feature vectors of the question-and-answer data to be stored are extracted using a preset semantic model.

3. The intelligent question-answering method as described in claim 1, characterized in that, The preset database and preset vector cluster periodically delete expired text content, including: For expired text content, the storage data corresponding to the expired text content in the preset vector cluster and the preset database are obtained through unique strings and data tables, and then deleted respectively.

4. An intelligent question-and-answer device, characterized in that, The device includes: The key text extraction module is used to receive medical question text sent by the client, obtain the text information to be detected based on the medical question text, and input the text information to be detected into a pre-trained keyword extraction model to obtain key text information. The text feature extraction module is used to convert the key text information into text feature vectors through a preset semantic model; The text feature extraction module is further configured to convert the question-and-answer data to be stored in the preset database into a unique string through hash encoding, concatenate the unique string with the data table of the preset vector cluster to generate the key value of the preset database, convert the key text information and various related information of the question-and-answer data to be stored into a string as the value value of the preset database, and jointly store the key value and the value value in the preset database. The text feature extraction module is also used to store the unique string and the text feature vector corresponding to the question and answer data to be stored into the data table corresponding to the question and answer data to be stored in the preset vector cluster; The similarity calculation module is used to obtain text vectors from the preset vector cluster that meet the preset similarity conditions with the text feature vectors, including: sorting the similarity between each text vector in the preset vector cluster and the text feature vector in descending order, and taking the top M text vectors with the highest similarity as text vectors with high similarity to the text feature vectors in the preset vector cluster, where M is a positive integer; or, calculating the similarity between each text vector in the preset vector cluster and the text feature vectors, comparing the similarity of each text vector with a preset threshold, and taking the text vectors with similarity higher than the preset threshold as the text vectors that meet the preset similarity conditions. The question and answer data extraction module is used to extract the unique string corresponding to the acquired text vector, and to filter the corresponding question and answer data from the preset database based on the unique string corresponding to the text vector as the question and answer result; The question-and-answer data extraction module is also used to periodically update the storage of newly added text content in the preset database and the preset vector cluster, including: after the newly added text content generates a corresponding unique string through hash encoding and concatenates it with a data table to generate a new key value, performing a batch search in the preset database to determine whether the new key value already exists; if it exists, only updating the value corresponding to the new key value in the preset database, and jointly storing the new key value and the corresponding value in the preset database.

5. An electronic device, characterized in that, The electronic device includes: At least one processor; and, A memory communicatively connected to the at least one processor; wherein, The memory stores a computer program that can be executed by the at least one processor, enabling the at least one processor to perform the intelligent question-answering method as described in any one of claims 1 to 3.

6. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by the processor, it implements the intelligent question-answering method as described in any one of claims 1 to 3.