WO2026007668A1 - 数据处理方法、问题处理方法、计算设备及存储介质 - Google Patents
数据处理方法、问题处理方法、计算设备及存储介质Info
- Publication number
- WO2026007668A1 WO2026007668A1 PCT/CN2025/100774 CN2025100774W WO2026007668A1 WO 2026007668 A1 WO2026007668 A1 WO 2026007668A1 CN 2025100774 W CN2025100774 W CN 2025100774W WO 2026007668 A1 WO2026007668 A1 WO 2026007668A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- data
- initial
- updated
- reasoning
- result
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N5/00—Computing arrangements using knowledge-based models
- G06N5/04—Inference or reasoning models
- G06N5/041—Abduction
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/30—Information retrieval; Database structures therefor; File system structures therefor of unstructured textual data
- G06F16/33—Querying
- G06F16/332—Query formulation
- G06F16/3329—Natural language query formulation
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F40/00—Handling natural language data
- G06F40/30—Semantic analysis
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/04—Architecture, e.g. interconnection topology
- G06N3/045—Combinations of networks
Definitions
- This disclosure relates to the field of computer technology, and in particular to a data processing method; one or more embodiments of this disclosure also relate to a problem-solving method, a computing device, a computer-readable storage medium, and a computer program product.
- neural network models can be used to process various types of data, thereby meeting the needs of practical applications.
- the data to be processed can be input into a neural network model, and the neural network model can be used to perform data inference to obtain the corresponding data inference results.
- the neural network model has the problem of low inference efficiency. Therefore, how to improve the data inference efficiency of the neural network model has become an urgent technical problem to be solved.
- embodiments of this disclosure provide a data processing method.
- One or more embodiments of this disclosure also relate to a problem-solving method, a data processing apparatus, a problem-solving device, a computing device, a computer-readable storage medium, and a computer program product, to address the technical deficiency of low data inference efficiency in prior art neural network models.
- a data processing method comprising:
- the initial data is updated using the data processing model based on the initial inference result to obtain updated data.
- the number of data in the updated data is less than the number of data in the initial data, and the data processing model is a machine learning model.
- the data processing model is used to perform data inference on the updated data to obtain the update inference result
- a data processing apparatus comprising:
- the first result determination module is configured to determine initial data and use a data processing model to perform data reasoning on the initial data to obtain an initial reasoning result;
- the data update module is configured to update the initial data using the data processing model based on the initial inference result, when the initial data is determined to meet the data inference conditions based on the initial inference result, to obtain updated data, wherein the number of data in the updated data is less than the number of data in the initial data, and the data processing model is a machine learning model.
- the second result determination module is configured to use the data processing model to perform data reasoning on the updated data to obtain an updated reasoning result.
- the third result determination module is configured to determine the update inference result as the target data processing result when it is determined, based on the update inference result, that the updated data does not meet the data inference conditions.
- a problem-solving method including:
- the initial question text is updated using the data processing model based on the initial question reasoning result to obtain an updated question text.
- the updated question text contains less data than the initial question text, and the data processing model is a machine learning model.
- the data processing model is used to perform question reasoning on the updated question text to obtain the updated question reasoning result
- the reasoning result of the updated question is determined as the target question processing result.
- a problem-solving apparatus comprising:
- the first result determination module is configured to determine the initial question text and use a data processing model to perform question reasoning on the initial question text to obtain the initial question reasoning result;
- the question update module is configured to update the initial question text using the data processing model based on the initial question reasoning result, when it is determined that the initial question text meets the question reasoning conditions, to obtain an updated question text, wherein the amount of data in the updated question text is less than the amount of data in the initial question text, and the data processing model is a machine learning model.
- the second result determination module is configured to use the data processing model to perform question reasoning on the updated question text to obtain the updated question reasoning result.
- the third result determination module is configured to determine the updated problem reasoning result as the target problem processing result when it is determined, based on the updated problem reasoning result, that the updated problem text does not meet the problem reasoning conditions.
- the memory is used to store computer programs/instructions
- the processor is used to execute the computer programs/instructions, which, when executed by the processor, implement the steps of the above-described data processing method or problem processing method.
- a computer program product including a computer program/instructions that, when executed by a processor, implement the steps of the above-described data processing method or problem processing method.
- the data processing method in the process of data processing using a data processing model, firstly, performs a first-stage data inference on the initial data using the data processing model to obtain an initial inference result; and then, if it is determined that the initial data meets the data inference conditions based on the initial inference result, the initial data is updated based on the initial inference result to obtain updated data with a smaller data quantity; then, the data processing model is used to perform a second-stage data inference on the updated data with a smaller data quantity to quickly obtain an updated inference result.
- the data processing model can perform rapid inference on updated data with a smaller data quantity, although it requires multiple stages of inference, the overall data inference efficiency is higher than that of the data processing model for data with a larger data quantity, thereby improving the data inference efficiency of the data processing model and avoiding the problem of low inference efficiency of neural network models when processing complex and large data quantities; and, if it is determined that the updated data does not meet the data inference conditions based on the updated inference result, the data inference is terminated, and the updated inference result is determined as the target data processing result, thereby meeting the needs of practical applications to use neural network models to process various types of data.
- Figure 1 is a schematic diagram illustrating the application of a data processing method provided in an embodiment of this disclosure
- FIG. 2 is a flowchart of a data processing method provided in an embodiment of this disclosure
- FIG. 3 is a flowchart of a data processing method provided in an embodiment of this disclosure.
- Figure 4 is a flowchart of a problem-solving method provided in an embodiment of this disclosure.
- Figure 6 is a schematic diagram of the structure of a problem-solving device provided in an embodiment of this disclosure.
- Figure 7 is a structural block diagram of a computing device provided in an embodiment of this disclosure.
- first, second, etc. may be used to describe various information in one or more embodiments of this disclosure, such information should not be limited to these terms. These terms are only used to distinguish information of the same type from one another. For example, first may also be referred to as second without departing from the scope of one or more embodiments of this disclosure, and similarly, second may also be referred to as first.
- word “if” as used herein may be interpreted as “when”, “in response to a determination”, or “when...”.
- the user information including but not limited to user device information, user personal information, etc.
- data including but not limited to data used for analysis, stored data, displayed data, etc.
- the collection, use and processing of related data must comply with the relevant laws, regulations and standards of the relevant countries and regions, and corresponding operation entry points are provided for users to choose to authorize or refuse.
- a large model refers to a deep learning model with a large number of model parameters, typically containing hundreds of millions, tens of billions, hundreds of billions, trillions, or even tens of trillions of model parameters.
- a large model can also be called a foundation model. It is pre-trained using large-scale unlabeled corpora to produce a pre-trained model with hundreds of millions of parameters.
- Such models can adapt to a wide range of downstream tasks and have good generalization ability. Examples include Large Language Models (LLMs) and multi-modal pre-training models.
- NLP Natural Language Processing
- VQA Visual Question Answering
- IC Image Captioning
- Image Generation computer vision tasks
- text-based sentiment classification text summarization
- machine translation text-based sentiment classification, text summarization, and machine translation.
- the main application scenarios for large models include digital assistants, intelligent robots, search, online education, office software, e-commerce, and intelligent design.
- RAG Retrieval-augmented Generation
- RAG refers to a retrieval-augmented generation model that combines retrieval and generation techniques. Specifically, when the model needs to generate text or answer questions, it first retrieves relevant information from a large document collection and then uses this retrieved information to guide text generation, thereby improving the quality and accuracy of predictions.
- a Markov chain is a stochastic process in probability theory and mathematical statistics that possesses the Markov property and exists within a discrete index set and state space. Its main idea is that it is a stochastic process in the state space that transitions from one state to another. This process requires the "memoryless" property: the probability distribution of the next state can only be determined by the current state, and events preceding it in the time series are irrelevant.
- CoT Choin of Thought
- tools refers to tools, which are various external tools that a large model can call.
- Reduction is the process of transforming a complex problem into one or more known, simpler problems. This transformation allows the original problem to be solved indirectly by solving these simpler problems.
- the process of taking steps refers to a series of steps or strategies employed when conducting data reasoning. For example, in solving a mathematical problem, a series of steps or strategies are taken, including selecting appropriate theorems, formulas, algorithms, or methods to gradually approach the solution to the problem. Another example is that in solving a complex integration problem, a series of substitutions, integration by parts, and other steps may be required. These can all be considered as "taking steps”.
- Markov thought chain a model used to describe and infer the behavior of a system, that is, to build an LLM based on Markov chains and large model thought chains.
- Reasoning task refers to the task of inferring unknown information using known information and reasoning rules.
- ToT (Tree of Thoughts): A novel reasoning framework for language models. This framework provides a more structured hinting framework for LLM reasoning by breaking down complex problems into smaller, more easily solvable problems.
- PoT refers to Procedural Reasoning, which is based on CoT and converts the natural descriptive language of thought chains into thought processes, resulting in better performance in reasoning.
- neural network models can be used to process various types of data to meet the needs of practical applications.
- large language models have become a hot research area in recent years.
- large models still perform poorly in logical reasoning, that is to say, large models face certain challenges and limitations in the field of reasoning (especially mathematical logic reasoning).
- this disclosure provides a solution for logical reasoning using methods such as CoT, PoT, and ToT.
- this solution suffers from problems such as low decoding efficiency, cumulative decoding errors, and low utilization of training data.
- One or more embodiments of this disclosure also relate to a problem processing method, a data processing apparatus, a problem processing device, a computing device, a computer-readable storage medium, and a computer program product, which will be described in detail in the following embodiments.
- a user can send a question to a server 104 via a terminal 102.
- the server 104 is the server used by the data processing method in one or more embodiments of this disclosure.
- the server 104 inputs the question into an LLM (Limited Least Model) large model, performs one-step reasoning on the current question using the large model, obtains a first-stage reasoning result, and then uses the question and reasoning result to obtain a new question.
- the large model then performs one-step reasoning on the new question to obtain a second-stage reasoning result, and again uses the reasoning result and the new question to obtain a simpler question with the same answer as the new question.
- Figure 2 shows a flowchart of a data processing method provided according to an embodiment of the present disclosure, which specifically includes the following steps.
- Step 202 Determine the initial data and use the data processing model to perform data reasoning on the initial data to obtain the initial reasoning result.
- the initial data can be understood as the data that needs to be processed using a data processing model.
- the initial data can be any type of data, such as text data, code data, audio data, video data, image data, etc. That is to say, the initial data can be initial question text, initial code data, initial audio data, initial image data, or initial video data, etc., without specific restrictions.
- This data processing model can be understood as a neural network model capable of data processing, such as an LLM or machine learning model. It should be noted that the data processing model differs depending on the application scenario.
- the initial data can be the initial problem text
- the initial reasoning result can be the initial problem reasoning result
- the data processing model can be a problem-solving model used for problem reasoning and updating the initial problem text. Based on this, by inputting the initial problem text into the problem-solving model, the problem reasoning result (e.g., the answer to the problem) output by the model is obtained, thus meeting the practical application requirement of using neural network models for problem reasoning.
- the initial data can be the initial code data
- the initial inference result can be the initial code optimization result based on the initial code data
- the data processing model can be a code optimization model, used to optimize the code and update the code based on the initial code data; based on this, by inputting the initial code data into the code optimization model, the optimized code data (i.e., the target data processing result) output by the code optimization model is obtained, thereby meeting the need for code optimization using a neural network model in practical applications.
- the initial inference result can be understood as the processing result obtained after performing the first stage of data inference on the initial data using the data processing model; the first stage of data inference can be understood as performing data inference on the initial sub-data in the initial data; for example, when the initial data is initial question text, the initial sub-data can be the sub-questions that constitute the initial question text; based on this, the initial inference result can be the question inference result obtained by performing question inference on the sub-questions in the initial question text using the data processing model; as another example, when the initial data is initial code data, the initial sub-data can be one or more code statements in the initial code data; based on this, the initial inference result can be the code optimization result obtained by performing code optimization on one or more code statements in the initial code data using the code optimization model.
- the data processing method provided in this disclosure can process the initial data using multi-stage data inference, and each stage can perform data inference on the initial sub-data in the initial data until the data inference on the initial data is completed; the specific implementation is as follows.
- the step of using a data processing model to perform data reasoning on the initial data to obtain initial reasoning results includes:
- the initial data is input into the data processing model, and the data processing model is used to extract data from the initial data to determine multiple initial sub-data contained in the initial data;
- the sub-data to be inferred is determined from the plurality of initial sub-data, and semantic reasoning is performed on the sub-data to be inferred to obtain the initial reasoning result.
- initial sub-data can be understood as the sub-data that constitutes the initial data.
- the initial sub-data can be sub-question text within the initial question text.
- the initial question text can be "What is 1 + 2 ⁇ 3?”
- the corresponding sub-question texts can be "What is 1 + 2?" and "What is 2 ⁇ 3?”.
- the initial question text can be "Who is the father of A's wife?"
- the corresponding sub-question texts can be "Who is A's wife?" and "Who is the wife's father?”.
- the initial sub-data can be one or more video frames within the initial video data.
- the initial sub-data can be a local image region within the initial image data or a small segment of audio data within the initial audio data.
- the initial sub-data can be one or more code statements within the initial code data.
- the initial code data can be "int main() ⁇
- the initial sub-data can be one or more code statements in the initial code data.
- the sub-data to be inferred can be understood as the sub-data among multiple initial sub-data that currently needs to be used for data inference using the data processing model.
- This sub-data to be inferred can be any one of the multiple initial sub-data, or the initial sub-data that needs to be used for the first stage of data inference, as determined by data inference rules (such as mathematical operation rules or code execution rules).
- data inference rules such as mathematical operation rules or code execution rules.
- the first sub-problem among multiple initial sub-problems, or the sub-problem that needs to be used for the first stage of data inference as determined by mathematical operation rules.
- the sub-problem that needs to be used for the first stage of data inference can be understood as the sub-problem "What is 2 ⁇ 3 equal to?” determined by the data processing model according to mathematical operation rules, which is the sub-problem for the first stage of data inference.
- the following example illustrates the application of the data processing method provided in this disclosure in a problem reasoning scenario.
- the initial data is the initial problem text
- the data processing model is the problem processing model
- the initial sub-data is the initial sub-problem
- the sub-data to be reasoned is the sub-problem to be reasoned
- the initial reasoning result is the initial problem reasoning result.
- the data processing method provided in this disclosure can be applied to a data processing node. After determining the initial problem text, the data processing node inputs the initial problem text into the trained problem processing model and uses the model to extract the problem from the initial problem text, thereby identifying multiple initial sub-problems contained within the initial problem text.
- a sub-problem to be reasoned is selected from these multiple initial sub-problems, and a first-stage problem reasoning is performed on the sub-problem to be reasoned, thereby obtaining the initial problem reasoning result for the sub-problem to be reasoned.
- the data processing node can be a server, virtual machine, container, cloud server, client, mobile terminal, or other device, or it can be an application, software system, or other software device; no specific limitation is made here.
- the data processing model is used to determine the sub-data to be reasoned from multiple initial sub-data contained in the initial data, and data reasoning is performed on the sub-data to be reasoned to obtain the initial reasoning result. Since the data processing model can quickly and accurately perform data reasoning on relatively simple sub-data with a small amount of data, when the data processing model uses a multi-stage data reasoning method to process the initial sub-data, it can efficiently realize data reasoning on the initial data, avoiding the problem of low reasoning efficiency that neural network models have when processing more complex data with a large amount of data.
- the data processing node used in the data processing method can receive initial data sent by the user based on the client, and can subsequently process the initial data.
- the specific implementation is as follows.
- the determination of initial data includes:
- the client receives the initial data sent by the client, wherein the initial data is generated by the client based on the data processing operations performed by the user on the data processing page;
- the client can be a mobile terminal, a smart device, or other server-side device, or it can be an application, software system, or other software.
- the data processing page can be understood as the user interface displayed in the client for processing user data; the data processing page can be a webpage, application interface, etc.
- This data processing operation allows users to perform actions on the data processing page, such as inputting data or clicking buttons, which trigger the data processing controls on the data processing page.
- the client can display a data processing page to the user.
- the user performs data processing operations based on the data processing controls (such as buttons, input boxes, etc.) on the data processing page, thereby triggering the client to generate initial data and send the initial data to the data processing node, instructing the data processing node to perform data processing operations on the initial data using the data processing model.
- the data processing controls such as buttons, input boxes, etc.
- users can perform data processing operations on the initial data by using the client and the data processing page, thereby meeting the user's need to use the data processing model to process the initial data.
- Step 204 If the initial data satisfies the data inference conditions based on the initial inference result, the initial data is updated using the data processing model based on the initial inference result to obtain updated data, wherein the number of data in the updated data is less than the number of data in the initial data, and the data processing model is a machine learning model.
- the data inference condition can be understood as the condition that requires data inference to be performed again using the data processing model.
- This condition can be set according to the actual application scenario. For example, meeting the data inference condition can be understood as not having completed data inference operations for all the initial sub-data contained in the initial data, or being able to update the data based on the data inference result (e.g., initial inference result, updated inference result). Conversely, not meeting the data inference condition can be understood as having completed data inference operations for all the initial sub-data contained in the initial data, or being unable to update the data based on the data inference result (e.g., initial inference result, updated inference result).
- a check can be performed at each stage to determine whether reasoning should continue, thereby enabling timely determination of whether reasoning is complete.
- the specific implementation method is as follows.
- the step of determining that the initial data satisfies the data reasoning conditions based on the initial reasoning result includes:
- the initial sub-data contained in the initial data is determined using the data processing model.
- Semantic analysis is performed on the initial sub-data and the initial inference result. If it is determined that there are multiple initial sub-data and there are sub-data to be updated that are associated with the initial inference result among the multiple initial sub-data, it is determined that the initial data satisfies the data inference condition.
- the sub-data to be updated can be understood as sub-data that needs to be updated using the initial inference result. For example, if there are multiple sub-problem texts such as "1+2 equals what" and “2 ⁇ 3 equals what", and the initial inference result is "2 ⁇ 3 equals 6", the large model can be used to determine the sub-problem "2 ⁇ 3 equals what" as the sub-data to be updated from the multiple sub-problem texts. Subsequently, the data to be updated can be updated based on the initial inference result.
- the initial problem reasoning result and the initial problem are input into the large model again for verification, thereby determining whether to continue problem reasoning (i.e., problem reduction). If it is determined that the initial problem contains multiple subproblems, and among these multiple subproblems there is a subproblem to be updated corresponding to "2 ⁇ 3 equals 6" that is "2 ⁇ 3 equals what". Then it is determined that problem reduction can continue.
- the initial data is an initial question text
- the initial reasoning result is an initial question reasoning result
- the data processing model is a question processing model
- the step of updating the initial data by using the data processing model based on the initial inference result, after determining that the initial data meets the data inference conditions, to obtain updated data includes:
- the initial question text is updated using the question processing model based on the initial question reasoning result to obtain the updated question text.
- the reasoning conditions for this problem can be reduced to the problem's inference conditions.
- the data processing method provided in this disclosure can process the initial data through multi-stage data inference. In each stage of processing, the data to be inferred (e.g., the initial data) in the current stage is updated using the data inference results to obtain data with a smaller amount of data.
- the specific implementation is as follows.
- the step of updating the initial data using the data processing model based on the initial inference result to obtain updated data includes steps one and two:
- Step 1 Using the data processing model, determine multiple initial sub-data contained in the initial data, and determine the sub-data to be updated that is associated with the initial inference result from the multiple initial sub-data.
- the step of using the data processing model to determine multiple initial sub-data contained in the initial data, and determining the sub-data to be updated associated with the initial inference result from the multiple initial sub-data includes:
- the initial inference result and the initial data are input into the data processing model, and the data processing model is used to extract data from the initial data to determine the multiple initial sub-data contained in the initial data.
- Semantic analysis is performed on each initial sub-data and the initial inference result to obtain the sub-data to be updated that is associated with the initial inference result.
- the initial problem reasoning result and the initial problem are input into the large model again for semantic analysis. From the multiple sub-problems contained in the initial problem, the sub-problem to be updated "2 ⁇ 3 equals what" corresponding to "2 ⁇ 3 equals 6" is determined, which facilitates the subsequent problem reduction.
- the data processing model can be used to perform semantic analysis on the multiple initial sub-data contained in the initial data, thereby determining the sub-data to be updated associated with the initial inference result. This facilitates the accurate updating of the sub-data to be updated using the initial inference result, avoids semantic deviation of the initial data due to update errors, and ensures the accuracy of the target data processing result.
- Step 2 Using the data processing model, update the sub-data to be updated in the initial data based on the initial inference result to obtain the updated data.
- the step of using the data processing model to update the sub-data to be updated in the initial data based on the initial inference result to obtain the updated data includes:
- the sub-data to be updated in the initial data is replaced based on the initial inference result to obtain the updated data;
- the semantics of the sub-data to be updated in the initial data are rewritten based on the initial inference results to obtain the updated data.
- the initial problem reasoning result can be "2 ⁇ 3 equals 6" or "6". Based on this, when the data processing model determines the sub-problem to be updated, "2 ⁇ 3 equals what", corresponding to the initial problem reasoning result "6", the sub-problem to be updated, "2 ⁇ 3 equals what”, can be directly replaced in the initial problem text "1+2 ⁇ 3 equals what", resulting in the replaced problem text "1+6 equals what", thus achieving problem reduction.
- Step 206 Use the data processing model to perform data reasoning on the updated data to obtain the update reasoning result.
- the process of using the data processing model to perform data reasoning on the updated data and obtaining the updated reasoning result can be referred to in the above steps of using the data processing model to perform data reasoning on the initial data and obtaining the initial reasoning result, and will not be elaborated on further here.
- the updated question text can be "What is 1+6 equal to?”, which is then input into the large model for semantic reasoning, yielding the corresponding reasoning result "1+6 equals 7".
- Step 208 If, based on the updated inference result, it is determined that the updated data does not meet the data inference conditions, the updated inference result is determined as the target data processing result.
- the target data processing result is understood as the processing result for the initial data.
- the target data processing result can be the question answer corresponding to the question text;
- the target data processing result can be the code data obtained after optimizing the initial code data;
- the initial inference result can be the inference result for a certain initial sub-data in the initial data, and the updated inference result can be the inference result for a certain updated sub-data in the updated data;
- the target data processing can be the processing result for the initial data as a whole; and if the updated inference result determines that the updated data does not meet the data inference conditions, the updated inference result can be determined as the target data processing result.
- the reasoning result of the updated question text is determined to be "1+6 equals 7"
- the reasoning result and the updated question are input into the large model again for semantic analysis. If it is determined that the updated question contains only one sub-question "1+6 equals what", and that the sub-question is related to the reasoning result of the updated question, then the multi-stage data reasoning is determined to be complete. Thus, the reasoning result of the updated question, "the answer equals 7", is taken as the final answer (i.e., the target data processing result).
- the reasoning result of the updated question is "1+6 equals 7”
- "1+6 equals 7" is converted into the question answer "1+2 ⁇ 3 equals 7" (i.e., the target data processing result).
- the step of determining that the updated data does not meet the data inference conditions based on the updated inference result includes:
- the updated sub-data contained in the updated data is determined using the data processing model
- Semantic analysis is performed on the updated sub-data and the updated inference result. If it is determined that there is only one updated sub-data and the updated sub-data is associated with the updated inference result, it is determined that the updated data does not satisfy the data inference condition.
- updated sub-data can be understood as the sub-data contained within the updated data.
- the updated data is an updated question text
- the updated sub-data can be understood as the sub-question text contained within the updated question text.
- the reasoning result of the update question text is determined to be "1+6 equals 7"
- the reasoning result of the update question and the update question are input into the large model again for semantic analysis. If it is determined that the update question contains only one sub-question "1+6 equals multiple”, and that the sub-question is related to the reasoning result of the update question, then the multi-stage data reasoning is determined to be complete.
- the data processing node applied by the data processing method can send the target data processing result to the client for display.
- the specific implementation method is as follows.
- the method further includes:
- the target data processing result is sent to the client so that the client can display the target data processing result based on the data processing page.
- Displaying the target data processing result based on the data processing page can be understood as displaying the target data processing result to the user based on the data processing page, or displaying the target data processing result to other objects based on the data processing page.
- These other objects can be objects that need to obtain the target data processing result.
- the user can be a teacher, and the other objects can be students.
- the target data processing results are displayed by utilizing the client and data processing page, thereby meeting the user's need to process the initial data using the data processing model.
- the method further includes:
- the updated data is updated using the data processing model according to the update inference result to obtain second updated data, wherein the number of data in the second updated data is less than the number of data in the updated data.
- the second updated data is determined as the updated data, and the step of using the data processing model to perform data reasoning on the updated data to obtain the updated reasoning result is continued until it is determined, based on the updated reasoning result, that the updated data does not meet the data reasoning condition.
- the initial problem could be "What is 1+1+2 ⁇ 3?”
- the updated problem could be "What is 1+1+6?”
- the reasoning result for the updated problem subproblem "What is 1+1?" could be "1+1 equals 2".
- the reasoning result and the updated problem are input back into the large model for verification to determine whether to continue problem reasoning (i.e., problem reduction). If it is determined that the updated problem contains multiple subproblems "What is 1+1?" and "What is 1+6?", and among these multiple subproblems there exists a corresponding subproblem to be updated, "What is 1+1?", then it is determined that problem reduction can continue.
- the data processing method in the process of data processing using a data processing model, firstly, performs a first-stage data inference on the initial data using the data processing model to obtain an initial inference result; and then, if it is determined that the initial data meets the data inference conditions based on the initial inference result, the initial data is updated based on the initial inference result to obtain updated data with a smaller data quantity; then, the data processing model is used to perform a second-stage data inference on the updated data with a smaller data quantity to quickly obtain an updated inference result.
- the data processing model can perform rapid inference on updated data with a smaller data quantity, although it requires multiple stages of inference, the overall data inference efficiency is higher than that of the data processing model for data with a larger data quantity, thereby improving the data inference efficiency of the data processing model and avoiding the problem of low inference efficiency of neural network models when processing complex and large data quantities; and, if it is determined that the updated data does not meet the data inference conditions based on the updated inference result, the data inference is terminated, and the updated inference result is determined as the target data processing result, thereby meeting the needs of practical applications to use neural network models to process various types of data.
- Figure 3 shows a flowchart of the processing procedure of a data processing method provided in one embodiment of this disclosure.
- the data processing method provided in this disclosure can combine Markov chains with CoT, PoT, or ToT. Its core idea is to transform the problem into multiple independent problem reasoning and sub-problem generation; that is, to transform a multi-step reasoning problem into a process of multiple independent problem reasoning and sub-problem generation, completing the reasoning process of the problem through multiple iterations; specifically, it includes the following steps.
- Step 302 Input the user-provided question 1 into the LLM for inference.
- Question 1 can be understood as a question that requires LLM reasoning to obtain an answer.
- Question 1 can be the original question input by the user.
- Step 304 Determine the reasoning result 1 obtained by the LLM in reasoning about problem 1, and reduce problem 1 based on the reasoning result 1 to obtain problem 2.
- the data processing method provided in this disclosure can complete the reasoning process of the problem through a multi-stage iterative process.
- the original large model LLM will use the information from previous reasoning to perform the reasoning of the current step (i.e. the current stage).
- the reasoning steps for the original problem are transformed into a more streamlined process in which the large model only needs to complete one step of reasoning based on the current problem to complete the reasoning of the entire task.
- This step of reasoning refers to simplifying/transforming and solving one or more sub-problems (i.e., known conditions) in the original problem by using a large model + tools or a large model CoT.
- the execution method in step 304 is as follows: the LLM large model can be used to perform one-step reasoning on the sub-problems in the current problem (i.e., problem 1); after the one-step reasoning is completed, the reasoning result 1 (i.e., step-wise solution) corresponding to the sub-problem is obtained;
- the reasoning result 1 i.e., step-wise solution
- the new problem is obtained by reducing problem 1 using reasoning result 1.
- the problem reduction refers to using the text generation capabilities of a large model to replace and rewrite the known conditions in the original problem based on the original problem and the simplified conditions (i.e., the reasoning results) in one step of reasoning, thereby obtaining a new problem that is simpler than the original problem.
- the large model needs to verify whether to continue problem reasoning at each stage. This ensures timely determination of whether reasoning is complete and avoids wasting computational resources due to repeated reasoning.
- the method by which this large model verifies whether to continue problem reasoning can be seen in the following example:
- the original problem could be "What is 1 + 2 ⁇ 3?”
- the corresponding subproblems could be "What is 1 + 2?" and "What is 2 ⁇ 3?”.
- the result of the reasoning is determined to be "2 ⁇ 3 equals 6".
- the large model can determine whether the original problem contains multiple subproblems, and whether there are subproblems among these multiple subproblems that can be reduced based on the reasoning results; if the original problem contains multiple subproblems, and there are subproblems that can be reduced, it is determined that problem reasoning needs to continue.
- the original problem is reduced based on the reasoning result to obtain a new problem, and then a further reasoning operation is performed based on the new problem until the data reasoning is completed.
- Step 306 Input question 2 into the LLM and continue with one more step of reasoning.
- Step 308 Determine the reasoning result 2 obtained by the LLM in reasoning about problem 2, and reduce problem 2 based on the reasoning result 2.
- the large model is used to perform one-step reasoning on the new problem to obtain a step-wise solution. Then, the step-wise solution is used again to reduce the new problem to obtain a simpler problem with the same answer as the new problem.
- Step 310 Input question N into LLM to continue question reasoning.
- Step 312 Obtain the final reasoning result N.
- judgment condition for the result of the problem reasoning can be:
- the large model needs to check whether to continue problem reasoning at each stage. If it is determined that the original problem contains only one subproblem and that the subproblem cannot be reduced to a problem, then the problem reasoning can be considered to have ended.
- the large model determines that the current original problem contains a subproblem of "what is 1+6", and that the subproblem cannot be reduced further, it determines that the problem reasoning ends.
- the data processing method in one or more embodiments of this disclosure provides an efficient reasoning method based on Markov thought chains.
- the above describes the application of Markov thought chain reasoning (MCTR) in mathematical reasoning tasks.
- MCTR Markov thought chain reasoning
- this method treats the problem as a state, the solution as an action, and the solution process as the process of taking the current action from the current state.
- the reduction process is abstracted as the state transition process from the current state to the next state, thereby realizing logical reasoning through multiple rounds of Markov state transitions.
- the data processing method in one or more embodiments of this disclosure after converting the model into the form of MCoT, will transform a complex problem into a series of one-step reasoning problems from difficult to simple sub-problems, called atomic steps. In this way, the uniqueness of the original reasoning chain can be broken, ensuring that when solving a new and more difficult problem, appropriate steps can be found from the previous atomic steps to combine and solve the problem.
- the data processing method in one or more embodiments of this disclosure guides the large model's inference efficiency/time to decrease significantly in the form of O(n ⁇ 2)/exponential as the inference length increases.
- the inference process of each sub-problem will be very short, which will significantly reduce the attention window of the large model, significantly reduce the demand of the large model for GPU memory, and improve decoding efficiency.
- the data processing method in one or more embodiments of this disclosure by employing the Markov Chain of Reasoning (MCoT) method, divides mathematical logic reasoning into two processes: one-step reasoning and problem reduction. It also utilizes the independence of reasoning for each sub-problem to effectively improve problem reduction on the dataset and the decoding efficiency of large models.
- MoT Markov Chain of Reasoning
- the original complex problem is simplified into a simpler and more intuitive problem.
- multiple complex problems can be transformed into the same simple and intuitive problem (problem reduction process). Therefore, the learning difficulty of the original complex problem in the reasoning path learning of the large model is reduced (the large model transforms from learning to solve this complex problem into a combination of simplifying the complex problem and solving the simple problem, and the simple problem/one-step reasoning problem is more abundant in the large model training corpus and is easier to learn). This achieves the goal of more efficient use of pre-trained models and task training data, and improves the efficiency of data utilization.
- the inference cost of large models is significantly reduced, and the inference efficiency of large models is improved (because in the inference process of large models, each inference step has to interact with all the previous steps, which makes the decoding computation and memory usage very high. If piecewise inference is performed, these two points can be significantly optimized).
- the current solution can make it possible to train large models without long context, which is an alternative to long context in inference generation; combined with rag, it can even solve all the current requirements of long context.
- the MCTR method has the advantages of: the process is more in line with human reasoning logic, the reasoning process is efficient and accurate, and the dataset does not need to be manually constructed.
- Figure 4 shows a flowchart of a problem-solving method provided according to an embodiment of the present disclosure, which specifically includes the following steps.
- Step 402 Determine the initial question text and use the data processing model to perform question reasoning on the initial question text to obtain the initial question reasoning result.
- Step 404 If, based on the initial question reasoning result, it is determined that the initial question text satisfies the question reasoning condition, the initial question text is updated using the data processing model based on the initial question reasoning result to obtain an updated question text.
- the updated question text contains less data than the initial question text, and the data processing model is a machine learning model.
- Step 406 Use the data processing model to perform question reasoning on the updated question text to obtain the updated question reasoning result.
- Step 408 If, based on the reasoning result of the updated problem, it is determined that the updated problem text does not meet the reasoning conditions of the problem, the reasoning result of the updated problem is determined as the target problem processing result.
- determining the initial question text includes:
- the client receives the initial problem text sent by the client, wherein the initial problem text is generated by the client based on the problem handling operation performed by the user on the problem handling page;
- the result of the target problem handling is sent to the client, so that the client can display the result of the target problem handling to the user based on the problem handling page.
- the problem-solving method in the process of using a problem-solving model for problem-solving, firstly, uses the problem-solving model to perform a first-stage problem reasoning on an initial problem text to obtain an initial problem reasoning result; and then, if it is determined that the initial problem text meets the problem reasoning conditions based on the initial problem reasoning result, the initial problem text is updated based on the initial problem reasoning result to obtain an updated problem text with a smaller amount of data; then, the problem-solving model is used to perform a second-stage problem reasoning on the updated problem text with a smaller amount of data to quickly obtain an updated problem reasoning result.
- the problem-solving model can perform rapid reasoning on updated problem text with a smaller amount of data, although it requires multiple stages of reasoning, the overall reasoning efficiency is higher than that of the problem-solving model for problem text with a larger amount of data, thereby improving the problem reasoning efficiency of the problem-solving model and avoiding the problem of low reasoning efficiency of neural network models when processing complex and large amounts of data; and, if it is determined that the updated problem text does not meet the problem reasoning conditions based on the updated problem reasoning result, the problem reasoning is terminated, and the updated problem reasoning result is determined as the target problem-solving result, thereby meeting the need in practical applications to use neural network models to process various types of problems.
- Figure 5 shows a schematic diagram of the structure of a data processing apparatus provided in one embodiment of this disclosure. As shown in Figure 5, the apparatus includes:
- the first result determination module 502 is configured to determine initial data and use a data processing model to perform data reasoning on the initial data to obtain an initial reasoning result;
- the data update module 504 is configured to update the initial data using the data processing model based on the initial inference result when the initial data is determined to meet the data inference conditions, thereby obtaining updated data.
- the updated data has a smaller data quantity than the initial data, and the data processing model is a machine learning model.
- the second result determination module 506 is configured to use the data processing model to perform data reasoning on the updated data to obtain an updated reasoning result.
- the third result determination module 508 is configured to determine the update inference result as the target data processing result when it is determined, based on the update inference result, that the updated data does not meet the data inference conditions.
- the data update module 504 is further configured to:
- the sub-data to be updated in the initial data is updated based on the initial inference result to obtain the updated data.
- the data update module 504 is further configured to:
- the sub-data to be updated in the initial data is replaced based on the initial inference result to obtain the updated data;
- the semantics of the sub-data to be updated in the initial data are rewritten based on the initial inference results to obtain the updated data.
- the data update module 504 is further configured to:
- the initial inference result and the initial data are input into the data processing model, and the data processing model is used to extract data from the initial data to determine the multiple initial sub-data contained in the initial data.
- Semantic analysis is performed on each initial sub-data and the initial inference result to obtain the sub-data to be updated that is associated with the initial inference result.
- the first result determination module 502 is further configured to:
- the initial data is input into the data processing model, and the data processing model is used to extract data from the initial data to determine multiple initial sub-data contained in the initial data;
- the sub-data to be inferred is determined from the plurality of initial sub-data, and semantic reasoning is performed on the sub-data to be inferred to obtain the initial reasoning result.
- the data processing device further includes a data inference module, configured to:
- the updated data is updated using the data processing model according to the update inference result to obtain second updated data, wherein the number of data in the second updated data is less than the number of data in the updated data.
- the second updated data is determined as the updated data, and the step of using the data processing model to perform data reasoning on the updated data to obtain the updated reasoning result is continued until it is determined, based on the updated reasoning result, that the updated data does not meet the data reasoning condition.
- the first result determination module 502 is further configured to:
- the client receives the initial data sent by the client, wherein the initial data is generated by the client based on the data processing operations performed by the user on the data processing page;
- the data processing device further includes a result sending module, configured as follows:
- the target data processing result is sent to the client so that the client can display the target data processing result based on the data processing page.
- the initial data is the initial question text
- the initial reasoning result is the initial question reasoning result
- the data processing model is the question processing model
- the data update module 504 is further configured to:
- the initial question text is updated using the question processing model based on the initial question reasoning result to obtain the updated question text.
- the data update module 504 is further configured to:
- the initial sub-data contained in the initial data is determined using the data processing model.
- Semantic analysis is performed on the initial sub-data and the initial inference result. If it is determined that there are multiple initial sub-data and there are sub-data to be updated that are associated with the initial inference result among the multiple initial sub-data, it is determined that the initial data satisfies the data inference condition.
- the third result determination module 508 is configured as follows:
- the updated sub-data contained in the updated data is determined using the data processing model
- Semantic analysis is performed on the updated sub-data and the updated inference result. If it is determined that there is only one updated sub-data and the updated sub-data is associated with the updated inference result, it is determined that the updated data does not satisfy the data inference condition.
- the data processing apparatus during the data processing process using a data processing model, firstly, performs a first-stage data inference on initial data using the data processing model to obtain an initial inference result; and then, if it is determined that the initial data meets the data inference conditions based on the initial inference result, the initial data is updated based on the initial inference result to obtain updated data with a smaller data quantity than the initial data; then, the data processing model performs a second-stage data inference on the updated data with a smaller data quantity to quickly obtain an updated inference result.
- the data processing model can perform rapid inference on updated data with a smaller data quantity, although multiple stages of inference are required, the overall data inference efficiency is higher than that of the data processing model for data with a larger data quantity, thereby improving the data inference efficiency of the data processing model and avoiding the problem of low inference efficiency of neural network models when processing complex and large data quantities; and, if it is determined that the updated data does not meet the data inference conditions based on the updated inference result, the data inference is terminated, and the updated inference result is determined as the target data processing result, thereby meeting the needs of practical applications to use neural network models to process various types of data.
- Figure 6 shows a schematic diagram of the structure of a problem-solving apparatus provided in one embodiment of this disclosure. As shown in Figure 6, the apparatus includes:
- the first result determination module 602 is configured to determine the initial question text and use a data processing model to perform question reasoning on the initial question text to obtain the initial question reasoning result;
- the question update module 604 is configured to update the initial question text using the data processing model based on the initial question reasoning result when it is determined that the initial question text meets the question reasoning conditions, thereby obtaining an updated question text.
- the updated question text contains less data than the initial question text, and the data processing model is a machine learning model.
- the second result determination module 606 is configured to use the data processing model to perform question reasoning on the updated question text to obtain the updated question reasoning result.
- the third result determination module 608 is configured to determine the updated problem reasoning result as the target problem processing result when it is determined, based on the updated problem reasoning result, that the updated problem text does not meet the problem reasoning conditions.
- the first result determination module 602 is further configured to:
- the client receives the initial problem text sent by the client, wherein the initial problem text is generated by the client based on the problem handling operation performed by the user on the problem handling page;
- the problem processing device further includes a result sending module, configured as follows:
- the result of the target problem handling is sent to the client, so that the client can display the result of the target problem handling to the user based on the problem handling page.
- the problem processing apparatus in the process of problem processing using a problem processing model, firstly, performs a first-stage problem reasoning on an initial problem text using the problem processing model to obtain an initial problem reasoning result; and then, if it is determined that the initial problem text meets the problem reasoning conditions based on the initial problem reasoning result, it updates the initial problem text based on the initial problem reasoning result to obtain an updated problem text with a smaller amount of data; then, it performs a second-stage problem reasoning on the updated problem text with a smaller amount of data using the problem processing model to quickly obtain an updated problem reasoning result.
- the problem processing model can perform rapid reasoning on updated problem text with a smaller amount of data, although it requires multiple stages of reasoning, the overall reasoning efficiency is higher than that of the problem processing model for problem text with a larger amount of data, thereby improving the problem reasoning efficiency of the problem processing model and avoiding the problem of low reasoning efficiency of neural network models when processing complex and large amounts of data; and, if it is determined that the updated problem text does not meet the problem reasoning conditions based on the updated problem reasoning result, it determines to end the problem reasoning and determines the updated problem reasoning result as the target problem processing result, thereby meeting the need in practical applications to use neural network models to process various types of problems.
- Figure 7 shows a structural block diagram of a computing device 700 according to an embodiment of the present disclosure.
- the components of the computing device 700 include, but are not limited to, a memory 710 and a processor 720.
- the processor 720 is connected to the memory 710 via a bus 730, and a database 750 is used to store data.
- the computing device 700 also includes an access device 740, which enables the computing device 700 to communicate via one or more networks 760.
- networks include a public switched telephone network (PSTN), a local area network (LAN), a wide area network (WAN), a personal area network (PAN), or a combination of communication networks such as the Internet.
- Access device 740 may include one or more of any type of wired or wireless network interface (e.g., network interface card (NIC)), such as an IEEE 802.11 Wireless Local Area Network (WLAN) wireless interface, a Wi-MAX (Worldwide Interoperability for Microwave Access) interface, an Ethernet interface, a Universal Serial Bus (USB) interface, a cellular network interface, a Bluetooth interface, or a Near Field Communication (NFC) interface.
- NIC network interface card
- the aforementioned components of the computing device 700 may be interconnected, for example, via a bus. It should be understood that the computing device block diagram shown in FIG. 7 is merely for illustrative purposes and is not intended to limit the scope of this disclosure. Those skilled in the art can add or replace other components as needed.
- the computing device 700 can be any type of stationary or mobile computing device, including mobile computers or mobile computing devices (e.g., tablet computers, personal digital assistants, laptop computers, notebook computers, netbooks, etc.), mobile phones (e.g., smartphones), wearable computing devices (e.g., smartwatches, smart glasses, etc.) or other types of mobile devices, or stationary computing devices such as desktop computers or personal computers (PCs).
- the computing device 700 can also be a mobile or stationary server.
- the processor 720 is configured to execute the following computer-executable instructions, which, when executed by the processor, implement the steps of the aforementioned data processing method or problem processing method.
- the various embodiments in this disclosure are described in a progressive manner. Similar or identical parts between embodiments can be referred to mutually. Each embodiment focuses on describing the differences from other embodiments.
- the computing device embodiments are basically similar to the data processing method or problem processing method embodiments, so the description is relatively simple; relevant parts can be referred to in the description of the data processing method or problem processing method embodiments.
- An embodiment of this disclosure also provides a computer-readable storage medium storing a computer program/instructions that, when executed by a processor, implement the steps of the above-described data processing method or problem processing method.
- An embodiment of this disclosure also provides a computer program product, including a computer program/instructions that, when executed by a processor, implement the steps of the above-described data processing method or problem processing method.
- the computer instructions include computer program code, which may be in the form of source code, object code, executable file, or certain intermediate forms.
- the computer-readable medium may include: any entity or device capable of carrying the computer program code, recording media, USB flash drive, portable hard drive, magnetic disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signals, telecommunication signals, and software distribution media, etc. It should be noted that the content included in the computer-readable medium may be appropriately added or removed according to the requirements of patent practice. For example, in some regions, according to patent practice, computer-readable media may not include electrical carrier signals and telecommunication signals.
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- Computational Linguistics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Artificial Intelligence (AREA)
- Mathematical Physics (AREA)
- Data Mining & Analysis (AREA)
- Evolutionary Computation (AREA)
- Software Systems (AREA)
- Computing Systems (AREA)
- Health & Medical Sciences (AREA)
- General Health & Medical Sciences (AREA)
- Audiology, Speech & Language Pathology (AREA)
- Biomedical Technology (AREA)
- Biophysics (AREA)
- Life Sciences & Earth Sciences (AREA)
- Molecular Biology (AREA)
- Databases & Information Systems (AREA)
- Human Computer Interaction (AREA)
- Machine Translation (AREA)
Abstract
本公开实施例提供数据处理方法、问题处理方法、计算设备及存储介质,其中所述数据处理方法,包括:确定初始数据,并利用数据处理模型对所述初始数据进行数据推理,获得初始推理结果;在根据所述初始推理结果,确定所述初始数据满足数据推理条件的情况下,根据所述初始推理结果,利用所述数据处理模型对所述初始数据进行数据更新,获得更新数据,其中,所述更新数据的数据数量小于所述初始数据的数据数量,且所述数据处理模型为机器学习模型;利用所述数据处理模型对所述更新数据进行数据推理,获得更新推理结果;在根据所述更新推理结果,确定所述更新数据不满足所述数据推理条件的情况下,将所述更新推理结果确定为目标数据处理结果。
Description
本公开要求申请号为202410897972.9的中国专利申请的优先权,该中国专利申请于2024年07月04日提交中国专利局,申请名称为“数据处理方法、问题处理方法、计算设备及存储介质”,其全部内容通过引用结合在本公开中。
本公开实施例涉及计算机技术领域,特别涉及一种数据处理方法;本公开一个或者多个实施例同时涉及一种问题处理方法,一种计算设备,一种计算机可读存储介质以及一种计算机程序产品。
随着人工智能技术不断地发展,可以利用神经网络模型对各种类型的数据进行处理,从而满足实际应用的需求。
在现有技术中,可以将待处理的数据输入神经网络模型,利用该神经网络模型进行数据推理,从而获得对应的数据推理结果;但是,神经网络模型在对较为复杂且数据量较大的数据进行处理的过程中,会存在推理效率较低的问题,因此,如何提高神经网络模型的数据推理效率成为亟需解决的技术问题。
有鉴于此,本公开实施例提供了一种数据处理方法。本公开一个或者多个实施例同时涉及一种问题处理方法,一种数据处理装置,一种问题处理装置,一种计算设备,一种计算机可读存储介质以及一种计算机程序产品,以解决现有技术中神经网络模型的数据推理效率较低的技术缺陷。
根据本公开实施例的第一方面,提供了一种数据处理方法,包括:
确定初始数据,并利用数据处理模型对所述初始数据进行数据推理,获得初始推理结果;
在根据所述初始推理结果,确定所述初始数据满足数据推理条件的情况下,根据所述初始推理结果,利用所述数据处理模型对所述初始数据进行数据更新,获得更新数据,其中,所述更新数据的数据数量小于所述初始数据的数据数量,且所述数据处理模型为机器学习模型;
利用所述数据处理模型对所述更新数据进行数据推理,获得更新推理结果;
在根据所述更新推理结果,确定所述更新数据不满足所述数据推理条件的情况下,将所述更新推理结果确定为目标数据处理结果。
根据本公开实施例的第二方面,提供了一种数据处理装置,包括:
第一结果确定模块,被配置为确定初始数据,并利用数据处理模型对所述初始数据进行数据推理,获得初始推理结果;
数据更新模块,被配置为在根据所述初始推理结果,确定所述初始数据满足数据推理条件的情况下,根据所述初始推理结果,利用所述数据处理模型对所述初始数据进行数据更新,获得更新数据,其中,所述更新数据的数据数量小于所述初始数据的数据数量,且所述数据处理模型为机器学习模型;
第二结果确定模块,被配置为利用所述数据处理模型对所述更新数据进行数据推理,获得更新推理结果;
第三结果确定模块,被配置为在根据所述更新推理结果,确定所述更新数据不满足所述数据推理条件的情况下,将所述更新推理结果确定为目标数据处理结果。
根据本公开实施例的第三方面,提供了一种问题处理方法,包括:
确定初始问题文本,并利用数据处理模型对所述初始问题文本进行问题推理,获得初始问题推理结果;
在根据所述初始问题推理结果,确定所述初始问题文本满足问题推理条件的情况下,根据所述初始问题推理结果,利用所述数据处理模型对所述初始问题文本进行问题更新,获得更新问题文本,其中,所述更新问题文本的数据数量小于所述初始问题文本的数据数量,且所述数据处理模型为机器学习模型;
利用所述数据处理模型对所述更新问题文本进行问题推理,获得更新问题推理结果;
在根据所述更新问题推理结果,确定所述更新问题文本不满足所述问题推理条件的情况下,将所述更新问题推理结果确定为目标问题处理结果。
根据本公开实施例的第四方面,提供了一种问题处理装置,包括:
第一结果确定模块,被配置为确定初始问题文本,并利用数据处理模型对所述初始问题文本进行问题推理,获得初始问题推理结果;
问题更新模块,被配置为在根据所述初始问题推理结果,确定所述初始问题文本满足问题推理条件的情况下,根据所述初始问题推理结果,利用所述数据处理模型对所述初始问题文本进行问题更新,获得更新问题文本,其中,所述更新问题文本的数据数量小于所述初始问题文本的数据数量,且所述数据处理模型为机器学习模型;
第二结果确定模块,被配置为利用所述数据处理模型对所述更新问题文本进行问题推理,获得更新问题推理结果;
第三结果确定模块,被配置为在根据所述更新问题推理结果,确定所述更新问题文本不满足所述问题推理条件的情况下,将所述更新问题推理结果确定为目标问题处理结果。
根据本公开实施例的第五方面,提供了一种计算设备,包括:
存储器和处理器;
所述存储器用于存储计算机程序/指令,所述处理器用于执行所述计算机程序/指令,该计算机程序/指令被处理器执行时实现上述数据处理方法或者问题处理方法的步骤。
根据本公开实施例的第六方面,提供了一种计算机可读存储介质,其存储有计算机程序/指令,该计算机程序/指令被处理器执行时实现上述数据处理方法或者问题处理方法的步骤。
根据本公开实施例的第七方面,提供了一种计算机程序产品,包括计算机程序/指令,该计算机程序/指令被处理器执行时实现上述数据处理方法或者问题处理方法的步骤。
本公开一个或多个实施例中提供的数据处理方法,在利用数据处理模型进行数据处理的过程中,首先,利用数据处理模型对初始数据进行第一阶段的数据推理,获得初始推理结果;并且,在根据初始推理结果确定初始数据满足数据推理条件的情况下,根据初始推理结果对初始数据进行数据更新,从而获得数据数量小于初始数据的更新数据;然后,利用该数据处理模型对数据数量较小的更新数据进行第二阶段的数据推理,从而快速的获得更新推理结果,由于数据处理模型可以对数据数量较小的更新数据进行快速推理,因此虽然需要通过多个阶段进行推理,但是整体的数据推理效率会高于数据处理模型针对数据量较大的数据的数据推理效率,从而提高了数据处理模型的数据推理效率,避免神经网络模型在对较为复杂且数据量较大的数据进行处理的过程中所存在的推理效率较低的问题;并且,在根据更新推理结果确定更新数据不满足数据推理条件的情况下,则确定结束数据推理,将更新推理结果确定为目标数据处理结果,从而满足了实际应用中需要利用神经网络模型对各种类型的数据进行数据处理的需求。
图1是本公开一个实施例提供的一种数据处理方法的应用示意图;
图2是本公开一个实施例提供的一种数据处理方法的流程图;
图3是本公开一个实施例提供的一种数据处理方法的处理过程流程图;
图4是本公开一个实施例提供的一种问题处理方法的流程图;
图5是本公开一个实施例提供的一种数据处理装置的结构示意图;
图6是本公开一个实施例提供的一种问题处理装置的结构示意图;
图7是本公开一个实施例提供的一种计算设备的结构框图。
在下面的描述中阐述了很多具体细节以便于充分理解本公开。但是本公开能够以很多不同于在此描述的其它方式来实施,本领域技术人员可以在不违背本公开内涵的情况下做类似推广,因此本公开不受下面公开的具体实施的限制。
在本公开一个或多个实施例中使用的术语是仅仅出于描述特定实施例的目的,而非旨在限制本公开一个或多个实施例。在本公开一个或多个实施例和所附权利要求书中所使用的单数形式的“一种”、“所述”和“该”也旨在包括多数形式,除非上下文清楚地表示其他含义。还应当理解,本公开一个或多个实施例中使用的术语“和/或”是指并包含一个或多个相关联的列出项目的任何或所有可能组合。
应当理解,尽管在本公开一个或多个实施例中可能采用术语第一、第二等来描述各种信息,但这些信息不应限于这些术语。这些术语仅用来将同一类型的信息彼此区分开。例如,在不脱离本公开一个或多个实施例范围的情况下,第一也可以被称为第二,类似地,第二也可以被称为第一。取决于语境,如在此所使用的词语“如果”可以被解释成为“在……时”或“当……时”或“响应于确定”。
此外,需要说明的是,本公开一个或多个实施例所涉及的用户信息(包括但不限于用户设备信息、用户个人信息等)和数据(包括但不限于用于分析的数据、存储的数据、展示的数据等),均为经用户授权或者经过各方充分授权的信息和数据,并且相关数据的收集、使用和处理需要遵守相关国家和地区的相关法律法规和标准,并提供有相应的操作入口,供用户选择授权或者拒绝。
本公开一个或多个实施例中,大模型是指具有大规模模型参数的深度学习模型,通常包含上亿、上百亿、上千亿、上万亿甚至十万亿以上的模型参数。大模型又可以称为基石模型/基础模型(Foundation Model),通过大规模无标注的语料进行大模型的预训练,产出亿级以上参数的预训练模型,这种模型能适应广泛的下游任务,模型具有较好的泛化能力,例如大规模语言模型(Large Language Model,LLM)、多模态预训练模型(multi-modal pre-training model)等。
大模型在实际应用时,仅需少量样本对预训练模型进行微调即可应用于不同的任务中,大模型可以广泛应用于自然语言处理(Natural Language Processing,简称NLP)、计算机视觉等领域,具体可以应用于如视觉问答(Visual Question Answering,简称VQA)、图像描述(Image Caption,简称IC)、图像生成等计算机视觉领域任务,以及基于文本的情感分类、文本摘要生成、机器翻译等自然语言处理领域任务,大模型主要的应用场景包括数字助理、智能机器人、搜索、在线教育、办公软件、电子商务、智能设计等。
首先,对本公开一个或多个实施例涉及的名词术语进行解释。
RAG(Retrieval-augmented Generation):是指检索增强生成,是一种结合检索和生成技术的检索增强生成模型;检索增强生成模型结合了语言模型和信息检索技术。具体来说,当模型需要生成文本或者回答问题时,它会先从一个庞大的文档集合中检索出相关的信息,然后利用这些检索到的信息来指导文本的生成,从而提高预测的质量和准确性。
马尔可夫链(Markov Chain,MC):是概率论和数理统计中具有马尔可夫性质(Markov property)且存在于离散的指数集(index set)和状态空间(state space)内的随机过程(stochastic process);其主要思想在于:状态空间中经过从一个状态到另一个状态的转换的随机过程。该过程要求具备“无记忆”的性质:下一状态的概率分布只能由当前状态决定,在时间序列中它前面的事件均与之无关。
CoT(Chain of Thought):是指大模型思维链,大模型思维链是一种高级提示工程,旨在增强大语言模型在各类复杂推理任务上的表现。通过让大模型逐步参与将一个复杂问题分解为一步一步的子问题并依次进行求解的过程可以显著提升大模型的性能,而这一系列推理的中间步骤就被称为思维链(Chain of Thought)。
tools:是指工具,是大模型能够调用的各种外部工具。
归约过程(Reduction):是指将一个复杂问题转化为一个或多个已知的、较简单的问题的过程。这种转换使得原问题可以通过解决这些简单问题来间接求解。
采取过程:指在进行数据推理时采用的一系列步骤或策略,例如,在解决数学问题时采取的一系列步骤或策略,这包括选择合适的定理、公式、算法或方法来逐步接近问题的解决方案;再例如,在解决一个复杂的积分问题时,可能需要采取一系列的代换、分部积分等步骤;这些都可以视为“采取过程”。
马尔可夫思维链:一种用于描述和推断系统行为的模型,也即是基于马尔可夫链以及大模型思维链构建LLM。
推理任务:指通过已知信息和推理规则来推断未知信息的任务。
ToT(Tree of Thoughts):即思维树,是一种新型语言模型推理框架。该思维树通过将复杂问题分解为更易于解决的小问题,为LLM推理提供了一个更结构化的提示框架。
PoT:是指思维程序推理,是在CoT的基础上,将思维链的自然描述语言转换为思维程序,能够在推理上表现得更好。
随着人工智能技术不断地发展,可以利用神经网络模型对各种类型的数据进行处理,从而满足实际应用的需求;例如,随着人工智能和自然语言处理技术的迅猛发展,大语言模型成为了近年来的热门研究领域;但是大模型在逻辑推理上依然表现较差,也即是说,大模型在推理领域(尤其是数理逻辑推理)存在一定的挑战和局限性。
在实际应用中,大模型的推理方法分为单步推理和多步推理,其中,单步推理可以解决简单的问题,且推理效率相对较高;其中,多步推理具有更强的推理逻辑和更高的推理准确率。然而,多步推理存在较大的缺陷:随着推理过程的加深,容易出现幻觉和推理效率低下的问题。
针对上述问题,本公开提供了采用CoT、PoT、ToT等方式进行逻辑推理的方案,但是该方案存在解码效率低,解码误差累计、训练数据利用率低等问题。
基于此,在本公开中,提供了一种数据处理方法,本公开一个或者多个实施例同时涉及一种问题处理方法,一种数据处理装置,一种问题处理装置,一种计算设备,一种计算机可读存储介质以及一种计算机程序产品,在下面的实施例中逐一进行详细说明。
参见图1,图1示出了根据本公开一个实施例提供的一种数据处理方法的应用示意图,基于图1可知,用户可以通过终端102向服务端104发送问题,该服务端104为本公开一个或多个实施例中的数据处理方法所应用的服务端;该服务端104在接收到问题之后,将该问题输入至LLM大模型中,利用大模型对当前问题进行一步推理,一步推理完成得到第一阶段的推理结果,然后利用问题和推理结果获得一个新问题;利用大模型对新问题进行一步推理,获得第二阶段的推理结果,并再次基于推理结果和新问题获得一个和新问题答案一致的、但是更简单的问题;重复这个过程,直到可以通过问题解答获得答案为止,获得用户问题对应的答案;然后将该答案发送至终端102。上述步骤中,通过将原始的复杂问题中长序列推理过程转化为多个短序列推理过程,显著降低大模型的推理成本,提高大模型的推理效率。
参见图2,图2示出了根据本公开一个实施例提供的一种数据处理方法的流程图,具体包括以下步骤。
步骤202:确定初始数据,并利用数据处理模型对所述初始数据进行数据推理,获得初始推理结果。
其中,该初始数据可以理解为需要利用数据处理模型进行数据处理的数据,该初始数据可以为任意一种类型的数据,例如,该初始数据可以为文本数据、代码数据、语言数据或视频数据、图像数据等。也即是说,该初始数据可以为初始问题文本、初始代码数据、初始语音数据、初始图像数据或初始视频数据等,在此不做具体限制。
该数据处理模型可以理解为能够进行数据处理的神经网络模型,该数据处理模型可以为LLM、机器学习模型;需要说明的是,在该数据处理方法应用于不同场景的情况下,该数据处理模型也不同,例如,在数据处理方法应用于问题推理场景的情况下,该初始数据可以为初始问题文本;该初始推理结果可以为初始问题推理结果;该数据处理模型可以问题处理模型,用于进行问题推理和对初始问题文本进行问题更新;基于此,通过将初始问题文本输入问题处理模型,获得该问题处理模型输出的问题推理结果(例如问题答案),从而满足实际应用中需要利用神经网络模型进行问题推理的需求。
再例如,在数据处理方法应用于代码优化场景的情况下,该初始数据可以为初始代码数据;该初始推理结果可以为针对初始代码数据的初始代码优化结果;该数据处理模型可以代码优化模型,用于进行代码优化和对初始代码数据进行代码更新;基于此,通过将初始代码数据输入代码优化模型,获得该代码优化模型输出的优化后的代码数据(即目标数据处理结果),从而满足实际应用中需要利用神经网络模型进行代码优化的需求。
该初始推理结果可以理解为利用该数据处理模型对初始数据进行第一阶段数据推理后获得的处理结果;该第一阶段数据推理可以理解为对初始数据中的初始子数据进行数据推理;例如,在初始数据为初始问题文本的情况下,该初始子数据可以为构成该初始问题文本的子问题;基于此,初始推理结果可以为利用数据处理模型对初始问题文本中的子问题进行问题推理,所获得的问题推理结果;再例如,在初始数据为初始代码数据的情况下,该初始子数据可以为该初始代码数据中的一条或多条代码语句;基于此,初始推理结果可以是利用代码优化模型对初始代码数据中的一条或多条代码语句进行代码优化,所获得的代码优化结果。
在本公开提供的一个或多个实施例中,考虑到神经网络模型在对较为复杂且数据量较大的数据进行处理的过程中,会存在推理效率较低的问题,因此,本公开提供的数据处理方法,能够针对初始数据采用多阶段的数据推理进行处理,而每阶段可以对初始数据中的初始子数据进行数据推理,直至完成针对初始数据的数据推理;具体实现方式如下。
所述利用数据处理模型对所述初始数据进行数据推理,获得初始推理结果,包括:
将所述初始数据输入所述数据处理模型,利用所述数据处理模型对所述初始数据进行数据提取,确定所述初始数据中包含的多个初始子数据;
从所述多个初始子数据中确定待推理子数据,并对所述待推理子数据进行语义推理,获得所述初始推理结果。
其中,初始子数据可以理解为构成该初始数据的子数据,在该初始数据为初始问题文本的情况下,该初始子数据可以为初始问题文本中的子问题文本,例如,该初始问题文本可以为“1+2×3等于多少”,对应的,该多个子问题文本为“1+2等于多少”、“2×3等于多少”;该初始问题文本可以为“A某的妻子的父亲是谁”,对应的,该多个子问题文本为“A某的妻子是谁”、“妻子的父亲是谁”;在初始数据为初始视频数据的情况下,该初始子数据可以为该初始视频数据中的一个或多个视频帧;在初始数据为初始图像数据或初始音频数据的情况下,该初始子数据可以为该初始图像数据中的局部图像区域或初始音频数据中的一小段音频数据等;在初始数据为初始代码数据的情况下,该初始子数据可以为该初始代码数据中的一条或多条代码语句,例如,该初始代码数据可以为“int main(){
对应的,该初始子数据可以为初始代码数据中的一条或多条代码语句,例如,该初始子数据可以为“int a=5;、int b=10;”这两条代码语句。
其中,待推理子数据可以理解为多个初始子数据中当前需要利用数据处理模型进行数据推理的子数据;该待推理子数据可以为多个初始子数据中的任意一个初始子数据、或者根据数据推理规则(比如数学运算规则、代码运行规则)确定的、需要进行第一阶段数据推理的初始子数据;例如,多个初始子问题中的第一个子问题,或者根据数学运算规则确定的、需要进行第一阶段数据推理的子问题,其中,在初始问题文本为“1+2×3等于多少”,多个子问题文本为“1+2等于多少”、“2×3等于多少”的情况下,根据数学运算规则确定的、需要进行第一阶段数据推理的子问题,可以理解为数据处理模型根据数学运算规则确定的“2×3等于多少”这个子问题,为进行第一阶段数据推理的子问题。
初始推理结果可以理解为利用数据处理模型对待推理子数据进行语义推理,所获得的结果,例如,在待推理子数据为子问题“2×3等于多少”的情况下,该初始问题推理结果(即初始推理结果)可以为“2×3等于6”;在待推理子数据为“int a=5;、int b=10;”这两条需要优化的代码语句的情况下,该初始代码优化结果(即初始推理结果)可以为“int a=5;、int b=10;可以被写为一条代码语句int a=5,b=10;”。
下面以本公开提供的数据处理方法在问题推理场景中的应用为例,对该数据处理方法进行说明解释,其中,该初始数据为初始问题文本、数据处理模型为问题处理模型、初始子数据为初始子问题、待推理子数据为待推理子问题、初始推理结果为初始问题推理结果;基于此,本公开提供的数据处理方法可以应用于数据处理节点,该数据处理节点在确定初始问题文本之后,会将该初始问题文本输入训练完成的问题处理模型,利用该问题处理模型对该初始问题文本进行问题提取,从而识别出该初始问题文本中包含的多个初始子问题;然后,从该多个初始子问题中选择一个待推理子问题,并对该待推理子问题进行第一阶段的问题推理,从而获得针对该待推理子问题的初始问题推理结果。
需要说明的是,该数据处理节点可以为服务端、服务器、虚拟机、容器、云服务器、客户端、移动终端等设备,或者该数据处理节点可以为应用程序、软件系统等软件设备,在此不做具体限定。
上述实施例中,在利用数据处理模型对所述初始数据进行数据推理,获得初始推理结果的过程中,通过利用数据处理模型从初始数据包含的多个初始子数据中确定待推理子数据,并对待推理子数据进行数据推理,获得所述初始推理结果;由于该数据处理模型可以快速且准确的对较为简单且数据数量较小的子数据进行数据推理,因此,当利用数据处理模型采用多阶段的数据推理方式对初始子数据进行处理的情况下,能够高效的实现对初始数据进行数据推理,避免了神经网络模型在对较为复杂且数据量较大的数据进行处理的过程中,会存在推理效率较低的问题。
在本公开提供的一个或多个实施例中,该数据处理方法所应用的数据处理节点可以接收用户基于客户端发送的初始数据,后续能够对该初始数据进行数据处理,具体实现方式如下。
所述确定初始数据,包括:
接收客户端发送的所述初始数据,其中,所述初始数据为所述客户端根据用户针对数据处理页面所进行的数据处理操作生成;
其中,客户端可以为移动终端、智能设备或其他服务端等设备,或者该客户端可以为应用程序、软件系统等软件。
其中,该数据处理页面可以理解为该客户端中展示的、用于实现用户的数据处理的用户交互界面;该数据处理页面可以为网页、应用程序界面等。
该数据处理操作可以为用户基于数据处理页面执行的、输入数据、点击按钮等触发数据处理页面中的数据处理控件的操作。
沿用上例,客户端可以向用户展示数据处理页面,用户基于该数据处理页面中的数据处理控件(例如按钮、输入框等)执行数据处理操作,从而触发客户端生成初始数据,并且,将该初始数据发送至数据处理节点,指示该数据处理节点利用数据处理模型执行针对该初始数据的数据处理操作。
上述实施例中,用户通过利用客户端、数据处理页面实现针对初始数据的数据处理操作,从而满足了用户需要利用数据处理模型对初始数据进行数据处理的需求。
步骤204:在根据所述初始推理结果,确定所述初始数据满足数据推理条件的情况下,根据所述初始推理结果,利用所述数据处理模型对所述初始数据进行数据更新,获得更新数据,其中,所述更新数据的数据数量小于所述初始数据的数据数量,且所述数据处理模型为机器学习模型。
其中,该数据推理条件可以理解为需要再次利用数据处理模型进行数据推理的条件,该数据推理条件可以根据实际应用场景进行设置,例如,满足数据推理条件可以理解为未完成针对该初始数据所包含的全部初始子数据的数据推理操作,或者,可以基于该数据推理结果(例如初始推理结果、更新推理结果)进行数据更新。再例如,不满足数据推理条件可以理解为完成针对该初始数据所包含的全部初始子数据的数据推理操作,或者,无法基于该数据推理结果(例如初始推理结果、更新推理结果)进行数据更新。
更新数据可以理解为对初始数据进行数据更新后获得的数据,例如,在初始数据为“1+2×3等于多少”、初始推理结果为“2×3等于6”的情况下,该更新数据可以为“1+6等于多少”;再例如,当初始推理结果为“int a=5;、int b=10;可以被写为一条代码语句int a=5,b=10;”的情况下,该更新数据可以为“
在本公开提供的一个或多个实施例中,在进行多阶段数据推理的过程中,可以在每一阶段进行是否继续进行推理的校验,从而能够及时的确定是否推理完成,具体实现方式如下。
所述根据所述初始推理结果,确定所述初始数据满足数据推理条件,包括:
利用所述数据处理模型确定所述初始数据中包含的初始子数据;
对所述初始子数据与所述初始推理结果进行语义分析,并在确定所述初始子数据为多个,且多个初始子数据中存在与所述初始推理结果关联的待更新子数据的情况下,确定所述初始数据满足所述数据推理条件;
其中,待更新子数据可以理解为需要利用初始推理结果进行数据更新的子数据,例如,在多个子问题文本为“1+2等于多少”、“2×3等于多少”,且初始推理结果为“2×3等于6”的情况下,可以利用大模型从多个子问题文本中确定“2×3等于多少”这一子问题为待更新子数据,后续可以基于该初始推理结果对该待更新子数据进行数据更新。
沿用上例,当利用数据处理模型确定初始问题推理结果“2×3等于6”之后,将该初始问题推理结果以及该初始问题再次输入至大模型中进行校验,从而判断是否继续进行问题推理(即问题归约),当确定初始问题中包含多个子问题,且该多个子问题中存在与“2×3等于6”相对应的待更新子问题“2×3等于多少”的情况下,确定还能够继续进行问题归约。
上述实施例中,在进行多阶段数据推理的过程中,通过在每一阶段进行是否继续进行推理的校验,从而能够及时的确定是否推理完成,避免由于重复推理导致计算资源被浪费。
在本公开提供的一个或多个实施例中,所述初始数据为初始问题文本,所述初始推理结果为初始问题推理结果,所述数据处理模型为问题处理模型;
所述在根据所述初始推理结果,确定所述初始数据满足数据推理条件的情况下,根据所述初始推理结果,利用所述数据处理模型对所述初始数据进行数据更新,获得更新数据,包括:
在根据所述初始问题推理结果,确定所述初始问题文本满足问题推理条件的情况下,根据所述初始问题推理结果,利用所述问题处理模型对所述初始问题文本进行问题更新,获得更新问题文本。
其中,该问题推理条件可以为问题归约。
针对该实施例的解释说明,可以参见其他一个或多个实施例中对应或相应的解释。
在本公开提供的一个或多个实施例中,考虑到神经网络模型在对较为复杂且数据量较大的数据进行处理的过程中,会存在推理效率较低的问题,因此,本公开提供的数据处理方法能够通过多阶段的数据推理对该初始数据进行处理,并且,在每阶段的处理过程中,会利用数据推理结果对当前阶段的待推理数据(例如初始数据)进行更新,获得数据数量较小的数据,具体实现方式如下。
所述根据所述初始推理结果,利用所述数据处理模型对所述初始数据进行数据更新,获得更新数据,包括步骤一至步骤二:
步骤一:利用所述数据处理模型,确定所述初始数据中包含的多个初始子数据,并从所述多个初始子数据中,确定与所述初始推理结果关联的待更新子数据。
具体的,所述利用所述数据处理模型,确定所述初始数据中包含的多个初始子数据,并从所述多个初始子数据中,确定与所述初始推理结果关联的待更新子数据,包括:
将所述初始推理结果以及所述初始数据输入所述数据处理模型,利用所述数据处理模型对所述初始数据进行数据提取,确定所述初始数据中包含的所述多个初始子数据;
将各初始子数据与所述初始推理结果进行语义分析,获得与所述初始推理结果关联的所述待更新子数据。
沿用上例,当利用数据处理模型确定初始问题推理结果“2×3等于6”之后,将该初始问题推理结果以及该初始问题再次输入至大模型中进行语义分析,从初始问题包含多个子问题中,确定与“2×3等于6”相对应的待更新子问题“2×3等于多少”,便于后续能够继续进行问题归约。
上述实施例中,利用所述数据处理模型,确定所述初始数据中包含的多个初始子数据,并从所述多个初始子数据中,确定与所述初始推理结果关联的待更新子数据的过程中,能够利用所述数据处理模型对初始数据中包含的多个初始子数据进行语义分析,从而确定与所述初始推理结果关联的所述待更新子数据,便于后续能够利用初始推理结果准确的对待更新子数据进行数据更新,避免更新错误导致初始数据的语义发生偏差,保证了目标数据处理结果的准确性。
步骤二:利用所述数据处理模型,基于所述初始推理结果对所述初始数据中的所述待更新子数据进行数据更新,获得所述更新数据。
具体的,所述利用所述数据处理模型,基于所述初始推理结果对所述初始数据中的所述待更新子数据进行数据更新,获得所述更新数据,包括:
利用所述数据处理模型,基于所述初始推理结果对所述初始数据中的所述待更新子数据进行替换,获得所述更新数据;或者
利用所述数据处理模型,基于所述初始推理结果对所述初始数据中的所述待更新子数据进行语义改写,获得所述更新数据。
沿用上例,初始问题推理结果可以为“2×3等于6”或者“6”;基于此,当利用数据处理模型确定与初始问题推理结果“6”相对应的待更新子问题“2×3等于多少”的情况下,可以直接基于该初始问题推理结果对该初始问题文本“1+2×3等于多少”中的待更新子问题“2×3等于多少”进行替换,获得替换后的问题文本“1+6等于多少”,从而实现问题归约。
在初始问题推理结果为“2×3等于6”的情况下,可以利用数据处理模型,基于初始问题推理结果“2×3等于6”对初始问题文本“1+2×3等于多少”中的待更新子数据“2×3等于多少”进行语义改写,获得语义改写后的问题文本“1+6等于多少”,从而实现问题归约。
上述实施例中,通过利用数据推理结果对当前阶段的待推理数据(例如初始数据)进行更新,获得数据数量较小的数据,从而提高了后续数据处理模型的数据处理效率。
步骤206:利用所述数据处理模型对所述更新数据进行数据推理,获得更新推理结果。
其中,利用所述数据处理模型对所述更新数据进行数据推理,获得更新推理结果,可以参见上述利用数据处理模型对所述初始数据进行数据推理,获得初始推理结果的步骤,在此不做过多赘述。
沿用上例,更新问题文本可以为“1+6等于多少”,将其输入至大模型进行语义推理,获得对应的推理结果“1+6等于7”。
步骤208:在根据所述更新推理结果,确定所述更新数据不满足所述数据推理条件的情况下,将所述更新推理结果确定为目标数据处理结果。
其中,该目标数据处理结果理解为针对该初始数据的处理结果,例如,在初始数据为初始问题文本的情况下,该目标数据处理结果可以为该问题文本对应的问题答案;在初始数据为初始代码数据的情况下,该目标数据处理结果可以为对初始代码数据进行优化后获得的代码数据;需要说明的是,该初始推理结果可以为针对初始数据中的某一初始子数据的推理结果,该更新推理结果可以为针对更新数据中某一更新子数据的推理结果;该目标数据处理可以为针对该初始数据的整体的处理结果;并且,在更新推理结果确定更新数据不满足数据推理条件的情况下,可以将更新推理结果确定为目标数据处理结果。
沿用上例,在确定更新问题文本对应的更新问题推理结果(即更新推理结果)为“1+6等于7”的情况下,将该更新问题推理结果以及该更新问题再次输入至大模型中进行语义分析,在确定该更新问题中仅包含一个子问题“1+6等于多少”,且该子问题与更新问题推理结果相关联的情况下,确定多阶段数据推理完成,从而将该更新问题推理结果“答案等于7”作为最后的答案(即目标数据处理结果),或者,在该更新问题推理结果是“1+6等于7”的情况下,将该“1+6等于7”转换为问题答案“1+2×3等于7”(即目标数据处理结果)。
在本公开提供的一个或多个实施例中,在进行多阶段数据推理的过程中,需要在每一阶段进行是否继续进行推理的校验,从而能够及时的确定是否推理完成,具体实现方式如下。
所述根据所述更新推理结果,确定所述更新数据不满足所述数据推理条件,包括:
利用所述数据处理模型确定所述更新数据中包含的更新子数据;
对所述更新子数据与所述更新推理结果进行语义分析,在确定所述更新子数据为一个,且所述更新子数据与所述更新推理结果关联的情况下,确定所述更新数据不满足所述数据推理条件。
其中,更新子数据可以理解为该更新数据中包含的子数据,例如,在更新数据为更新问题文本的情况下,该更新子数据可以理解为该更新问题文本中包含的子问题文本。
沿用上例,在确定更新问题文本对应的更新问题推理结果(即更新推理结果)为“1+6等于7”的情况下,将该更新问题推理结果以及该更新问题再次输入至大模型中进行语义分析,在确定该更新问题中仅包含一个子问题“1+6等于多个”,且该子问题与更新问题推理结果相关联的情况下,确定多阶段数据推理完成。
上述实施例中,在进行多阶段数据推理的过程中,通过在每一阶段进行是否继续进行推理的校验,从而能够及时的确定是否推理完成,避免由于重复推理导致计算资源被浪费。
在本公开提供的一个或多个实施例中,该数据处理方法所应用的数据处理节点在接收用户基于客户端发送的初始数据并对该初始数据进行数据处理之后,能够将该目标数据处理结果发生至客户端进行展示,具体实现方式如下。
所述在根据所述更新推理结果,确定所述更新数据不满足所述数据推理条件的情况下,将所述更新推理结果确定为目标数据处理结果之后,还包括:
将所述目标数据处理结果发送至所述客户端,以使所述客户端基于所述数据处理页面对所述目标数据处理结果进行展示。
其中,基于所述数据处理页面对所述目标数据处理结果进行展示,可以理解为基于所述数据处理页面将所述目标数据处理结果向用户展示,或者,基于所述数据处理页面将所述目标数据处理结果向其他对象进行展示,该其他对象可以为需要获取目标数据处理结果的对象,例如,该用户可以为老师,该其他对象可以为学生。
上述实施例中,通过利用客户端、数据处理页面实现将目标数据处理结果进行展示,从而满足了用户需要利用数据处理模型对初始数据进行数据处理的需求。
在本公开提供的一个或多个实施例中,在进行多阶段数据推理的过程中,需要在每一阶段进行是否继续进行推理的校验,从而能够及时的确定是否推理完成,具体实现方式如下。
所述利用所述数据处理模型对所述更新数据进行数据推理,获得更新推理结果之后,还包括:
在根据所述更新推理结果,确定所述更新数据满足所述数据推理条件的情况下,根据所述更新推理结果,利用所述数据处理模型对所述更新数据进行数据更新,获得第二更新数据,其中,所述第二更新数据的数据数量小于所述更新数据的数据数量;
将所述第二更新数据确定为更新数据,并继续执行所述利用所述数据处理模型对所述更新数据进行数据推理,获得更新推理结果的步骤,直至根据所述更新推理结果,确定所述更新数据不满足所述数据推理条件。
沿用上例,初始问题可以为“1+1+2×3等于多少”,该更新问题可以为“1+1+6等于多少”,针对更新问题中“1+1等于多少”这一子问题的更新问题推理结果可以为“1+1等于2”,基于此,当利用数据处理模型确定更新问题推理结果“1+1等于2”之后,将该更新问题推理结果以及该更新问题再次输入至大模型中进行校验,从而判断是否继续进行问题推理(即问题归约),当确定更新问题中包含多个子问题“1+1等于多少”、“1+6等于多少”,且该多个子问题中存在与“1+1等于2”相对应的待更新子问题“1+1等于多少”的情况下,确定还能够继续进行问题归约。
本公开一个或多个实施例中提供的数据处理方法,在利用数据处理模型进行数据处理的过程中,首先,利用数据处理模型对初始数据进行第一阶段的数据推理,获得初始推理结果;并且,在根据初始推理结果确定初始数据满足数据推理条件的情况下,根据初始推理结果对初始数据进行数据更新,从而获得数据数量小于初始数据的更新数据;然后,利用该数据处理模型对数据数量较小的更新数据进行第二阶段的数据推理,从而快速的获得更新推理结果,由于数据处理模型可以对数据数量较小的更新数据进行快速推理,因此虽然需要通过多个阶段进行推理,但是整体的数据推理效率会高于数据处理模型针对数据量较大的数据的数据推理效率,从而提高了数据处理模型的数据推理效率,避免神经网络模型在对较为复杂且数据量较大的数据进行处理的过程中所存在的推理效率较低的问题;并且,在根据更新推理结果确定更新数据不满足数据推理条件的情况下,则确定结束数据推理,将更新推理结果确定为目标数据处理结果,从而满足了实际应用中需要利用神经网络模型对各种类型的数据进行数据处理的需求。
下述结合附图3,以本公开提供的数据处理方法在数据推理场景中的应用为例,对所述数据处理方法进行进一步说明。其中,图3示出了本公开一个实施例提供的一种数据处理方法的处理过程流程图,基于图3可知,本公开提供的数据处理方法可以将马尔科夫链与CoT、PoT、或ToT相结合,其核心思想是将问题转换为多个独立问题推理和子问题生成;也即是,将多步推理问题转化为多个独立问题推理和子问题生成的过程,通过多轮迭代的形式完成问题的推理过程;具体包括以下步骤。
步骤302:将用户提供的问题1输入至LLM中进行推理。
具体的,该问题1可以理解为需要利用LLM进行问题推理、从而获得答案的问题,该问题1可以为用户输入的原始问题,例如,该问题1可以是“已知sin a=1/2,且a是第一象限角,求解tan a?”。
步骤304:确定该LLM对问题1进行问题推理所获得的推理结果1,并基于该推理结果1对该问题1进行问题归约,获得问题2。
具体的,本公开提供的数据处理方法,可以通过多阶段迭代的形式完成问题的推理过程,在此过程中,原始大模型LLM会利用之前推理的信息,去进行当前步(即当前阶段)的推理;从而将针对原始问题的问题推理步骤,转化为一个大模型只需要通过当前问题去完成一步推理的就可以完成全部任务推理的一个更精简的过程。
其中,该一步推理:是指采用大模型+tools或者大模型CoT的形式,对原始问题中的某个或者多个子问题(即已知条件)进行化简/转化和求解。
基于此,在步骤304的执行方式是:可以利用LLM大模型对当前问题(即问题1)中的子问题进行一步推理;一步推理完成后获得该子问题对应的推理结果1(即step-wise solution);
然后,利用原始问题和推理结果1获得一个新问题(即问题2),该新问题和原始问题具有相同的答案。
其中,该新问题是利用推理结果1对问题1进行问题归约获得。
该问题归约:是指利用大模型的文本生成能力,基于原始问题和一步推理过程中简化后的条件(即推理结果),对原始问题中已知条件替换和改写,从而得到比原始问题更简单的新问题;
例如,还是以上述问题1为例对问题归约进行解释说明;该原始问题是“已知sin a=1/2,且a是第一象限角,求解tan a?”;对其进行一步推理可以得到的推理结果是:“因为sin a=1/2,且a是第一象限角,则可以得到a=30度”;也即是说,该一步推理是针对原始问题中的“已知sin a=1/2,且a是第一象限角”这一子问题进行问题推理,从而获得对应的推理结果。
然后,基于该推理结果,可以将原始问题“已知sin a=1/2,且a是第一象限角,求解tan a?”中的“已知sin a=1/2,且a是第一象限角”这一子问题进行替换和改写,从而将原始问题转换为新问题“已知a=30度,求解tan a?”。
此外需要说明的是,在进行多阶段的问题推理的过程中,大模型需要在每一阶段进行是否继续进行问题推理的校验,从而能够及时的确定是否推理完成,避免由于重复推理导致计算资源被浪费;该大模型校验是否继续进行问题推理的方式可以参见下例:
例如,该原始问题可以为“1+2×3等于多少”,对应的,该多个子问题为“1+2等于多少”、“2×3等于多少”;当对原始问题进行第一阶段的一步推理之后,确定推理结果为“2×3等于6”。
在利用大模型确定一步推理的推理结果为“2×3等于6”之后,将原始问题和当前推理结果输入至大模型中校验是否继续进行问题推理。
在校验是否继续进行问题推理的过程中,大模型能够确定原始问题中是否包含多个子问题,以及该多个子问题中是否存在能够基于推理结果进行问题归约的子问题;如果原始问题中包含多个子问题,且存在能够进行问题归约的子问题,确定需要继续进行问题推理。
例如,大模型在确定当前原始问题中包含“1+2等于多少”、“2×3等于多少”这两个子问题,且该子问题中存在能够利用推理结果“2×3等于6”进行问题归约的子问题“2×3等于多少”的情况下,确定需要继续进行问题推理。
在确定需要继续进行问题推理的情况下,基于该推理结果对原始问题进行问题归约,获得新问题,并基于该新问题继续进行一步推理的操作,直至完成数据推理。
步骤306:将问题2输入至LLM中继续进行一步推理。
步骤308:确定该LLM对问题2进行问题推理所获得的推理结果2,并基于该推理结果2对该问题2进行问题归约。
具体的,利用大模型对新问题进行一步推理,获得推理结果2(step-wise solution)之后,再次利用推理结果2对新问题进行问题归约,获得一个和新问题答案一致的、但更简单的问题。
重复执行上述一步推理以及问题归约的步骤,直至获得最精简的问题N。
例如,在原始问题为“已知sin a=1/2,且a是第一象限角,求解tan a?”的情况下,最精简的问题N可以为“已知a=30度,求解tan a?”。
再例如,在原始问题可以为“1+2×3等于多少”的情况下,最精简的问题N可以为“1+6等于多少”。
步骤310:将问题N输入至LLM中继续进行问题推理。
步骤312:获得最终的推理结果N。
具体的,重复执行上述一步推理和问题归约的过程,直到通过问题解答获得答案(即推理结果N)为止,确定问题推理结束。
需要说明的是,问题推理结果的判断条件可以为:
在进行多阶段的问题推理的过程中,大模型需要在每一阶段进行是否继续进行问题推理的校验,在校验是否继续进行问题推理的过程中,如果确定原始问题中仅包含一个子问题,且该子问题不能够进行问题归约,那么可以确定问题推理结束。
例如,大模型在确定当前原始问题中包含“1+6等于多少”这一个子问题,且该子问题中不能够再进行问题归约的情况下,确定问题推理结束。
基于上述内容可知,本公开一个或多个实施例中的数据处理方法,提供了一种基于马尔可夫思维链的高效推理方法,上述说明了马尔可夫思维链推理(MCTR)方法在数学推理任务中的应用;基于上述内容可知,本方法将问题看作一个状态,将解答看作一个动作,将解答过程抽象为当前状态到当前动作的采取过程,将归约过程抽象为当前状态到下一状态的状态转移过程,从而通过多轮的马尔可夫状态转移的实现逻辑推理。
需要说明的是,本公开一个或多个实施例中的数据处理方法,考虑到采用CoT、PoT、ToT等方式进行逻辑推理的方案所存在的缺陷,提出了对应的解决方式。
其中,针对训练数据利用率低:上述方案中的大模型训练数据都需要每个问题有一条完整的推理链路,这样的数据构造难度相对较高,而且当前推理链路只能满足这个问题的推理,所以推理链路具有唯一性。
但是,本公开一个或多个实施例中的数据处理方法,将模型转化为MCoT的形式后,会把一个复杂问题转化为一系列的从难到简单的子问题的一步推理问题,称为原子步骤,这样就可以将原始推理链路的唯一性打破,保证再求解新的较难问题的时候可以从之前原子步骤中找到合适的步骤进行组合实现求解。
其中,针对解码效率低:本公开一个或多个实施例中的数据处理方法,指导大模型的推理效率/时间随着推理长度的增加,效率会按照o(n^2)/指数级的形式显著下降,当转化为MCoT的形式后,每一个子问题的推理过程都会非常的短,这样会显著降低大模型的attention窗口,显著降低大模型解码对显存的需求,提高解码效率。
基于此可知,本公开一个或多个实施例中的数据处理方法,通过采用马尔可夫思维链(MCoT)推理方法,将数理逻辑推理分为一步推理和问题归约两个过程,并利用各子问题推理的独立性实现数据集上的问题归元和大模型解码效率的有效提升,本方法所达到的技术效果在于:
首先,通过一步推理和问题归约两个过程,将原始复杂问题化简转化为更简单直观的问题,同时多个复杂问题可以被转化为同一个简单直观问题(问题归元过程),因此降低大模型推理路径学习上对原始复杂问题的学习难度(大模型从学习求解这个复杂问题转化为化简复杂问题和求解简单的问题的组合,而简单问题/一步推理问题是大模型训练语料中较多的数据,更容易学习),实现更高效的利用包括预训练模型和任务训练数据的目的,提高数据的利用效率;
其次,通过将原始的复杂问题中长序列推理过程转化为多个短序列推理过程,显著降低大模型的推理成本,提高大模型的推理效率(因为大模型推理过程中,每一步推理都要和前面所有步做交互,使得解码计算量和显存占用都很高,如果进行分片区推理,就可以显著优化这两点),当前方案可以使训练大模型不需要longcontext(即长上下文),是一种在推理生成上的对longcontext的替代方案;配合rag甚至可以解决现在longcontext的所有需求。
最后,MCTR方法具有:过程更加符合人类的推理逻辑、推理过程高效且准确、数据集不需要进行人工构造等优点。
参见图4,图4示出了根据本公开一个实施例提供的一种问题处理方法的流程图,具体包括以下步骤。
步骤402:确定初始问题文本,并利用数据处理模型对所述初始问题文本进行问题推理,获得初始问题推理结果。
步骤404:在根据所述初始问题推理结果,确定所述初始问题文本满足问题推理条件的情况下,根据所述初始问题推理结果,利用所述数据处理模型对所述初始问题文本进行问题更新,获得更新问题文本,其中,所述更新问题文本的数据数量小于所述初始问题文本的数据数量,且所述数据处理模型为机器学习模型。
步骤406:利用所述数据处理模型对所述更新问题文本进行问题推理,获得更新问题推理结果。
步骤408:在根据所述更新问题推理结果,确定所述更新问题文本不满足所述问题推理条件的情况下,将所述更新问题推理结果确定为目标问题处理结果。
本公开提供的一个或多个实施例中,所述确定初始问题文本,包括:
接收客户端发送的所述初始问题文本,其中,所述初始问题文本为所述客户端根据用户针对问题处理页面所进行的问题处理操作生成;
所述在根据所述更新问题推理结果,确定所述更新问题文本不满足问题推理条件的情况下,将所述更新问题推理结果确定为目标问题处理结果之后,还包括:
将所述目标问题处理结果发送至所述客户端,以使所述客户端基于所述问题处理页面将所述目标问题处理结果向所述用户展示。
本公开一个或多个实施例中提供的问题处理方法,在利用问题处理模型进行问题处理的过程中,首先,利用问题处理模型对初始问题文本进行第一阶段的问题推理,获得初始问题推理结果;并且,在根据初始问题推理结果确定初始问题文本满足问题推理条件的情况下,根据初始问题推理结果对初始问题文本进行问题更新,从而获得数据数量小于初始问题文本的更新问题文本;然后,利用该问题处理模型对数据数量较小的更新问题文本进行第二阶段的问题推理,从而快速的获得更新问题推理结果,由于问题处理模型可以对数据数量较小的更新问题文本进行快速推理,因此虽然需要通过多个阶段进行推理,但是整体的推理效率会高于问题处理模型针对数据量较大的问题文本的问题推理效率,从而提高了问题处理模型的问题推理效率,避免神经网络模型在对较为复杂且数据量较大的数据进行处理的过程中所存在的推理效率较低的问题;并且,在根据更新问题推理结果确定更新问题文本不满足问题推理条件的情况下,则确定结束问题推理,将更新问题推理结果确定为目标问题处理结果,从而满足了实际应用中需要利用神经网络模型对各种类型的问题进行问题处理的需求。
上述为本实施例的一种问题处理方法的示意性方案。需要说明的是,该问题处理方法的技术方案与上述数据处理方法的技术方案属于同一构思,问题处理方法的技术方案未详细描述的细节内容,均可以参见上述数据处理方法的技术方案的描述。
与上述方法实施例相对应,本公开还提供了数据处理装置实施例,图5示出了本公开一个实施例提供的一种数据处理装置的结构示意图。如图5所示,该装置包括:
第一结果确定模块502,被配置为确定初始数据,并利用数据处理模型对所述初始数据进行数据推理,获得初始推理结果;
数据更新模块504,被配置为在根据所述初始推理结果,确定所述初始数据满足数据推理条件的情况下,根据所述初始推理结果,利用所述数据处理模型对所述初始数据进行数据更新,获得更新数据,其中,所述更新数据的数据数量小于所述初始数据的数据数量,且所述数据处理模型为机器学习模型;
第二结果确定模块506,被配置为利用所述数据处理模型对所述更新数据进行数据推理,获得更新推理结果;
第三结果确定模块508,被配置为在根据所述更新推理结果,确定所述更新数据不满足所述数据推理条件的情况下,将所述更新推理结果确定为目标数据处理结果。
可选地,所述数据更新模块504,还被配置为:
利用所述数据处理模型,确定所述初始数据中包含的多个初始子数据,并从所述多个初始子数据中,确定与所述初始推理结果关联的待更新子数据;
利用所述数据处理模型,基于所述初始推理结果对所述初始数据中的所述待更新子数据进行数据更新,获得所述更新数据。
可选地,所述数据更新模块504,还被配置为:
利用所述数据处理模型,基于所述初始推理结果对所述初始数据中的所述待更新子数据进行替换,获得所述更新数据;或者
利用所述数据处理模型,基于所述初始推理结果对所述初始数据中的所述待更新子数据进行语义改写,获得所述更新数据。
可选地,所述数据更新模块504,还被配置为:
将所述初始推理结果以及所述初始数据输入所述数据处理模型,利用所述数据处理模型对所述初始数据进行数据提取,确定所述初始数据中包含的所述多个初始子数据;
将各初始子数据与所述初始推理结果进行语义分析,获得与所述初始推理结果关联的所述待更新子数据。
可选地,所述第一结果确定模块502,还被配置为:
将所述初始数据输入所述数据处理模型,利用所述数据处理模型对所述初始数据进行数据提取,确定所述初始数据中包含的多个初始子数据;
从所述多个初始子数据中确定待推理子数据,并对所述待推理子数据进行语义推理,获得所述初始推理结果。
可选地,所述数据处理装置还包括数据推理模块,被配置为:
在根据所述更新推理结果,确定所述更新数据满足所述数据推理条件的情况下,根据所述更新推理结果,利用所述数据处理模型对所述更新数据进行数据更新,获得第二更新数据,其中,所述第二更新数据的数据数量小于所述更新数据的数据数量;
将所述第二更新数据确定为更新数据,并继续执行所述利用所述数据处理模型对所述更新数据进行数据推理,获得更新推理结果的步骤,直至根据所述更新推理结果,确定所述更新数据不满足所述数据推理条件。
可选地,所述第一结果确定模块502,还被配置为:
接收客户端发送的所述初始数据,其中,所述初始数据为所述客户端根据用户针对数据处理页面所进行的数据处理操作生成;
所述数据处理装置还包括结果发送模块,被配置为:
将所述目标数据处理结果发送至所述客户端,以使所述客户端基于所述数据处理页面对所述目标数据处理结果进行展示。
可选地,所述初始数据为初始问题文本,所述初始推理结果为初始问题推理结果,所述数据处理模型为问题处理模型;
所述数据更新模块504,还被配置为:
在根据所述初始问题推理结果,确定所述初始问题文本满足问题推理条件的情况下,根据所述初始问题推理结果,利用所述问题处理模型对所述初始问题文本进行问题更新,获得更新问题文本。
可选地,所述数据更新模块504,还被配置为:
利用所述数据处理模型确定所述初始数据中包含的初始子数据;
对所述初始子数据与所述初始推理结果进行语义分析,并在确定所述初始子数据为多个,且多个初始子数据中存在与所述初始推理结果关联的待更新子数据的情况下,确定所述初始数据满足所述数据推理条件;
所述第三结果确定模块508,被配置为:
利用所述数据处理模型确定所述更新数据中包含的更新子数据;
对所述更新子数据与所述更新推理结果进行语义分析,在确定所述更新子数据为一个,且所述更新子数据与所述更新推理结果关联的情况下,确定所述更新数据不满足所述数据推理条件。
本公开一个或多个实施例中提供的数据处理装置,在利用数据处理模型进行数据处理的过程中,首先,利用数据处理模型对初始数据进行第一阶段的数据推理,获得初始推理结果;并且,在根据初始推理结果确定初始数据满足数据推理条件的情况下,根据初始推理结果对初始数据进行数据更新,从而获得数据数量小于初始数据的更新数据;然后,利用该数据处理模型对数据数量较小的更新数据进行第二阶段的数据推理,从而快速的获得更新推理结果,由于数据处理模型可以对数据数量较小的更新数据进行快速推理,因此虽然需要通过多个阶段进行推理,但是整体的数据推理效率会高于数据处理模型针对数据量较大的数据的数据推理效率,从而提高了数据处理模型的数据推理效率,避免神经网络模型在对较为复杂且数据量较大的数据进行处理的过程中所存在的推理效率较低的问题;并且,在根据更新推理结果确定更新数据不满足数据推理条件的情况下,则确定结束数据推理,将更新推理结果确定为目标数据处理结果,从而满足了实际应用中需要利用神经网络模型对各种类型的数据进行数据处理的需求。
上述为本实施例的一种数据处理装置的示意性方案。需要说明的是,该数据处理装置的技术方案与上述的数据处理方法的技术方案属于同一构思,数据处理装置的技术方案未详细描述的细节内容,均可以参见上述数据处理方法的技术方案的描述。
与上述方法实施例相对应,本公开还提供了问题处理装置实施例,图6示出了本公开一个实施例提供的一种问题处理装置的结构示意图。如图6所示,该装置包括:
第一结果确定模块602,被配置为确定初始问题文本,并利用数据处理模型对所述初始问题文本进行问题推理,获得初始问题推理结果;
问题更新模块604,被配置为在根据所述初始问题推理结果,确定所述初始问题文本满足问题推理条件的情况下,根据所述初始问题推理结果,利用所述数据处理模型对所述初始问题文本进行问题更新,获得更新问题文本,其中,所述更新问题文本的数据数量小于所述初始问题文本的数据数量,且所述数据处理模型为机器学习模型;
第二结果确定模块606,被配置为利用所述数据处理模型对所述更新问题文本进行问题推理,获得更新问题推理结果;
第三结果确定模块608,被配置为在根据所述更新问题推理结果,确定所述更新问题文本不满足所述问题推理条件的情况下,将所述更新问题推理结果确定为目标问题处理结果。
可选地,所述第一结果确定模块602,还被配置为:
接收客户端发送的所述初始问题文本,其中,所述初始问题文本为所述客户端根据用户针对问题处理页面所进行的问题处理操作生成;
所述问题处理装置还包括结果发送模块,被配置为:
将所述目标问题处理结果发送至所述客户端,以使所述客户端基于所述问题处理页面将所述目标问题处理结果向所述用户展示。
本公开一个或多个实施例中提供的问题处理装置,在利用问题处理模型进行问题处理的过程中,首先,利用问题处理模型对初始问题文本进行第一阶段的问题推理,获得初始问题推理结果;并且,在根据初始问题推理结果确定初始问题文本满足问题推理条件的情况下,根据初始问题推理结果对初始问题文本进行问题更新,从而获得数据数量小于初始问题文本的更新问题文本;然后,利用该问题处理模型对数据数量较小的更新问题文本进行第二阶段的问题推理,从而快速的获得更新问题推理结果,由于问题处理模型可以对数据数量较小的更新问题文本进行快速推理,因此虽然需要通过多个阶段进行推理,但是整体的推理效率会高于问题处理模型针对数据量较大的问题文本的问题推理效率,从而提高了问题处理模型的问题推理效率,避免神经网络模型在对较为复杂且数据量较大的数据进行处理的过程中所存在的推理效率较低的问题;并且,在根据更新问题推理结果确定更新问题文本不满足问题推理条件的情况下,则确定结束问题推理,将更新问题推理结果确定为目标问题处理结果,从而满足了实际应用中需要利用神经网络模型对各种类型的问题进行问题处理的需求。
上述为本实施例的一种问题处理装置的示意性方案。需要说明的是,该问题处理装置的技术方案与上述的问题处理方法的技术方案属于同一构思,问题处理装置的技术方案未详细描述的细节内容,均可以参见上述问题处理方法的技术方案的描述。
图7示出了根据本公开一个实施例提供的一种计算设备700的结构框图。该计算设备700的部件包括但不限于存储器710和处理器720。处理器720与存储器710通过总线730相连接,数据库750用于保存数据。
计算设备700还包括接入设备740,接入设备740使得计算设备700能够经由一个或多个网络760通信。这些网络的示例包括公用交换电话网(PSTN,Public Switched Telephone Network)、局域网(LAN,Local Area Network)、广域网(WAN,Wide Area Network)、个域网(PAN,Personal Area Network)或诸如因特网的通信网络的组合。接入设备740可以包括有线或无线的任何类型的网络接口(例如,网络接口卡(NIC,network interface controller))中的一个或多个,诸如IEEE802.11无线局域网(WLAN,Wireless Local Area Network)无线接口、全球微波互联接入(Wi-MAX,Worldwide Interoperability for Microwave Access)接口、以太网接口、通用串行总线(USB,Universal Serial Bus)接口、蜂窝网络接口、蓝牙接口、近场通信(NFC,Near Field Communication)。
在本公开的一个实施例中,计算设备700的上述部件以及图7中未示出的其他部件也可以彼此相连接,例如通过总线。应当理解,图7所示的计算设备结构框图仅仅是出于示例的目的,而不是对本公开范围的限制。本领域技术人员可以根据需要,增添或替换其他部件。
计算设备700可以是任何类型的静止或移动计算设备,包括移动计算机或移动计算设备(例如,平板计算机、个人数字助理、膝上型计算机、笔记本计算机、上网本等)、移动电话(例如,智能手机)、可佩戴的计算设备(例如,智能手表、智能眼镜等)或其他类型的移动设备,或者诸如台式计算机或个人计算机(PC,Personal Computer)的静止计算设备。计算设备700还可以是移动式或静止式的服务器。
其中,处理器720用于执行如下计算机可执行指令,该计算机可执行指令被处理器执行时实现上述数据处理方法或问题处理方法的步骤。
本公开中的各个实施例均采用递进的方式描述,各个实施例之间相同相似的部分互相参见即可,每个实施例重点说明的都是与其他实施例的不同之处。尤其,对于计算设备实施例而言,由于其基本相似于数据处理方法或问题处理方法实施例,所以描述的比较简单,相关之处参见数据处理方法或问题处理方法实施例的部分说明即可。
本公开一实施例还提供一种计算机可读存储介质,其存储有计算机程序/指令,该计算机程序/指令被处理器执行时实现上述数据处理方法或问题处理方法的步骤。
本公开中的各个实施例均采用递进的方式描述,各个实施例之间相同相似的部分互相参见即可,每个实施例重点说明的都是与其他实施例的不同之处。尤其,对于计算机可读存储介质实施例而言,由于其基本相似于数据处理方法或问题处理方法实施例,所以描述的比较简单,相关之处参见数据处理方法或问题处理方法实施例的部分说明即可。
本公开一实施例还提供一种计算机程序产品,包括计算机程序/指令,该计算机程序/指令被处理器执行时实现上述数据处理方法或问题处理方法的步骤。
上述为本实施例的一种计算机程序产品的示意性方案。需要说明的是,该计算机程序产品的技术方案与上述的数据处理方法或问题处理方法的技术方案属于同一构思,计算机程序产品的技术方案未详细描述的细节内容,均可以参见上述数据处理方法或问题处理方法的技术方案的描述。
上述对本公开特定实施例进行了描述。其它实施例在所附权利要求书的范围内。在一些情况下,在权利要求书中记载的动作或步骤可以按照不同于实施例中的顺序来执行并且仍然可以实现期望的结果。另外,在附图中描绘的过程不一定要求示出的特定顺序或者连续顺序才能实现期望的结果。在某些实施方式中,多任务处理和并行处理也是可以的或者可能是有利的。
所述计算机指令包括计算机程序代码,所述计算机程序代码可以为源代码形式、对象代码形式、可执行文件或某些中间形式等。所述计算机可读介质可以包括:能够携带所述计算机程序代码的任何实体或装置、记录介质、U盘、移动硬盘、磁碟、光盘、计算机存储器、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、电载波信号、电信信号以及软件分发介质等。需要说明的是,所述计算机可读介质包含的内容可以根据专利实践的要求进行适当的增减,例如在某些地区,根据专利实践,计算机可读介质不包括电载波信号和电信信号。
需要说明的是,对于前述的各方法实施例,为了简便描述,故将其都表述为一系列的动作组合,但是本领域技术人员应该知悉,本公开实施例并不受所描述的动作顺序的限制,因为依据本公开实施例,某些步骤可以采用其它顺序或者同时进行。其次,本领域技术人员也应该知悉,本公开中所描述的实施例均属于优选实施例,所涉及的动作和模块并不一定都是本公开实施例所必须的。
在上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述的部分,可以参见其它实施例的相关描述。
以上公开的本公开优选实施例只是用于帮助阐述本公开。可选实施例并没有详尽叙述所有的细节,也不限制该公开仅为所述的具体实施方式。显然,根据本公开实施例的内容,可作很多的修改和变化。本公开选取并具体描述这些实施例,是为了更好地解释本公开实施例的原理和实际应用,从而使所属技术领域技术人员能很好地理解和利用本公开。本公开仅受权利要求书及其全部范围和等效物的限制。
Claims (14)
- 一种数据处理方法,包括:确定初始数据,并利用数据处理模型对所述初始数据进行数据推理,获得初始推理结果;在根据所述初始推理结果,确定所述初始数据满足数据推理条件的情况下,根据所述初始推理结果,利用所述数据处理模型对所述初始数据进行数据更新,获得更新数据,其中,所述更新数据的数据数量小于所述初始数据的数据数量,且所述数据处理模型为机器学习模型;利用所述数据处理模型对所述更新数据进行数据推理,获得更新推理结果;在根据所述更新推理结果,确定所述更新数据不满足所述数据推理条件的情况下,将所述更新推理结果确定为目标数据处理结果。
- 根据权利要求1所述的数据处理方法,所述根据所述初始推理结果,利用所述数据处理模型对所述初始数据进行数据更新,获得更新数据,包括:利用所述数据处理模型,确定所述初始数据中包含的多个初始子数据,并从所述多个初始子数据中,确定与所述初始推理结果关联的待更新子数据;利用所述数据处理模型,基于所述初始推理结果对所述初始数据中的所述待更新子数据进行数据更新,获得所述更新数据。
- 根据权利要求2所述的数据处理方法,所述利用所述数据处理模型,基于所述初始推理结果对所述初始数据中的所述待更新子数据进行数据更新,获得所述更新数据,包括:利用所述数据处理模型,基于所述初始推理结果对所述初始数据中的所述待更新子数据进行替换,获得所述更新数据;或者利用所述数据处理模型,基于所述初始推理结果对所述初始数据中的所述待更新子数据进行语义改写,获得所述更新数据。
- 根据权利要求2或3所述的数据处理方法,所述利用所述数据处理模型,确定所述初始数据中包含的多个初始子数据,并从所述多个初始子数据中,确定与所述初始推理结果关联的待更新子数据,包括:将所述初始推理结果以及所述初始数据输入所述数据处理模型,利用所述数据处理模型对所述初始数据进行数据提取,确定所述初始数据中包含的所述多个初始子数据;将各初始子数据与所述初始推理结果进行语义分析,获得与所述初始推理结果关联的所述待更新子数据。
- 根据权利要求1至4任意一项所述的数据处理方法,所述利用数据处理模型对所述初始数据进行数据推理,获得初始推理结果,包括:将所述初始数据输入所述数据处理模型,利用所述数据处理模型对所述初始数据进行数据提取,确定所述初始数据中包含的多个初始子数据;从所述多个初始子数据中确定待推理子数据,并对所述待推理子数据进行语义推理,获得所述初始推理结果。
- 根据权利要求1至5任意一项所述的数据处理方法,所述利用所述数据处理模型对所述更新数据进行数据推理,获得更新推理结果之后,还包括:在根据所述更新推理结果,确定所述更新数据满足所述数据推理条件的情况下,根据所述更新推理结果,利用所述数据处理模型对所述更新数据进行数据更新,获得第二更新数据,其中,所述第二更新数据的数据数量小于所述更新数据的数据数量;将所述第二更新数据确定为更新数据,并继续执行所述利用所述数据处理模型对所述更新数据进行数据推理,获得更新推理结果的步骤,直至根据所述更新推理结果,确定所述更新数据不满足所述数据推理条件。
- 根据权利要求1至6任意一项所述的数据处理方法,所述确定初始数据,包括:接收客户端发送的所述初始数据,其中,所述初始数据为所述客户端根据用户针对数据处理页面所进行的数据处理操作生成;所述在根据所述更新推理结果,确定所述更新数据不满足所述数据推理条件的情况下,将所述更新推理结果确定为目标数据处理结果之后,还包括:将所述目标数据处理结果发送至所述客户端,以使所述客户端基于所述数据处理页面对所述目标数据处理结果进行展示。
- 根据权利要求1至7任意一项所述的数据处理方法,所述初始数据为初始问题文本,所述初始推理结果为初始问题推理结果,所述数据处理模型为问题处理模型;所述在根据所述初始推理结果,确定所述初始数据满足数据推理条件的情况下,根据所述初始推理结果,利用所述数据处理模型对所述初始数据进行数据更新,获得更新数据,包括:在根据所述初始问题推理结果,确定所述初始问题文本满足问题推理条件的情况下,根据所述初始问题推理结果,利用所述问题处理模型对所述初始问题文本进行问题更新,获得更新问题文本。
- 根据权利要求1至8任意一项所述的数据处理方法,所述根据所述初始推理结果,确定所述初始数据满足数据推理条件,包括:利用所述数据处理模型确定所述初始数据中包含的初始子数据;对所述初始子数据与所述初始推理结果进行语义分析,并在确定所述初始子数据为多个,且多个初始子数据中存在与所述初始推理结果关联的待更新子数据的情况下,确定所述初始数据满足所述数据推理条件;所述根据所述更新推理结果,确定所述更新数据不满足所述数据推理条件,包括:利用所述数据处理模型确定所述更新数据中包含的更新子数据;对所述更新子数据与所述更新推理结果进行语义分析,在确定所述更新子数据为一个,且所述更新子数据与所述更新推理结果关联的情况下,确定所述更新数据不满足所述数据推理条件。
- 一种问题处理方法,包括:确定初始问题文本,并利用数据处理模型对所述初始问题文本进行问题推理,获得初始问题推理结果;在根据所述初始问题推理结果,确定所述初始问题文本满足问题推理条件的情况下,根据所述初始问题推理结果,利用所述数据处理模型对所述初始问题文本进行问题更新,获得更新问题文本,其中,所述更新问题文本的数据数量小于所述初始问题文本的数据数量,且所述数据处理模型为机器学习模型;利用所述数据处理模型对所述更新问题文本进行问题推理,获得更新问题推理结果;在根据所述更新问题推理结果,确定所述更新问题文本不满足所述问题推理条件的情况下,将所述更新问题推理结果确定为目标问题处理结果。
- 根据权利要求10所述的问题处理方法,所述确定初始问题文本,包括:接收客户端发送的所述初始问题文本,其中,所述初始问题文本为所述客户端根据用户针对问题处理页面所进行的问题处理操作生成;所述在根据所述更新问题推理结果,确定所述更新问题文本不满足问题推理条件的情况下,将所述更新问题推理结果确定为目标问题处理结果之后,还包括:将所述目标问题处理结果发送至所述客户端,以使所述客户端基于所述问题处理页面将所述目标问题处理结果向所述用户展示。
- 一种计算设备,包括:存储器和处理器;所述存储器用于存储计算机程序/指令,所述处理器用于执行所述计算机程序/指令,该计算机程序/指令被处理器执行时实现权利要求1至9任意一项所述数据处理方法或者权利要求10至11任意一项所述问题处理方法的步骤。
- 一种计算机可读存储介质,其存储有计算机程序/指令,该计算机程序/指令被处理器执行时实现权利要求1至9任意一项所述数据处理方法或者权利要求10至11任意一项所述问题处理方法的步骤。
- 一种计算机程序产品,包括计算机程序/指令,该计算机程序/指令被处理器执行时实现权利要求1至9任意一项所述数据处理方法或者权利要求10至11任意一项所述问题处理方法的步骤。
Applications Claiming Priority (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202410897972.9A CN119005329A (zh) | 2024-07-04 | 2024-07-04 | 数据处理方法、问题处理方法、计算设备及存储介质 |
| CN202410897972.9 | 2024-07-04 |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2026007668A1 true WO2026007668A1 (zh) | 2026-01-08 |
Family
ID=93471041
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/CN2025/100774 Pending WO2026007668A1 (zh) | 2024-07-04 | 2025-06-12 | 数据处理方法、问题处理方法、计算设备及存储介质 |
Country Status (2)
| Country | Link |
|---|---|
| CN (1) | CN119005329A (zh) |
| WO (1) | WO2026007668A1 (zh) |
Families Citing this family (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN119005329A (zh) * | 2024-07-04 | 2024-11-22 | 阿里巴巴(中国)有限公司 | 数据处理方法、问题处理方法、计算设备及存储介质 |
Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US5353380A (en) * | 1990-04-17 | 1994-10-04 | Apt Corporation | Approximate reasoning apparatus |
| JPH08190483A (ja) * | 1995-01-09 | 1996-07-23 | Fuji Xerox Co Ltd | ファジィルール自動作成方法およびその実施装置 |
| US20230214692A1 (en) * | 2020-06-01 | 2023-07-06 | Nec Corporation | Information processing apparatus, information processing method, and computer-readable recording medium |
| CN119005329A (zh) * | 2024-07-04 | 2024-11-22 | 阿里巴巴(中国)有限公司 | 数据处理方法、问题处理方法、计算设备及存储介质 |
-
2024
- 2024-07-04 CN CN202410897972.9A patent/CN119005329A/zh active Pending
-
2025
- 2025-06-12 WO PCT/CN2025/100774 patent/WO2026007668A1/zh active Pending
Patent Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US5353380A (en) * | 1990-04-17 | 1994-10-04 | Apt Corporation | Approximate reasoning apparatus |
| JPH08190483A (ja) * | 1995-01-09 | 1996-07-23 | Fuji Xerox Co Ltd | ファジィルール自動作成方法およびその実施装置 |
| US20230214692A1 (en) * | 2020-06-01 | 2023-07-06 | Nec Corporation | Information processing apparatus, information processing method, and computer-readable recording medium |
| CN119005329A (zh) * | 2024-07-04 | 2024-11-22 | 阿里巴巴(中国)有限公司 | 数据处理方法、问题处理方法、计算设备及存储介质 |
Also Published As
| Publication number | Publication date |
|---|---|
| CN119005329A (zh) | 2024-11-22 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| CN111639710B (zh) | 图像识别模型训练方法、装置、设备以及存储介质 | |
| US20230133981A1 (en) | Method of training image generation model, and method of generating image | |
| CN115062617A (zh) | 基于提示学习的任务处理方法、装置、设备及介质 | |
| JP7820630B2 (ja) | ニューラルネットワークを使用したタスク記述からのコンピュータコード生成 | |
| CN114218951B (zh) | 实体识别模型的训练方法、实体识别方法及装置 | |
| WO2025036077A1 (zh) | 任务处理方法、实体识别方法及任务处理的数据处理方法 | |
| WO2025007892A1 (zh) | 任务处理方法以及任务处理系统 | |
| WO2022052744A1 (zh) | 会话信息处理方法、装置、计算机可读存储介质及设备 | |
| CN117573842A (zh) | 文档检索方法以及自动问答方法 | |
| CN110162766A (zh) | 词向量更新方法和装置 | |
| CN113505206B (zh) | 基于自然语言推理的信息处理方法、装置和电子设备 | |
| CN112417156B (zh) | 多任务学习方法、装置、设备以及存储介质 | |
| CN114238656A (zh) | 基于强化学习的事理图谱补全方法及其相关设备 | |
| WO2026007668A1 (zh) | 数据处理方法、问题处理方法、计算设备及存储介质 | |
| CN114282552B (zh) | 非自回归翻译模型的训练方法及其装置 | |
| CN118747542A (zh) | 语言模型调整方法、装置、电子设备和计算机可读介质 | |
| CN112948584B (zh) | 短文本分类方法、装置、设备以及存储介质 | |
| CN114817476A (zh) | 语言模型的训练方法、装置、电子设备和存储介质 | |
| CN111538817A (zh) | 人机交互方法和装置 | |
| US20230095352A1 (en) | Translation Method, Apparatus and Storage Medium | |
| CN115186738B (zh) | 模型训练方法、装置和存储介质 | |
| US20220286416A1 (en) | Method and apparatus for generating account intimacy | |
| CN115795310A (zh) | 数据增强方法、装置、设备及其存储介质 | |
| CN116028618A (zh) | 文本处理、文本检索方法、装置、电子设备及存储介质 | |
| CN115269830A (zh) | 异常文本检测模型训练方法、异常文本检测方法及装置 |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| 121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 25832022 Country of ref document: EP Kind code of ref document: A1 |