Search system and search method

JP7558910B2Active Publication Date: 2024-10-01KK TOSHIBA
View PDF 9 Cites 0 Cited by

Patent Information

Application Number
JP2021145603
Authority / Receiving Office
JP · JP
Patent Type
Patents
Current Assignee / Owner
Filing Date
2021-09-07
Publication Date
2024-10-01
Estimated Expiration
2041-09-07

Smart Images

  • Figure 0007558910000001
    Figure 0007558910000001
  • Figure 0007558910000002
    Figure 0007558910000002
  • Figure 0007558910000003
    Figure 0007558910000003
Patent Text Reader

Abstract

To provide a retrieval device and a retrieval method for outputting information necessary for a user.SOLUTION: A retrieval device of an embodiment includes: storage means which stores a plurality of first document vectors respectively regarding a plurality of software components; generation means which receives retrieval phrases containing a first word indicating execution environments of the software components and second words indicating functions of the software components, and generates a plurality of second document vectors based on respective combinations of the first word and the plurality of second words; retrieval means which retrieves document vector combinations from the plurality of first document vectors on the basis of a plurality of similarities between the plurality of second document vectors and the plurality of first document vectors; and output means which outputs software component combination information indicating a plurality of software components regarding the document vector combinations.SELECTED DRAWING: Figure 5
Need to check novelty before this filing date? Find Prior Art

Description

[Technical field]

[0001] An embodiment of the present invention is a search system and a search method. [Background technology]

[0002] The search device determines the degree of similarity between a search term input by a user and a large amount of information, and outputs information with a high degree of similarity as a search result. [Prior art documents] [Patent documents]

[0003] [Patent Document 1] JP 2001-14154 A [Patent Document 2] International Publication No. 2016 / 151865 Summary of the Invention [Problem to be solved by the invention]

[0004] In conventional search devices, there are cases where information with a high degree of similarity found based on a search phrase is not necessarily the information that a user needs.

[0005] The object of the present invention is to provide a search engine that outputs the information required by the user. system and to provide a search method. [Means for solving the problem]

[0006] Search by embodiment systemthe system includes a storage means for storing a plurality of first document vectors relating to each of a plurality of software components; a generation means for receiving a search term including a first word representing an execution environment of the software component and a plurality of second words representing a function of the software component, and generating a plurality of second document vectors based on each combination of the first word and the plurality of second words; a search means for searching for document vector combinations from the plurality of first document vectors based on a plurality of similarities between the plurality of second document vectors and the plurality of first document vectors; and an output means for outputting software component combination information representing a plurality of software components relating to the document vector combinations. [Brief description of the drawings]

[0007] [Figure 1] FIG. 2 is a block diagram showing an example of hardware of the search system according to the first embodiment. [Diagram 2] FIG. 2 is a functional block diagram showing an example of a terminal device and a search device in the search system. [Diagram 3] FIG. 4 is a diagram showing an example of a screen configuration of a display device of a terminal device. [Figure 4] FIG. 4 is a diagram showing an example of a display screen of a terminal device. [Diagram 5] FIG. 11 is a diagram showing another example of the display screen of the terminal device. [Figure 6] FIG. 11 is a diagram showing another example of the display screen of the terminal device. [Figure 7] FIG. 11 is a diagram showing another example of the display screen of the terminal device. [Figure 8] FIG. 11 is a diagram showing another example of the display screen of the terminal device. [Figure 9] FIG. 11 is a diagram showing another example of the display screen of the terminal device. [Figure 10] FIG. 11 is a diagram showing another example of the display screen of the terminal device. [Figure 11] FIG. 11 is a diagram showing another example of the display screen of the terminal device. [Figure 12] FIG. 4 is a diagram showing an example of data stored in a database. [Figure 13] 11 is a flowchart showing an example of a process of a software component document vector generation unit. [Figure 14] 13 is a diagram showing an example of a management table stored in a software component document vector management unit. [Figure 15] 11 is a flowchart showing an example of a process of a query generating unit. [Figure 16] 11 is a flowchart showing an example of a process of a similarity evaluation unit. [Figure 17] 13 is a diagram showing another example of the management information managed by the software component document vector management unit. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

[0008] Hereinafter, the embodiments will be described with reference to the drawings. The following description is an example of an apparatus and a method for embodying the technical idea of ​​the embodiment, and the technical idea of ​​the embodiment is not limited to the structure, shape, arrangement, material, etc. of the components described below. Modifications that a person skilled in the art can easily conceive are naturally included in the scope of the disclosure. In order to make the description clearer, the size, thickness, planar dimensions, or shape of each element may be changed from the actual embodiment and shown diagrammatically. Elements having different dimensional relationships or ratios may be included in multiple drawings. In multiple drawings, corresponding elements may be given the same reference numerals and duplicated descriptions may be omitted. Some elements may be given multiple names, but these examples of names are merely examples and do not deny the use of other names for these elements. Elements not given multiple names may also be given other names. In the following description, "connection" means not only direct connection but also connection via other elements.

