Task multi-level reasoning method and device for low-bit large language model, equipment and medium

By constructing a directed acyclic graph and semantic extension, and dynamically adjusting the task reasoning rounds, the ambiguity and lack of detailed answers in abstract and fuzzy problems of large language models are resolved, and efficient and accurate multi-level task reasoning is achieved in low-bit models.

CN120806168BActive Publication Date: 2025-11-18XINGFAN XINGQI (CHENGDU) TECH CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202511242514.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-09-02
Publication Date
2025-11-18
Estimated Expiration
2045-09-02

AI Technical Summary

Technical Problem

Existing large language models are prone to ambiguity or misjudgment when dealing with highly abstract, semantically ambiguous, or overly broad questions, and their unreasonable task decomposition rounds result in incomplete answers.

Method used

By acquiring the first task, an initial directed acyclic graph is constructed, the task reasoning rounds are dynamically adjusted, and the second task is generated by combining the pre-set knowledge graph for associative reasoning. Semantic expansion and semantic replacement are then performed to form a refined set of sub-tasks, and finally, the answer is generated in a low-bit, high-language model.

Benefits of technology

It enables accurate answers to granular questions in low-bit, high-language models, improving reasoning depth and answer completeness while avoiding resource waste.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120806168B_ABST
    Figure CN120806168B_ABST
Patent Text Reader

Abstract

The application discloses a task multi-level reasoning method and device for a low-bit large language model, equipment and a medium, comprising: determining a task reasoning round according to a first task; performing associated reasoning on the first task to obtain a plurality of second tasks; adjusting an initial directed acyclic graph based on the task reasoning round to obtain a target directed acyclic graph; determining a round task decomposition number corresponding to each second task according to the second task; screening a second subtask based on the round task decomposition number of the second task to obtain a second subtask set corresponding to the second task; replacing the second task in the target directed acyclic graph with the corresponding second subtask set and inputting into a preset low-bit large language model to obtain a target reply text corresponding to the first task. The application belongs to the field of task reasoning. The application can accurately answer problems with low granularity.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of task reasoning, and more particularly to a method, apparatus, device, and medium for multi-level task reasoning using low-bit, large-language models. Background Technology

[0002] When large language models deal with highly abstract, semantically ambiguous, or overly broad questions, the lack of specific contextual support, clear conceptual definitions, and a well-defined logical structure in the question content can easily lead to ambiguity or misjudgment during the understanding and reasoning process. In such cases, the model may make guesses based on incomplete or uncertain information, resulting in generated answers that are incomplete, logically confused, off-topic, or even output seemingly reasonable but actually incorrect information.

[0003] Patent document CN202410970256.9 provides a task decomposition method and system based on large language models. In CN202410970256.9, the task is decomposed into multiple sub-tasks and decomposed in multiple rounds. The problem with this approach is that the rounds of decomposition are not directly related to the task, which may result in too many or too few rounds, ultimately leading to an incomplete answer to the question. Therefore, this invention provides a multi-level reasoning method for low-bit large language models. Summary of the Invention

[0004] This invention solves the technical problem of unreasonable task decomposition rounds in the prior art by providing a multi-level reasoning method, apparatus, device and medium for low-bit large language models, and achieves the technical effect of accurately answering questions with low granularity.

[0005] In a first aspect, the present invention provides a multi-level reasoning method for low-bit, high-language-model tasks, including:

[0006] Obtain the first task and determine the task reasoning round based on the first task, where the first task is the task to be reasoned;

[0007] Based on a pre-defined knowledge graph, the first task is subjected to associative reasoning to obtain several second tasks;

[0008] Construct several initial directed acyclic graphs corresponding to the second tasks, and adjust the initial directed acyclic graphs based on the task reasoning rounds to obtain the target directed acyclic graph, where the directed acyclic graph includes the execution order of each second task;

[0009] In the target directed acyclic graph, the number of round task decompositions corresponding to each second task is determined based on each second task. The number of round task decompositions is used to limit the number of decomposable second tasks in each round of reasoning.

[0010] Semantic expansion, semantic supplementation, or semantic replacement are performed on each second task in the target directed acyclic graph to obtain several second sub-tasks corresponding to the second task. Based on the number of rounds of task decomposition of the second task, the second sub-tasks are filtered to obtain the set of second sub-tasks corresponding to the second task. The second task is contained in the corresponding set of second sub-tasks.

[0011] The second task in the target directed acyclic graph is replaced with the corresponding set of second subtasks and input into a preset low-bit large language model to obtain the target response text corresponding to the first task.

[0012] Furthermore, based on the first task, the task reasoning rounds are determined, including:

[0013] Identify the keywords in the first task and construct the first keyword set;

[0014] Perform semantic replacement on each keyword in the first keyword set to obtain the maximum number of keywords with the same semantic meaning for each keyword;

[0015] Based on a pre-set language database, the abstractness index of each keyword is determined;

[0016] Determine the missing subject, verb, and object in the first task;

