Configurable advanced search system and search method

By providing a configurable advanced search system with multiple modules, the existing advanced search solutions solve the bottlenecks and lack of flexibility in complex and large-scale data, and achieve fast and easy advanced search configuration and efficient query processing.

CN120179307APending Publication Date: 2025-06-20CLP CHAOYUN (NANJING) TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510239880.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-03
Publication Date
2025-06-20

AI Technical Summary

Technical Problem

When facing complex data structures and large-scale data, existing advanced search solutions are insufficient flexibility, complex configuration, and performance bottlenecks, making it difficult to meet users' various advanced search needs.

Method used

It provides a configurable advanced search system, including front-end and back-end components, the back-end includes field management module, candidate value module, data search module, cache module, special processing module and AI assistant module, supports a variety of query conditions and operators, and optimizes performance through factory mode and cache technology.

Benefits of technology

It realizes the fast and simple configuration of advanced search functions, supports complex query needs, improves search efficiency and user experience, and is suitable for various software development scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120179307A_ABST
    Figure CN120179307A_ABST
Patent Text Reader

Abstract

The invention provides a configurable advanced search system and search method, and relates to the technical field of computer software. The configurable advanced search system comprises a front end and a rear end, the front end comprises an input box, a pull-down candidate menu of the input box, a search configuration interface and an AI assistant interface; the rear end comprises a field management module, a candidate value module, a data search module, a cache module, a special processing module and an AI assistant module; according to the application, through the cooperation of various components at the front end and multiple modules at the rear end, a flexible, rapid and efficient advanced search function is provided for various software applications, various search conditions and operators are supported, meanwhile, a tag function and an intelligent input mode are integrated, the user experience is optimized, and the search efficiency is improved in combination with a cache technology.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the technical field of computer software development, and in particular, to a configurable advanced search system and search method. Background Art

[0002] With the continuous development of information technology, the amount of data in modern software systems is increasing continuously. How to efficiently and flexibly extract the information required by users from a large amount of data has become one of the key problems in many software developments. Traditional search functions usually only support simple keyword matching and cannot meet complex query requirements. In practical applications, users often need to perform combined queries based on multiple conditions, such as supporting complex requirements like dictionary mapping, array queries, calculation operations, and special processing. Traditional searches often have difficulty implementing these functions.

[0003] To address these challenges, many software systems have begun to introduce advanced search functions. Advanced search can not only support the combination of multiple query conditions but also support various operators, such as equal to, not equal to, contains, does not contain, is empty, is not empty, etc., and can meet diverse query requirements. However, existing advanced search solutions usually have certain limitations, mainly reflected in aspects such as insufficient flexibility, complex configuration, and performance bottlenecks. Especially when facing complex data structures and large-scale data, the search efficiency is often affected. Summary of the Invention

[0004] The purpose of this application is to provide a configurable advanced search system and search method, which can be used in various software developments to more quickly and simply implement the function of advanced search and meet the special needs of users in various advanced searches.

[0005] In a first aspect, the present application provides a configurable advanced search system, which includes: a front end and a back end; the front end includes three components: an input box and its drop-down candidate menu, a search configuration interface, and an AI assistant interface; the back end includes a field management module, a candidate value selection module, a data search module, a cache module, a special processing module, and an AI assistant module; the field management module is used to return multiple fields and operation types to the front end according to the mode name passed in by the front-end input box for display in the front-end drop-down box; among them, the fields include ordinary fields and labels; the return of multiple fields and operation types depends on the configuration of field-related information through the search configuration interface; the candidate value selection module is used to return candidate data to the front end according to the target field and target operation type selected in the front-end drop-down candidate menu for display in the front-end drop-down candidate menu; the data search module is used to generate a query statement according to the target candidate data selected in the front-end drop-down candidate menu, as well as the obtained target field, target operation type, and mode name, search in the database through the query statement, and return the search result to the front end; the special processing module is used to perform secondary processing on the search result based on the factory mode to obtain the data required by the end user and return it to the front end for display; the AI assistant module is used to construct a query statement based on the natural language description statement sent by the front end through the AI assistant interface and send it to the data search module to process and return the data required by the user through the data search module and the special processing module; the cache module is used to perform multiple caches when receiving a front-end request, specifically including: field cache, candidate data cache, and search result cache.

