A query index method and device, electronic equipment and medium

By matching user input information with the query task mapping table, the parameter templates and interfaces of sub-query tasks are obtained, solving the problem of high computational cost of large model query strategies and realizing fast and flexible business query system integration.

CN120336350BActive Publication Date: 2025-11-21WUHAN UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510354366.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-03-25
Publication Date
2025-11-21
Estimated Expiration
2045-03-25

AI Technical Summary

Technical Problem

Existing large-scale model query strategies are computationally expensive, time-consuming, and suffer from inconsistent planning and low reliability, making it difficult to quickly and flexibly integrate with business query systems.

Method used

By matching user input with a pre-defined query task mapping table, sub-query tasks are obtained. The query parameters are then obtained directly by utilizing the sub-query task's calling interface and parameter template, thus reducing the dependence on the large model.

Benefits of technology

It reduces computational and time costs, ensures fast querying of subquery tasks, improves the relevance and flexibility of generated tasks, and reduces the need for fine-tuning of large models and interface development.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120336350B_ABST
    Figure CN120336350B_ABST
Patent Text Reader

Abstract

The application provides a query index method and device, electronic equipment and medium. The method comprises: obtaining input information of a user; matching the input information with a sub-query task in a preset query task mapping table to obtain at least one matched sub-query task; obtaining a parameter template corresponding to the at least one sub-query task, and performing standardized processing on a query parameter of the sub-query task based on the parameter template; calling a query interface of the at least one sub-query task to obtain the standardized query parameter of the at least one sub-query task, and outputting a query result of each sub-query task. The query task mapping table comprises a plurality of sub-query tasks, and each sub-query task corresponds to a parameter template and a query interface. The application solves the technical problem of high calculation cost and long calculation time of the existing large model query strategy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of large model technology, and in particular to a query indexing method, apparatus, electronic device, and medium. Background Technology

[0002] Handling complex query transactions has always been a challenge for big data model technology. As big data models are deployed in many industries, how to flexibly and quickly integrate big data models into existing business query systems and fully automate business queries has also become one of the current challenges.

[0003] To address the aforementioned issues, existing solutions for handling complex query transactions typically employ decomposition programming. These solutions primarily utilize two strategies for query task decomposition: decomposition priority and staggered decomposition.

[0004] Decomposition-first methods break down a query task into subquery objectives and then develop a plan for each subquery objective in turn. This strategy ensures a strong correlation between subquery tasks and the original query task, reducing the risk of task omissions and miscalculations.

[0005] Interleaved decomposition methods interleave query task decomposition and subquery task planning, revealing only one or two subquery tasks of the current state at a time. This strategy can dynamically adjust task decomposition based on environmental feedback, thus improving fault tolerance to some extent.

[0006] However, both of the above strategies rely entirely on large models to decompose query tasks, which makes it difficult to guarantee the feasibility of the resulting subquery tasks and their low relevance to business needs.

[0007] The planning process typically consists of two steps: multi-plan generation and optimal plan selection. The multi-plan generation phase can be considered as attempting to generate a series of possible plans; while the optimal plan selection phase represents choosing the best plan from multiple candidate plans.

[0008] Theoretically, this generation strategy can provide users with efficient and innovative plans. However, in practice, each step requires a significant amount of time and computational cost, and the inherent randomness of large models can lead to different plans being generated for the same problem, making it difficult to guarantee the consistency and reliability of the plans. Summary of the Invention

[0009] This invention provides a query indexing method, apparatus, electronic device, and medium to solve the technical problems of high computational cost and long computation time of existing large model query strategies.

[0010] According to one aspect of the present invention, a method for querying an index is provided, comprising:

[0011] Obtain user input information;

[0012] The input information is matched with the sub-query tasks in the preset query task mapping table to obtain at least one matched sub-query task.

[0013] Obtain at least one parameter template corresponding to the subquery task, and standardize the query parameters of the subquery task based on the parameter template;

[0014] Call the query interface of at least one of the subquery tasks to obtain the normalized query parameters of at least one of the subquery tasks, and output the query result of each subquery task; the query task mapping table includes multiple subquery tasks, and each subquery task corresponds to a parameter template and a query interface.