[0017] The task reasoning rounds for the first task are determined based on the subject-verb-object missing information, the abstractness index of several keywords, and the number of the largest semantically related keywords corresponding to the keywords.

[0018] Further, based on the subject-verb-object missing information, the abstractness index of several keywords, and the number of the largest semantically related keywords corresponding to the keywords, the task reasoning rounds of the first task are determined, including:

[0019]

[0020] in, For the first task, the task reasoning rounds and Round down to the nearest integer. The first keyword in the set of keywords The maximum number of semantically related keywords for a given keyword. For the preset quantity, The number of keywords in the first keyword set. To set the maximum abstractness index of content words in the predefined language database, For the first Abstraction index of each keyword To pre-determine the standard task reasoning rounds, In cases where the subject, verb, and object are missing, when the subject is missing... Take 3; when the object is missing, Take 2; when the predicate is missing, Take 1.

[0021] Furthermore, based on each second task, the number of rounds of task decomposition corresponding to that second task is determined, including:

[0022] Extract several keywords from the second task to obtain the second keyword set corresponding to the second task;

[0023] Based on a pre-set language database, determine the abstractness index of each keyword in the second keyword set;

[0024] Based on the number of words in the second task, the number of words in the second keyword set, and the abstractness index of each keyword, determine the number of rounds of task decomposition corresponding to the second task.

[0025] Furthermore, based on the number of words in the second task, the number of words in the second keyword set, and the abstractness index of each keyword, the number of rounds of task decomposition corresponding to the second task is determined, including:

[0026]

[0027]

[0028] in, For the first The number of rounds of task breakdown corresponding to each second task. For the first The number of characters in the second keyword set. For the first The number of words in the second task To pre-determine the number of tasks to be broken down in each round, As an additional index, The average abstractness index of the keywords for the first task. For the first The average abstractness index of the keywords for the second task. Round down to the nearest integer.

[0029] Furthermore, based on a pre-defined knowledge graph, associative reasoning is performed on the first task to obtain several second tasks, including:

[0030] Extract the key entities from the first task;

[0031] In the pre-defined knowledge graph, target nodes are located based on key entities;

[0032] In the pre-defined knowledge graph, several second tasks are obtained by performing association reasoning based on the relationship paths corresponding to the target nodes.

[0033] Furthermore, construct several initial directed acyclic graphs corresponding to the second tasks, including:

[0034] Input several second tasks into a pre-defined low-bit large language model to obtain the reasoning order corresponding to the several second tasks;

[0035] The second task is filled into the preset reasoning template in the order of reasoning to obtain the initial directed acyclic graph.

[0036] Secondly, the present invention provides a task-based multi-level inference apparatus for low-bit, large-language models, comprising:

[0037] The acquisition module is used to acquire the first task and determine the task reasoning round based on the first task, where the first task is the task to be reasoned.

[0038] The reasoning module is used to perform associative reasoning on the first task based on a preset knowledge graph to obtain several second tasks;

[0039] The acyclic graph module is used to construct initial directed acyclic graphs corresponding to several second tasks, and adjust the initial directed acyclic graphs based on the task inference rounds to obtain the target directed acyclic graph, wherein the directed acyclic graph includes the execution order of each second task;

[0040] The decomposition module is used to determine the number of round-based task decompositions corresponding to each second task in the target directed acyclic graph, where the number of round-based task decompositions is used to limit the number of decomposable second tasks in each round of inference.

[0041] The extension module is used to perform semantic extension, semantic supplementation or semantic replacement on each second task in the target directed acyclic graph to obtain several second sub-tasks corresponding to the second task. Based on the number of rounds of task decomposition of the second task, the second sub-tasks are filtered to obtain the set of second sub-tasks corresponding to the second task. The second task is contained in the corresponding set of second sub-tasks.

[0042] The result output module is used to replace the second task in the target directed acyclic graph with the corresponding set of second subtasks and input it into the preset low-bit large language model to obtain the target response text corresponding to the first task.

[0043] Thirdly, the present invention provides an electronic device, comprising:

[0044] processor;

[0045] Memory used to store processor-executable instructions;

[0046] The processor is configured to execute a multi-level reasoning method for low-bit, large-language models, as provided in the first aspect.

[0047] Fourthly, the present invention provides a non-transitory computer-readable storage medium, wherein when the instructions in the non-transitory computer-readable storage medium are executed by a processor of an electronic device, the electronic device is able to execute a task-based multi-level reasoning method for low-bit large language models as provided in the first aspect.

[0048] One or more technical solutions provided in this invention have at least the following technical effects or advantages:

[0049] This invention dynamically determines the task reasoning rounds by analyzing the keyword abstractness, semantic ambiguity, and subject-verb-object completeness of the first task, thereby improving the adaptability of the reasoning depth. This invention combines a pre-defined knowledge graph to extend the task's associations, generating several second tasks and constructing an initial directed acyclic graph (DAG) of their execution order, thus achieving structured modeling of the task flow.