[0009] Hereinafter, the present embodiment will be described in detail with reference to the drawings. FIG. 1 is a block diagram showing an example of hardware of a search system according to a first embodiment. The search system includes a terminal device 10, a search device 30, and a database 50. The terminal device 10 inputs search conditions and displays search results transmitted from the search device 30. The terminal device 10 is connected to the search device 30 via a network. The search device 30 searches the database 50 based on the search conditions, searches for data based on the search conditions, and transmits the searched data to the terminal device 10 as search results. The search device 30 is also called a server. The terminal device 10 is also called a client. The terminal device 10 may not be an external device of the search device 30, but may be a device built into the search device 30. The database 50 may also be a device built into the search device 30, but may not be an external device of the search device 30.

[0010] Any type of data may be searched. In this specification, the search device 30 searches for software as an example of data. In recent years, general-purpose hardware has been controlled by software to realize a wide variety of functions. In order to improve the efficiency of software development, the use of open source software (OSS), which makes software source code publicly available and allows use of the source code, is being considered. With OSS, a mechanism for efficiently searching for software is desired.

[0011] The search system according to the embodiment provides such a mechanism. Software may be developed using multiple pieces of software. Therefore, in this specification, the units constituting the software are referred to as software components (hereinafter referred to as SW components), the search target is referred to as SW components, and the database 50 stores a large number of SW components. Examples of the database 50 are software repositories (GitHub, etc.) and package manager repositories. These are known for each programming language, such as Perl (cpan.org), Python (pypi.org), JavaScript (registered trademark) (npmjs.com), and JAVA (registered trademark) (mvnrepository.com), and for each distribution (an integration of an operating system (OS), a library, and software).

[0012] The terminal device 10 transmits search conditions including search terms that specify the execution environment, functions, etc. of the SW component to the search device 30. Examples of the execution environment are the operating OS, the implementation language, the type of CPU, the type of board on which the CPU is mounted (whether it is an embedded device or not, etc.), and the framework (one that runs on a virtual machine, for mobile use, one that runs on the cloud). Examples of the functions are authentication and approval.

[0013] The terminal device 10 includes an input device 12, a display device 14, a CPU 16, a communication device 18, and a memory 20. The input device 12 is a keyboard, a mouse, etc. The input device 12, the display device 14, the CPU 16, the communication device 18, and the memory 20 are connected to a bus line 22. The CPU 16 executes a program stored in the memory 20 to realize a plurality of functions of the terminal device 10.

[0014] The retrieval device 30 includes a CPU 32, a storage device 34, and a communication device 36. The CPU 32, the storage device 34, and the communication device 36 are connected to a bus line 38. The CPU 32 executes a program stored in the storage device 34 to realize a plurality of functions of the retrieval device 30. The terminal device 10 and the retrieval device 30 communicate data with each other via the communication devices 18, 36.

[0015] The database 50 is connected to the communication device 36. The storage device 34 of the search device 30 may store the SW parts without providing the database 50. Furthermore, the storage device 34 may store some of the SW parts, and the database 50 may store the remaining SW parts. Although not shown, the database 50 also includes a communication device, and the search device 30 and the database 50 communicate data with each other.

[0016] FIG. 2 is a functional block diagram of the terminal device 10 and the search device 30. As shown in FIG. The CPU 16 of the terminal device 10 functions as a search term input unit 102, a search option input unit 104, a search condition transmission unit 106, a search result / search option display unit 108, and a search history reading unit 110. The search options are information that restricts the search or information that changes the display mode of the search results. The details of the search options will be described later, but one example is information that specifies whether the search targets are individual SW parts or combinations of SW parts. For example, when the search conditions include multiple functions, the search device 30 may be configured to search for individual SW parts that include all of the multiple functions, or may be configured to search for combinations of multiple SW parts that each include the multiple functions.

[0017] The search term input unit 102 displays the search term input by the user using the input device 12 on the display device 14, and transmits the search term to the search condition transmission unit 106. The search option input unit 104 displays the search options input by the user using the input device 12 on the display device 14, and transmits the search options to the search condition transmission unit 106. The search condition transmission unit 106 transmits the search term and the search options to the search device 30 as search conditions.

[0018] The search result / search option display unit 108 displays the search results and search options sent from the search device 30 on the display device 14 .

[0019] The search history reading unit 110 reads the history of search results (search history) from the search device 30 , and transmits the search history to the search term input unit 102 and the search option input unit 104 .

[0020] The CPU 32 of the search device 30 functions as a search condition receiving unit 121, a search condition evaluation unit 122, a software component document vector generation unit (SW component document vector generation unit) 124, a software component document vector management unit (SW component document vector management unit) 126, a similarity evaluation unit 128, and a search history management unit 130.

[0021] A search is a search for SW parts that match or are similar to search conditions specified by a user from among a set of SW parts. The user can specify using a search option whether the search device 30 searches for a single SW part that matches or is similar to the search conditions, or searches for a combination of SW parts that match or are similar to the search conditions.

[0022] Various criteria can be used as a criterion for determining whether a document matches or is similar to a search condition. In the embodiment, an example will be described in which vector similarity between a document vector related to the search condition and a document vector related to a SW part is used as a criterion. The vector similarity may be calculated using cosine similarity.

[0023] The SW part document vector generation unit 124 extracts words (candidates for characteristic words) that represent characteristics of SW parts from documents related to multiple SW parts and / or attributes of the SW parts themselves stored in the database 50. The SW part document vector generation unit 124 determines characteristic words from among words using a TF (Term Frequency)-IDF (Inverse Document Frequency) method based on the frequency of word appearance, etc., and generates multiple SW part document vectors each consisting of the characteristic words.