[0015] Optionally, matching the input information with sub-query tasks in a preset query task mapping table to obtain at least one matched sub-query task includes:

[0016] Extract keywords from the input information;

[0017] The keywords of the input information and the keywords of the sub-query task are matched for similarity, and at least one sub-query task that matches the input information is determined based on the similarity value.

[0018] Alternatively, the keywords of the input information and the keywords of the parent query task are matched for similarity. Based on the similarity value, at least one parent query task that matches the input information is determined, thereby obtaining at least one sub-query task that matches the input information; the parent query task corresponds to at least one sub-query task.

[0019] Optionally, matching the input information with sub-query tasks in a preset query task mapping table to obtain at least one matched sub-query task includes:

[0020] The large model performs contextual reasoning on the input information and performs similarity matching between the reasoning results and the task templates of each subquery task to obtain at least one matched subquery task; each task template corresponds to at least one subquery task.

[0021] Optionally, matching the input information with sub-query tasks in a preset query task mapping table to obtain at least one matched sub-query task includes:

[0022] The large model makes inferences based on the input information;

[0023] The reasoning result is then matched with the task description of the subquery task to obtain at least one subquery task that matches the input information.

[0024] Alternatively, the reasoning result can be matched with the task description of the parent query task to obtain at least one parent query task that matches the input information, and then at least one sub-query task that matches the input information; the parent query task corresponds to at least one sub-query task.

[0025] Optionally, after matching the input information with subquery tasks in a preset query task mapping table to obtain at least one matched subquery task, the method further includes:

[0026] Each of the subquery tasks is assigned to a separate thread for processing.

[0027] Optionally, it also includes:

[0028] As needed, add, delete, and modify the task name, task characteristics, parameter template, and query interface of the parent query task or child query task in the query task mapping table.

[0029] Optionally, it also includes:

[0030] Based on the context of the input information, user information, and user preferences, query parameters are extracted and used as normalized query parameters.

[0031] According to another aspect of the present invention, a query indexing apparatus is provided, comprising:

[0032] The information acquisition unit is used to acquire user input information;

[0033] The task matching unit is used to match the input information with sub-query tasks in a preset query task mapping table to obtain at least one matched sub-query task.

[0034] A normalization processing unit is used to obtain at least one parameter template corresponding to the subquery task, and to normalize the query parameters of the subquery task based on the parameter template.

[0035] The query unit is used to call the query interface of at least one of the sub-query tasks, obtain the normalized query parameters of at least one of the sub-query tasks, and output the query result of each sub-query task; the query task mapping table includes multiple sub-query tasks, and each sub-query task corresponds to a parameter template and a query interface.

[0036] According to another aspect of the present invention, an electronic device is provided, the electronic device comprising:

[0037] At least one processor; and

[0038] A memory communicatively connected to the at least one processor; wherein,

[0039] The memory stores a computer program that can be executed by the at least one processor, the computer program being executed by the at least one processor to enable the at least one processor to perform the query indexing method according to any embodiment of the present invention.

[0040] According to another aspect of the present invention, a computer-readable storage medium is provided, the computer-readable storage medium storing computer instructions for causing a processor to execute and implement the query indexing method according to any embodiment of the present invention.

[0041] The technical solution of this invention obtains at least one matched subquery task by matching the user's input information with subquery tasks in a preset query task mapping table. Each subquery task has a corresponding calling interface and parameter template in the query task mapping table, thus eliminating the need to call a large model for task planning, reducing computation and time costs, and ensuring fast querying of the generated subquery tasks.

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

[0043] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0044] Figure 1 This is a flowchart illustrating two decomposition methods for large models to decompose query tasks in existing technologies.

[0045] Figure 2 This is a flowchart of a query index method provided in Embodiment 1 of the present invention;

[0046] Figure 3 This is a structural diagram of a query indexing device provided according to Embodiment 2 of the present invention;

[0047] Figure 4 This is a schematic diagram of the structure of an electronic device that implements the query indexing method of this invention. Detailed Implementation