[0050] This invention dynamically sets the number of rounds of task decomposition for each second task based on task language features, precisely controlling the granularity of subtask generation. Furthermore, it semantically expands and supplements the second tasks, generating rich subtasks, which are then filtered according to quantity limitations to form a refined set of subtasks. Finally, the optimized task graph is input into a low-bit, high-performance model to generate the target response. While ensuring lightweight model deployment, this invention significantly improves the understanding depth and response completeness of complex tasks through graph structure, semantic quantization, and hierarchical reasoning mechanisms, overcoming the bottleneck of small models struggling to handle abstract and ambiguous problems.

[0051] This invention performs vertical reasoning through a second task and horizontal reasoning through a second sub-task. It also reasonably limits vertical reasoning by the number of task reasoning rounds and horizontal reasoning by the number of task decomposition rounds. This ensures accurate output while avoiding the waste of resources caused by unreasonable multi-round reasoning. Attached Figure Description

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

[0053] Figure 1 A flowchart illustrating the multi-level reasoning method for low-bit large language models provided by this invention;

[0054] Figure 2 This is a schematic diagram of the structure of the multi-level inference device for low-bit large language models provided by the present invention. Detailed Implementation

[0055] The embodiments of the present invention provide a multi-level reasoning method for low-bit large language models, which solves the technical problem of unreasonable task decomposition rounds in the prior art.

[0056] The technical solution of this invention is to solve the above-mentioned technical problems, and the overall idea is as follows:

[0057] A multi-level reasoning method for low-bit, high-language-scale models includes: obtaining a first task and determining the task reasoning rounds based on the first task, where the first task is the task to be reasoned; performing associative reasoning on the first task based on a pre-defined knowledge graph to obtain several second tasks; constructing an initial directed acyclic graph (DAG) corresponding to the several second tasks, and adjusting the initial DAG based on the task reasoning rounds to obtain a target DAG, where the DAG includes the execution order of each second task; and determining the number of rounds of task decomposition corresponding to each second task in the target DAG, where... The number of round-based task decompositions is used to limit the number of decomposable second tasks in each round of inference. Semantic expansion, semantic supplementation, or semantic replacement is performed on each second task in the target directed acyclic graph to obtain several corresponding second sub-tasks. Based on the number of round-based task decompositions for each second task, the second sub-tasks are filtered to obtain a set of corresponding second sub-tasks. The second task is contained within the corresponding set of second sub-tasks. The second task in the target directed acyclic graph is replaced with the corresponding set of second sub-tasks and input into a preset low-bit, high-language model to obtain the target response text corresponding to the first task.

[0058] To better understand the above technical solutions, the following will provide a detailed explanation of the technical solutions in conjunction with the accompanying drawings and specific implementation methods.

[0059] First, it should be clarified that the term "and / or" in this article is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, or B existing alone. Additionally, the character " / " in this article generally indicates that the preceding and following related objects have an "or" relationship.

[0060] This invention provides, for example Figure 1 The multi-level reasoning method for low-bit, large-language models shown includes steps S11-S16:

[0061] Step S11: Obtain the first task and determine the task reasoning round based on the first task, where the first task is the task to be reasoned.

[0062] The first task refers to a number of highly abstract, semantically ambiguous, or overly broad problems. The number of problems can usually be 1. When multiple problems are input into a large model at once, the problems can be split and steps S11-S16 can be executed for each problem.

[0063] Based on the first task, determine the task reasoning rounds, including:

[0064] Identify the keywords for the first task and construct the first keyword set.

[0065] The vocabulary carrying the core semantics can be extracted from the first task description. Natural language processing techniques (such as part-of-speech tagging and named entity recognition) can be used to extract nouns, verbs, adjectives and other content words.

[0066] For example:

[0067] Task: How to enhance a company's innovation capabilities?

[0068] Keyword set = {improvement, enterprise, innovation, capability};

[0069] Perform semantic replacement on each keyword in the first keyword set to obtain the maximum number of semantically related keywords for each keyword.

[0070] You can query thesaurus (such as WordNet, HowNet, or a self-built semantic thesaurus) to count the number of synonyms that can replace each word (i.e., the maximum number of semantically related keywords corresponding to each keyword).

[0071] For example:

[0072] Synonyms for innovation: innovation, creation, transformation, breakthrough, etc., quantity = 5;

[0073] Synonyms for "enterprise": company, institution, organization; quantity = 3

[0074] The larger the quantity, the more abstract the word or the stronger its context dependence.

[0075] The maximum number of synonyms for each keyword measures the semantic richness or ambiguity of the word. The more synonyms there are, the more ambiguous the meaning or the greater the interpretable space.

[0076] Based on a pre-set language database, the abstractness index of each keyword is determined.

[0077] The pre-set language database can be a psycholinguistic database (such as the MRC Psycholinguistic Database), or it can be a vocabulary collected by relevant staff themselves, and then each vocabulary word is assigned a value based on its level of abstraction.