[0006] Further, the above-mentioned field management module is used to configure and maintain a basic search table, a SearchColumn table, and a label search table; the basic search table is used to provide the mode name and the table names and aliases involved in the mode name; the SearchColumn table is used to provide information about each field under each table in the basic search table; the label search table is used to provide the Key and Value of the label and the association relationship between the label and the entity, and is used to assign specific labels to the specified entity to facilitate querying in advanced search; in the field management module, searches are distinguished by mode name, and an interface for returning corresponding information to the front end according to the mode name is provided. The information includes: all fields and their types under the mode name, the operators supported by each field, and the display names.

[0007] Further, the above-mentioned candidate value selection module is used to automatically complete the search input information by means of association; the association methods include: field association and value association; field association is controlled by the front end; value association is controlled by the back end.

[0008] Further, the above data search module is used to convert the search statement into a database query statement, specifically including: after receiving the search statement and the pattern name, splitting the search statement according to the preset keywords to obtain multiple clauses; for each clause, splitting it according to the operator and converting it into an SQL statement according to the operator type to obtain the SQL statement corresponding to each clause; performing a multi-table join query according to the pattern name to obtain a Join statement; and combining the Join statement and the SQL statements corresponding to each clause to obtain a database query statement.

[0009] Further, the above field cache is used to cache the data obtained under each pattern name involved in the field management module, and delete the corresponding cached data when the pattern is updated; the candidate data cache is used to cache the candidates in the auto-completion involved in the candidate value selection module; the search result cache is used to cache the same search statement in the same pattern involved in the data search module for a short time.

[0010] Further, the above special processing module is used to dynamically select and combine data processing logics according to different business requirements by introducing the factory pattern; the data processing logics include: calculating fields, data conversion, and permission verification.

[0011] Further, the above AI assistant module is used to adopt the question-and-answer large model technology, and provide answers based on the natural language questions input by the user through natural language processing and machine learning algorithms.

[0012] Further, the front end uses Vue and JavaScript to implement the interactive interface; the back end uses Java for business logic processing and service management, uses Redis to cache data, and introduces a large model to implement the intelligent parsing function.

[0013] Further, the above large models include: ChatGPT, GPT-4, or ERNIE Bot.

[0014] Second aspect, the present application also provides a search method, which is applied to the backend of the configurable advanced search system as described in the first aspect; the method includes: receiving the pattern name passed in by the front end through the input box, and returning multiple fields and operation types to the front end according to the pattern name through the field management module for display in the drop-down candidate menu on the front end; the fields include ordinary fields and labels; receiving the target field and target operation type selected by the front end in the drop-down candidate menu, and returning candidate data to the front end according to the pattern name, target field and target operation type through the candidate value selection module for display in the drop-down candidate menu on the front end; receiving the target candidate data selected by the front end in the drop-down candidate menu, generating a query statement according to the target candidate data, target field, target operation type, and pattern name through the data search module, searching in the database through the query statement, and returning the search result to the front end; or further including: performing secondary processing on the search result based on the factory pattern through the special processing module to obtain the data required by the end user and returning it to the front end for display; or further including: receiving the natural language description statement sent by the front end, constructing a query statement through the AI assistant module and sending it to the data search module to process and return the data required by the user through the data search module and the special processing module.

[0015] The configurable advanced search system and search method provided by the present application can be used in various software developments to more quickly and simply implement the advanced search function, and can meet various special situations in advanced search, such as: dictionaries, arrays, calculations, special processing, etc. At the same time, it can also support a variety of operators, such as equal to, not equal to, contains, does not contain, is empty, is not empty, etc. In addition, this solution can also combine the label function for searching, further increasing the flexibility of searching. In terms of experience optimization, not only is caching used, but there is also configuration for searching on relevant pages. To facilitate users to input advanced search statements, direct input, combined input, and AI-assisted input are provided, meeting the needs of users in multiple aspects. BRIEF DESCRIPTION OF THE DRAWINGS