[0024] The SW part document vector management unit 126 manages the SW part document vectors generated by the SW part document vector generation unit 124. Specifically, the SW part document vector management unit 126 stores a plurality of SW part document vectors for each of a plurality of SW parts. The SW part document vector management unit 126 transmits the plurality of SW part document vectors to the similarity evaluation unit 128.

[0025] The search condition receiving unit 121 receives the search conditions transmitted from the search condition transmitting unit 106. The search condition receiving unit 121 transmits the search terms and search options included in the received search conditions to the search condition evaluation unit 122. The search condition receiving unit 121 transmits the search options to the similarity evaluation unit 128.

[0026] The search condition evaluation unit 122 extracts characteristic words from the search term transmitted from the search condition receiving unit 121, and generates one query or multiple queries based on the characteristic words according to the search option transmitted from the search condition receiving unit 121. When the search option selects a single SW part, the search condition evaluation unit 122 generates one query for a single SW part search including all characteristic words included in the search term. When the search option selects a combination of SW parts, the search condition evaluation unit 122 generates multiple queries for a SW part combination search including combinations of multiple characteristic words included in the search term. The search condition evaluation unit 122 transmits the one query or multiple queries to the similarity evaluation unit 128.

[0027] The similarity evaluation unit 128 extracts characteristic words from the query transmitted from the search condition evaluation unit 122, and generates a query document vector by the TF-IDF method based on the frequency of the characteristic words, etc. The similarity evaluation unit 128 calculates the vector similarity between the query document vector and the SW part document vector transmitted from the SW part document vector management unit 126, and searches for a SW part document vector whose vector similarity to the query document vector is equal to or greater than a certain value.

[0028] When the search option transmitted from the search condition receiving unit 121 selects single SW part, the similarity evaluation unit 128 receives one query and searches for at least one SW part document vector similar to one query document vector generated from one query. The similarity evaluation unit 128 transmits single SW part information representing at least one single SW part related to at least one SW part document vector to the terminal device 10 as a search result. The at least one single SW part information is displayed in order of high similarity on the terminal device 10.

[0029] When the search option transmitted from the search condition receiving unit 121 selects a combination of SW parts, the similarity evaluation unit 128 searches for at least one SW part document vector combination consisting of multiple SW part document vectors similar to each of multiple query document vectors generated from multiple queries. The similarity evaluation unit 128 transmits SW part combination information representing at least one SW part combination related to at least one SW part document vector combination to the terminal device 10 as a search result. The terminal device 10 displays at least one SW part combination information in order of high similarity.

[0030] The similarity evaluation unit 128 also transmits the search results to the search history management unit 130. The search history management unit 130 stores the search history. The search history stored in the search history management unit 130 is read by the search history reading unit 110. The search history reading unit 110 obtains candidates for search terms and search options according to the search history, and displays the candidates on the display device 14. This improves the efficiency of inputting search terms and search options.

[0031] The search system searches for SW components based on vector similarity, but since the number of search targets becomes huge when searching for a combination of SW components, it may be processed as a combinatorial optimization problem. In other words, it may be processed as searching for the number of combinations of SW components to be used while maximizing or minimizing a certain index under some constraint condition. An example of a constraint condition is resources. Resources are not limited to simple hardware resources or software resources, but also include expected development man-hours, release timing, binary size (which affects the footprint at the time of installation), memory consumption, and the number of SW components to be combined. Under the constraint condition that the amount of resources does not exceed a certain amount, it may be possible to search for a single SW component or a combination of SW components or a single combination that maximizes the vector similarity by document vectors.

[0032] Explain search options. Assume that the terminal device 10 does not include the search option input unit 104, and the search condition evaluation unit 122 of the search device 30 generates one query for a single SW part search, and does not generate multiple queries for a SW part combination search. In this case, the search device 30 searches for at least one SW part document vector having a high vector similarity with the query document vector, i.e., at least one SW part document vector including all feature words included in the query document vector. SW part single information representing at least one SW part related to each of the at least one SW part document vector is displayed in order of high similarity. The user can select one SW part from the at least one SW part.

[0033] However, when a user develops software that realizes multiple functions, there are cases where the user would prefer to develop the software using a combination of multiple SW components that each realize a number of functions, rather than using a single SW component that realizes the multiple functions.

[0034] In addition, the search results may include SW components that have never been used or that have hardly been updated since their release. When developing software, users may want to select SW components not only by simply implementing multiple functions, but also by considering whether they have been used frequently.

[0035] Furthermore, when calculating the vector similarity between a query document vector and a SW part document vector, it may be desirable to weight feature terms in the vector.

[0036] In order to indicate such user intentions that cannot be expressed by search terms to the search device 30, the terminal device 10 has a search option input unit 104. Examples of search options include selection of the type of search target, whether to search for a single SW component or a combination of SW components, narrowing down the search target based on usage history and update history, and weighting of feature words when calculating vector similarity. Usage history includes whether security has been implemented, whether operation has been thoroughly tested, whether it has already been incorporated into a product, etc.

[0037] 3 shows an example of a screen configuration of the display device 14 of the terminal device 10. The screen of the display device 14 includes a search term area 202, a search result area 204, and a search option area 206. The search term area 202 displays search terms when the user inputs the search terms. The search result area 204 displays search results by the search device 30. The search option area 206 displays search options when the user inputs the search options.