[0078] Taking the use of psycholinguistic databases as an example:

[0079] The psycholinguistic database assigns a concreteness score to each word (i.e., the abstractness index of this invention). The abstractness index is usually 1-5 or 1-7. The higher the abstractness index, the more concrete the word is. The higher the abstractness index and the lower the abstractness index, the more abstract the word is and the less easily it is understood.

[0080] For example: 1 = extremely abstract; 5 = highly specific.

[0081] Determine if the subject, verb, and object are missing in the first task.

[0082] A complete question typically consists of core components such as subject (S), verb (V), and object (O). When these components are missing, the semantic integrity of the question is compromised, thus affecting comprehension. The influence of the subject (S), verb (V), and object (O) on the question is uneven.

[0083] In this invention, it is determined that, in most cases, the absence of a subject (S) has the greatest impact, while the absence of a predicate (V) has the least impact.

[0084] It is understandable that the impact of missing subject, verb, and object can also be related to the specific domain of the problem; however, this invention only discusses the majority of cases.

[0085] The task reasoning rounds for the first task are determined based on the subject-verb-object missing information, the abstractness index of several keywords, and the number of the largest semantically related keywords corresponding to the keywords.

[0086] Specifically, it includes:

[0087]

[0088] in, For the first task, the task reasoning rounds and Round down to the nearest integer. The first keyword in the set of keywords The maximum number of semantically related keywords for a given keyword. For the preset quantity, The number of keywords in the first keyword set. To set the maximum abstractness index of content words in the predefined language database, For the first Abstraction index of each keyword To pre-determine the standard task reasoning rounds, In cases where the subject, verb, and object are missing, when the subject is missing... Take 3; when the object is missing, Take 2; when the predicate is missing, Take 1.

[0089] The above method dynamically determines the inference rounds by quantifying the ambiguity and structural defects of the task language. The first part measures semantic uncertainty, reflecting the richness of synonyms for keywords; a higher ratio indicates more divergent semantics. The second part measures the level of abstraction; the more abstract the keywords, the higher the score. It also directly increases the inference burden by considering missing subject-verb-object pairs. The overall formula transforms linguistic features into calculable inference strength indicators.

[0090] It can be understood that the above formula is only one possible form, and its meaning is that the more severe the subject-verb-object missing situation, the lower the abstractness index of several keywords (i.e., the more abstract), and the more major semantic keywords corresponding to the keywords, the more rounds of reasoning are required.