[0016] In order to more clearly illustrate the specific embodiments of the present application or the technical solutions in the prior art, the following will briefly introduce the drawings required to be used in the description of the specific embodiments or the prior art. Obviously, the drawings in the following description are some embodiments of the present application. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.

[0017] Figure 1 It is a schematic diagram of the overall architecture of a configurable advanced search system provided by an embodiment of the present application;

[0018] Figure 2 It is an interaction mode diagram of a search configuration interface provided by an embodiment of the present application;

[0019] Figure 3 This is the table structure diagram of a Search table and a SearchColumn table provided by an embodiment of the present application;

[0020] Figure 4 This is the data sample diagram of a Search table provided by an embodiment of the present application;

[0021] Figure 5 This is the data sample diagram of a SearchColumn table provided by an embodiment of the present application;

[0022] Figure 6 This is the table structure diagram of a table used for label search provided by an embodiment of the present application;

[0023] Figure 7 This is the label editing interface diagram provided by an embodiment of the present application;

[0024] Figure 8 This is the field association schematic diagram provided by an embodiment of the present application;

[0025] Figure 9 This is the value association schematic diagram provided by an embodiment of the present application;

[0026] Figure 10 This is the data search flow chart provided by an embodiment of the present application;

[0027] Figure 11 This is the special processing factory mode diagram provided by an embodiment of the present application;

[0028] Figure 12 This is the AI assistant schematic diagram provided by an embodiment of the present application;

[0029] Figure 13 This is the prompt word schematic diagram provided by an embodiment of the present application;

[0030] Figure 14 This is the cache acquisition flow chart provided by an embodiment of the present application;

[0031] Figure 15 This is the flow chart of a search method provided by an embodiment of the present application;

[0032] Figure 16 This is the overall front-end and back-end interaction flow chart provided by an embodiment of the present application. Detailed implementation manners

[0033] The technical solution of the present application will be clearly and completely described below in conjunction with the embodiments. Obviously, the described embodiments are part of the embodiments of the present application, rather than all of them. All other embodiments obtained by those of ordinary skill in the art based on the embodiments in the present application without creative efforts shall fall within the scope of protection of the present application.

[0034] In the existing search-related technologies, as users' requirements for the usage experience increase, many systems have started to introduce the tag function so that users can more intuitively mark and search for data. However, how to effectively combine the tag function with advanced search and provide a convenient input method is a problem that needs to be solved. Therefore, developing a configurable advanced search solution that can not only meet various complex query requirements but also improve the search efficiency and enhance the user experience has become an urgent need in current software development.

[0035] Based on this, the embodiments of the present application provide a configurable advanced search system and a search method, which can be used in various software developments to more quickly and simply implement the function of advanced search and meet the special requirements in various advanced searches of users. For the convenience of understanding this embodiment, first, a configurable advanced search system disclosed in the embodiments of the present application will be introduced in detail.

[0036] Figure 1 FIG. 10 is a schematic diagram of the overall architecture of a configurable advanced search system provided by the embodiments of the present application. The system includes: a front end and a back end; the front end includes three components: an input box and its drop-down candidate menu, a search configuration interface, and an AI assistant interface. The front end is implemented using JS and Vue, and the back end is implemented using Java. The input box and its drop-down candidate menu, such as Figure 1 the front-end interaction component shown on the left corresponds to the upper position in the interface (this part can construct an advanced search statement) and the middle left position (conventional input box and drop-down candidate menu); the AI assistant interface, such as Figure 1 the front-end interaction component shown on the left corresponds to the middle right position in the interface; the search configuration interface is not shown in Figure 1 FIG. 10. The search configuration interface can be configured by users or operation and maintenance personnel, such as configuring whether a certain field is displayed, the display order, supported operators, etc. The interaction method is as shown in Figure 2 FIG. 18, and data such as column names, descriptions, types, etc. are configured on the interface.

[0037] As Figure 1 shown on the right, the back-end data processing module specifically includes: a field management module, a candidate value selection module, a data search module, a cache module, a special processing module, and an AI assistant module. Externally involved are - two tables Search and Search_Column, and a conversational generation AI for assisting in generating search statements.