[0038] The search system extracts characteristic words from information related to SW components registered in the database 50, and generates a SW component document vector. Specifically, the SW component document vector generation unit 124 extracts characteristic words related to the description of the SW component, keywords entered by the person registrating the SW component when registering it, the program language, implementation function, execution environment, implementation form (how the SW component is used), usage history, evaluation, etc., contained in the source code etc. registered as the SW component, and generates a SW component document vector according to the frequency of the characteristic words.

[0039] An example of a SW component description is, "This software has authentication and payment functions, is a mobile application, was released on XX, and was last updated on XX. The operating environment for this software is operating system: OS1, implementation language: JAVA, and CPU: CPU1." Examples of feature words to be extracted are OS1, JAVA, CPU1, authentication, and payment.

[0040] The search condition evaluation unit 122 extracts characteristic words (for example, OS1, authentication, payment) from the search phrase, and generates a query from the characteristic words depending on whether the search target is a single SW component or a combination of SW components.

[0041] The search system can specify a search option. When the search option is specified before the vector similarity calculation, the similarity evaluation unit 128 calculates the vector similarity taking the search option into account. The search option can also be specified or changed after the vector similarity calculation. When the search option is specified or changed after the vector similarity calculation, the similarity evaluation unit 128 recalculates the vector similarity taking the search option into account.

[0042] 4 to 11, examples of changes in the screen of the display device 14 of the terminal device 10 according to user operations are shown. In Fig. 4 to 7, the search option is a selection of the type of single item / combination. In Fig. 8 to 11, the search option is a selection of the type of single item / combination and feature word control information.

[0043] 4 shows an example of the screen of the display device 14 when the user inputs a search term including the words function a (e.g., authentication), operating system type (e.g., OS1), and function b (e.g., payment) in the search term area 202 and selects "single item" as the type selection 212 in the search option area 206. The example in FIG. 4 shows a case where the user inputs a search term in units of words, but the user may also input a sentence including words.

[0044] A user inputs a search term including characteristic words specifying the execution environment (type of operating system, etc.) and realized functions (authentication, payment, etc.) of the SW component he / she requires in the search term area 202. A characteristic word expressing the execution environment is called a common characteristic word, and a word expressing a function is called a functional characteristic word. A common characteristic word is a word that, when three or more words are input as a search term, is likely to be usable in a search in combination with each of the other two or more words.

[0045] The common feature words may be classified into categories by automatic means or by settings made by the user of the terminal device 10 or the operator of the search device 30. An example of the automatic means is a natural language processing technique such as machine learning.

[0046] Examples of categories of common characteristic words include operating system, implementation language, CPU, type of board equipped with the CPU (e.g. whether it is an embedded device or not), framework (one that runs on a virtual machine, for mobile use, one that runs on the cloud), release timing (any combination or all combinations may be selectable), and adoption history (any combination, all combinations, or individual SW components may be selectable).

[0047] Examples of functional feature words are authentication (also synonymous with authentication) and payment (also synonymous with payment). Names of technical specifications such as Oauth and RFC6749 are also functional feature words.

[0048] The search condition evaluation unit 122 extracts words included in the search conditions and determines whether the words are common characteristic words or functional characteristic words. Since the search option type selection 212 selects "single item," the search condition evaluation unit 122 generates one query (function a, OS1, function b) that includes all common characteristic words and functional characteristic words, i.e., function a, OS1, and function b.

[0049] The similarity evaluation unit 128 generates one query document vector from one query, searches for at least one SW part document vector whose vector similarity with the query document vector is equal to or greater than a certain level, and transmits to the terminal device 10 single item information representing at least one SW part related to the at least one SW part document vector found.

[0050] In the search result area 204, individual item information (SW part names and descriptions) 214a, 214b, ... regarding individual SW parts (SW part A, SW part B, ...) that match or are similar to all of the characteristic words function a, OS1, and function b are displayed in order of highest vector similarity.

[0051] FIG. 5 shows an example of the screen of the display device 14 when the user inputs a search term including function a, OS1, and function b in the search term area 202 and selects a combination as the type selection 212 in the search option area 206.

[0052] Since the type selection 212 selects combination, the search condition evaluation unit 122 generates two queries including the common characteristic word and each of the multiple functional characteristic words. That is, the search condition evaluation unit 122 generates a first query including OS1 and function a, and a second query including OS1 and function b.

[0053] The similarity evaluation unit 128 generates first and second query document vectors from the first and second queries, respectively. The similarity evaluation unit 128 searches for at least one first SW part document vector whose vector similarity with the first query document vector is equal to or greater than a certain similarity. The similarity evaluation unit 128 searches for at least one second SW part document vector whose vector similarity with the second query document vector is equal to or greater than a certain similarity. The similarity evaluation unit 128 transmits combination information representing at least one SW part combination related to a combination of at least one first SW part document vector and at least one second part document vector to the terminal device 10.

[0054] The search result area 204 displays combination information (combined SW part names and descriptions) 216a, 216b, ... relating to combinations of SW parts (SW part A, SW part C, ...) that match or are similar to the common characteristic word OS1 and the functional characteristic word function a, and SW parts (SW part B, SW part D, ...) that match or are similar to the common characteristic word OS1 and the functional characteristic word function b, in order of highest vector similarity.