[0091] The value of can be 0 in some cases, meaning that the first task is very specific and does not need to be decomposed; it can be directly input into the semantic network model to obtain the answer. This invention mainly discusses... When the value is greater than or equal to 2 ( A value of 1 indicates that the first task is relatively clear, and the answer to the first task can be directly obtained from the semantic model. When the value is 0 or 1, in addition to obtaining a response directly from the semantic model, the steps provided by this invention can also be continued. When the value is 0 or 1, the first task is the second task.

[0092] The task reasoning rounds of the first task refer to the number of questions corresponding to the steps of reasoning the first task (i.e., the number of questions in the second task below).

[0093] For example: How to cook spaghetti? If the first task has 5 reasoning rounds, then the second task has 5 rounds.

[0094] Second task: Where to get the noodles?

[0095] Second task: Where to get the tomato sauce?

[0096] Second task: How much more water do we need to add?

[0097] Second task: When to cook the pasta?

[0098] Second task: When should the fire be turned off?

[0099] Traditional methods often employ fixed rounds or simple rules, making it difficult to handle diverse user questioning styles. This invention integrates three dimensions—semantic ambiguity, conceptual abstraction, and syntactic completeness—to intelligently assess task complexity. For highly abstract, vaguely expressed, or structurally incomplete questions, it automatically increases the number of reasoning rounds to clarify intent, decompose subtasks, and retrieve related knowledge, thereby improving the accuracy and completeness of the answer. The method provided by this invention enhances the robustness and interpretability of large models in open-domain tasks, making it particularly suitable for scenarios requiring a deep understanding of user intent, such as intelligent customer service, educational guidance, and decision support.

[0100] Step S12: Based on the preset knowledge graph, perform association reasoning on the first task to obtain several second tasks.

[0101] Specifically, this includes: extracting key entities from the first task; locating target nodes in the pre-defined knowledge graph based on the key entities; and performing association reasoning based on the relationship paths corresponding to the target nodes in the pre-defined knowledge graph to obtain several second tasks.

[0102] Extracting key entities from the first task refers to identifying nominal components that carry core semantics from the natural language task (first task) input by the user. "Key entities" are the bridge connecting real-world problems and knowledge graphs, and are used for subsequent matching and querying.

[0103] A knowledge graph is a semantic network composed of nodes and edges. The system uses the keywords extracted in the previous step as indexes to find the corresponding nodes in the graph, which serve as the starting point for reasoning.

[0104] Starting from the located nodes, traverse and reason along the relational edges in the graph to discover other nodes related to the original task, thereby generating a series of second tasks that need to be completed.

[0105] Taking the question "How to cook pasta?" as an example:

[0106] Key entities identified: pasta, cooking.

[0107] Locate the target node in the pre-defined knowledge graph, assuming the knowledge graph contains the following structured knowledge:

[0108] Pasta → Ingredients needed → Pasta, tomato sauce;

[0109] Pasta → Instructions → Bring water to a boil, then add pasta to the pot;

[0110] ...

[0111] The above are just some examples.

[0112] By matching entities such as spaghetti and cooking, the corresponding nodes in the graph are located, and the graph begins to expand outward along their relational edges.

[0113] Starting from the pasta node, the second task is automatically generated by reasoning along the relationship path of required ingredients and operation steps.

[0114] In addition to the method provided by this invention, problem reasoning can also be performed on the first task based on common models (such as chatgpt, Tongyi Qianwen, Doubao, etc.) to obtain several second tasks.

[0115] Step S13: Construct several initial directed acyclic graphs corresponding to the second tasks, and adjust the initial directed acyclic graphs based on the task reasoning rounds to obtain the target directed acyclic graph, wherein the directed acyclic graph includes the execution order of each second task.

[0116] Specifically, it includes:

[0117] Input several second tasks into a preset low-bit large language model to obtain the reasoning order corresponding to the second tasks; fill the second tasks into the preset reasoning template in the order of reasoning to obtain the initial directed acyclic graph.

[0118] Low-bit Large Language Models (LLMs) refer to large language models that were originally stored and computed using high-precision floating-point numbers (such as 32-bit or 16-bit floating-point numbers, i.e., FP32 / FP16) and then converted to models using lower bit counts (such as 8 bits, 4 bits, or even lower) through quantization techniques. The core goal of LLMs is to significantly reduce the model's storage footprint, memory consumption, and computational resource requirements while maintaining model performance as much as possible, thereby achieving more efficient deployment and inference. This is particularly suitable for resource-constrained devices (such as mobile phones and edge devices) or scenarios requiring low-cost, large-scale services.

[0119] In addition to the low-bit, high-language model, it can also continue to be executed using commonly used ordinary models (such as chatgpt, Tongyi Qianwen, Doubao, etc.).

[0120] After obtaining several second tasks, there is no logical connection between the second tasks. Therefore, by inputting several second tasks into a preset low-bit large language model, the reasoning order corresponding to several second tasks can be obtained.

[0121] For example: How to cook pasta?

[0122] Sequence 1: Second task: Where to get the noodles?

[0123] Order 1: Second task: Where to get the ketchup?

[0124] Sequence 3: Second task: How much more water do we need to add?

[0125] Fourth in sequence: Second task: When to cook the pasta?

[0126] Fifth in sequence: Second task: When to turn off the fire?

[0127] The preset reasoning template is a structured framework used to organize the process relationships between tasks, represented as a graph structure. Sorted tasks can be filled into this template one by one, forming directed connections between nodes.

[0128] A directed acyclic graph (DAG) represents a graph where tasks have a clear direction of execution and there are no circular dependencies.

[0129] This invention utilizes an efficient low-bit model for logical sorting and then generates a task dependency graph through a templated structure, providing clear action path planning.

[0130] An initial directed acyclic graph (DAG) is obtained, and adjustments are made to the initial DAG based on the task inference rounds to obtain the target DAG, specifically including:

[0131] Generally speaking, the number of second tasks obtained after knowledge graph reasoning is much greater than the number of task reasoning rounds.

[0132] Therefore, this invention mainly discusses cases where the number of second tasks is greater than the number of task reasoning rounds (if it is less than or equal to, the initial directed acyclic graph can be directly used as the target directed acyclic graph).

[0133] If the number of second tasks exceeds the number of task reasoning rounds, then the number of second tasks needs to be reduced to the same number as the number of task reasoning rounds.

[0134] The importance of the first task can be determined based on the second task, and the second tasks that rank higher in importance can be retained (the number of which is the same as the number of task reasoning rounds).

[0135] For example, if the task reasoning rounds are 5 and the second task is 7, then the top 5 second tasks that are most important to achieving the first task are retained, and the remaining 2 second tasks are pruned from the initial directed acyclic graph to obtain the target directed acyclic graph. It can be understood that the second tasks in the pruned target directed acyclic graph also contain the execution order.

[0136] Step S14: In the target directed acyclic graph, determine the number of round task decompositions corresponding to each second task based on each second task. The number of round task decompositions is used to limit the number of decomposable second tasks in each round of reasoning.

[0137] Specifically, this includes: extracting several keywords from the second task to obtain the second keyword set corresponding to the second task; determining the abstractness index of each keyword in the second keyword set based on a preset language database; and determining the number of rounds of task decomposition corresponding to the second task based on the number of words in the second task, the number of words in the second keyword set, and the abstractness index of each keyword.

[0138] Specifically, based on the number of words in the second task, the number of words in the second keyword set, and the abstractness index of each keyword, the number of rounds of task decomposition corresponding to the second task is determined, including:

[0139]

[0140]

[0141] in, For the first The number of rounds of task breakdown corresponding to each second task. For the first The number of characters in the second keyword set. For the first The number of words in the second task To pre-determine the number of tasks to be broken down in each round, As an additional index, The average abstractness index of the keywords for the first task. For the first The average abstractness index of the keywords for the second task. Round down to the nearest integer.

[0142] Extracting keywords from the second task is similar to the steps described above for extracting keywords, and will not be repeated here.

[0143] In the constructed Directed Acyclic Graph (DAG), for each second task, the maximum number of finer-grained subtasks it can be decomposed into during subsequent reasoning is dynamically determined (i.e., the number of round-based task decompositions). The number of round-based task decompositions is used to control the depth and granularity of reasoning, preventing over-decomposition or under-decomposition.

[0144] The first part measures the semantic density of the task. A high percentage of keywords indicates concentrated information, requiring further breakdown.

[0145] Understandably, after reasoning about the first task, the second task can usually be more detailed than the first; that is, under normal circumstances... That is, no additional quantity is needed; however, to avoid the impact of the second task potentially being less understandable than the first task, therefore, in In special cases, increase the number of decompositions.

[0146] This invention considers both language structure and semantic abstraction, avoiding over-decomposition of simple tasks and under-decomposition of complex tasks, thereby improving the rationality of task planning and execution efficiency. Furthermore, by adding an additional index, it avoids the impact caused by the second task being less comprehensible than the first task in rare cases.

[0147] Step S15: Perform semantic expansion, semantic supplementation or semantic replacement on each second task in the target directed acyclic graph to obtain several second sub-tasks corresponding to the second task. Based on the number of rounds of task decomposition of the second task, filter the second sub-tasks to obtain the set of second sub-tasks corresponding to the second task. The second task is included in the corresponding set of second sub-tasks.

[0148] It is understandable that the relationship between the first task and the second task is vertical, that is, the second task is a breakdown of the first task. Please refer to the example above for details.

[0149] The relationship between the second task and the second subtask is a horizontal one, meaning that the second subtask and the second task are semantically interchangeable.

[0150] By using large language models, knowledge graphs, and the work experience of relevant personnel, the semantics of each second task in the target directed acyclic graph can be expanded, supplemented, or replaced to obtain several second sub-tasks corresponding to the second task.

[0151] It is also understandable that It can be 0 or 1, then the second task is the second subtask. A value of 0 or 1 indicates that the second task is clear and specific, and synonym substitution is not required.

[0152] When the number of second subtasks exceeds the number of task decompositions in a round, the second subtasks can be filtered. The filtering rules can be determined by human experience, the average abstraction index of the second subtasks, etc.

[0153] For example, the sentence abstraction index of the second subtask can be determined based on the average abstraction index of the keywords in the second subtask, and sentences with higher abstraction indices are retained.

[0154] For example, in the target directed acyclic graph, the number of rounds of task decomposition for the second task ranked second is 3. After inputting into the large language model, the number of second subtasks is 8. Then, the average abstraction index of each second subtask can be calculated, and the top 2 second subtasks can be retained (where the second task is directly retained as a second subtask, so the total is 3).

[0155] Step S16: Replace the second task in the target directed acyclic graph with the corresponding set of second subtasks and input it into the preset low-bit large language model to obtain the target response text corresponding to the first task.

[0156] You can pre-set response templates or response prompts in a preset low-bit, high-language model, for example:

[0157] "Please output the most suitable response for each of the provided second subtask sets, and concatenate the responses from each second subtask set into a single response," or,

[0158] "In each set of second subtasks, based on the context, select the most appropriate second subtask to respond to, and then concatenate each response in order to obtain a response content," etc.

[0159] After inputting the target directed acyclic graph into the preset low-bit large language model, the preset low-bit large language model outputs the target response text corresponding to the first task according to the preset response template.

[0160] In summary, this invention dynamically determines the task reasoning rounds by analyzing the keyword abstractness, semantic ambiguity, and subject-verb-object completeness of the first task, thereby improving the adaptability of the reasoning depth. This invention combines a pre-defined knowledge graph to extend the task's associations, generating several second tasks and constructing an initial directed acyclic graph (DAG) of their execution order, thus achieving structured modeling of the task flow.

[0161] This invention dynamically sets the number of rounds of task decomposition for each second task based on task language features, precisely controlling the granularity of subtask generation. Furthermore, it semantically expands and supplements the second tasks, generating rich subtasks, which are then filtered according to quantity limitations to form a refined set of subtasks. Finally, the optimized task graph is input into a low-bit, high-performance model to generate the target response. While ensuring lightweight model deployment, this invention significantly improves the understanding depth and response completeness of complex tasks through graph structure, semantic quantization, and hierarchical reasoning mechanisms, overcoming the bottleneck of small models struggling to handle abstract and ambiguous problems.

[0162] This invention performs vertical reasoning through a second task and horizontal reasoning through a second sub-task. It also reasonably limits vertical reasoning by the number of task reasoning rounds and horizontal reasoning by the number of task decomposition rounds. This ensures accurate output while avoiding the waste of resources caused by unreasonable multi-round reasoning.

[0163] Based on the same inventive concept, the present invention provides, as follows: Figure 2 The multi-level inference device for low-bit, large-language models shown includes:

[0164] The acquisition module 21 is used to acquire the first task and determine the task reasoning round based on the first task, wherein the first task is the task to be reasoned.

[0165] Reasoning module 22 is used to perform associative reasoning on the first task based on a preset knowledge graph to obtain several second tasks;

[0166] The acyclic graph module 23 is used to construct an initial directed acyclic graph corresponding to several second tasks, and adjust the initial directed acyclic graph based on the task reasoning rounds to obtain a target directed acyclic graph, wherein the directed acyclic graph includes the execution order of each second task;

[0167] The decomposition module 24 is used to determine the number of round task decompositions corresponding to each second task in the target directed acyclic graph, based on each second task. The number of round task decompositions is used to limit the number of decomposable second tasks in each round of inference.

[0168] The extension module 25 is used to perform semantic extension, semantic supplementation or semantic replacement on each second task in the target directed acyclic graph to obtain several second sub-tasks corresponding to the second task. Based on the number of round task decompositions of the second task, the second sub-tasks are filtered to obtain the set of second sub-tasks corresponding to the second task. The second task is included in the corresponding set of second sub-tasks.

[0169] The output module 26 is used to replace the second task in the target directed acyclic graph with the corresponding set of second subtasks and input it into the preset low-bit large language model to obtain the target response text corresponding to the first task.

[0170] Based on the same inventive concept, the present invention also provides an electronic device, comprising:

[0171] processor;

[0172] Memory used to store processor-executable instructions;

[0173] The processor is configured to execute a multi-level reasoning method for low-bit, large-language models, as described above.

[0174] Based on the same inventive concept, the present invention also provides a non-transitory computer-readable storage medium that, when the instructions in the storage medium are executed by the processor of an electronic device, enables the electronic device to execute the multi-level reasoning method for low-bit large language models as described above.

[0175] Since the electronic device described in this embodiment is an electronic device used to implement the information processing method in the embodiments of the present invention, those skilled in the art can understand the specific implementation methods and various variations of the electronic device in this embodiment based on the information processing method described in the embodiments of the present invention. Therefore, how the electronic device implements the method in the embodiments of the present invention will not be described in detail here. Any electronic device used by those skilled in the art to implement the information processing method in the embodiments of the present invention falls within the scope of protection of the present invention.

[0176] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0177] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0178] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0179] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1The steps of the function specified in one or more boxes.