[0038] (1) The field management module is used to return multiple field and operation types to the front end according to the mode name passed in by the front-end input box for display in the front-end drop-down box; among them, the fields include ordinary fields and labels; the return of multiple field and operation types depends on the configuration of field-related information through the search configuration interface.

[0039] The above field management module is also used to configure and maintain the basic search table, SearchColumn table, and label search table; the basic search table is used to provide the mode name and the table names and aliases involved in that mode name. If multi-table joint query is required, it also provides the SQL statement for connection; the SearchColumn table is used to provide information about each field under each table in the basic search table, such as column name, display name, type, sorting weight, supported operators, whether to display, etc. If its type is an array or dictionary, its data source can also be configured, etc.; the label search table is used to provide the Key and Value of the label and the association relationship between the label and the entity, which is used to assign specific labels to the specified entity for convenient query in advanced search; in the field management module, searches are distinguished by mode name, and an interface that returns corresponding information to the front end according to the mode name is provided. The information includes: all fields and their types under the mode name, the operators supported by each field, and the display names.

[0040] This module requires developers or configurators to maintain the fields in advance. The table structures of the Search table and SearchColumn table are as Figure 3 shown, and the data samples of the Search table and SearchColumn table are respectively as Figure 4 and Figure 5 shown. In this embodiment, each search is distinguished by mode_name. For example, if two modules need to be developed, corresponding to "asset list" and "asset instance" respectively, their mode_name fields are "asset" and "instance" respectively. Each mode corresponds to the fields it needs, which are used as identifiers for developing different modules. The field management module is responsible for maintaining the above data and provides an interface that returns corresponding information according to mode_name to the front end. The information includes all fields and their types under this mode, the operators supported by each field, the display names, etc.

[0041] In addition, label search is supported in this solution. The table used for label search is as Figure 6 shown. The label editing interface is as Figure 7 shown. The entity in the label is the same as the modeName, which is convenient for the field management module to locate and select all the labels associated with this mode.

[0042] (2) Candidate Selection Value Module, which is used to return candidate data to the front end according to the selected target field and target operation type in the front-end drop-down candidate menu, so as to be displayed in the front-end drop-down candidate menu; the above-mentioned candidate selection value module is also used to automatically complete the search input information in an associative manner; the associative manner includes: field association and value association; the field association is controlled by the front end; the value association is controlled by the back end.

[0043] This module is responsible for handling the auto-completion during input, for input association, to facilitate user input, including field (Field) association and value (Value) association. Among them, the field association is controlled by the front end, and the value association is controlled by the back end. The field association is as Figure 8 shown, and the value association is as Figure 9 shown.

[0044] (3) Data Search Module, which is used to generate a query statement according to the selected target candidate data in the front-end drop-down candidate menu, as well as the obtained target field, target operation type, and mode name, search in the database through the query statement, and return the search result to the front end;

[0045] This module is responsible for converting the provided search statement into a database query statement, specifically including: after receiving the search statement and the mode name, splitting the search statement according to the preset keywords to obtain multiple sub-clauses; for each sub-clause, splitting according to the operator and converting it into an SQL statement according to the operator type to obtain the SQL statement corresponding to each sub-clause; performing a multi-table join query according to the mode name to obtain a Join statement; combining the Join statement and the SQL statement corresponding to each sub-clause to obtain a database query statement.

[0046] As Figure 10 shown, after receiving the statement and its mode_name, split it according to the defined keywords (such as AND, OR) into several sub-clauses, each sub-clause is in the form of (primary specification = 4090_24G), that is, (Field operator Value), and each operator has its own SQL conversion implementation, so as to obtain a part of the final SQL. According to the Join table situation, another part of the SQL can also be obtained, and combining them can obtain the complete statement for searching. After searching, perform paging and label completion, and then the result can be returned for display by the Web application.

[0047] (4) Special Processing Module, which is used to perform secondary processing on the search result based on the factory mode to obtain the data required by the end user and return it to the front end for display; the above-mentioned special processing module is also used to dynamically select and combine data processing logics according to different business requirements by introducing the factory mode; the data processing logics include: calculating fields, data conversion, and permission verification.