[0055] The display order of the SW parts in each of the combination information 216a and 216b is the order (from the top) of the SW parts that realize the functions corresponding to the feature words in the order input as search terms. FIG. 6 shows another example of the screen of the display device 14 when the user inputs a search term including function a, OS1, and function b in the search term area 202 and selects a combination as the type selection 212 in the search option area 206. In FIG.

[0056] The search result area 204 displays combination information (combined part names and descriptions) 218a, 218b, ... relating to combinations of SW parts (SW part A, SW part C, ...) that match or are similar to the common characteristic word OS1 and the functional characteristic word function a, and SW parts (SW part B, SW part D, ...) that match or are similar to the common characteristic word OS1 and the functional characteristic word function b, in order of highest vector similarity.

[0057] Figures 5 and 6 both show display examples when the search results are combinations of SW components. The difference between Figures 5 and 6 is that Figure 5 shows a display example of a combination of SW components that are in a parallel dependent relationship (also called a usage relationship) with a certain SW component, while Figure 6 shows a display example of a combination of SW components that are in a subordinate dependent relationship, such as a certain SW component being in a dependent relationship with another SW component, and yet another SW component being in a dependent relationship with the other SW component. Search results rarely contain only one combination of either one, and in reality the display examples of Figures 5 and 6 are mixed together.

[0058] A combination of dependent SW components is a combination of two SW components in which one SW component calls the other SW component, causes the other SW component to execute a certain process, and reads the results of the other SW component's process, like the import statement in JAVA. In contrast, when multiple SW components operate independently, the combination of these SW components is called a parallel combination.

[0059] FIG. 7 shows an example of the screen of the display device 14 when the user inputs a search term including function a, OS1, and function b in the search term area 202 and selects both single item and combination as the type selection 212 in the search option area 206.

[0060] In the search result area 204, combination information (combined parts name and description) 218a, 218b, ... relating to the combination of SW parts (SW part A, SW part C, ...) that match or are similar to OS1 and function a and SW parts (SW part B, SW part D, ...) that match or are similar to OS1 and function b, and single part information (part name and description) 218c, 218d, ... relating to single SW parts (SW part E, SW part F, ...) that match or are similar to all of OS1, function a, and function b are displayed in descending order of vector similarity. Note that when both single parts and combinations are selected as the type selection 212, the combination information and single part information are displayed in the order according to the similarity, so that only combination information or only single part information may be displayed.

[0061] Figures 8 to 11 show examples of display when control information regarding feature words is added to the search options. Although feature word control information can be added to any of Figures 4 to 7, an example in which feature word control information is added to the display example of Figure 7 is explained as an example.

[0062] 8 shows an example where the search option area 206 displays feature word control information 222 in addition to the type selection 212. The feature word control information 222 includes three feature word icons, namely OS1, function a, and function b, which are input as search terms, an up icon, and a down icon. The three feature word icons are arranged vertically.

[0063] When the search option type selection 212 selects combination, the search condition evaluation unit 122 generates two queries including a combination of a common characteristic word and a functional characteristic word from the search phrase. That is, the search condition evaluation unit 122 generates a query including a combination of OS1 and function a, and a query including a combination of OS1 and function b, and transmits the two generated queries to the similarity evaluation unit 128.

[0064] When the search option type selection 212 selects combination, the similarity evaluation unit 128 detects that OS1 has been recognized as a common characteristic word from the two queries, and transmits to the search result / search option display unit 108 that OS1 has been recognized as a common characteristic word.

[0065] In the characteristic word control information 222 of the search option area 206, the icon of OS1 recognized as a common characteristic word is displayed in the top row, and from the next row onwards, icons of functional characteristic words, i.e., the icon of function a and the icon of function b, are displayed in the order in which they were entered as search terms.

[0066] If the user wants to set a search condition with function a as the common characteristic word instead of OS1, the user can operate the up icon or down icon to display the icon of function a in the top row. In other words, the user can change the common characteristic word from OS1 to function a. When the display order of the information in the characteristic word control information 222 is changed to function a, OS1, function b, the display in the search result area 204 is changed so that OS1 is subordinate to function 2, and function b is subordinate to OS1.

[0067] The user's operation on the feature word control information 222 in the search option area 206 is transmitted from the search option input unit 104 to the search condition evaluation unit 122 and the similarity evaluation unit 128 via the search condition transmission unit 106. For this reason, the search condition evaluation unit 122 generates, from the search phrase, a query including a combination of function a and OS1 and a query including a combination of function a and function b, and transmits the two generated queries to the similarity evaluation unit 128. This enables the search device 30 to execute the search again and output search results in accordance with the user's intention.

[0068] The three characteristic word icons may be arranged in the left-right direction. In this case, a right-pointing icon is displayed instead of the upward icon, and a left-pointing icon is displayed instead of the downward icon. The characteristic word icon recognized as a common characteristic word is displayed at the leftmost or rightmost position. If the user wishes to change this recognition result, the user can operate the right-pointing icon or the left-pointing icon to display the icon of the characteristic word that the user wishes to set as a common characteristic word at the rightmost or leftmost position.