[0180] Although preferred embodiments of the invention have been described, those skilled in the art, upon learning the basic inventive concept, can make other changes and modifications to these embodiments. Therefore, the appended claims are intended to be interpreted as including both the preferred embodiments and all changes and modifications falling within the scope of the invention.

[0181] Obviously, those skilled in the art can make various modifications and variations to this invention without departing from its spirit and scope. Therefore, if these modifications and variations fall within the scope of the claims of this invention and their equivalents, this invention also intends to include these modifications and variations.

Claims

1. A multi-level reasoning method for low-bit, large-language-model tasks, characterized in that: include: Obtain a first task and determine the task reasoning rounds based on the first task, wherein the first task is the task to be reasoned, including: determining the keywords in the first task and constructing a first keyword set; performing semantic substitution on each keyword in the first keyword set to obtain the maximum number of semantically identical keywords corresponding to each keyword; determining the abstractness index of each keyword based on a preset language database; determining the subject-verb-object missing status of the first task; and determining the task reasoning rounds of the first task based on the subject-verb-object missing status, the abstractness index of several keywords, and the maximum number of semantically identical keywords corresponding to the keywords. Based on a pre-defined knowledge graph, the first task is subjected to associative reasoning to obtain several second tasks; Several initial directed acyclic graphs (DAGs) corresponding to the second tasks are constructed, and the initial DAGs are adjusted based on the task inference rounds to obtain a target DAG. The DAG includes the execution order of each second task. When the number of second tasks is greater than the number of task inference rounds, the initial DAG is pruned according to the importance of the second tasks to the achievement of the first task to obtain the target DAG. When the number of second tasks is less than or equal to the number of task inference rounds, the initial DAG is used as the target DAG. In the target directed acyclic graph, the number of round task decompositions corresponding to each second task is determined according to each second task, wherein the number of round task decompositions is used to limit the number of decomposable second tasks in each round of reasoning; Semantic expansion, semantic supplementation, or semantic replacement are performed on each second task in the target directed acyclic graph to obtain several second sub-tasks corresponding to the second task. Based on the number of rounds of task decomposition of the second task, the second sub-tasks are filtered to obtain the set of second sub-tasks corresponding to the second task. The second task is contained in the corresponding set of second sub-tasks. The second task in the target directed acyclic graph is replaced with the corresponding set of second subtasks and input into a preset low-bit large language model to obtain the target response text corresponding to the first task.