[0048] During development, the data presented is not necessarily static. For possible calculated fields, data conversions, permission verifications, etc., if each mode cannot be processed separately, the flexibility cannot meet the usage requirements. Therefore, a special processing module is also needed to process the search results according to actual needs.

[0049] As Figure 11 shown in the special processing factory pattern diagram, by introducing the factory pattern, this module can dynamically select and combine data processing logics according to different business requirements, thus enhancing the flexibility and scalability of the system. The factory pattern not only simplifies the system structure but also makes it easier and more efficient to add new processing logics, providing strong guarantees for the long-term maintenance and expansion of the system.

[0050] (5) The AI assistant module is used to construct a query statement based on the natural language description statement sent by the front end through the AI assistant interface and send it to the data search module to process and return the data required by the user through the data search module and the special processing module; the AI assistant module is also used to adopt the question-and-answer large model technology to provide answers based on the natural language questions input by the user through natural language processing and machine learning algorithms.

[0051] The AI assistant module adopts the question-and-answer large model technology, aiming to provide users with more intelligent and efficient query and decision-making support through natural language processing and machine learning algorithms. By introducing large-scale pre-trained language models, the AI assistant can understand and process users' natural language inputs and provide them with accurate and context-related answers or suggestions, thus simplifying the process of data query and information acquisition.

[0052] The core advantage of this module is that it can support complex query logics and natural language interactions. Users only need to input questions in daily language, and the AI assistant can understand their intentions and quickly generate corresponding queries or results. For example, users can simply ask "Find items with a price greater than 500 among all assets", and the AI assistant will automatically convert it into a query statement that the system can process and return the corresponding search results.

[0053] The schematic diagram of the AI assistant is as Figure 12 shown. On the premise of ensuring the correctness of the large model, the prompt words need to be close to the actual situation. As Figure 13 shown in the schematic diagram of the prompt words, in this solution, the information of the Search and Search_column tables can be provided to improve the correctness of the question and answer.

[0054] (6) Cache module, which is used to perform multiple caches when receiving a front - end request, specifically including: field cache, candidate data cache, and search result cache. Among them, the field cache is used to cache the data obtained under each mode name involved in the field management module, and when the mode is updated, the corresponding cached data is deleted; the candidate data cache is used to cache the candidate items in the auto - completion involved in the candidate value selection module; the search result cache is used to perform short - term caching of the same search statement in the same mode in the data search module.

[0055] When the data volume is large, high - concurrency direct access to the database will cause lag. Therefore, it is necessary to add a cache module to this advanced search. The cache acquisition flow chart is as Figure 14 shown. In this embodiment, it is necessary to cache fields, candidates, and results. For fields, that is, the data obtained for each mode involved in the field management module is cached, and when the mode is updated, the corresponding cache needs to be deleted; for candidates, that is, the candidate items in the auto - completion involved in the candidate value selection module are cached; for results, that is, for the same search statement in the same mode in the data search module, short - term caching can be done to prevent database breakdown, resulting in lag or service interruption.

[0056] The beneficial effects of the configurable advanced search system provided by the embodiments of this application are as follows:

[0057] 1. Flexible configuration and support for multiple query conditions

[0058] Through the collaborative work of the field management module, candidate value selection module, and data search module, the present invention realizes flexible support for multiple query conditions, meeting the diverse query needs of users in practical applications. In particular, it can support complex query conditions such as dictionary mapping, array query, calculation, and special processing, effectively improving the flexibility of query.

[0059] 2. Support for multiple operators

[0060] This solution supports a variety of common operators (such as equal to, not equal to, contains, does not contain, is empty, is not empty, etc.), which can meet the needs of different query scenarios, enhancing the adaptability of the system to various application scenarios in software, especially when involving various data types and different business requirements.

[0061] 3. Intelligent input and convenient experience

[0062] To improve the user experience, the present invention supports multiple intelligent input methods, such as direct input, combined input, and AI-assisted input. Through the AI assistant module, users can input query statements in natural language, greatly simplifying the usage threshold of advanced search and enabling users unfamiliar with database query syntax to quickly achieve complex searches.