[0069] FIG. 9 shows an example where the search option area 206 displays feature word control information 224 in addition to the type selection 212. The feature word control information 224 is different from the feature word control information 222 in FIG. 8 in that a weight / constraint condition field is added under each feature word icon of the feature word control information 222. The weight / constraint condition field may be a slide bar or a field where data is directly input. For example, a slide bar for specifying a weight is displayed under the feature word icon of OS1 and the feature word icon of function a. An input field for constraint conditions is displayed under the feature word icon of function b. The weight is a weight that is multiplied by the feature word when calculating the vector similarity between the query document vector and the SW part document vector. The constraint condition is information for narrowing down the search target for which the similarity evaluation unit 128 calculates the vector similarity with the query document vector. Examples of constraint conditions are information on quality such as the degree of document maintenance and the level of commit activity, information on the level of usage history, and the release date of the software. For example, the constraint for function b is that the release date is after January 1, 2021.

[0070] The similarity evaluation unit 128 calculates the vector similarity between the query document vector and the SW part document vector based on the weights and constraint conditions, so that the search device 30 can output search results in accordance with the user's intention.

[0071] 10 shows an example where the search option area 206 displays feature word control information 226A in addition to the type selection 212. The feature word control information 226A is different from the feature word control information 224 in FIG. 9 in that a connecting line (dashed line) indicating how the feature word icons are grouped (tree structure) is added to the feature word control information 224.

[0072] 10, "single item" is selected as the type selection 212 in the search option area 206. When the search option type selection 212 selects "single item", the search condition evaluation unit 122 transmits a query including all of the function a, OS1, and function b input as search terms to the similarity evaluation unit 128. The similarity evaluation unit 128 transmits the search options transmitted from the search condition transmission unit 106 of the terminal device 10 to the search result / search option display unit 108 of the terminal device 10.

[0073] The search result / search option display unit 108 displays dashed lines indicating that the characteristic word icon OS1, the characteristic word icon function a, and the characteristic word icon function b are connected in series in the characteristic word control information 226A of the search option area 206. This means that the type selection of the search option selected single item, and the search device 30 searched for single SW parts that match or are similar to all of OS1, function a, and function b.

[0074] If the user wants to search for a combination of SW parts rather than a single item, the user uses the input device (e.g., a mouse) 12 to change the tree structure of the characteristic word icons in the characteristic word control information 226A so that it becomes multiple trees with the common characteristic word as the root and each of the multiple functional characteristic words as leaves, as shown in Figure 11.

[0075] The characteristic word control information 226B in Fig. 11 displays two trees: one tree with the characteristic word icon OS1 as the root and the characteristic word icon function a as the leaf, and another tree with the characteristic word icon OS1 as the root and the characteristic word icon function b as the leaf. With this change in the tree structure, the type selection 212 in the search option area 206 is changed from single item to combination.

[0076] FIG. 12 shows an example of data stored in the database 50. The database 50 stores information about SW parts to be searched. The search system provider may create the database 50, or a database specialist provider other than the search system provider may create the database 50. The database 50 stores a SW part catalog 142, a SW part repository 144, and deliverable management data 146. The SW part catalog 142 includes license information, vulnerability information, intellectual property-related information such as copyrights and patents, export control information, etc. The SW part repository 144 includes source code, related documents such as instructions, binary code, etc. The deliverable management data 146 includes software reputation, etc.

[0077] Other examples of data stored in the database 50 include data collected by crawling information on SW component websites, information posted in SW component distribution repositories, and the like.

[0078] FIG. 13 is a flowchart showing an example of the process of the SW part document vector generation unit 124. In S302, the SW part document vector generation unit 124 selects one SW part from among the SW parts stored in the database 50 for which a document vector has not been created.

[0079] In S304, the SW part document vector generation unit 124 extracts characteristic words related to the selected SW part from the data in the SW part catalog 142, the SW part repository 144, and the deliverable management data 146.

[0080] In S306, the SW part document vector generation unit 124 generates a pseudo document d by linking the feature words, and generates a SW part document vector TF-IDF(t, d) from the document d by the TF-IDF method.

[0081] TF-IDF(t,d)=TF(t,d)·IDF(t) Equation 1 Where: TF(t,d) is the number of feature words t contained in document d. IDF(t) is log(total documents D / number of documents containing feature term t).

[0082] The SW part document vector generation unit 124 transmits the SW part document vector to the SW part document vector management unit 126 in S308.

[0083] In S310, the SW part document vector generation unit 124 determines whether or not there is an instruction to stop document vector generation, and if there is an instruction, ends the process, and if there is no instruction, executes the process from S302 again.

[0084] Fig. 14 shows an example of a management table stored in the SW part document vector management unit 126. The SW part document vector management unit 126 stores a feature word / IDF table (Fig. 14(a)) that manages the IDF value for each feature word (common feature word and functional feature word). The SW part document vector generation unit 124 creates the feature word / IDF table when calculating a SW part document vector. The SW part document vector management unit 126 also stores a SW part ID / document vector table (Fig. 14(b)) that manages SW part document vectors for each SW part. The SW part document vector management unit 126 also stores a word / feature word table (Fig. 14(c)) that indicates the correspondence between words and feature words (common feature words and functional feature words). The word / feature word table is stored in advance in the search device 30 as a dictionary. The word / feature word table associates similar words with the same feature word. Similar words are words that have the same meaning but are spoken in different languages, such as authentication, payment, etc.

