WO2020056979A1 - 知识库搜索方法、装置及计算机可读存储介质 - Google Patents

知识库搜索方法、装置及计算机可读存储介质 Download PDF

Info

Publication number
WO2020056979A1
WO2020056979A1 PCT/CN2018/123597 CN2018123597W WO2020056979A1 WO 2020056979 A1 WO2020056979 A1 WO 2020056979A1 CN 2018123597 W CN2018123597 W CN 2018123597W WO 2020056979 A1 WO2020056979 A1 WO 2020056979A1
Authority
WO
WIPO (PCT)
Prior art keywords
knowledge
knowledge point
weight
operation behavior
preset
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Ceased
Application number
PCT/CN2018/123597
Other languages
English (en)
French (fr)
Inventor
周俊琨
石卢靖
许扬
温利聪
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Ping An Technology Shenzhen Co Ltd
Original Assignee
Ping An Technology Shenzhen Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Ping An Technology Shenzhen Co Ltd filed Critical Ping An Technology Shenzhen Co Ltd
Publication of WO2020056979A1 publication Critical patent/WO2020056979A1/zh
Anticipated expiration legal-status Critical
Ceased legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/30Information retrieval; Database structures therefor; File system structures therefor of unstructured textual data
    • G06F16/33Querying
    • G06F16/332Query formulation
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/30Information retrieval; Database structures therefor; File system structures therefor of unstructured textual data
    • G06F16/36Creation of semantic tools, e.g. ontology or thesauri
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/955Retrieval from the web using information identifiers, e.g. uniform resource locators [URL]
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Definitions

  • the present application relates to the field of big data technology, and in particular, to a method, an apparatus, and a computer-readable storage medium for searching a knowledge base based on the synergy of knowledge content and user behavior.
  • a knowledge base is a database of a consultative nature, and such a knowledge base is shared. From the perspective of future development, a huge knowledge base will emerge. As the name implies, there is a huge amount of information in a huge knowledge base, so it is not easy to find a solution to a specific problem quickly and accurately in the knowledge base.
  • the present application provides a method, a device, and a computer-readable storage medium for searching a knowledge base, the main purpose of which is to present users with accurate search results when they search in the knowledge base.
  • a method for searching a knowledge base includes:
  • the present application further provides a knowledge base search device, which includes a memory and a processor, where the memory stores a knowledge base search program that can be run on the processor, and the knowledge base When the search program is executed by the processor, the following steps are implemented:
  • the present application also provides a computer-readable storage medium, where the computer-readable storage medium stores a knowledge base search program, and the knowledge base search program can be executed by one or more processors, To implement the steps of the knowledge base search method as described above.
  • the knowledge base search method, device, and computer-readable storage medium provided in the present application combine a content weight of all knowledge in the knowledge base and all users in the knowledge base when a user searches in a knowledge base using keywords.
  • the operation behavior during the middle search sorts the knowledge points obtained by using the keyword search, so that users can be presented with accurate search results.
  • FIG. 1 is a schematic flowchart of a knowledge base search method according to an embodiment of the present application
  • FIG. 2 is a schematic diagram of an internal structure of a knowledge base searching apparatus according to an embodiment of the present application
  • FIG. 3 is a schematic diagram of a module of a knowledge base search program in a knowledge base search apparatus provided by an embodiment of the present application.
  • FIG. 1 is a schematic flowchart of a knowledge base search method according to an embodiment of the present application. The method may be performed by a device, which may be implemented by software and / or hardware.
  • the knowledge base search method includes:
  • the user may be a customer service staff of a financial enterprise, such as Ping An of China.
  • the customer service staff receives a user inquiry through a phone, web page, APP, or WeChat channel, they can enter a keyword into the financial company's knowledge base according to the user inquiry, such as "Ping An Zun Hong Life has What are the characteristics. "
  • the preferred embodiment of the present application performs a word segmentation operation on the currently received keyword.
  • the preferred embodiment of the present application uses the principle of long word priority to segment the received keywords according to a pre-stored thesaurus.
  • the long word priority principle refers to: for a phrase T1 that needs to be segmented, start with the first word A, find a longest word X1 starting from A from the pre-stored lexicon, and then start from T1 After removing X1 from T2, the same slicing principle is applied to T2.
  • the slicing result is "X1 / X2 / ,,,,,,”.
  • the pre-stored thesaurus may include a conventional thesaurus and a specific thesaurus, such as a financial thesaurus and a product thesaurus.
  • a conventional thesaurus you can get participles such as “peace”, “life”, “what”, and “characteristics”, but according to the financial thesaurus, you can get the participle "zunhong life”. Therefore, in the preferred embodiment of the present application, after the keyword “What are the characteristics of Zunhong's life in peace” is segmented, the word segmentation that can be obtained is “peaceful", “of”, “zunhong life", “have”, “What", “characteristics”.
  • the obtained word segmentation may be further filtered.
  • the filtering process may be performed in one or two of the following ways: Method 1: Filter according to part of speech, retain nouns, verbs, and Adjective; Method two: Filter based on frequency, and retain participles whose frequency is greater than the frequency threshold, where frequency refers to the frequency or number of times the participle appears in the knowledge base.
  • user A1 searches with a first keyword to obtain a number of knowledge points of N1; user A2 searches with a second keyword to obtain a number of knowledge points with N2; user A3 searches with a third keyword, If the number of knowledge points is N3, etc., the historical search records of all users including the keywords for each search and the corresponding knowledge points are obtained.
  • the preferred embodiment of the present application performs the word segmentation operation on the first keyword, the second keyword, and the third keyword according to the method described above.
  • the segmentation obtained according to the first keyword is compared with the segmentation obtained according to the currently received keyword to obtain the similarity between the two. Compare the word segmentation obtained from the currently received keywords to obtain the similarity between the two, and compare the word segmentation obtained from the third keyword with the above-mentioned word segmentation obtained from the currently received keywords to obtain the similarity between the two. When the similarity is greater than a preset value, such as 50%, it is considered that the keywords currently received in the historical search record match.
  • a preset value such as 50%
  • the calculation of the similarity may be comparing the percentages of the same participles to all the participles.
  • the obtained participles are “peace”, “respect for life”, “what”, and “features”, and according to the first keyword in the historical search record, The participle is “peaceful”, “respect for life”, and “features”, the similarity between the two is 75%.
  • weights may be given to each participle according to some specific thesaurus, such as a financial thesaurus and a product thesaurus. For example, “Zunhong Life” comes from the product thesaurus, so you can assign a weight of 1.5 to this participle.
  • the preset operation behavior is a click behavior on a knowledge point in the historical search record.
  • the user A1 searches with the first keyword to obtain the number of knowledge points of N1, and searches with the second keyword to obtain the number of knowledge points of N2 as matching Historical search history, then click behavior of this historical search record is obtained.
  • the search is performed with the first keyword, and the obtained knowledge points of N1 items include t1, t2, t3, t4, t5, t6, t7, t8, t9, and t10, and the user views the knowledge points t1 in turn through the click behavior.
  • the acquired click behavior includes the knowledge points t1, t3, t4, and t8 in order; searching with the second keyword, the obtained N2 knowledge points include t1, t11, t2, t5, t12 , T13, t8, t14, and t15, in which the user sequentially views the knowledge points t1, t11, t5, and t8 through the click behavior, and the obtained click behavior includes the knowledge points t1, t11, t5, and t8 in this order.
  • the obtained N1 knowledge points include t1, t2, t3, t4, t5, t6, t7, t8, t9, and t10, where the user views the knowledge points in turn by clicking t1, t3, t4, and t8, then the last clicked knowledge point is t8.
  • one embodiment of the case obtained three matching historical search records is the knowledge point that the user last clicked, and the second matching historical search record.
  • t15 is the last knowledge point clicked by the user
  • t8 is the last knowledge point clicked by the user
  • the percentage of knowledge point t8 is 67%
  • the knowledge point that the user last clicked may represent that the knowledge point solved the user's problem.
  • the obtained knowledge points of N1 items include t1, t2, t3, t4, t5, t6, t7, t8, t9, and t10, where the user views the knowledge points in order by clicking behavior t1, t3, t4, and t8, the other clicked knowledge points except the last knowledge point are in order t1, t3, and t4.
  • one embodiment of the present application obtains three matching historical search records.
  • the clicked knowledge points are t1 and t3. , T4; in the second matching history search record, the other knowledge points that were clicked excluding the last knowledge point are t1, t5, t6; and in the third matching history search record, the last knowledge is removed
  • the other clicked knowledge points are t3, t7, and t8; then the second percentage of knowledge point t1 is 67%, the second percentage of knowledge point t3 is 67%, and knowledge points t4, t5, The second percentages of t6, t7, and t8 are all 33%.
  • the predetermined word segmentation rules are as follows:
  • the long word priority principle refers to: for a phrase T1 that needs to be segmented, starting with the first word A , Find a longest word X1 starting from A from the pre-stored thesaurus, then remove X1 from T1 and leave T2, then use the same division principle for T2, and the result after division is "X1 / X2 / ,,,,,,, "; for example, when the phrase” Ping An "," Launch “,” Le “,” Zhonghong Life “, and” Products "are included in the pre-stored thesaurus, the phrase” Ping An has launched Zunhong Life Products " The segmentation result is "ping'an” / "launch” / "le” / "zunhong life” / "product”).
  • the obtained word segmentation may be further filtered.
  • the filtering process may be performed in one or two of the following ways: Method 1: Filter according to part of speech, retain nouns, verbs, and Adjective; Method two: Filter based on frequency, and retain participles whose frequency is greater than the frequency threshold, where frequency refers to the frequency or number of times the participle appears in the knowledge base.
  • the pre-stored thesaurus includes a conventional thesaurus, and a specific thesaurus, such as a financial thesaurus and a product thesaurus.
  • the word frequency (Tf), inverse word frequency (Idf), word weight (Tw), and position weight (Fw) of the document segmentation in each knowledge point are calculated, and each of the knowledge is calculated.
  • Tf refers to the number of times each document segmentation occurs in a knowledge point containing the document segmentation
  • the counterword frequency (Idf) refers to the number of times each document segmentation occurs in the entire database
  • Word weight refers to the different word segmentation of each document, and its word weight is different. For example, if a document segmentation comes from a specific thesaurus, such as financial thesaurus and product thesaurus, the weight of the document segmentation High, for example, set to 1.2, and the weight of word segmentation of documents that are not from the specific thesaurus is low, for example, set to 1;
  • Position weight means that each document segmentation has a different position in the knowledge point, and its weight is different. For example, if a certain document segmentation is in the title of a knowledge point, the position weight of the document segmentation is higher, for example Set to 1.2, if a certain document segmentation is located in the body of the knowledge point, the position weight of the document segmentation is low, for example, set to 1, and if a certain document segmentation is located in the attachment of the knowledge point, the document segmentation Position weight is lower, for example, set to 0.8;
  • the normalization factor of the length of the knowledge point Norm 1 / (1 + text length of the knowledge point / 1000);
  • each of the above-mentioned knowledge points and one or more preset weight coefficients of the document word segmentation accounts for all the last preset presets.
  • the preset algorithm is:
  • Nd is the number of knowledge points, i is the number of participles, and n is a total of n participles;
  • Lbw is the weight of the last operation, which is set according to the percentage of the last knowledge point that was clicked.
  • the weight of the knowledge point may be set to 1.4; if the percentage of a knowledge point clicked by the last one is greater than 50% but less than or equal to 80%, the knowledge point may be set The weight of the knowledge point is 1.3; the percentage of a knowledge point clicked by the last one is greater than 30% but less than or equal to 50%, and the weight of the knowledge point can be set to 1.2; the percentage of a knowledge point clicked by the last one is less than 30%, can be set The weight of this knowledge point is 1.1; otherwise, if a knowledge point is not re-clicked by the most one, its weight is 1.
  • Bw is the operation behavior weight, which is set according to the percentage of knowledge points that were clicked but not the last clicked.
  • a knowledge point is clicked more than 80%, you can set the weight of the knowledge point to 1.2; if a knowledge point is clicked more than 50% but less than or equal to 80%, you can set the weight of the knowledge point to 1.15 ;
  • the percentage of a knowledge point clicked is greater than 30% but less than or equal to 50%, the weight of the knowledge point can be set to 1.1; the percentage of a knowledge point clicked is less than 30%, the weight of the knowledge point can be set to 1.05, otherwise, If a knowledge point is restarted and has not been clicked, its weight is 1.
  • the preset algorithm may also be:
  • Cw is the channel weight of each knowledge point
  • the channel weight (Cw) of the knowledge point is set to 1.2, otherwise, if it does not belong to the same channel , Set it to 1.0.
  • W is the company weight of each knowledge point
  • the company weight (W) of the knowledge point is set to 1.2, otherwise, if it does not belong to the same company, it is set to 1.0.
  • the invention also provides a knowledge base search device.
  • a schematic diagram of an internal structure of a knowledge base searching apparatus according to an embodiment of the present application is shown.
  • the knowledge base searching device 1 may be a PC (Personal Computer), a terminal device such as a smart phone, a tablet computer, a portable computer, or a server.
  • the knowledge base searching apparatus 1 includes at least a memory 11, a processor 12, a communication bus 13, and a network interface 14.
  • the memory 11 includes at least one type of readable storage medium.
  • the readable storage medium includes a flash memory, a hard disk, a multimedia card, a card-type memory (for example, SD or DX memory, etc.), a magnetic memory, a magnetic disk, an optical disk, and the like.
  • the memory 11 may be an internal storage unit of the knowledge base searching device 1 in some embodiments, such as a hard disk of the knowledge base searching device 1.
  • the memory 11 may also be an external storage device of the knowledge base searching device 1 in other embodiments, for example, a plug-in hard disk, a smart memory card (SMC), and a secure digital (Secure) Digital, SD) cards, flash cards, etc.
  • the memory 11 may include both an internal storage unit of the knowledge base search apparatus 1 and an external storage device.
  • the memory 11 can be used not only to store application software and various types of data installed in the knowledge base search device 1, such as the code of the knowledge base search program 01, but also to temporarily store data that has been or will be output.
  • the processor 12 may be a central processing unit (CPU), a controller, a microcontroller, a microprocessor, or other data processing chip in some embodiments, and is configured to run program codes or processes stored in the memory 11 Data, such as executing the knowledge base search program 01 and the like.
  • CPU central processing unit
  • controller a controller
  • microcontroller a microprocessor
  • microprocessor or other data processing chip in some embodiments, and is configured to run program codes or processes stored in the memory 11 Data, such as executing the knowledge base search program 01 and the like.
  • the communication bus 13 is used to implement connection and communication between these components.
  • the network interface 14 may optionally include a standard wired interface, a wireless interface (such as a WI-FI interface), and is generally used to establish a communication connection between the device 1 and other electronic devices.
  • a standard wired interface such as a WI-FI interface
  • the device 1 may further include a user interface.
  • the user interface may include a display, an input unit such as a keyboard, and the optional user interface may further include a standard wired interface and a wireless interface.
  • the display may be an LED display, a liquid crystal display, a touch-type liquid crystal display, an OLED (Organic Light-Emitting Diode, organic light emitting diode) touch device, or the like.
  • the display may also be appropriately referred to as a display screen or a display unit for displaying information processed in the knowledge base searching device 1 and for displaying a visual user interface.
  • FIG. 2 only shows the knowledge base search device 1 having components 11-14 and the knowledge base search program 01.
  • FIG. 1 does not constitute a limitation on the knowledge base search device 1.
  • the knowledge base search program 01 is stored in the memory 11; when the processor 12 executes the knowledge base search program 01 stored in the memory 11, the following steps are implemented:
  • Step 1 Receive a keyword input by a user into a preset knowledge base, and perform a word segmentation operation on the received keyword.
  • the user may be a customer service staff of a financial enterprise, such as Ping An of China.
  • the customer service staff receives a user inquiry through a phone, web page, APP, or WeChat channel, they can enter a keyword into the financial company's knowledge base according to the user inquiry, such as "Ping An Zun Hong Life has What are the characteristics. "
  • the preferred embodiment of the present application performs a word segmentation operation on the currently received keyword.
  • the word segmentation operation adopts a long word priority principle, and performs segmentation on the received keywords according to a pre-stored word library.
  • the long word priority principle refers to: for a phrase T1 that needs to be segmented, start with the first word A, find a longest word X1 starting from A from the pre-stored lexicon, and then start from T1 After removing X1 from T2, the same slicing principle is applied to T2.
  • the slicing result is "X1 / X2 / ,,,,,,”.
  • the pre-stored thesaurus may include a conventional thesaurus and a specific thesaurus, such as a financial thesaurus and a product thesaurus.
  • a conventional thesaurus you can get participles such as “peace”, “life”, “what”, and “characteristics”, but according to the financial thesaurus, you can get the participle "zunhong life”. Therefore, in the preferred embodiment of the present application, after the keyword “What are the characteristics of Zunhong's life in peace” is segmented, the word segmentation that can be obtained is “peaceful", “of”, “zunhong life", “have”, “What", “characteristics”.
  • the obtained word segmentation may be further filtered.
  • the filtering process may be performed in one or two of the following ways: Method 1: Filter according to part of speech, retain nouns, verbs, and Adjective; Method two: Filter based on frequency, and retain participles whose frequency is greater than the frequency threshold, where frequency refers to the frequency or number of times the participle appears in the knowledge base.
  • Step 2 Obtain historical search records of all users in the preset knowledge base.
  • user A1 searches with a first keyword to obtain a number of knowledge points of N1; user A2 searches with a second keyword to obtain a number of knowledge points with N2; user A3 searches with a third keyword, If the number of knowledge points is N3, etc., the historical search records of all users including the keywords for each search and the corresponding knowledge points are obtained.
  • Step 3 Perform a word segmentation operation on the keywords of the historical search record, and match the keywords with the currently received keywords to find the historical search records that match the currently received keywords.
  • the preferred embodiment of the present application performs the word segmentation operation on the first keyword, the second keyword, and the third keyword according to the method described above.
  • the segmentation obtained according to the first keyword is compared with the segmentation obtained according to the currently received keyword to obtain the similarity between the two
  • the segmentation obtained according to the second keyword is compared with the foregoing. Compare the word segmentation obtained from the currently received keywords to obtain the similarity between the two, and compare the word segmentation obtained from the third keyword with the above-mentioned word segmentation obtained from the currently received keywords to obtain the similarity between the two.
  • a preset value such as 50%
  • the calculation of the similarity may be comparing the percentages of the same participles to all the participles.
  • the obtained participles are “peace”, “respect for life”, “what”, and “features”, and according to the first keyword in the historical search record, The participle is “peaceful”, “respect for life”, and “features”, the similarity between the two is 75%.
  • weights may be given to each participle according to some specific thesaurus, such as a financial thesaurus and a product thesaurus. For example, “Zunhong Life” comes from the product thesaurus, so you can assign a weight of 1.5 to this participle.
  • Step 4 Obtain a preset operation behavior that is performed by matching historical search records.
  • the preset operation behavior is a click behavior on a knowledge point in the historical search record.
  • the user A1 searches with the first keyword to obtain the number of knowledge points of N1, and searches with the second keyword to obtain the number of knowledge points of N2 as matching Historical search history, then click behavior of this historical search record is obtained.
  • the search is performed with the first keyword, and the obtained knowledge points of N1 items include t1, t2, t3, t4, t5, t6, t7, t8, t9, and t10, and the user views the knowledge points t1 in turn through the click behavior.
  • the acquired click behavior includes the knowledge points t1, t3, t4, and t8 in order; searching with the second keyword, the obtained N2 knowledge points include t1, t11, t2, t5, t12 , T13, t8, t14, and t15, in which the user sequentially views the knowledge points t1, t11, t5, and t8 through the click behavior, and the obtained click behavior includes the knowledge points t1, t11, t5, and t8 in this order.
  • Step 5 Count the knowledge points of the last executed preset operation behavior in each matching historical search record, and calculate the knowledge points of each last executed preset operation behavior to account for all the last executed preset The percentage of knowledge points for operational behavior.
  • the obtained knowledge points of N1 items include t1, t2, t3, t4, t5, t6, t7, t8, t9, and t10, where the user views the knowledge points in order by clicking behavior t1, t3, t4, and t8, then the last clicked knowledge point is t8.
  • one embodiment of the case obtained three matching historical search records is the knowledge point that the user last clicked, and the second matching historical search record.
  • t15 is the last knowledge point clicked by the user
  • t8 is the last knowledge point clicked by the user
  • the percentage of knowledge point t8 is 67%
  • the knowledge point that the user last clicked may represent that the knowledge point solved the user's problem.
  • Step 6 Count the knowledge points of each matched historical search record except the last knowledge point for which the preset operation behavior is performed, and calculate each knowledge point for which the preset operation behavior is performed to account for all the performed pre-operations. Set the percentage of knowledge points for operating behavior.
  • the obtained knowledge points of N1 items include t1, t2, t3, t4, t5, t6, t7, t8, t9, and t10, where the user views the knowledge points in order by clicking behavior t1, t3, t4, and t8, the other clicked knowledge points except the last knowledge point are in order t1, t3, and t4.
  • one embodiment of the present application obtains three matching historical search records.
  • the clicked knowledge points are t1 and t3. , T4; in the second matching history search record, the other knowledge points that were clicked excluding the last knowledge point are t1, t5, t6; and in the third matching history search record, the last knowledge is removed
  • the other clicked knowledge points are t3, t7, and t8; then the second percentage of knowledge point t1 is 67%, the second percentage of knowledge point t3 is 67%, and knowledge points t4, t5, The second percentages of t6, t7, and t8 are all 33%.
  • Step 7 Acquire all knowledge points in the preset knowledge base, and perform word segmentation operations on all content in each knowledge point according to a predetermined word segmentation rule to obtain a document word segmentation in each knowledge point.
  • the predetermined word segmentation rules are as follows:
  • Short sentence splitting of content in knowledge points according to preset type punctuation marks for example, ",”, “.”, “!, “;”, Etc.
  • the information between the preset type punctuation marks is a short sentence; if there is no preset type punctuation at the end of the message, the information from the penultimate preset type punctuation to the end of the message is a short sentence, and For the information from the first preset type punctuation mark to the penultimate preset type punctuation mark, the information between every two preset type punctuation marks is a short sentence; if there is a preset type at the end of the message Punctuation marks, for the information from the first preset type punctuation mark to the penultimate preset type punctuation mark, the information between every two preset type punctuation marks is a short sentence);
  • the long word priority principle refers to: for a phrase T1 that needs to be segmented, starting with the first word A , Find a longest word X1 starting from A from the pre-stored thesaurus, then remove X1 from T1 and leave T2, then use the same division principle for T2, and the result after division is "X1 / X2 / ,,,,,,, "; for example, when the phrase” Ping An "," Launch “,” Le “,” Zhonghong Life “, and” Products "are included in the pre-stored thesaurus, the phrase” Ping An has launched Zunhong Life Products " The segmentation result is "ping'an” / "launch” / "le” / "zunhong life” / "product”).
  • the obtained word segmentation may be further filtered.
  • the filtering process may be performed in one or two of the following ways: Method 1: Filter according to part of speech, retain nouns, verbs, and Adjective; Method two: Filter based on frequency, and retain participles whose frequency is greater than the frequency threshold, where frequency refers to the frequency or number of times the participle appears in the knowledge base.
  • the pre-stored thesaurus includes a conventional thesaurus, and a specific thesaurus, such as a financial thesaurus and a product thesaurus.
  • Step 8 Calculate one or more weight coefficients of each knowledge point and the document segmentation in it.
  • the word frequency Tf, the inverse word frequency Idf, the word weight Tw, and the position weight Fw of the document segmentation in each knowledge point are calculated, and the knowledge weight Kw and length of each knowledge point are calculated.
  • Tf refers to the number of times each document segmentation appears in a knowledge point containing the document segmentation
  • the counterword frequency Idf refers to the number of times each document segmentation occurs in the entire database
  • the word weight Tw means that the word segmentation of each document has different sources and different word weights. For example, if a document segmentation comes from a specific thesaurus, such as a financial thesaurus and a product thesaurus, the document segmentation has a higher weight. For example, it is set to 1.2, and the weight of word segmentation of documents not from the specific thesaurus is low, for example, it is set to 1.
  • the position weight Fw means that each document segmentation has a different position in the knowledge point, and its weight is different. For example, if a certain document segmentation is located in the title of the knowledge point, the position weight of the document segmentation is higher, for example, set to 1.2, if a certain document segmentation is located in the body of the knowledge point, the position weight of the document segmentation is low, for example, set to 1, and if a certain document segmentation is located in the attachment of the knowledge point, the position of the document segmentation Lower weight, for example set to 0.8;
  • the normalization factor of the length of the knowledge point Norm 1 / (1 + text length of the knowledge point / 1000);
  • Step 9 According to each of the above knowledge points and one or more preset weight coefficients of the document word segmentation, and each of the last knowledge points to which the preset operation behavior is performed accounts for all the last to be executed. Set the percentage of knowledge points of the operation behavior and the percentage of knowledge points of each performed preset operation behavior to the knowledge points of all performed preset operation behaviors. Use the preset algorithm to calculate the weight of each knowledge point. According to the weight value, all knowledge points are sorted and presented to the user.
  • the preset algorithm is:
  • Nd is the number of knowledge points, i is the number of participles, and n is a total of n participles;
  • Lbw is the weight of the last operation, which is set according to the percentage of the last knowledge point that was clicked.
  • the weight of the knowledge point may be set to 1.4; if the percentage of a knowledge point clicked by the last one is greater than 50% but less than or equal to 80%, the knowledge point may be set The weight of the knowledge point is 1.3; the percentage of a knowledge point clicked by the last one is greater than 30% but less than or equal to 50%, and the weight of the knowledge point can be set to 1.2; the percentage of a knowledge point clicked by the last one is less than 30%, can be set The weight of this knowledge point is 1.1; otherwise, if a knowledge point is not re-clicked by the most one, its weight is 1.
  • Bw is the operation behavior weight, which is set according to the percentage of knowledge points that were clicked but not the last clicked.
  • a knowledge point is clicked more than 80%, you can set the weight of the knowledge point to 1.2; if a knowledge point is clicked more than 50% but less than or equal to 80%, you can set the weight of the knowledge point to 1.15 ;
  • the percentage of a knowledge point clicked is greater than 30% but less than or equal to 50%, the weight of the knowledge point can be set to 1.1; the percentage of a knowledge point clicked is less than 30%, the weight of the knowledge point can be set to 1.05, otherwise, If a knowledge point is restarted and has not been clicked, its weight is 1.
  • the preset algorithm may also be:
  • Cw is the channel weight of each knowledge point
  • the channel weight (Cw) of the knowledge point is set to 1.2, otherwise, if it does not belong to the same channel , Set it to 1.0.
  • W is the company weight of each knowledge point
  • the company weight (W) of the knowledge point is set to 1.2, otherwise, if it does not belong to the same company, it is set to 1.0.
  • the knowledge base search program may also be divided into one or more modules, and the one or more modules are stored in the memory 11 and are composed of one or more processors (this embodiment is The processor 12) executes to complete this application.
  • the modules referred to in this application refer to a series of computer program instruction segments capable of performing specific functions, and are used to describe the execution process of the knowledge base search program in the knowledge base search device.
  • FIG. 3 it is a schematic diagram of a program module of a knowledge base search program in an embodiment of the knowledge base search apparatus of this application.
  • the knowledge base search program may be divided into a keyword receiving module 10,
  • the user behavior analysis module 20, the knowledge point content analysis module 30, and the search module 40 for example:
  • the keyword receiving module 10 is configured to: receive a keyword input by a user into a preset knowledge base, and perform a word segmentation operation on the received keyword.
  • the user behavior analysis module 20 is configured to: obtain historical search records of all users in the preset knowledge base, perform word segmentation on keywords in the historical search records, and match keywords currently received to find To a historical search record matching a currently received keyword, and calculate historical operation behavior data of a knowledge point in the historical search record.
  • the knowledge point content analysis module 30 is configured to: obtain all knowledge points in the preset knowledge base, and perform word segmentation operations on all content in each knowledge point according to a predetermined word segmentation rule to obtain each knowledge point. Document segmentation and calculate one or more weight coefficients for each knowledge point and the document segmentation in it.
  • the search module 40 is configured to calculate a weight of each knowledge point searched by using the keyword according to the weight coefficient and historical operation behavior data of the knowledge point, and According to the weight value, all knowledge points searched by using the keywords are sorted and presented to the user.
  • an embodiment of the present application further provides a computer-readable storage medium.
  • the computer-readable storage medium stores a knowledge base search program, and the knowledge base search program may be executed by one or more processors to implement the following. operating:
  • a preset algorithm is used to calculate the weight value of each knowledge point searched by using the keyword, and according to the weight value, the weight will be used
  • the keyword searches all knowledge points and sorts and presents them to the user.
  • the methods in the above embodiments can be implemented by means of software plus a necessary universal hardware platform, and of course, also by hardware, but in many cases the former is better.
  • Implementation Based on such an understanding, the technical solution of this application that is essentially or contributes to the existing technology can be embodied in the form of a software product.
  • the computer software product is stored in a storage medium (such as ROM / RAM) as described above. , Magnetic disk, optical disc), including a number of instructions for causing a terminal device (which may be a mobile phone, a computer, a server, or a network device, etc.) to execute the methods described in the embodiments of the present application.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Databases & Information Systems (AREA)
  • Data Mining & Analysis (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computational Linguistics (AREA)
  • Mathematical Physics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

本申请涉及一种大数据技术,揭露了一种知识库搜索方法,包括:获取所述知识库与当前接收的关键字相匹配的历史搜索记录,并计算所述历史搜索记录中的知识点的历史操作行为数据;计算所述预设知识库中每一条知识点的权值系数;根据所述权值系数以及对所述知识点的历史操作行为数据,利用预设的算法,计算利用所述当前接收的关键字搜索到的每一条知识点的权值,并根据所述权值,将利用所述当前接收的关键字搜索到所有知识点进行排序呈现给用户。本申请还提出一种知识库搜索装置以及一种计算机可读存储介质。本申请实现了知识库的精准搜索。

Description

知识库搜索方法、装置及计算机可读存储介质
本申请要求于2018年9月19日提交中国专利局,申请号为201811096202.5、发明名称为“知识库搜索方法、装置及计算机可读存储介质”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及大数据技术领域,尤其涉及一种基于知识内容和用户行为协同的知识库搜索方法、装置及计算机可读存储介质。
背景技术
知识库是指具有咨询性质的数据库,这种知识库是共享的。从今后的发展来看,巨型知识库将会出现。顾名思义,在巨型知识库中,存在海量的信息,因此,在知识库中快速、准确地寻找特定问题的解决方案并不是一件容易的事情。
传统的知识库搜索方案中,当接收到用户输入一个特定问题时,所采用的搜索算法大多是基于知识文本本身的相关性来进行搜索排序的,这种搜索排序结果可能并不能使用户快速、准确地找到问题的答案,给用户及/或客户带来不好的使用体验。
例如,随着人们收入水平的不断提高,人们可能会越来越关注金融信息,如存在哪些理财产品、哪些保险服务,哪些产品更适合自己等等。因此,人们可能会通过电话或者网络的方式向金融企业的客服进行询问。由于金融产品成千上万,客服并不能详细了解每一款金融产品,因此,需要向企业的知识库中进行搜索。如何能够做到快速且准确地回答客户的询问,完全依赖于企业知识库的搜索结果。
发明内容
本申请提供一种知识库搜索方法、装置及计算机可读存储介质,其主要目的在于当用户在知识库中进行搜索时,给用户呈现出精准的搜索结果。
为实现上述目的,本申请提供的一种知识库搜索方法,包括:
获取所述知识库中与当前接收的关键字相匹配的历史搜索记录,并计算所述历史搜索记录中的知识点的历史操作行为数据;
计算所述知识库中每一条知识点的权值系数;
根据所述权值系数以及所述知识点的历史操作行为数据,利用预设的算法,计算利用所述当前接收的关键字搜索到的每一条知识点的权值,并根据所述权值,将利用所述当前接收的关键字搜索到所有知识点进行排序呈现给用户。
此外,为实现上述目的,本申请还提供一种知识库搜索装置,该装置包括存储器和处理器,所述存储器中存储有可在所述处理器上运行的知识库搜 索程序,所述知识库搜索程序被所述处理器执行时实现如下步骤:
获取所述知识库中与当前接收的关键字相匹配的历史搜索记录,并计算所述历史搜索记录中的知识点的历史操作行为数据;
计算所述知识库中每一条知识点的权值系数;
根据所述权值系数以及所述知识点的历史操作行为数据,利用预设的算法,计算利用所述当前接收的关键字搜索到的每一条知识点的权值,并根据所述权值,将利用所述当前接收的关键字搜索到所有知识点进行排序呈现给用户。
此外,为实现上述目的,本申请还提供一种计算机可读存储介质,所述计算机可读存储介质上存储有知识库搜索程序,所述知识库搜索程序可被一个或者多个处理器执行,以实现如上所述的知识库搜索方法的步骤。
本申请提出的知识库搜索方法、装置及计算机可读存储介质,在用户利用关键字在一个知识库中进行搜索时,结合所述知识库中所有知识的内容权重以及所有用户在所述知识库中搜索时的操作行为,对利用所述关键字搜索得到的知识点进行排序,从而可以给用户呈现出精准的搜索结果。
附图说明
图1为本申请一实施例提供的知识库搜索方法的流程示意图;
图2为本申请一实施例提供的知识库搜索装置的内部结构示意图;
图3为本申请一实施例提供的知识库搜索装置中知识库搜索程序的模块示意图。
本申请目的的实现、功能特点及优点将结合实施例,参照附图做进一步说明。
具体实施方式
应当理解,此处所描述的具体实施例仅仅用以解释本申请,并不用于限定本申请。
本申请提供一种知识库搜索方法。参照图1所示,为本申请一实施例提供的知识库搜索方法的流程示意图。该方法可以由一个装置执行,该装置可以由软件和/或硬件实现。
在本实施例中,知识库搜索方法包括:
S1、接收用户输入到预设知识库的关键字,并对接收的关键字执行分词操作。
本申请较佳实施例中,所述用户可以是某一个金融企业,如中国平安等的客服人员。当所述客服人员通过电话、网页、APP、或者微信等渠道接收到一个用户询问时,可以根据所述用户询问向该金融企业的知识库中输入一个关键字,如“平安的尊宏人生有什么特点”。本申请较佳实施例在接收到所述关键字后,对当前接收的关键字执行分词操作。
本申请较佳实施例采用长词优先原则,根据预存的词库对接收的关键字 进行分词。
例如,所述长词优先原则指的是:对于一个需要分词的短语T1,先从第一个字A开始,从预存的词库找出一个由A起始的最长词语X1,然后从T1中剔除X1剩下T2,再对T2采用相同的切分原理,切分后的结果为“X1/X2/、、、、、、”。
所述预存的词库可以包括常规的词库以及特定词库,如金融词库和产品词库等。例如,根据常规的词库,可以得到“平安”、“人生”、“什么”、“特点”等分词,但是根据金融词库,可以得到“尊宏人生”这个分词。因此,本申请较佳实施例对所述关键字“平安的尊宏人生有什么特点”进行分词后,可以得到的分词为“平安”、“的”、“尊宏人生”、“有”、“什么”、“特点”。
进一步地,本申请较佳实施例中,还可以进一步对得到的分词进行过滤处理,具体地,过滤处理采用以下任一种或两种方式:方式一:根据词性进行过滤,保留名词、动词以及形容词;方式二:根据频次进行过滤,保留频次大于频次阈值的分词,其中,频次是指分词在知识库中出现的频率或者次数。
S2、获取所有用户在所述预设知识库的历史搜索记录。
例如,用户A1以第一关键字进行搜索,得到数量为N1条的知识点;用户A2以第二关键字进行搜索,得到数量为N2条的知识点;用户A3以第三关键字进行搜索,得到数量为N3条的知识点等等,则获取包括每一次搜索的关键字以及对应得到的知识点的所有用户的历史搜索记录。
S3、将所述历史搜索记录的关键字执行分词操作,并与当前接收的关键字进行匹配,以查找到与当前接收的关键字匹配的历史搜索记录。
根据上述例子,本申请较佳实施例将第一关键字、第二关键字以及第三关键字按照上述介绍的方法进行分词操作。
进一步地,本申请较佳实施例将根据第一关键字得到的分词与上述根据当前接收的关键字得到的分词进行比较,得到两者的相似度,将根据第二关键字得到的分词与上述根据当前接收的关键字得到的分词进行比较,得到两者的相似度,以及将根据第三关键字得到的分词与上述根据当前接收的关键字得到的分词进行比较,得到两者的相似度。当相似度大于一个预设数值,如50%,则认为该条历史搜索纪录当前接收的关键字匹配。
所述相似度的计算可以是比较两者相同的分词占所有分词的百分比。
在一个实施例中,根据当前接收的关键字,得到的分词为“平安”、“尊宏人生”、“什么”、“特点”,根据所述历史搜索记录中的第一关键字,得到的分词为“平安”、“尊宏人生”、“特点”,则两者的相似度为75%。
进一步地,在本申请其他实施例中,也可以根据一些特定的词库,如金融词库和产品词库,赋予每个分词不同的权值。例如,“尊宏人生”为来于自产品词库,则可以赋予该分词1.5的权值等。
S4、获取相匹配的历史搜索记录被执行的预设操作行为。
本申请较佳实施例中,所述预设操作行为为对所述历史搜索记录中的知 识点的点击行为。
在一个实施例中,根据上述匹配,用户A1以第一关键字进行搜索,得到数量为N1条的知识点,以及以第二关键字进行搜索,得到数量为N2条的知识点为相匹配的历史搜索记录,则获取该条历史搜索记录的点击行为。
假设,以第一关键字进行搜索,得到的N1条的知识点包括t1、t2、t3、t4、t5、t6、t7、t8、t9以及t10,其中用户通过点击行为依次查看了知识点t1、t3、t4以及t8,则获取的点击行为依次包括所述知识点t1、t3、t4以及t8;以第二关键字进行搜索,得到的N2条的知识点包括t1、t11、t2、t5、t12、t13、t8、t14,以及t15,其中用户通过点击行为依次查看了知识点t1、t11、t5以及t8,则获取的点击行为依次包括所述知识点t1、t11、t5以及t8。
S5、统计每个相匹配的历史搜索记录中最后一条被执行预设操作行为的知识点,并计算所述每个最后一条被执行预设操作行为的知识点占所有最后一条被执行预设操作行为的知识点的百分比。
根据上述例子,以第一关键字进行搜索,得到的N1条的知识点包括t1、t2、t3、t4、t5、t6、t7、t8、t9以及t10,其中用户通过点击行为依次查看了知识点t1、t3、t4以及t8,则最后一条被点击的知识点为t8。
本案其中一个实施例根据上述流程,共得到三条相匹配的历史搜索记录,其中,第一条相匹配的历史搜索记录中,t8为用户最后一次点击的知识点,第二条相匹配的历史搜索记录中,t15为用户最后一次点击的知识点,以及第三条相匹配的历史搜索记录中,t8为用户最后一次点击的知识点,则知识点t8的百分比为67%,知识点t15的百分比为33%。
应该了解,用户最后一次点击的知识点可能代表该知识点解决了用户的问题。
S6、统计每个相匹配的历史搜索记录中除去最后一条知识点的其他条被执行预设操作行为的知识点,并计算其中每一条被执行预设操作行为的知识点占所有被执行预设操作行为的知识点的百分比。
根据上述例子,以第一关键字进行搜索,得到的N1条的知识点包括t1、t2、t3、t4、t5、t6、t7、t8、t9以及t10,其中用户通过点击行为依次查看了知识点t1、t3、t4以及t8,则除去最后一条知识点的其他条被点击的知识点依次为t1、t3、t4。
本申请其中一个实施例根据上述流程,共得到三条相匹配的历史搜索记录,其中,第一条相匹配的历史搜索记录中,除去最后一条知识点的其他条被点击的知识点为t1、t3、t4;第二条相匹配的历史搜索记录中,除去最后一条知识点的其他条被点击的知识点为t1、t5、t6;以及第三条相匹配的历史搜索记录中,除去最后一条知识点的其他条被点击的知识点为t3、t7、t8;,则知识点t1的第二百分比为67%、知识点t3的第二百分比为67%、知识点t4、t5、t6、t7、t8的第二百分比均为33%。
S7、获取所述预设知识库中的所有知识点,并对每一条知识点中的所有内容按照预先确定的分词规则执行分词操作,得到每一条知识点中的文档分 词。
优选地,所述预先确定的分词规则如下:
按预设类型标点符号(例如,“,”、“。”、“!”、“;”等等)对获取的各个信息进行短句拆分(例如,从信息起始位置至第一个预设类型标点符号之间的信息为一个短句;若信息结束位置无预设类型标点符号,则从倒数第一个预设类型标点符号至信息结束位置之间的信息为一个短句,且针对从第一个预设类型标点符号至倒数第一个预设类型标点符号之间的信息,每两个预设类型标点符号之间的信息为一个短句;若信息结束位置有预设类型标点符号,则针对从第一个预设类型标点符号至倒数第一个预设类型标点符号之间的信息,每两个预设类型标点符号之间的信息为一个短句);
对拆分的每一个短句,采用长词优先原则,根据预设的词库进行分词(例如,长词优先原则指的是:对于一个需要分词的短语T1,先从第一个字A开始,从预存的词库找出一个由A起始的最长词语X1,然后从T1中剔除X1剩下T2,再对T2采用相同的切分原理,切分后的结果为“X1/X2/、、、、、、”;例如,在预存的词库中包括“平安”、“推出”、“了”、“尊宏人生”和“产品”时,短语“平安推出了尊宏人生产品”的切分结果为“平安”/“推出”/“了”/“尊宏人生”/“产品”)。
进一步地,本申请较佳实施例中,还可以进一步对得到的分词进行过滤处理,具体地,过滤处理采用以下任一种或两种方式:方式一:根据词性进行过滤,保留名词、动词以及形容词;方式二:根据频次进行过滤,保留频次大于频次阈值的分词,其中,频次是指分词在知识库中出现的频率或者次数。
本申请较佳实施例中,所述预存的词库包括常规的词库,以及特定词库,如金融词库和产品词库等。
S8、计算每一条知识点以及其中的文档分词的一种或者多种权值系数。
本申请较佳实施例中,计算所述每个知识点中的文档分词的词频(Tf)、反词频(Idf)、词权重(Tw)以及位置权重(Fw),并计算所述每一个知识点的知识权重(Kw)、长度归一化因子(Norm)等。
其中:
所述词频(Tf)指的是每个文档分词在包含该文档分词的知识点中出现的次数;
所述反词频(Idf)指的是每个文档分词在整个资料库中出现的次数;
词权重(Tw)是指每个文档分词的来源不同,其词权重不同,例如,若某一个文档分词来自于特定词库,如金融词库和产品词库等,则该文档分词的权重较高,例如设置为1.2,非来自于所述特定词库的文档分词的权重较低,例如设置为1;
位置权重(Fw)是指每个文档分词在知识点中的位置不同,则其权重不同,例如,若某一个文档分词位于知识点的标题中,则所述文档分词的位置权重较高,例如设置为1.2,若某一个文档分词位于知识点的正文中,则所述 文档分词的位置权重较低,例如设置为1,以及若某一个文档分词位于知识点的附件中,则所述文档分词的位置权重更低,例如设置为0.8;
所述知识点的知识权重(Kw)为所述知识点中每个文档分词的词频-反词频的加权求和,即Kw=Tf1*Idf1+Tf2*Idf2+...+Tfn*Idfn;
所述知识点的长度归一化因子Norm=1/(1+知识点的文本长度/1000);
S9,根据上述每一条知识点以及其中的文档分词的一种或者多种预设的权值系数,以及所述每个最后一条被执行预设操作行为的知识点占所有最后一条被执行预设操作行为的知识点的百分比及每一条被执行预设操作行为的知识点占所有被执行预设操作行为的知识点的百分比,利用预设的算法,计算每一条知识点的权值Weight,并根据所述权值,将所有知识点进行排序呈现给用户。
本申请较佳实施例中,所述预设的算法为:
Figure PCTCN2018123597-appb-000001
其中:
Nd为知识点的个数,i为第几个分词,n为共n个分词;
Lbw为最后一次操作行为权重,是根据最后一条被点击的知识点的百分比设置的。
例如,一条知识点被最后一条被点击的百分比大于80%,可以设置该知识点的权重为1.4;一条知识点被最后一条被点击的百分比大于50%但是小于等于80%,可以设置该知识点的权重为1.3;一条知识点被最后一条被点击的百分比大于30%但是小于等于50%,可以设置该知识点的权重为1.2;一条知识点被最后一条被点击的百分比小于30%,可以设置该知识点的权重为1.1,否则,若一条知识点重来没有被最有一条点击过,则其权重为1;
Bw为操作行为权重,是根据被点击但非最后一条被点击的知识点的百分比设置的。
例如,一条知识点被被点击的百分比大于80%,可以设置该知识点的权重为1.2;一条知识点被被点击的百分比大于50%但是小于等于80%,可以设置该知识点的权重为1.15;一条知识点被点击的百分比大于30%但是小于等于50%,可以设置该知识点的权重为1.1;一条知识点被点击的百分比小于30%,可以设置该知识点的权重为1.05,否则,若一条知识点重来没有被点击过,则其权重为1。
本申请其他实施例中,所述预设的算法也可以为:
Figure PCTCN2018123597-appb-000002
其中:
Cw是每一条知识点的渠道权重;
例如,当某一个知识点与当前搜索属于同一渠道,如同属客服人工搜索、或同属机器人智能搜索等,则所述知识点的渠道权重(Cw)设置为1.2,否则,若不属于相同的渠道,则设置为1.0。
W是每一条知识点的所属公司权重;
例如,当某一个知识点与当前搜索属于同一公司,如同属寿险组公司,所述知识点的公司权重(W)设置为1.2,否则,若不属于相同的公司,则设置为1.0。
发明还提供一种知识库搜索装置。参照图2所示,为本申请一实施例提供的知识库搜索装置的内部结构示意图。
在本实施例中,所述知识库搜索装置1可以是PC(Personal Computer,个人电脑),或者是智能手机、平板电脑、便携计算机等终端设备,也可以是一种服务器等。该知识库搜索装置1至少包括存储器11、处理器12,通信总线13,以及网络接口14。
其中,存储器11至少包括一种类型的可读存储介质,所述可读存储介质包括闪存、硬盘、多媒体卡、卡型存储器(例如,SD或DX存储器等)、磁性存储器、磁盘、光盘等。存储器11在一些实施例中可以是知识库搜索装置1的内部存储单元,例如该知识库搜索装置1的硬盘。存储器11在另一些实施例中也可以是知识库搜索装置1的外部存储设备,例如知识库搜索装置1上配备的插接式硬盘,智能存储卡(Smart Media Card,SMC),安全数字(Secure Digital,SD)卡,闪存卡(Flash Card)等。进一步地,存储器11还可以既包括知识库搜索装置1的内部存储单元也包括外部存储设备。存储器11不仅可以用于存储安装于知识库搜索装置1的应用软件及各类数据,例如知识库搜索程序01的代码等,还可以用于暂时地存储已经输出或者将要输出的数据。
处理器12在一些实施例中可以是一中央处理器(Central Processing Unit,CPU)、控制器、微控制器、微处理器或其他数据处理芯片,用于运行存储器11中存储的程序代码或处理数据,例如执行知识库搜索程序01等。
通信总线13用于实现这些组件之间的连接通信。
网络接口14可选的可以包括标准的有线接口、无线接口(如WI-FI接口),通常用于在该装置1与其他电子设备之间建立通信连接。
可选地,该装置1还可以包括用户接口,用户接口可以包括显示器(Display)、输入单元比如键盘(Keyboard),可选的用户接口还可以包括标准的有线接口、无线接口。可选地,在一些实施例中,显示器可以是LED显示器、液晶显示器、触控式液晶显示器以及OLED(Organic Light-Emitting Diode,有机发光二极管)触摸器等。其中,显示器也可以适当的称为显示屏或显示单元,用于显示在知识库搜索装置1中处理的信息以及用于显示可视化的用户界面。
图2仅示出了具有组件11-14以及知识库搜索程序01的知识库搜索装置1,本领域技术人员可以理解的是,图1示出的结构并不构成对知识库搜索装置1的限定,可以包括比图示更少或者更多的部件,或者组合某些部件,或者不同的部件布置。
在图2所示的装置1实施例中,存储器11中存储有知识库搜索程序01; 处理器12执行存储器11中存储的知识库搜索程序01时实现如下步骤:
步骤一、接收用户输入到预设知识库的关键字,并对接收的关键字执行分词操作。
本申请较佳实施例中,所述用户可以是某一个金融企业,如中国平安等的客服人员。当所述客服人员通过电话、网页、APP、或者微信等渠道接收到一个用户询问时,可以根据所述用户询问向该金融企业的知识库中输入一个关键字,如“平安的尊宏人生有什么特点”。本申请较佳实施例在接收到所述关键字后,对当前接收的关键字执行分词操作。
本申请较佳实施例,所述分词操作采用长词优先原则,根据预存的词库对接收的关键字进行分词。
例如,所述长词优先原则指的是:对于一个需要分词的短语T1,先从第一个字A开始,从预存的词库找出一个由A起始的最长词语X1,然后从T1中剔除X1剩下T2,再对T2采用相同的切分原理,切分后的结果为“X1/X2/、、、、、、”。
所述预存的词库可以包括常规的词库以及特定词库,如金融词库和产品词库等。例如,根据常规的词库,可以得到“平安”、“人生”、“什么”、“特点”等分词,但是根据金融词库,可以得到“尊宏人生”这个分词。因此,本申请较佳实施例对所述关键字“平安的尊宏人生有什么特点”进行分词后,可以得到的分词为“平安”、“的”、“尊宏人生”、“有”、“什么”、“特点”。
进一步地,本申请较佳实施例中,还可以进一步对得到的分词进行过滤处理,具体地,过滤处理采用以下任一种或两种方式:方式一:根据词性进行过滤,保留名词、动词以及形容词;方式二:根据频次进行过滤,保留频次大于频次阈值的分词,其中,频次是指分词在知识库中出现的频率或者次数。
步骤二、获取所有用户在所述预设知识库的历史搜索记录。
例如,用户A1以第一关键字进行搜索,得到数量为N1条的知识点;用户A2以第二关键字进行搜索,得到数量为N2条的知识点;用户A3以第三关键字进行搜索,得到数量为N3条的知识点等等,则获取包括每一次搜索的关键字以及对应得到的知识点的所有用户的历史搜索记录。
步骤三、将所述历史搜索记录的关键字执行分词操作,并与当前接收的关键字进行匹配,以查找到与当前接收的关键字匹配的历史搜索记录。
根据上述例子,本申请较佳实施例将第一关键字、第二关键字以及第三关键字按照上述介绍的方法进行分词操作。
进一步地,本申请较佳实施例将根据第一关键字得到的分词与上述根据当前接收的关键字得到的分词进行比较,得到两者的相似度,将根据第二关键字得到的分词与上述根据当前接收的关键字得到的分词进行比较,得到两者的相似度,以及将根据第三关键字得到的分词与上述根据当前接收的关键字得到的分词进行比较,得到两者的相似度。当相似度大于一个预设数值,如50%,则认为该条历史搜索纪录当前接收的关键字匹配。
所述相似度的计算可以是比较两者相同的分词占所有分词的百分比。
在一个实施例中,根据当前接收的关键字,得到的分词为“平安”、“尊宏人生”、“什么”、“特点”,根据所述历史搜索记录中的第一关键字,得到的分词为“平安”、“尊宏人生”、“特点”,则两者的相似度为75%。
进一步地,在本申请其他实施例中,也可以根据一些特定的词库,如金融词库和产品词库,赋予每个分词不同的权值。例如,“尊宏人生”为来于自产品词库,则可以赋予该分词1.5的权值等。
步骤四、获取相匹配的历史搜索记录被执行的预设操作行为。
本申请较佳实施例中,所述预设操作行为为对所述历史搜索记录中的知识点的点击行为。
在一个实施例中,根据上述匹配,用户A1以第一关键字进行搜索,得到数量为N1条的知识点,以及以第二关键字进行搜索,得到数量为N2条的知识点为相匹配的历史搜索记录,则获取该条历史搜索记录的点击行为。
假设,以第一关键字进行搜索,得到的N1条的知识点包括t1、t2、t3、t4、t5、t6、t7、t8、t9以及t10,其中用户通过点击行为依次查看了知识点t1、t3、t4以及t8,则获取的点击行为依次包括所述知识点t1、t3、t4以及t8;以第二关键字进行搜索,得到的N2条的知识点包括t1、t11、t2、t5、t12、t13、t8、t14,以及t15,其中用户通过点击行为依次查看了知识点t1、t11、t5以及t8,则获取的点击行为依次包括所述知识点t1、t11、t5以及t8。
步骤五、统计每个相匹配的历史搜索记录中最后一条被执行预设操作行为的知识点,并计算所述每个最后一条被执行预设操作行为的知识点占所有最后一条被执行预设操作行为的知识点的百分比。
根据上述例子,以第一关键字进行搜索,得到的N1条的知识点包括t1、t2、t3、t4、t5、t6、t7、t8、t9以及t10,其中用户通过点击行为依次查看了知识点t1、t3、t4以及t8,则最后一条被点击的知识点为t8。
本案其中一个实施例根据上述流程,共得到三条相匹配的历史搜索记录,其中,第一条相匹配的历史搜索记录中,t8为用户最后一次点击的知识点,第二条相匹配的历史搜索记录中,t15为用户最后一次点击的知识点,以及第三条相匹配的历史搜索记录中,t8为用户最后一次点击的知识点,则知识点t8的百分比为67%,知识点t15的百分比为33%。
应该了解,用户最后一次点击的知识点可能代表该知识点解决了用户的问题。
步骤六、统计每个相匹配的历史搜索记录中除去最后一条知识点的其他条被执行预设操作行为的知识点,并计算其中每一条被执行预设操作行为的知识点占所有被执行预设操作行为的知识点的百分比。
根据上述例子,以第一关键字进行搜索,得到的N1条的知识点包括t1、t2、t3、t4、t5、t6、t7、t8、t9以及t10,其中用户通过点击行为依次查看了知识点t1、t3、t4以及t8,则除去最后一条知识点的其他条被点击的知识点依次为t1、t3、t4。
本申请其中一个实施例根据上述流程,共得到三条相匹配的历史搜索记录,其中,第一条相匹配的历史搜索记录中,除去最后一条知识点的其他条被点击的知识点为t1、t3、t4;第二条相匹配的历史搜索记录中,除去最后一条知识点的其他条被点击的知识点为t1、t5、t6;以及第三条相匹配的历史搜索记录中,除去最后一条知识点的其他条被点击的知识点为t3、t7、t8;,则知识点t1的第二百分比为67%、知识点t3的第二百分比为67%、知识点t4、t5、t6、t7、t8的第二百分比均为33%。
步骤七、获取所述预设知识库中的所有知识点,并对每一条知识点中的所有内容按照预先确定的分词规则执行分词操作,得到每一条知识点中的文档分词。
优选地,所述预先确定的分词规则如下:
按预设类型标点符号(例如,“,”、“。”、“!”、“;”等等)对知识点中的内容进行短句拆分(例如,从信息起始位置至第一个预设类型标点符号之间的信息为一个短句;若信息结束位置无预设类型标点符号,则从倒数第一个预设类型标点符号至信息结束位置之间的信息为一个短句,且针对从第一个预设类型标点符号至倒数第一个预设类型标点符号之间的信息,每两个预设类型标点符号之间的信息为一个短句;若信息结束位置有预设类型标点符号,则针对从第一个预设类型标点符号至倒数第一个预设类型标点符号之间的信息,每两个预设类型标点符号之间的信息为一个短句);
对拆分的每一个短句,采用长词优先原则,根据预设的词库进行分词(例如,长词优先原则指的是:对于一个需要分词的短语T1,先从第一个字A开始,从预存的词库找出一个由A起始的最长词语X1,然后从T1中剔除X1剩下T2,再对T2采用相同的切分原理,切分后的结果为“X1/X2/、、、、、、”;例如,在预存的词库中包括“平安”、“推出”、“了”、“尊宏人生”和“产品”时,短语“平安推出了尊宏人生产品”的切分结果为“平安”/“推出”/“了”/“尊宏人生”/“产品”)。
进一步地,本申请较佳实施例中,还可以进一步对得到的分词进行过滤处理,具体地,过滤处理采用以下任一种或两种方式:方式一:根据词性进行过滤,保留名词、动词以及形容词;方式二:根据频次进行过滤,保留频次大于频次阈值的分词,其中,频次是指分词在知识库中出现的频率或者次数。
本申请较佳实施例中,所述预存的词库包括常规的词库,以及特定词库,如金融词库和产品词库等。
步骤八、计算每一条知识点以及其中的文档分词的一种或者多种权值系数。
本申请较佳实施例中,计算所述每个知识点中的文档分词的词频Tf、反词频Idf、词权重Tw以及位置权重Fw,并计算所述每一个知识点的知识权重Kw、长度归一化因子Norm等。
其中:
所述词频Tf指的是每个文档分词在包含该文档分词的知识点中出现的次数;
所述反词频Idf指的是每个文档分词在整个资料库中出现的次数;
词权重Tw是指每个文档分词的来源不同,其词权重不同,例如,若某一个文档分词来自于特定词库,如金融词库和产品词库等,则该文档分词的权重较高,例如设置为1.2,非来自于所述特定词库的文档分词的权重较低,例如设置为1;
位置权重Fw是指每个文档分词在知识点中的位置不同,则其权重不同,例如,若某一个文档分词位于知识点的标题中,则所述文档分词的位置权重较高,例如设置为1.2,若某一个文档分词位于知识点的正文中,则所述文档分词的位置权重较低,例如设置为1,以及若某一个文档分词位于知识点的附件中,则所述文档分词的位置权重更低,例如设置为0.8;
所述知识点的知识权重Kw为所述知识点中每个文档分词的词频-反词频的加权求和,即Kw=Tf1*Idf1+Tf2*Idf2+...+Tfn*Idfn;
所述知识点的长度归一化因子Norm=1/(1+知识点的文本长度/1000);
步骤九、根据上述每一条知识点以及其中的文档分词的一种或者多种预设的权值系数,以及所述每个最后一条被执行预设操作行为的知识点占所有最后一条被执行预设操作行为的知识点的百分比及每一条被执行预设操作行为的知识点占所有被执行预设操作行为的知识点的百分比,利用预设的算法,计算每一条知识点的权值Weight,并根据所述权值,将所有知识点进行排序呈现给用户。
本申请较佳实施例中,所述预设的算法为:
Figure PCTCN2018123597-appb-000003
其中:
Nd为知识点的个数,i为第几个分词,n为共n个分词;
Lbw为最后一次操作行为权重,是根据最后一条被点击的知识点的百分比设置的。
例如,一条知识点被最后一条被点击的百分比大于80%,可以设置该知识点的权重为1.4;一条知识点被最后一条被点击的百分比大于50%但是小于等于80%,可以设置该知识点的权重为1.3;一条知识点被最后一条被点击的百分比大于30%但是小于等于50%,可以设置该知识点的权重为1.2;一条知识点被最后一条被点击的百分比小于30%,可以设置该知识点的权重为1.1,否则,若一条知识点重来没有被最有一条点击过,则其权重为1;
Bw为操作行为权重,是根据被点击但非最后一条被点击的知识点的百分比设置的。
例如,一条知识点被被点击的百分比大于80%,可以设置该知识点的权重为1.2;一条知识点被被点击的百分比大于50%但是小于等于80%,可以设置该知识点的权重为1.15;一条知识点被点击的百分比大于30%但是小于等 于50%,可以设置该知识点的权重为1.1;一条知识点被点击的百分比小于30%,可以设置该知识点的权重为1.05,否则,若一条知识点重来没有被点击过,则其权重为1。
本申请其他实施例中,所述预设的算法也可以为:
Figure PCTCN2018123597-appb-000004
其中:
Cw是每一条知识点的渠道权重;
例如,当某一个知识点与当前搜索属于同一渠道,如同属客服人工搜索、或同属机器人智能搜索等,则所述知识点的渠道权重(Cw)设置为1.2,否则,若不属于相同的渠道,则设置为1.0。
W是每一条知识点的所属公司权重;
例如,当某一个知识点与当前搜索属于同一公司,如同属寿险组公司,所述知识点的公司权重(W)设置为1.2,否则,若不属于相同的公司,则设置为1.0。
可选地,在其他实施例中,知识库搜索程序还可以被分割为一个或者多个模块,一个或者多个模块被存储于存储器11中,并由一个或多个处理器(本实施例为处理器12)所执行以完成本申请,本申请所称的模块是指能够完成特定功能的一系列计算机程序指令段,用于描述知识库搜索程序在知识库搜索装置中的执行过程。
例如,参照图3所示,为本申请知识库搜索装置一实施例中的知识库搜索程序的程序模块示意图,该实施例中,所述知识库搜索程序可以被分割为关键字接收模块10、用户行为分析模块20、知识点内容分析模块30以及搜索模块40,示例性地:
所述关键字接收模块10用于:接收用户输入到预设知识库的关键字,并对接收的关键字执行分词操作。
所述用户行为分析模块20用于:获取所有用户在所述预设知识库的历史搜索记录,将所述历史搜索记录的关键字执行分词操作,并与当前接收的关键字进行匹配,以查找到与当前接收的关键字匹配的历史搜索记录,并计算所述历史搜索记录中的知识点的历史操作行为数据。
所述知识点内容分析模块30用于:获取所述预设知识库中的所有知识点,并对每一条知识点中的所有内容按照预先确定的分词规则执行分词操作,得到每一条知识点中的文档分词,并计算每一条知识点以及其中的文档分词的一种或者多种权值系数。
所述搜索模块40用于:根据所述权值系数以及对所述知识点的历史操作行为数据,利用预设的算法,计算利用所述关键字搜索到的每一条知识点的权值,并根据所述权值,将利用所述关键字搜索到所有知识点进行排序呈现给用户。
上述关键字接收模块10、用户行为分析模块20、知识点内容分析模块30 以及搜索模块40等程序模块被执行时所实现的功能或操作步骤与上述实施例大体相同,在此不再赘述。
此外,本申请实施例还提出一种计算机可读存储介质,所述计算机可读存储介质上存储有知识库搜索程序,所述知识库搜索程序可被一个或多个处理器执行,以实现如下操作:
接收用户输入到预设知识库的关键字,并对接收的关键字执行分词操作;
获取所有用户在所述预设知识库的历史搜索记录,将所述历史搜索记录的关键字执行分词操作,并与当前接收的关键字进行匹配,以查找到与当前接收的关键字匹配的历史搜索记录,并计算所述历史搜索记录中的知识点的历史操作行为数据;
获取所述预设知识库中的所有知识点,并对每一条知识点中的所有内容按照预先确定的分词规则执行分词操作,得到每一条知识点中的文档分词,并计算每一条知识点以及其中的文档分词的一种或者多种权值系数;
根据所述权值系数以及对所述知识点的历史操作行为数据,利用预设的算法,计算利用所述关键字搜索到的每一条知识点的权值,并根据所述权值,将利用所述关键字搜索到所有知识点进行排序呈现给用户。
本申请计算机可读存储介质具体实施方式与上述知识库搜索装置和方法各实施例基本相同,在此不作累述。
需要说明的是,上述本申请实施例序号仅仅为了描述,不代表实施例的优劣。并且本文中的术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、装置、物品或者方法不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、装置、物品或者方法所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括该要素的过程、装置、物品或者方法中还存在另外的相同要素。
通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到上述实施例方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在如上所述的一个存储介质(如ROM/RAM、磁碟、光盘)中,包括若干指令用以使得一台终端设备(可以是手机,计算机,服务器,或者网络设备等)执行本申请各个实施例所述的方法。
以上仅为本申请的优选实施例,并非因此限制本申请的专利范围,凡是利用本申请说明书及附图内容所作的等效结构或等效流程变换,或直接或间接运用在其他相关的技术领域,均同理包括在本申请的专利保护范围内。

Claims (20)

  1. 一种知识库搜索方法,其特征在于,所述方法包括:
    获取所述知识库中与当前接收的关键字相匹配的历史搜索记录,并计算所述历史搜索记录中的知识点的历史操作行为数据;
    计算所述知识库中每一条知识点的权值系数;
    根据所述权值系数以及所述知识点的历史操作行为数据,利用预设的算法,计算利用所述当前接收的关键字搜索到的每一条知识点的权值,并根据所述权值,将利用所述当前接收的关键字搜索到所有知识点进行排序呈现给用户。
  2. 如权利要求1所述的知识库搜索方法,其特征在于,所述获取所述知识库中与当前接收的关键字相匹配的历史搜索记录,并计算所述历史搜索记录中的知识点的历史操作行为数据,包括:
    接收用户输入到所述知识库的关键字,并对接收的关键字执行分词操作;
    获取所有用户在所述知识库的历史搜索记录,将所述历史搜索记录的关键字执行分词操作,并与当前接收的关键字进行匹配,以查找到与当前接收的关键字匹配的历史搜索记录;及
    计算所述历史搜索记录中的知识点的历史操作行为数据。
  3. 如权利要求2所述的知识库搜索方法,其特征在于,所述计算所述历史搜索记录中的知识点的历史操作行为数据包括:
    根据相匹配的历史搜索记录被执行的预设操作行为数据,统计每个相匹配的历史搜索记录中最后一条被执行预设操作行为的知识点;
    计算所述每个最后一条被执行预设操作行为的知识点占所有最后一条被执行预设操作行为的知识点的百分比;
    统计每个相匹配的历史搜索记录中除去最后一条知识点的其他条被执行预设操作行为的知识点;
    计算其中每一条被执行预设操作行为的知识点占所有被执行预设操作行为的知识点的百分比;
    其中,所述预设操作行为包括对所述历史搜索记录中的知识点的点击行为。
  4. 如权利要求1所述的知识库搜索方法,其特征在于,所述计算所述预设知识库中每一条知识点的权值系数,包括:
    获取所述预设知识库中的所有知识点;
    对每一条知识点中的所有内容按照预先确定的分词规则执行分词操作,得到每一条知识点中的文档分词;及
    计算每一条知识点以及其中的文档分词的一种或者多种权值系数。
  5. 如权利要求2所述的知识库搜索方法,其特征在于,所述计算所述预设知识库中每一条知识点的权值系数,包括:
    获取所述预设知识库中的所有知识点;
    对每一条知识点中的所有内容按照预先确定的分词规则执行分词操作,得到每一条知识点中的文档分词;及
    计算每一条知识点以及其中的文档分词的一种或者多种权值系数。
  6. 如权利要求3所述的知识库搜索方法,其特征在于,所述计算所述预设知识库中每一条知识点的权值系数,包括:
    获取所述预设知识库中的所有知识点;
    对每一条知识点中的所有内容按照预先确定的分词规则执行分词操作,得到每一条知识点中的文档分词;及
    计算每一条知识点以及其中的文档分词的一种或者多种权值系数。
  7. 如权利要求4-6任一项所述的知识库搜索方法,其特征在于,所述预设的算法为:
    Figure PCTCN2018123597-appb-100001
    其中:
    Nd为知识点的个数,i为第几个分词,n为共n个分词;
    Lbw为最后一次操作行为权重,是根据最后一条被执行预设操作行为的知识点占所有最后一条被执行预设操作行为的知识点的百分比预先设置的;
    Bw为操作行为权重,是根据每一条被执行预设操作行为的知识点占所有被执行预设操作行为的知识点的百分比预先设置的;及
    Tf、Idf、Tw、Fw、Kw及Norm为每一条知识点以及其中的文档分词的权值系数,分别代表所述每个知识点中的文档分词的词频、反词频、词权重以及位置权重,以及每一个知识点的知识权重、长度归一化因子。
  8. 一种知识库搜索装置,其特征在于,所述装置包括存储器和处理器,所述存储器上存储有可在所述处理器上运行的知识库搜索程序,所述知识库搜索程序被所述处理器执行时实现如下步骤:
    获取所述知识库中与当前接收的关键字相匹配的历史搜索记录,并计算所述历史搜索记录中的知识点的历史操作行为数据;
    计算所述知识库中每一条知识点的权值系数;
    根据所述权值系数以及所述知识点的历史操作行为数据,利用预设的算法,计算利用所述当前接收的关键字搜索到的每一条知识点的权值,并根据所述权值,将利用所述当前接收的关键字搜索到所有知识点进行排序呈现给用户。
  9. 如权利要求8所述的知识库搜索装置,其特征在于,所述获取所述知识库中与当前接收的关键字相匹配的历史搜索记录,并计算所述历史搜索记录中的知识点的历史操作行为数据,包括:
    接收用户输入到所述知识库的关键字,并对接收的关键字执行分词操作;
    获取所有用户在所述知识库的历史搜索记录,将所述历史搜索记录的关键字执行分词操作,并与当前接收的关键字进行匹配,以查找到与当前接收 的关键字匹配的历史搜索记录;及
    计算所述历史搜索记录中的知识点的历史操作行为数据。
  10. 如权利要求9所述的知识库搜索装置,其特征在于,统计每个相匹配的历史搜索记录中最后一条被执行预设操作行为的知识点;
    计算所述每个最后一条被执行预设操作行为的知识点占所有最后一条被执行预设操作行为的知识点的百分比;
    统计每个相匹配的历史搜索记录中除去最后一条知识点的其他条被执行预设操作行为的知识点;
    计算其中每一条被执行预设操作行为的知识点占所有被执行预设操作行为的知识点的百分比;
    其中,所述预设操作行为包括对所述历史搜索记录中的知识点的点击行为。
  11. 如权利要求8所述的知识库搜索装置,其特征在于,所述计算所述预设知识库中每一条知识点的权值系数,包括:
    获取所述预设知识库中的所有知识点;
    对每一条知识点中的所有内容按照预先确定的分词规则执行分词操作,得到每一条知识点中的文档分词;及
    计算每一条知识点以及其中的文档分词的一种或者多种权值系数。
  12. 如权利要求9所述的知识库搜索装置,其特征在于,所述计算所述预设知识库中每一条知识点的权值系数,包括:
    获取所述预设知识库中的所有知识点;
    对每一条知识点中的所有内容按照预先确定的分词规则执行分词操作,得到每一条知识点中的文档分词;及
    计算每一条知识点以及其中的文档分词的一种或者多种权值系数。
  13. 如权利要求10所述的知识库搜索装置,其特征在于,所述计算所述预设知识库中每一条知识点的权值系数,包括:
    获取所述预设知识库中的所有知识点;
    对每一条知识点中的所有内容按照预先确定的分词规则执行分词操作,得到每一条知识点中的文档分词;及
    计算每一条知识点以及其中的文档分词的一种或者多种权值系数。
  14. 如权利要求11-13任一项所述的知识库搜索装置,其特征在于,所述预设的算法为:
    Figure PCTCN2018123597-appb-100002
    其中:
    Nd为知识点的个数,i为第几个分词,n为共n个分词;
    Lbw为最后一次操作行为权重,是根据最后一条被执行预设操作行为的知识点占所有最后一条被执行预设操作行为的知识点的百分比预先设置的;
    Bw为操作行为权重,是根据每一条被执行预设操作行为的知识点占所有 被执行预设操作行为的知识点的百分比预先设置的;及
    Tf、Idf、Tw、Fw、Kw及Norm为每一条知识点以及其中的文档分词的权值系数,分别代表所述每个知识点中的文档分词的词频、反词频、词权重以及位置权重,以及每一个知识点的知识权重、长度归一化因子。
  15. 一种计算机可读存储介质,其特征在于,所述计算机可读存储介质上存储有知识库搜索程序,所述知识库搜索程序可被一个或者多个处理器执行,以实现如下步骤:
    获取所述知识库中与当前接收的关键字相匹配的历史搜索记录,并计算所述历史搜索记录中的知识点的历史操作行为数据;
    计算所述知识库中每一条知识点的权值系数;
    根据所述权值系数以及所述知识点的历史操作行为数据,利用预设的算法,计算利用所述当前接收的关键字搜索到的每一条知识点的权值,并根据所述权值,将利用所述当前接收的关键字搜索到所有知识点进行排序呈现给用户。
  16. 如权利要求15所述的计算机可读存储介质,其特征在于,所述获取所述知识库中与当前接收的关键字相匹配的历史搜索记录,并计算所述历史搜索记录中的知识点的历史操作行为数据,包括:
    接收用户输入到所述知识库的关键字,并对接收的关键字执行分词操作;
    获取所有用户在所述知识库的历史搜索记录,将所述历史搜索记录的关键字执行分词操作,并与当前接收的关键字进行匹配,以查找到与当前接收的关键字匹配的历史搜索记录;及
    计算所述历史搜索记录中的知识点的历史操作行为数据。
  17. 如权利要求16所述的计算机可读存储介质,其特征在于,统计每个相匹配的历史搜索记录中最后一条被执行预设操作行为的知识点;
    计算所述每个最后一条被执行预设操作行为的知识点占所有最后一条被执行预设操作行为的知识点的百分比;
    统计每个相匹配的历史搜索记录中除去最后一条知识点的其他条被执行预设操作行为的知识点;
    计算其中每一条被执行预设操作行为的知识点占所有被执行预设操作行为的知识点的百分比;
    其中,所述预设操作行为包括对所述历史搜索记录中的知识点的点击行为。
  18. 如权利要求15所述的计算机可读存储介质,其特征在于,所述计算所述预设知识库中每一条知识点的权值系数,包括:
    获取所述预设知识库中的所有知识点;
    对每一条知识点中的所有内容按照预先确定的分词规则执行分词操作,得到每一条知识点中的文档分词;及
    计算每一条知识点以及其中的文档分词的一种或者多种权值系数。
  19. 如权利要求16或17所述的计算机可读存储介质,其特征在于,所 述计算所述预设知识库中每一条知识点的权值系数,包括:
    获取所述预设知识库中的所有知识点;
    对每一条知识点中的所有内容按照预先确定的分词规则执行分词操作,得到每一条知识点中的文档分词;及
    计算每一条知识点以及其中的文档分词的一种或者多种权值系数。
  20. 如权利要求19项所述的计算机可读存储介质,其特征在于,所述预设的算法为:
    Figure PCTCN2018123597-appb-100003
    其中:
    Nd为知识点的个数,i为第几个分词,n为共n个分词;
    Lbw为最后一次操作行为权重,是根据最后一条被执行预设操作行为的知识点占所有最后一条被执行预设操作行为的知识点的百分比预先设置的;
    Bw为操作行为权重,是根据每一条被执行预设操作行为的知识点占所有被执行预设操作行为的知识点的百分比预先设置的;及
    Tf、Idf、Tw、Fw、Kw及Norm为每一条知识点以及其中的文档分词的权值系数,分别代表所述每个知识点中的文档分词的词频、反词频、词权重以及位置权重,以及每一个知识点的知识权重、长度归一化因子。
PCT/CN2018/123597 2018-09-19 2018-12-25 知识库搜索方法、装置及计算机可读存储介质 Ceased WO2020056979A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201811096202.5A CN109299235B (zh) 2018-09-19 2018-09-19 知识库搜索方法、装置及计算机可读存储介质
CN201811096202.5 2018-09-19

Publications (1)

Publication Number Publication Date
WO2020056979A1 true WO2020056979A1 (zh) 2020-03-26

Family

ID=65163532

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2018/123597 Ceased WO2020056979A1 (zh) 2018-09-19 2018-12-25 知识库搜索方法、装置及计算机可读存储介质

Country Status (2)

Country Link
CN (1) CN109299235B (zh)
WO (1) WO2020056979A1 (zh)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112035512A (zh) * 2020-09-02 2020-12-04 中国银行股份有限公司 知识库的检索方法、装置、电子设备及计算机存储介质
CN112541064A (zh) * 2020-12-09 2021-03-23 联仁健康医疗大数据科技股份有限公司 健康评测方法、装置、计算机设备及存储介质
CN113158091A (zh) * 2021-03-24 2021-07-23 北京奇艺世纪科技有限公司 一种召回方法、装置、电子设备及存储介质
CN114547469A (zh) * 2022-03-07 2022-05-27 北京高途云集教育科技有限公司 知识点反馈方法、装置、设备以及存储介质
CN116166780A (zh) * 2022-12-30 2023-05-26 深圳云天励飞技术股份有限公司 数据搜索方法、装置及存储介质

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110046177A (zh) * 2019-04-24 2019-07-23 北京思特奇信息技术股份有限公司 一种知识提取的方法、系统、存储介质及计算机设备
CN111259129B (zh) * 2020-01-19 2024-04-30 中国平安人寿保险股份有限公司 数据报表搜索方法、装置、电子设备及存储介质
CN112163066B (zh) * 2020-09-08 2023-12-05 天讯瑞达通信技术有限公司 人工智能模型训练方法、知识点推送方法、装置和介质
CN115269666A (zh) * 2022-07-27 2022-11-01 中国银行股份有限公司 一种知识搜索方法及装置、存储介质及电子设备

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101996215A (zh) * 2009-08-27 2011-03-30 阿里巴巴集团控股有限公司 一种应用于电子商务网站的信息匹配方法和系统
CN102591969A (zh) * 2011-12-31 2012-07-18 北京百度网讯科技有限公司 基于用户历史行为提供搜索结果的方法及服务器
CN104123332A (zh) * 2014-01-24 2014-10-29 腾讯科技(深圳)有限公司 搜索结果的显示方法及装置
CN108335137A (zh) * 2018-01-31 2018-07-27 北京三快在线科技有限公司 排序方法及装置、电子设备、计算机可读介质
US20180218087A1 (en) * 2017-01-31 2018-08-02 Wal-Mart Stores, Inc. Systems and methods for webpage personalization

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108038096A (zh) * 2017-11-10 2018-05-15 平安科技(深圳)有限公司 知识库文档快速检索方法、应用服务器计算机可读存储介质
CN107885874B (zh) * 2017-11-28 2020-09-29 上海智臻智能网络科技股份有限公司 数据查询方法和装置、计算机设备及计算机可读存储介质

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101996215A (zh) * 2009-08-27 2011-03-30 阿里巴巴集团控股有限公司 一种应用于电子商务网站的信息匹配方法和系统
CN102591969A (zh) * 2011-12-31 2012-07-18 北京百度网讯科技有限公司 基于用户历史行为提供搜索结果的方法及服务器
CN104123332A (zh) * 2014-01-24 2014-10-29 腾讯科技(深圳)有限公司 搜索结果的显示方法及装置
US20180218087A1 (en) * 2017-01-31 2018-08-02 Wal-Mart Stores, Inc. Systems and methods for webpage personalization
CN108335137A (zh) * 2018-01-31 2018-07-27 北京三快在线科技有限公司 排序方法及装置、电子设备、计算机可读介质

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112035512A (zh) * 2020-09-02 2020-12-04 中国银行股份有限公司 知识库的检索方法、装置、电子设备及计算机存储介质
CN112035512B (zh) * 2020-09-02 2023-08-18 中国银行股份有限公司 知识库的检索方法、装置、电子设备及计算机存储介质
CN112541064A (zh) * 2020-12-09 2021-03-23 联仁健康医疗大数据科技股份有限公司 健康评测方法、装置、计算机设备及存储介质
CN113158091A (zh) * 2021-03-24 2021-07-23 北京奇艺世纪科技有限公司 一种召回方法、装置、电子设备及存储介质
CN114547469A (zh) * 2022-03-07 2022-05-27 北京高途云集教育科技有限公司 知识点反馈方法、装置、设备以及存储介质
CN116166780A (zh) * 2022-12-30 2023-05-26 深圳云天励飞技术股份有限公司 数据搜索方法、装置及存储介质

Also Published As

Publication number Publication date
CN109299235B (zh) 2023-04-25
CN109299235A (zh) 2019-02-01

Similar Documents

Publication Publication Date Title
WO2020056979A1 (zh) 知识库搜索方法、装置及计算机可读存储介质
US20210319032A1 (en) Systems and methods for contextual retrieval and contextual display of records
KR101644817B1 (ko) 탐색 결과들을 생성하는 방법
US10169449B2 (en) Method, apparatus, and server for acquiring recommended topic
WO2020237856A1 (zh) 基于知识图谱的智能问答方法、装置及计算机存储介质
CN110390094B (zh) 对文档进行分类的方法、电子设备和计算机程序产品
US8949227B2 (en) System and method for matching entities and synonym group organizer used therein
WO2020140373A1 (zh) 一种意图识别方法、识别设备及计算机可读存储介质
WO2019091026A1 (zh) 知识库文档快速检索方法、应用服务器及计算机可读存储介质
CN111680152B (zh) 目标文本的摘要提取方法及装置、电子设备、存储介质
CN103688260B (zh) 在实体解析系统中搜索实体的方法、计算机系统和装置
US8793120B1 (en) Behavior-driven multilingual stemming
CN111414375A (zh) 基于数据库查询的输入推荐方法、电子装置及存储介质
WO2021052148A1 (zh) 基于人工智能的合同敏感词校验方法、装置、计算机设备及存储介质
CN113609847B (zh) 信息抽取方法、装置、电子设备及存储介质
CN113127621A (zh) 对话模块的推送方法、装置、设备及存储介质
CN112199588A (zh) 舆情文本筛选方法及装置
CN111369148A (zh) 对象指标的监测方法、电子装置及存储介质
WO2023151576A1 (zh) 搜索推荐方法、搜索推荐系统、计算机设备及存储介质
CN111339166A (zh) 基于词库的匹配推荐方法、电子装置及存储介质
CN113190649A (zh) 基于ElasticSearch的企业名称搜索匹配方法及装置
CN110851560B (zh) 信息检索方法、装置及设备
CN110909130B (zh) 文本主题提取分析方法、装置及计算机可读存储介质
CN119782590A (zh) 基于大模型的问答处理方法、装置、电子设备及存储介质
CN112597287A (zh) 一种语句处理方法、语句处理装置及智能设备

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 18933826

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 18933826

Country of ref document: EP

Kind code of ref document: A1