[0063] 4. Cache technology optimizes query efficiency

[0064] In the face of a large amount of data, the present invention effectively solves the performance bottleneck problem that may be caused by directly accessing the database under high concurrency by introducing a cache module. The cache solution includes cache processing of fields, candidate values, and search results, which not only ensures the fast response of data queries but also avoids excessive access to the database, optimizing the overall performance of the system.

[0065] 5. The combination with the tag function enhances search flexibility

[0066] A unique highlight of the present invention is the support for the tag function. Through tag search, users can more intuitively and flexibly mark and find data, and at the same time support the combined use of tags with other query conditions, enhancing the applicable scope and flexibility of advanced search.

[0067] 6. The special processing module enhances the system scalability

[0068] By introducing the factory mode through the special processing module, the present invention improves the flexibility and scalability of the system. The special processing module can dynamically select and combine data processing logics according to different business requirements, support complex logics such as calculated fields, data conversion, and permission verification, ensuring that the system can handle changing business requirements and further enhancing the maintainability and scalability of the system.

[0069] 7. AI-assisted query improves user efficiency

[0070] The introduced AI assistant module, combined with a large-scale pre-trained language model, can intelligently parse natural language queries input by users and quickly generate corresponding query statements. The AI assistant can handle complex query logics, provide simple, accurate, and context-related query suggestions for users, improving the operation efficiency of users, especially suitable for user groups without a technical background.

[0071] In summary, the present invention not only improves the flexibility, efficiency, and user experience of the advanced search function but also ensures the high efficiency of queries in a high-concurrency environment, having strong application value.

[0072] Based on the above system embodiments, the embodiments of the present application further provide a search method, which is applied to the backend of the configurable advanced search system as described in the previous embodiment; see Figure 15As shown, the method includes the following steps:

[0073] Step S151: Receive the mode name passed in by the front end through the input box, and use the field management module to return multiple field and operation types to the front end according to the mode name for display in the drop-down candidate menu on the front end; the fields include ordinary fields and labels.

[0074] Step S152: Receive the target field and target operation type selected by the front end in the drop-down candidate menu, and use the candidate value selection module to return candidate data to the front end according to the mode name, target field, and target operation type for display in the drop-down candidate menu on the front end.

[0075] Step S153: Receive the target candidate data selected by the front end in the drop-down candidate menu, use the data search module to generate a query statement according to the target candidate data, target field, target operation type, and mode name, search in the database through the query statement, and return the search results to the front end.

[0076] Or it may further include:

[0077] Step S154: Use the special processing module to perform secondary processing on the search results based on the factory pattern to obtain the data required by the end user, and return it to the front end for display.

[0078] Or it may further include:

[0079] Step S155: Receive the natural language description statement sent by the front end, use the AI assistant module to construct a query statement and send it to the data search module to process and return the data required by the user through the data search module and the special processing module.

[0080] This technical solution is based on the front end using Vue and JavaScript to implement the interaction interface, the back end using Java for business logic processing and service management, using Redis to cache data, and introducing large models (such as ChatGPT, GPT-4, Wenxin Yiyan, etc.) to implement intelligent parsing functions. Refer to Figure 16 As shown in the overall front-end and back-end interaction flowchart, the specific process handling in the flowchart is now elaborated:

[0081] 1. Before developing the module, it is first necessary to agree on the modeName value of the module, which represents different modules and is used to isolate data between different searches. Back-end developers need to configure fields according to this value, and front-end developers need to send requests according to this value to obtain candidate data for the corresponding page.

[0082] 2. Front-end developers first call the getFields interface to interact with the field management module, pass in the modeName parameter, and obtain an array composed of the following objects, as shown in Table 1:

[0083] Table 1

[0084]

[0085] Based on the information obtained by getFields, the relevant data of the drop-down box can be filled. According to the type and supported operators, different contents are displayed. Among them, the label belongs to a special field and can be freely configured by the user. Since this data does not change frequently, caching will be used to improve the interface efficiency.