[0085] FIG. 15 is a flowchart showing an example of the process of the search condition evaluation unit 122. The search condition evaluation unit 122 extracts words from the search phrase transmitted from the search condition transmission unit 106 in S402.

[0086] In S404, the search condition evaluation unit 122 recognizes the word, and searches for a characteristic word corresponding to the recognized word by referring to the word / characteristic word table (FIG. 14(c)) of the SW part document vector management unit 126. If the word is registered in the word / characteristic word table, the search condition evaluation unit 122 searches for a corresponding characteristic word, and if the word is not registered in the word / characteristic word table, it searches for a characteristic word corresponding to a similar word.

[0087] In S406, the search condition evaluation unit 122 determines the selection of the search option type selection 212. If the type selection is "single item", in S408, the search condition evaluation unit 122 generates a query including function a, OS1, and function b.

[0088] When the type selection is "combination," the search condition evaluation unit 122 generates two queries in S410: a first query including OS1 and function a, and a second query including OS1 and function b.

[0089] The search condition evaluation unit 122 transmits the query generated in S408 or S410 to the similarity evaluation unit 128 in S412.

[0090] FIG. 16 is a flowchart showing an example of the process of the similarity evaluation unit 128. In S502, the similarity evaluation unit 128 determines whether the type of search option selected is a single item or a combination.

[0091] If the similarity evaluation unit 128 determines that the type selection is "single item," then in S504, the similarity evaluation unit 128 extracts characteristic words from the query transmitted from the search condition evaluation unit 122.

[0092] In S506, the similarity evaluation unit 128 refers to the feature word / IDF table (FIG. 14(a)) of the SW part document vector management unit 126, reads out the IDF value of the feature word, and generates one query document vector according to Equation 1.

[0093] In S508, the similarity evaluation unit 128 calculates the vector similarity (cosine similarity) between one query document vector and all the SW part document vectors stored in the SW part document vector management unit 126 as follows.

[0094] If the query document vector is vector P and the SW part document vector is vector Q, vectors P and Q are normalized and then the inner product of the vectors (cosine similarity) is calculated as cos(Q,P) = (Q·P) / (|Q||P|). Q·P represents the inner product of vectors P and Q, and |P| and |Q| represent the norms of vectors P and Q, respectively. The larger the value of this inner product, the more the SW part related to that SW part document vector is evaluated to match the search conditions. The feature terms, which are elements of the vectors, are weighted based on the search options. The greater the similarity of feature terms with higher weights, the greater the cosine similarity. For this reason, the user can specify weights for feature terms that they want to emphasize by performing the operations shown in Figure 9.

[0095] In S510, the similarity evaluation unit 128 identifies SW part document vectors whose cosine similarity is equal to or greater than a certain value. In S512, the similarity evaluation unit 128 transmits unit information (e.g., FIG. 4) indicating a single SW part related to the identified SW part document vector to the search result / search option display unit 108.

[0096] If the similarity evaluation unit 128 determines in S502 that the type selection is combination, in S514, it extracts a first characteristic word from the first query transmitted from the search condition evaluation unit 122, and extracts a second characteristic word from the second query.

[0097] In S516, the similarity evaluation unit 128 refers to the feature word / IDF table ( FIG. 14(a) ) of the SW part document vector management unit 126, reads the IDF value of the first feature word, and generates a first query document vector in accordance with formula 1, and also refers to the feature word / IDF table, reads the IDF value of the second feature word, and generates a second query document vector in accordance with formula 1.

[0098] At S518, the similarity evaluation unit 128 calculates a first cosine similarity between the first query document vector and all of the SW part document vectors stored in the SW part document vector management unit 126, and calculates a second cosine similarity between the second query document vector and all of the SW part document vectors stored in the SW part document vector management unit 126.

[0099] The similarity evaluation unit 128 calculates the vector similarity between the two query document vectors and the SW part document vector in S518, but in order to reduce the calculation and evaluation of the vector similarity of SW part document vectors having overlapping functions, the SW part document vectors to be searched may be limited. For example, after calculating the vector similarity between the first query document vector and the SW part document vector, when calculating the vector similarity between the second query document vector and the SW part document vector, only the vector similarity with SW part document vectors that do not include function a which is a functional characteristic word included in the first query document vector may be calculated.

[0100] In S520, the similarity evaluation unit 128 specifies a first SW part document vector having a first cosine similarity equal to or greater than a certain value, and specifies a second SW part document vector having a second cosine similarity equal to or greater than a certain value. In S522, the similarity evaluation unit 128 transmits combination information (e.g., FIG. 5 and FIG. 6) representing a combination of a first SW part related to the specified first SW part document vector and a second SW part related to the second SW part document vector to the search result / search option display unit 108.

[0101] In addition, if there are constraints or weightings in S508 and S518, the similarity evaluation unit 128 may weight the feature words of the document vectors accordingly, or may narrow down the SW part document vectors as search targets for calculating the similarity.