[0048] To enable those skilled in the art to better understand the present invention, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of the present invention.

[0049] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of the invention described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.

[0050] With the widespread adoption of large-scale models across various industries, one of the current challenges is how to flexibly and quickly integrate these models into existing business query systems to fully automate business queries. To address these issues, existing large-scale models typically employ decomposition programming methods when handling complex query transactions.

[0051] There are two main strategies for decomposing query tasks, see appendix. Figure 1 :

[0052] Figure 1 The left side illustrates the Decomposition-First Methods strategy, which breaks down the query task into subquery objectives and then plans for each subquery objective in turn. This strategy ensures a strong correlation between subquery tasks and the original query task, reducing the risk of task omissions and misinterpretations.

[0053] Figure 1 The right side shows the Interleaved Decomposition Methods strategy, which interleaves query task decomposition and subquery task planning, revealing only one or two subquery tasks of the current state at a time. This strategy can dynamically adjust task decomposition based on environmental feedback, improving fault tolerance to some extent. However, both of these strategies rely entirely on a large model for query task decomposition, making it difficult to guarantee the feasibility of the generated subquery tasks and resulting in low relevance to business requirements.

[0054] The planning generation process typically consists of two steps: multi-plan generation and optimal plan selection. The multi-plan generation phase can be considered as attempting to generate a series of possible plans; the optimal plan selection phase involves choosing the best plan from multiple candidate plans. Theoretically, this generation strategy can provide users with efficient and innovative plans. However, in practice, each step requires significant time and computational costs, and the inherent randomness of large models means that different plans may be generated for the same problem, making it difficult to guarantee the consistency and reliability of the plans.

[0055] On the other hand, regarding the integration of business query systems and large-scale models, enterprises select suitable large-scale models based on business needs and provide business data to fine-tune the models. They also need to develop query interfaces for interaction between the business systems and the large-scale models. This method offers good stability and scalability to support high concurrency and complex business scenarios. However, it struggles to quickly adapt to business adjustments, requiring re-tuning of the models and development of query interfaces, resulting in low flexibility and portability.

[0056] To address the aforementioned two issues, this invention matches user input with sub-query tasks in a pre-defined query task mapping table to obtain at least one matched sub-query task. The main model can then directly call the calling interface and parameter template in the sub-query task of the query task mapping table to retrieve query parameters. This complete decoupling of the main model from the business query system eliminates the need for task planning within the main model, significantly reducing computational and time costs and ensuring rapid querying of generated sub-query tasks. Furthermore, by setting task templates, keywords, and task descriptions for each parent and sub-query task in the query task mapping table, the main model can more easily match relevant sub-query tasks to input information, ensuring absolute relevance to the business even with incomplete or ambiguous user input. Finally, because this application completely decouples the main model from the business query system, adjustments to the business only require changes to the query task mapping table, without needing to fine-tune the main model or redevelop the task query interface, greatly reducing development costs.

[0057] This application will provide a detailed description of the present invention through the following embodiments.

[0058] Example 1

[0059] Figure 2 The flowchart illustrates a query index method provided in Embodiment 1 of the present invention. Figure 2 As shown, the method includes:

[0060] S101. Obtain user input information.

[0061] User input can be either voice or text. If it is voice input, a speech recognition algorithm can be used to recognize the user's speech and convert it into text.

[0062] S102. Match the input information with the sub-query tasks in the preset query task mapping table to obtain at least one matched sub-query task.

[0063] The query task mapping table is a pre-set table designed to build a mapping relationship between subquery tasks, parameter templates, and query interfaces, so that the large model can directly obtain subquery tasks that match the input information and call the query interface of the subquery task to obtain query parameters.

[0064] In this embodiment, there are multiple methods to match the input information with the subquery tasks in the preset query task mapping table. For example, keywords of the input information can be extracted and the keywords of the input information can be matched with the keywords of the subquery tasks based on similarity, so that at least one subquery task corresponding to the input information can be matched.