2. The task-based multi-level reasoning method for low-bit, large-language models as described in claim 1, characterized in that, Based on the subject-verb-object missing information, the abstractness index of several keywords, and the number of the largest semantically related keywords, the task reasoning rounds of the first task are determined, including: in, The task reasoning rounds for the first task and Round down to the nearest integer. The first keyword in the set of keywords The maximum number of semantically related keywords for a given keyword. For the preset quantity, The number of keywords in the first keyword set. To set the maximum abstractness index of content words in the predefined language database, For the first Abstraction index of each keyword To pre-determine the standard task reasoning rounds, In cases where the subject, verb, and object are missing, when the subject is missing... Take 3; when the object is missing, Take 2; when the predicate is missing, Take 1.

3. The task-based multi-level reasoning method for low-bit, large-language models as described in claim 1, characterized in that... Based on each second task, determine the number of rounds of task decomposition corresponding to that second task, including: Extract several keywords from the second task to obtain the second keyword set corresponding to the second task; Based on a pre-set language database, determine the abstractness index of each keyword in the second keyword set; Based on the number of words in the second task, the number of words in the second keyword set, and the abstractness index of each keyword, determine the number of rounds of task decomposition corresponding to the second task.

4. The task-based multi-level reasoning method for low-bit, large-language models as described in claim 3, characterized in that, Based on the word count in the second task, the word count in the second keyword set, and the abstractness index of each keyword, determine the number of rounds of task decomposition corresponding to the second task, including: in, For the first The number of rounds of task breakdown corresponding to each second task. For the first The number of characters in the second keyword set. For the first The number of words in the second task To pre-determine the number of tasks to be broken down in each round, As an additional index, The average abstractness index of the keywords for the first task. For the first The average abstractness index of the keywords for the second task. Round down to the nearest integer.