[0102] FIG. 17 shows another example of management information managed by the SW component document vector management unit 126. This management information includes revision history, search information, reliability, and lower-level SW component information for each SW component ID. The revision history includes a version number, upgrade date and time, upgrader, and upgrade content. The upgrade content is information indicating the change part. The search information includes a category, a basic function, attribute information, and a search history. The category is information for classifying the functions of the SW component. The search history includes a document vector (TF-IDF(t,d)) calculated in the past and feature words extracted in the past. The reliability includes a usage record (including the reaction of users of the SW component (real voices of users)), quality (including the degree of document maintenance and the activity of commits), and security safety level. The lower-level SW component information is information on other SW components (lower-level SW components) called in a SW component that calls other SW components using a JAVA import statement or the like. The lower layer SW component information includes a lower layer SW component ID, a lower layer SW component call timing, and a lower layer SW component operation check level.

[0103] When the similarity evaluation unit 128 identifies an SW part document vector in S510 or S522, it refers to the management information related to the identified SW part document vector shown in Fig. 17 and determines whether or not a lower-level SW component is subordinate to the SW part. When the similarity evaluation unit 128 recognizes that a lower-level SW component is subordinate to the identified SW part, it may transmit combination information representing a combination of the SW part and the lower-level SW component to the terminal device 10, regardless of the selection result of the search option.

[0104] The present invention is not limited to the above-described embodiment as it is, and the components can be modified and embodied in the implementation stage without departing from the gist of the invention. In addition, various inventions can be formed by appropriately combining the multiple components disclosed in the above-described embodiment. For example, some components may be deleted from all the components shown in the embodiment. Furthermore, components from different embodiments may be appropriately combined. [Explanation of symbols]

[0105] 10... terminal device, 30... search device, 50... database, 102... search term input unit, 104... search option input unit, 106... search condition transmission unit, 108... search result / search option display unit, 110... search history reading unit, 122... search condition evaluation unit, 124... SW part document vector generation unit, 126... SW part document vector management unit, 128... similarity evaluation unit, 130... search history management unit

Claims

1. a storage means for storing a plurality of first document vectors relating to each of a plurality of software components; a generating means for receiving a search phrase including a first word representing an execution environment of a software component and a plurality of second words representing functions of the software component, and generating a plurality of second document vectors based on each combination of the first word and the plurality of second words; a search means for searching for a document vector combination from among the plurality of first document vectors based on a plurality of similarities between the plurality of second document vectors and the plurality of first document vectors; an output means for outputting software component combination information representing a plurality of software components related to the document vector combination; A search system comprising:

2. The generating means includes: Also receiving selection information selecting a single software component or a combination of software components; generating a third document vector based on the first word and the plurality of second words if the selection information selects a single software component; generating the plurality of second document vectors if the selection information selects a combination of software components; The search means includes: if the selection information selects a single software component, searching for at least one document vector from among the plurality of first document vectors based on a plurality of similarities between the third document vector and the plurality of first document vectors; If the selection information selects a combination of software components, searching for the document vector combination; The output means includes: If the selection information selects a single software component, outputting single software component information representing the at least one document vector; 2. The search system according to claim 1, wherein when the selection information selects a combination of software components, the search system outputs the software component combination information.

3. The selection information further selects a single software component and a combination of multiple software components; The generating means includes: generating the third document vector and the plurality of second document vectors when the selection information selects a single software component and a combination of software components; The search means includes: if the selection information selects a single software component and a combination of software components, searching for the at least one document vector and / or the document vector combination; The output means includes:

3. The search system according to claim 2, wherein when the selection information selects a single software component and a combination of software components, the single software component information and / or the software component combination information is output.

4. The generating means includes: a table for storing a plurality of words representing execution environments of the software components and a plurality of words representing functions of the software components; 4. The search system according to claim 1, further comprising: a search function for searching a search phrase; a search result table for searching a search term; and a search result table for searching a search term.

5. The search means includes: receiving weight information of words included in each of the plurality of second document vectors; The search system according to claim 1 , wherein the plurality of similarities are calculated in accordance with the weight information.

6. a second generating means for generating the first document vectors according to a frequency of appearance of a word included in a document related to each of the software components; 4. The search system according to claim 1, wherein the storage means stores the plurality of first document vectors generated by the second generation means.

7. An input means for inputting the search term; a display means for displaying the search phrase and the software component combination information; The search system according to any one of claims 1 to 6, further comprising:

8. 8. The search system according to claim 7, wherein said display means displays first information indicating a parallel combination of said plurality of software components or second information indicating a subordinate combination of said plurality of software components.

9. the display means displays weights of the first word and the second words in the second document vector in the calculation of the similarities together with the first word and the second words; The search system according to claim 7 , wherein said input means comprises means for changing said weights.

10. A method of receiving a search phrase including a first word representing an execution environment of a software component and a plurality of second words representing functions of the software component by executing a program by a processor; generating a plurality of second document vectors based on each combination of the first word and the plurality of second words by executing the program with the processor; The processor executes the program to search for a document vector combination from the first document vectors based on a plurality of similarities between the first document vectors and the second document vectors related to each of a plurality of software components; outputting software component combination information representing a plurality of software components related to the document vector combination by executing the program with the processor; A search method comprising:

11. The search method as described in claim 10, further comprising displaying the search term and the software component combination information by the processor executing the program.

Citation Information

Patent Citations

  • Software component storage device

    JP1998063495A

  • Object-oriented software component extraction supporting and retrieval device

    JP2001014154A

  • Retrieval system and program for software component

    JP2007304685A

  • Browse information editing device, program, and browse information editing method

    JP2013033387A

  • Document classification support device, document classification support method and program

    JP2014067154A