[0065] S103. Obtain at least one parameter template corresponding to the sub-query task, and perform normalization processing on the query parameters of the sub-query task based on the parameter template.

[0066] The parameter template is used to define the normalized form of query parameters. In a specific query, the large model can match the user input information with the parameter template corresponding to the subquery task and obtain the normalized query parameters for each subquery task. This ensures that each subquery task has normalized parameters, thereby improving model accuracy and efficiency.

[0067] S104. Call the query interface of at least one of the sub-query tasks to obtain the normalized query parameters of at least one of the sub-query tasks, so as to output the query result of each sub-query task; the query task mapping table includes multiple sub-query tasks, and each sub-query task corresponds to a parameter template and a query interface.

[0068] In this embodiment, when a corresponding subquery task needs to be executed, the query interface corresponding to the subquery task can be directly called, and the normalized query parameters corresponding to the query interface can be obtained. The query results of the subquery task can be quickly obtained by using the normalized query parameters as input to the large model.

[0069] The technical solution of this invention obtains at least one matched subquery task by matching the user's input information with subquery tasks in a preset query task mapping table. Each subquery task has a corresponding calling interface and parameter template in the query task mapping table, thus eliminating the need to call a large model for task planning, reducing computation and time costs, and ensuring fast querying of the generated subquery tasks.

[0070] In one embodiment, step S102 matches the input information with sub-query tasks in a preset query task mapping table to obtain at least one matched sub-query task, which may specifically include:

[0071] Extract keywords from the input information;

[0072] The keywords of the input information and the keywords of the sub-query task are matched for similarity, and at least one sub-query task that matches the input information is determined based on the similarity value.

[0073] Alternatively, the keywords of the input information and the keywords of the parent query task are matched for similarity. Based on the similarity value, at least one parent query task that matches the input information is determined, thereby obtaining at least one sub-query task that matches the input information; the parent query task corresponds to at least one sub-query task.

[0074] It's important to note that large models can perform word segmentation and vectorization on user input. Word segmentation breaks down the user-input text into individual words or sub-word units. For example, the sentence "I like artificial intelligence" might be segmented into units such as "I," "like," and "artificial intelligence." Vectorization converts these word or sub-word units into vector representations in a vector space. Each vector contains semantic and syntactic information about the word. Different words have different positions and features in the vector space, thus transforming textual information into a digital form that computers can process.

[0075] In this embodiment, keywords for each sub-query task and the parent query task can be pre-defined in the query task mapping table. For example, when the parent query task is food recommendation, its corresponding keywords may include food, restaurants, etc. Furthermore, each parent query task can correspond to multiple sub-query tasks. For instance, when the parent query task is food recommendation, its corresponding sub-query tasks may include queries based on average spending per person and queries based on geographical location. Similarly, each sub-query task can correspond to multiple keywords. For example, keywords for queries based on average spending per person may include cost-effectiveness, affordability, etc., and keywords for queries based on geographical location may include nearby, kilometers, etc.

[0076] In this embodiment, the keywords of the input information and the keywords of the sub-query tasks can be converted into vector form, and the similarity can be calculated in the vector space. Then, based on the similarity value, at least one parent query task or sub-query task that is closest to the input information can be determined. If the parent query task is matched, at least one sub-query task corresponding to the parent query task is matched with the input information.

[0077] In one embodiment, step S102, which matches the input information with sub-query tasks in a preset query task mapping table to obtain at least one matched sub-query task, may further include:

[0078] The large model performs contextual reasoning on the input information and performs similarity matching between the reasoning results and the task templates of each subquery task to obtain at least one matched subquery task; each task template corresponds to at least one subquery task.

[0079] It's important to note that task templates for each subquery task and the parent query task can be pre-defined in the query task mapping table. For example, for the parent query task of food recommendation, its task template could be set to "I want to eat something nearby." Similarly, similar task templates can be set for each subquery task. The large model can perform contextual reasoning on the input information and then perform similarity matching between the reasoning results and the task templates of each parent and subquery task to find the parent and subquery tasks that match the input information. Since a parent query task can correspond to at least one subquery task, when the input information matches a parent query task, the corresponding subquery task also matches the input information.