[0086] 3. After selecting the fields and operators, it is necessary to call the getData interface to interact with the candidate value module. getData needs to provide modeName, fieldName (field name), and type. Through these data, the candidate value module can obtain the Map of candidate values for the corresponding field name and return it to the front end.

[0087] 4. After the front end obtains the candidate data, it can be displayed in the drop-down box for the user to filter, and this process also supports fuzzy search.

[0088] 5. After selecting the drop-down box, a part of the query statement has been constructed. If the next part of the statement needs to be constructed, AND or OR is required for connection, or ORDER BY is used to specify the sorted field to end the construction.

[0089] In addition to the above construction method, an AI assistant can also be used to assist in the construction of the query statement. By inputting natural language and according to special prompt words, using the language generation model, the corresponding query statement can be generated for direct filling, reducing the user's filling time.

[0090] 6. After the back end obtains the constructed statement, it can query according to this statement. First, it is split according to the connection operators (AND, OR, ORDER BY), and then split according to the operators (=,!=, ~,!~, is, is not, in, not in) to construct the SQL query statement, and then query in the database.

[0091] For the query results, if special processing is still required - adding calculated fields (fields calculated based on other fields), adding units, dictionary mapping, etc. It is also necessary to rely on a special processing module and process it through the factory mode according to its modeName.

[0092] Or, an AI assistant or manual filling can also be used for data query.

[0093] The method provided by the embodiments of this application has the same implementation principle and technical effects as those of the foregoing system embodiments. For the sake of brief description, for the parts not mentioned in the method embodiments, reference may be made to the corresponding content in the foregoing system embodiments.

[0094] The embodiments of this application also provide a computer-readable storage medium, which stores computer-executable instructions. When the computer-executable instructions are called and executed by a processor, the computer-executable instructions prompt the processor to implement the above method. For specific implementation, reference may be made to the foregoing method embodiments and will not be elaborated herein.

[0095] The computer program product of the method, device and electronic device provided by the embodiments of this application includes a computer-readable storage medium storing program code. The instructions included in the program code can be used to execute the method described in the foregoing method embodiments. For specific implementation, reference may be made to the method embodiments and will not be elaborated herein.

[0096] Unless otherwise specifically stated, the relative steps, numerical expressions and values of the components and steps set forth in these embodiments do not limit the scope of this application.

[0097] If the above functions are implemented in the form of software function units and sold or used as independent products, they can be stored in a non-volatile computer-readable storage medium executable by a processor. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a part of this technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The foregoing storage medium includes: various media such as USB flash drives, mobile hard disks, read-only memories (ROM, Read-Only Memory), random access memories (RAM, Random Access Memory), magnetic disks or optical discs that can store program code.

[0098] In the description of this application, it should be noted that the orientation or positional relationship indicated by the terms "center", "upper", "lower", "left", "right", "vertical", "horizontal", "inner", "outer", etc. is based on the orientation or positional relationship shown in the drawings, and is only for the convenience of describing this application and simplifying the description, rather than indicating or implying that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of this application. In addition, the terms "first", "second", "third" are only used for descriptive purposes and should not be construed as indicating or implying relative importance.

[0099] Finally, it should be noted that the above-described embodiments are only specific implementation manners of the present application, used to illustrate the technical solutions of the present application, rather than limiting it. The protection scope of the present application is not limited thereto. Although the present application has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that any person skilled in the art within the technical scope disclosed by the present application can still modify the technical solutions described in the foregoing embodiments or can easily think of changes, or perform equivalent replacements on some of the technical features; and these modifications, changes or replacements do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present application, and should all be covered within the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the protection scope of the claims.

Claims