5. The task-based multi-level reasoning method for low-bit, large-language models as described in claim 1, characterized in that, Based on a pre-defined knowledge graph, associative reasoning is performed on the first task to obtain several second tasks, including: Extract the key entities from the first task; In the preset knowledge graph, target nodes are located based on key entities; In the preset knowledge graph, several second tasks are obtained by performing association reasoning based on the relationship paths corresponding to the target nodes.

6. The task-based multi-level reasoning method for low-bit, large-language models as described in claim 1, characterized in that, Construct several initial directed acyclic graphs corresponding to the second tasks, including: Input several second tasks into a pre-defined low-bit large language model to obtain the reasoning order corresponding to the several second tasks; The second task is filled into the preset reasoning template in the order of reasoning to obtain the initial directed acyclic graph.

7. A multi-level reasoning device for low-bit, large-language models, characterized in that, The multi-level reasoning method for low-bit large language models described in any one of claims 1-6 includes: The acquisition module is used to acquire the first task and determine the task reasoning round based on the first task, wherein the first task is the task to be reasoned. The reasoning module is used to perform associative reasoning on the first task based on a preset knowledge graph to obtain several second tasks; The acyclic graph module is used to construct initial directed acyclic graphs corresponding to several second tasks, and adjust the initial directed acyclic graphs based on the task inference rounds to obtain a target directed acyclic graph, wherein the directed acyclic graph includes the execution order of each second task; The decomposition module is used to determine the number of round task decompositions corresponding to each second task in the target directed acyclic graph, wherein the number of round task decompositions is used to limit the number of decomposable second tasks in each round of inference. The extension module is used to perform semantic extension, semantic supplementation or semantic replacement on each second task in the target directed acyclic graph to obtain several second sub-tasks corresponding to the second task, and to filter the second sub-tasks based on the number of round task decompositions of the second task to obtain the set of second sub-tasks corresponding to the second task, and the second task is included in the corresponding set of second sub-tasks. The result output module is used to replace the second task in the target directed acyclic graph with the corresponding set of second subtasks and input it into a preset low-bit large language model to obtain the target response text corresponding to the first task.

8. An electronic device, characterized in that, include: processor; Memory used to store the processor's executable instructions; The processor is configured to execute a task-based multi-level reasoning method for low-bit large language models as described in any one of claims 1 to 6.

9. A non-transitory computer-readable storage medium, characterized in that, When the instructions in the non-transitory computer-readable storage medium are executed by the processor of the electronic device, the electronic device is able to perform a task-based multi-level reasoning method for a low-bit large language model as described in any one of claims 1 to 6.

Citation Information

Patent Citations

  • Task decomposition method and system based on large language model

    CN118520073B

  • Adaptive task decomposition method and system for achievement transformation large model

    CN119990327A

  • Complex task full-automatic processing method based on multi-agent cooperation and related device

    CN120256113A