[0080] In one embodiment, step S102, which matches the input information with sub-query tasks in a preset query task mapping table to obtain at least one matched sub-query task, may further include:

[0081] The large model makes inferences based on the input information;

[0082] The reasoning result is then matched with the task description of the subquery task to obtain at least one subquery task that matches the input information.

[0083] Alternatively, the reasoning result can be matched with the task description of the parent query task to obtain at least one parent query task that matches the input information, and then at least one sub-query task that matches the input information; the parent query task corresponds to at least one sub-query task.

[0084] It's important to note that task descriptions for each subquery task and the parent query task can be pre-defined in the query task mapping table. For example, for the parent query task "Food Recommendation," the task description could be: "Users want to obtain food recommendations based on their personal taste, location, or other preferences." For the subquery task "Query based on average spending per person," the task description could be: "Users want to obtain relevant food recommendations based on a specific average spending range per person." The large model can perform inference based on the input information and match the inference results with the task descriptions of the subquery tasks and the parent query task based on similarity. The model will then select the subquery task or parent query task with the highest similarity as the matching query task. Furthermore, since a parent query task can correspond to at least one subquery task, when the input information matches the parent query task, the corresponding subquery task will also match the input information.

[0085] In this embodiment, the query task mapping table can be as shown in Table 1 below. Table 1 only provides an example of a parent query task named "Food Recommendation," but there can actually be multiple parent query tasks. The task characteristics of each parent query task in Table 1 include its task template, keywords, and task description. Furthermore, each parent query task corresponds to two sub-query tasks: query based on average spending per person and query based on geographical location. Similarly, each sub-query task includes keywords and a task description. Each sub-query task in Table 1 corresponds to a parameter template and a query interface API. This embodiment is merely an illustrative example and is not intended to be restrictive.

[0086] Table 1 Query Task Mapping Table

[0087]

[0088] In one embodiment, the method further includes assigning each of the subquery tasks to a separate thread for processing.

[0089] In this embodiment, by matching user input information with sub-query tasks in the query task mapping table, at least one sub-query task matching the input information is found. Then, each sub-query task is assigned to a separate thread for parallel processing. Each thread matches the user input information with the parameters in the parameter template to extract the normalized query parameters. Each thread can use an HTTP request library to concurrently call these interfaces, using the normalized query parameters as input, to obtain the query results of each sub-query task.

[0090] In one embodiment, the method further includes adding, deleting, and modifying the task name, task characteristics, parameter template, and query interface of the sub-query task in the query task mapping table according to requirements.

[0091] When business operations are adjusted, the task name, task characteristics, parameter templates, and query interfaces of the parent or child query tasks in the query task mapping table can be added, deleted, or modified without needing to fine-tune the large model or redevelop the query interface.

[0092] In one embodiment, the method further includes: extracting query parameters based on the context of the input information, user information, and user preferences, and using these parameters as normalized query parameters.

[0093] For example, when the user input already contains explicit parameters or user-preferred parameters, these explicit or user-preferred parameters can be directly used as normalized parameters. For instance, if the user input includes "within 5 kilometers," and the parameter template for the subquery task defines "nearby" as a range of less than or equal to 2 kilometers, then the user input "within 5 kilometers" can be directly used as the normalized distance parameter.

[0094] The technical solution of this invention matches user input information with sub-query tasks in a pre-set query task mapping table to obtain at least one matched sub-query task. The large model can then directly call the calling interface and parameter template in the sub-query task of the query task mapping table to obtain query parameters. This method of completely decoupling the large model from the business query system eliminates the need for task planning by calling the large model, significantly reducing computational and time costs and ensuring fast querying of generated sub-query tasks. Furthermore, by setting task templates, keywords, and task descriptions for each parent and sub-query task in the query task mapping table, the large model can more easily match relevant sub-query tasks to input information, ensuring absolute relevance to the business even with incomplete or ambiguous user input. Finally, because this application completely decouples the large model from the business query system, when business needs adjustment, only the content of the query task mapping table needs to be adjusted, without fine-tuning the large model or redeveloping the task query interface, greatly reducing development costs.