1. A configurable advanced search system, characterized in that: The system includes: a front end and a back end; the front end includes three components: an input box and a drop-down candidate menu, a search configuration interface, and an AI assistant interface; the back end includes a field management module, a candidate value module, a data search module, a cache module, a special processing module, and an AI assistant module; The field management module is used to return multiple fields and operation types to the front end according to the mode name passed in the front end input box, so as to be displayed in the front end drop-down box; wherein the fields include ordinary fields and labels; the return of the multiple fields and operation types depends on the configuration of field related information through the search configuration interface; The candidate value module is used to return candidate data to the front end according to the target field and target operation type selected in the front end drop-down candidate menu, so as to be displayed in the front end drop-down candidate menu; The data search module is used to generate a query statement based on the target candidate data selected in the front-end drop-down candidate menu, as well as the acquired target field, target operation type, and mode name, search in the database through the query statement, and return the search results to the front-end; The special processing module is used to perform secondary processing on the search results based on the factory mode to obtain the data required by the end user and return it to the front end for display; The AI ​​assistant module is used to construct a query statement based on the natural language description statement sent by the front end through the AI ​​assistant interface and send it to the data search module, so as to return the data required by the user through the data search module and the special processing module; The cache module is used to perform multiple caches upon receiving a front-end request, specifically including: field cache, candidate data cache, and search result cache.

2. The system according to claim 1, characterized in that The field management module is used to configure and maintain the basic search table, SearchColumn table and label search table; the basic search table is used to provide the mode name and the table name and alias involved in the mode name; the SearchColumn table is used to provide the information of each field under each table in the basic search table; the label search table is used to provide the Key and Value of the label and the association relationship between the label and the entity, and is used to assign a specific label to the specified entity, so as to facilitate query in advanced search; In the field management module, the search is distinguished by the pattern name, and an interface for returning corresponding information to the front end according to the pattern name, the information includes: all fields under the pattern name and their types, operators supported by each field and display names.

3. The system according to claim 1, characterized in that The candidate value module is used to automatically complete the search input information through an association method; the association method includes: field association and value association; the field association is controlled by the front end; the value association is controlled by the back end.

4. The system according to claim 1, characterized in that The data search module is used to convert the search statement into a database query statement, specifically including: after receiving the search statement and the mode name, segmenting the search statement according to preset keywords to obtain multiple clauses; for each clause, segmenting according to the operator, and converting it into an SQL statement according to the operator type to obtain the SQL statement corresponding to each clause; performing a multi-table joint query according to the mode name to obtain a Join statement; combining the Join statement and the SQL statement corresponding to each clause to obtain a database query statement.

5. The system according to claim 1, characterized in that The field cache is used to cache the data obtained under each mode name involved in the field management module, and delete the corresponding cached data when the mode is updated; the candidate data cache is used to cache the candidate items involved in the automatic completion in the candidate value module; The search result cache is used to cache the same search statement in the same mode involved in the data search module for a short period of time.

6. The system according to claim 1, characterized in that The special processing module is used to dynamically select and combine data processing logic according to different business requirements by introducing a factory mode; the data processing logic includes: calculation fields, data conversion and permission verification.

7. The system according to claim 1, characterized in that The AI ​​assistant module is used to adopt the question-answering large model technology to provide answers based on natural language questions input by users through natural language processing and machine learning algorithms.

8. The system according to claim 1, characterized in that The front end uses Vue and JavaScript to implement the interactive interface; the back end uses Java for business logic processing and service management, uses Redis to cache data, and introduces a large model to implement intelligent parsing functions.

9. The system according to claim 8, characterized in that The large models include: ChatGPT, GPT-4 or Wenxinyiyan.

10. A search method, characterized in that: The method is applied to the back end of the configurable advanced search system according to any one of claims 1 to 9; the method comprises: Receive the mode name passed in by the front end through the input box, and return multiple fields and operation types to the front end according to the mode name through the field management module to display in the drop-down candidate menu of the front end; the fields include ordinary fields and labels; Receive the target field and target operation type selected by the front end in the pull-down candidate menu, and return candidate data to the front end through the candidate value module according to the mode name, the target field and the target operation type, so as to be displayed in the pull-down candidate menu of the front end; Receive the target candidate data selected by the front end in the drop-down candidate menu, generate a query statement according to the target candidate data, target field, target operation type, and mode name through the data search module, search in the database through the query statement, and return the search result to the front end; Or also include: Through the special processing module, the search results are processed again based on the factory mode to obtain the data required by the end user and return it to the front end for display; Or also include: Receive the natural language description statement sent by the front end, construct a query statement through the AI ​​assistant module and send it to the data search module, so as to return the data required by the user through the data search module and the special processing module.