[0095] Example 2

[0096] Figure 3 This is a schematic diagram of a query indexing device provided in Embodiment 2 of the present invention. Figure 3 As shown, the device includes:

[0097] Information acquisition unit 201 is used to acquire user input information;

[0098] The task matching unit 202 is used to match the input information with sub-query tasks in a preset query task mapping table to obtain at least one matched sub-query task.

[0099] The normalization processing unit 203 is used to obtain at least one parameter template corresponding to the subquery task, and to normalize the query parameters of the subquery task based on the parameter template.

[0100] The query unit 204 is used to call the query interface of at least one of the sub-query tasks to obtain the normalized query parameters of at least one of the sub-query tasks, so as to output the query result of each sub-query task; the query task mapping table includes multiple sub-query tasks, and each sub-query task corresponds to a parameter template and a query interface.

[0101] The query indexing device provided in the embodiments of the present invention can execute the query indexing method provided in any embodiment of the present invention, and has the corresponding functional modules and beneficial effects of the execution method.

[0102] Example 4

[0103] Figure 4 A schematic diagram of an electronic device 10 that can be used to implement embodiments of the present invention is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processors, cellular phones, smartphones, wearable devices (e.g., helmets, glasses, watches, etc.), and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the invention described and / or claimed herein.

[0104] like Figure 4 As shown, the electronic device 10 includes at least one processor 11 and a memory, such as a read-only memory (ROM) 12 or a random access memory (RAM) 13, communicatively connected to the at least one processor 11. The memory stores computer programs executable by the at least one processor. The processor 11 can perform various appropriate actions and processes based on the computer program stored in the ROM 12 or loaded from storage unit 18 into the RAM 13. The RAM 13 may also store various programs and data required for the operation of the electronic device 10. The processor 11, ROM 12, and RAM 13 are interconnected via a bus 14. An input / output (I / O) interface 15 is also connected to the bus 14.

[0105] Multiple components in electronic device 10 are connected to I / O interface 15, including: input unit 16, such as keyboard, mouse, etc.; output unit 17, such as various types of displays, speakers, etc.; storage unit 18, such as disk, optical disk, etc.; and communication unit 19, such as network card, modem, wireless transceiver, etc. Communication unit 19 allows electronic device 10 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks.

[0106] Processor 11 can be a variety of general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of processor 11 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. Processor 11 performs the various methods and processes described above, such as a query indexing method.

[0107] In some embodiments, a query indexing method may be implemented as a computer program tangibly contained in a computer-readable storage medium, such as storage unit 18. In some embodiments, part or all of the computer program may be loaded and / or mounted on electronic device 10 via ROM 12 and / or communication unit 19. When the computer program is loaded into RAM 13 and executed by processor 11, one or more steps of the query indexing method described above may be performed. Alternatively, in other embodiments, processor 11 may be configured to perform a query indexing method by any other suitable means (e.g., by means of firmware).

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

[0109] Computer programs used to implement the methods of the present invention may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, such that when executed by the processor, the computer programs cause the functions / operations specified in the flowcharts and / or block diagrams to be performed. The computer programs may be executed entirely on a machine, partially on a machine, or as a standalone software package, partially on a machine and partially on a remote machine, or entirely on a remote machine or server.

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

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

[0112] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as data servers), or computing systems that include middleware components (e.g., application servers), or computing systems that include frontend components (e.g., user computers with graphical user interfaces or web browsers through which users can interact with implementations of the systems and technologies described herein), or any combination of such backend, middleware, or frontend components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., communication networks). Examples of communication networks include local area networks (LANs), wide area networks (WANs), blockchain networks, and the Internet.

[0113] A computing system can include clients and servers. Clients and servers are generally located far apart and typically interact through communication networks. The client-server relationship is created by computer programs running on the respective computers and having a client-server relationship with each other. The server can be a cloud server, also known as a cloud computing server or cloud host, which is a hosting product within the cloud computing service system to address the shortcomings of traditional physical hosts and VPS services, such as high management difficulty and weak business scalability.

[0114] It should be understood that the various forms of processes shown above can be used, with steps reordered, added, or deleted. For example, the steps described in this invention can be executed in parallel, sequentially, or in different orders, as long as the desired result of the technical solution of this invention can be achieved, and this is not limited herein.

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

Claims

1. A query index method, characterized in that, include: Obtain user input information; The input information is matched with the sub-query tasks in the preset query task mapping table to obtain at least one matched sub-query task. Obtain at least one parameter template corresponding to the subquery task, and standardize the query parameters of the subquery task based on the parameter template; Call the query interface of at least one of the subquery tasks to obtain the normalized query parameters of at least one of the subquery tasks, and output the query results of each subquery task; The query task mapping table includes multiple sub-query tasks, and each sub-query task corresponds to a parameter template and a query interface.

2. The query indexing method according to claim 1, characterized in that, The step of matching the input information with sub-query tasks in a preset query task mapping table to obtain at least one matched sub-query task includes: Extract keywords from the input information; The keywords of the input information and the keywords of the sub-query task are matched for similarity, and at least one sub-query task that matches the input information is determined based on the similarity value. Alternatively, the keywords of the input information and the keywords of the parent query task are matched for similarity. Based on the similarity value, at least one parent query task that matches the input information is determined, thereby obtaining at least one sub-query task that matches the input information; the parent query task corresponds to at least one sub-query task.

3. The query indexing method according to claim 1, characterized in that, The step of matching the input information with sub-query tasks in a preset query task mapping table to obtain at least one matched sub-query task includes: The large model performs contextual reasoning on the input information and performs similarity matching between the reasoning results and the task templates of each subquery task to obtain at least one matched subquery task; each task template corresponds to at least one subquery task.

4. The query indexing method according to claim 1, characterized in that, The step of matching the input information with sub-query tasks in a preset query task mapping table to obtain at least one matched sub-query task includes: The large model makes inferences based on the input information; The reasoning result is then matched with the task description of the subquery task to obtain at least one subquery task that matches the input information. Alternatively, the reasoning result can be matched with the task description of the parent query task to obtain at least one parent query task that matches the input information, and then at least one sub-query task that matches the input information; the parent query task corresponds to at least one sub-query task.

5. The query indexing method according to claim 1, characterized in that, After matching the input information with sub-query tasks in a preset query task mapping table to obtain at least one matched sub-query task, the process further includes: Each of the subquery tasks is assigned to a separate thread for processing.

6. The query indexing method according to claim 1, characterized in that, Also includes: As needed, add, delete, and modify the task name, task characteristics, parameter template, and query interface of the parent query task or child query task in the query task mapping table.

7. The query indexing method according to claim 1, characterized in that, Also includes: Based on the context of the input information, user information, and user preferences, query parameters are extracted and used as normalized query parameters.

8. A query indexing device, characterized in that, include: The information acquisition unit is used to acquire user input information; The task matching unit is used to match the input information with sub-query tasks in a preset query task mapping table to obtain at least one matched sub-query task. A normalization processing unit is used to obtain at least one parameter template corresponding to the subquery task, and to normalize the query parameters of the subquery task based on the parameter template. The query unit is used to call the query interface of at least one of the sub-query tasks, obtain the normalized query parameters of at least one of the sub-query tasks, and output the query results of each of the sub-query tasks. The query task mapping table includes multiple sub-query tasks, and each sub-query task corresponds to a parameter template and a query interface.

9. An electronic device, characterized in that, The electronic device includes: At least one processor; and A memory communicatively connected to the at least one processor; wherein, The memory stores a computer program that can be executed by the at least one processor, the computer program being executed by the at least one processor to enable the at least one processor to perform the query indexing method according to any one of claims 1-7.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions that cause a processor to execute the query indexing method according to any one of claims 1-7.

Citation Information

Patent Citations

  • Structured large-field data query method and device and electronic equipment

    CN118132550A

  • Natural language-based query statement conversion method and device and storage medium

    CN119336783A