Congestion handling methods, systems, computer equipment, storage media, and program products
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-07-15
- Publication Date
- 2026-08-14
AI Technical Summary
[0004]相关阻塞处理方式存在以下问题:试错执行容易留存错误路径,大范围检索会引入无效信息,自主猜测易引发后续执行偏差,人工干预也会大幅降低流水线运行效率
[0056]采用本申请实施例提供的阻塞处理方法、系统、计算机设备、存储介质和程序产品,不再依靠Agent反复试错、主观推测的方式处理阻塞,而是在发生决策路径缺陷类型的阻塞时,基于当前阻塞上下文信息驱动目标决策路径逐节点核验,锁定真实缺口,并根据该缺口内容和设置的参考文档范围定向寻找参考答案,从根源避免因随意试错、主观猜测形成的错误决策逻辑,防止异常路径被持续沿用的问题,且可以消除无边界全域检索带来的冗余无效信息,通过减少无关数据的引入,规避冗余信息干扰决策判断,以提高决策精准度。也即,本申请实施例针对决策路径类阻塞,提供了一个高效且精准的处理方式,可以基于自主定位缺口、定向检索资料、临时修补并复测验证的自动化流程完成阻塞处置,可以有效缩短阻塞处置耗时,使得流水线能够在阻塞修复后自主接续运行,有效提高Agent执行过程中的阻塞处理效率和阻塞修补精准度。
Smart Images

Figure CN122570189A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of artificial intelligence technology, and in particular to a blocking handling method, system, computer device, storage medium, and program product. Background Technology
[0002] Currently, mainstream AI Agent (Artificial Intelligence Agent) frameworks generally encapsulate domain-specific knowledge in the form of skills, tools, or plugins. Different skill files define the decision rules, execution steps, and reference materials for corresponding scenarios. Complex multi-step tasks are scheduled to execute various skills sequentially by a pipeline orchestrator, which is widely used in automated operation scenarios such as the development of AI chip operators.
[0003] When the Agent encounters blocking issues such as ambiguous decision paths, missing rules, or unclear interface semantics during execution, relevant technologies often adopt conventional emergency handling methods, including verifying the execution results through multiple trial-and-error coding, expanding the search scope to look up a large number of irrelevant files, autonomously predicting and skipping abnormal nodes, and pausing the task to wait for manual intervention.
[0004] The existing blocking handling methods have the following problems: trial-and-error execution can easily leave behind error paths, large-scale searches can introduce invalid information, arbitrary guessing can easily lead to deviations in subsequent execution, and manual intervention can significantly reduce pipeline efficiency. In other words, there is currently a lack of efficient and accurate blocking handling methods in the Agent execution process. Summary of the Invention
[0005] Therefore, it is necessary to provide a blocking handling method, system, computer device, storage medium, and program product that can improve the efficiency and accuracy of blocking handling during Agent execution, in order to address the above-mentioned technical problems.
[0006] In a first aspect, this application provides a blocking handling method applied to a blocking handling system, the method comprising:
[0007] When a blockage occurs in a pipeline step, determine the type of blockage corresponding to the current blockage location;
[0008] If the blocking type is a decision path defect type, the target decision path corresponding to the current blocking position is driven to execute decisions node by node according to the current blocking context information, generating a gap record. The gap record includes a gap problem description and a reference document range.
[0009] Based on the description of the gap problem and the scope of the reference documents, an answer is retrieved, a corresponding reference answer is generated, and the target decision path is temporarily repaired based on the reference answer;
[0010] After the temporary repair of the target decision path is completed, the target decision path is re-driven to execute decisions node by node according to the current blocking context information. If each node in the target decision path can make a correct decision, the pipeline step execution is resumed.
[0011] In one embodiment, determining the blockage type corresponding to the current blockage location when a blockage occurs in a pipeline step includes:
[0012] Receive blocking information reported by the pipeline step executor, the blocking information including error description, blocking location information and current blocking context information;
[0013] Based on the blocking information, the blocking type corresponding to the current blocking position is determined. The blocking type includes implementation defect type or decision path defect type.
[0014] In one embodiment, the step of driving the target decision path corresponding to the current blocking position to execute decisions node by node based on the current blocking context information to generate a gap record includes:
[0015] Based on the blockage location information, determine the skill file corresponding to the current blockage location;
[0016] Based on the current blocking context information and the attributed skill file, the target decision path is driven to execute decisions node by node in sequence, and during the decision execution phase of each node, the executability standard is evaluated for the node.
[0017] When any of the nodes fails to meet the executability criteria, the traversal of subsequent nodes is terminated, and the corresponding decision trajectory and gap record are generated.
[0018] In one embodiment, generating the corresponding decision trajectory and gap record includes:
[0019] Based on the decision-making process results, generate the corresponding decision trajectory and gap location markers;
[0020] The gap type is determined based on the current blocking context information, the decision trajectory, and the gap location identifier;
[0021] The reference document range is determined based on the gap type, and a gap record is generated based on the gap type and the reference document range.
[0022] In one embodiment, the method further includes:
[0023] If a new gap record is generated during the process of re-driving the target decision path node by node in turn based on the current blocking context information, then the next round of blocking processing will begin based on the new gap record, until the target decision path is re-drived and each node in the target decision path can make a correct decision.
[0024] In one embodiment, the method further includes:
[0025] The reference answer is evaluated. If the evaluation result indicates that the reference answer is a stable and reusable answer, then the reference answer is written into the skill knowledge base based on the repair constraint.
[0026] The repair constraints include at least one of the following:
[0027] Prioritize repairing the attribution skill files corresponding to the target decision path;
[0028] Repair the associated files of the attributed skill file;
[0029] The reference answer is written into at least one of the attribution skill file and the associated file using an executable expression.
[0030] In one embodiment, the implementation defect type includes at least one of compilation error and logic error, and the decision path defect type includes at least one of rule missing, ambiguity, inconsistency between inner and outer boundaries, cyclic dependency, implicit cross-file dependency, and operation undefined.
[0031] In one embodiment, the executability criterion includes at least one of the following: whether the rule is executable, whether the priority is clear, whether the operating conditions are clear, and whether two independent readers reach the same conclusion.
[0032] Secondly, this application also provides a blocking processing system, including: a blocking classifier, a gap generator, a reference retrieval unit, and a re-decision engine, wherein:
[0033] The blockage classifier is used to determine the blockage type corresponding to the current blockage location when a blockage occurs in a pipeline step.
[0034] The gap generator is used to drive the target decision path corresponding to the current blockage position to execute decisions node by node according to the current blockage context information if the blockage type is a decision path defect type, and generate a gap record. The gap record includes a gap problem description and a reference document range.
[0035] The reference retrieval device is used to retrieve answers based on the gap problem description and the range of reference documents, generate corresponding reference answers, and temporarily repair the target decision path based on the reference answers;
[0036] The re-decision engine is used to, after completing the temporary repair of the target decision path, re-drive the target decision path to execute decisions node by node according to the current blocking context information. If each node in the target decision path can make a correct decision, the pipeline step execution is resumed.
[0037] In one embodiment, determining the blockage type corresponding to the current blockage location when a blockage occurs in a pipeline step includes:
[0038] Receive blocking information reported by the pipeline step executor, the blocking information including error description, blocking location information and current blocking context information;
[0039] Based on the blocking information, the blocking type corresponding to the current blocking position is determined. The blocking type includes implementation defect type or decision path defect type.
[0040] In one embodiment, the gap generator includes a dry-running engine and a gap detector. The step of driving the target decision path corresponding to the current blockage position to execute decisions node by node based on the current blockage context information to generate gap records includes:
[0041] The dry running engine is used to determine the corresponding skill file of the current blocking position based on the blocking position information; drive the target decision path to execute decisions node by node according to the current blocking context information and the corresponding skill file, and evaluate the feasibility standard of each node during the decision execution phase; when any node fails to meet the feasibility standard, terminate the traversal execution of subsequent nodes, and generate the corresponding decision trajectory and gap position identifier according to the decision execution result.
[0042] The gap detector is used to determine the gap type based on the current blocking context information, the decision trajectory, and the gap location identifier; determine the reference document range based on the gap type; and generate a gap record based on the gap type and the reference document range.
[0043] In one embodiment, the re-decision engine is further configured to:
[0044] If a new gap record is generated during the process of re-driving the target decision path node by node in turn based on the current blocking context information, then the next round of blocking processing will begin based on the new gap record, until the target decision path is re-drived and each node in the target decision path can make a correct decision.
[0045] In one embodiment, the system further includes:
[0046] Write back to the engine to evaluate the reference answer. If the evaluation result indicates that the reference answer is a stable and reusable answer, then write the reference answer into the skill knowledge base based on the repair constraint.
[0047] The repair constraints include at least one of the following:
[0048] Prioritize repairing the attribution skill files corresponding to the target decision path;
[0049] Repair the associated files of the attributed skill file;
[0050] The reference answer is written into at least one of the attribution skill file and the associated file using an executable expression.
[0051] In one embodiment, the implementation defect type includes at least one of compilation error and logic error, and the decision path defect type includes at least one of rule missing, ambiguity, inconsistency between inner and outer boundaries, cyclic dependency, implicit cross-file dependency, and operation undefined.
[0052] In one embodiment, the executability criterion includes at least one of the following: whether the rule is executable, whether the priority is clear, whether the operating conditions are clear, and whether two independent readers reach the same conclusion.
[0053] Thirdly, this application also provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement any of the blocking processing methods described above.
[0054] Fourthly, this application also provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements any of the blocking processing methods described above.
[0055] Fifthly, this application also provides a computer program product, including a computer program that, when executed by a processor, implements any of the blocking processing methods described above.
[0056] The blocking handling method, system, computer device, storage medium, and program product provided in this application no longer rely on repeated trial and error or subjective speculation by the agent to handle blocking. Instead, when a blocking of decision path defect type occurs, it drives the target decision path to verify node by node based on the current blocking context information, identifies the real gap, and searches for reference answers in a targeted manner according to the content of the gap and the set reference document range. This avoids erroneous decision logic formed by arbitrary trial and error and subjective speculation from the root, prevents the problem of abnormal paths being used continuously, and can eliminate redundant and invalid information brought about by boundless global search. By reducing the introduction of irrelevant data, it avoids redundant information interfering with decision judgment, thereby improving the accuracy of decision-making. In other words, this application provides an efficient and accurate handling method for decision path type blocking. It can complete the blocking handling based on an automated process of autonomously locating gaps, targetedly searching for information, temporarily repairing, and retesting and verifying. It can effectively shorten the blocking handling time, enabling the pipeline to autonomously continue running after the blocking is repaired, effectively improving the blocking handling efficiency and blocking repair accuracy during agent execution. Attached Figure Description
[0057] To more clearly illustrate the technical solutions in the embodiments of this application or related technologies, the drawings used in the description of the embodiments of this application or related technologies will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0058] Figure 1 This is a flowchart illustrating a blocking handling method in one embodiment;
[0059] Figure 2 This is a schematic diagram of the heterogeneous hardware platform in one embodiment;
[0060] Figure 3 This is a schematic diagram of the structure of an artificial intelligence chip in one embodiment;
[0061] Figure 4 This is a flowchart illustrating the steps for determining the blocking type in one embodiment;
[0062] Figure 5 This is a flowchart illustrating the gap record generation steps in one embodiment;
[0063] Figure 6 This is a flowchart illustrating the steps for generating decision trajectories and gap records in one embodiment;
[0064] Figure 7 This is a block diagram of a blocking handling system in one embodiment;
[0065] Figure 8 This is a hierarchical diagram of a blocking handling system in one embodiment;
[0066] Figure 9 Here is a hierarchy diagram of the blocking handling system in another embodiment;
[0067] Figure 10 This is a schematic diagram of the decision path repair process in one embodiment;
[0068] Figure 11 This is a schematic diagram of the write-back engine patching process in one embodiment;
[0069] Figure 12 This is a schematic diagram of the patching process of the heavy decision engine in one embodiment;
[0070] Figure 13 This is a schematic diagram of the entire process of the blocking handling method in one embodiment;
[0071] Figure 14 This is an internal structural diagram of a computer device in one embodiment. Detailed Implementation
[0072] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.
[0073] It should be noted that the terms "first," "second," etc., used in this application can be used to describe various elements, but these elements are not limited by these terms. These terms are only used to distinguish the first element from the second element. The terms "comprising" and "having," and any variations thereof, used in this application, are intended to cover non-exclusive inclusion. The term "multiple" used in this application refers to two or more. The term "and / or" used in this application refers to one of the embodiments, or any combination of multiple embodiments.
[0074] Current mainstream AI agent frameworks primarily employ a modular approach, incorporating skills, tools, and plugins to organize and encapsulate domain-specific knowledge. Each skill file corresponds to a specific business domain, clearly defining the agent's decision-making rules, execution processes, and reference criteria. When faced with complex, multi-step tasks, the system uses a pipeline orchestrator to systematically invoke various skill modules, completing automated tasks according to a predetermined process. This is currently the mainstream architecture for AI agents to achieve autonomous task execution.
[0075] When an AI agent encounters abnormal blocking situations during task execution, such as ambiguous decision paths, missing rules, or unclear API (Application Programming Interface) semantic definitions, existing systems generally adopt four common handling strategies. The first is trial-and-error coding, where the agent autonomously tries multiple implementation schemes and determines their feasibility based on compilation and execution results. The second is global retrieval, which expands the scope of file searches, traversing a large number of irrelevant documents to identify valid clues. The third is skipping continuation, where, based on autonomous judgment and inference, questionable nodes are skipped and the task continues. The fourth is manual intervention, which directly pauses the current task and waits for staff to handle the abnormal issues.
[0076] Furthermore, the maintenance of the AI Agent's knowledge base and skill files is currently primarily conducted offline via manual operations. Staff need to periodically check the completeness and standardization of the skill files, and system defects are mainly discovered passively through user feedback. Additionally, after the knowledge base or skill files are corrected and optimized, the AI agent needs to be redeployed or restarted for the updated content to take effect, making real-time iterative updates impossible.
[0077] In other words, the existing AI Agent automated execution and knowledge base operation and maintenance system has the following obvious defects:
[0078] 1. Inability to distinguish the root cause of the failure. The existing system uniformly categorizes all task blocking issues as implementation layer defects and defaults to resolving the problem by adjusting the code logic. If the root cause of the blockage is that the skill file decision path itself has problems such as missing rules, semantic ambiguity, or circular dependencies, code adjustments can only temporarily avoid the current failure. The underlying decision-making defects are not fixed, and subsequent similar tasks will still experience the same blocking problem.
[0079] Second, unbounded retrieval leads to information redundancy. When faced with decision-making uncertainty, intelligent agents typically expand their search scope autonomously. Unconstrained retrieval patterns absorb a large amount of irrelevant information, not only consuming system context resources and reducing decision accuracy, but also potentially generating erroneous analogical derivations, interfering with normal task execution.
[0080] Third, fault gaps cannot be accurately traced. The existing system can only identify task blocking status, but cannot structurally distinguish fault types, and cannot accurately determine whether the problem originates from missing rules, rule conflicts, ambiguous priority definitions, or circular dependencies. Due to the lack of a standardized gap recording mechanism, fault repair lacks a clear direction, and subsequent problem review and operation and maintenance audit work is difficult to carry out.
[0081] Fourth, effective solutions cannot be accumulated and iterated. Even if an agent successfully solves the problem of single-task blocking through various means, the corresponding effective solution rules are only retained in temporary scenarios such as the current task dialogue and code comments, and cannot be synchronously updated to the decision path of the skill file, resulting in the knowledge base not being able to continuously iterate and optimize with the execution of tasks.
[0082] Fifth, the repair results lack a verification mechanism. After obtaining the reference solution, the existing system directly proceeds with subsequent tasks based on the repair content, without re-executing the decision verification process in the updated decision path. This makes it impossible to check whether the repair operation introduces new logical conflicts or business anomalies, and the stability of task execution cannot be guaranteed.
[0083] To address the aforementioned technical issues, this application provides an efficient and accurate blocking handling method for decision path blocking. It can complete blocking handling based on an automated process of autonomously locating gaps, directional data retrieval, temporary repair, and retesting. This can effectively shorten the blocking handling time, enabling the pipeline to autonomously resume operation after blocking is repaired, and effectively improve the blocking handling efficiency and blocking repair accuracy during Agent execution.
[0084] like Figure 1 As shown, a blocking handling method is provided, applicable to heterogeneous hardware platforms equipped with CPUs (Central Processing Units) and artificial intelligence chips, as described above. Figure 2 As shown. In this embodiment of the application, the artificial intelligence chip can be any one of GPU (Graphics Processing Unit), TPU (Tensor Processing Unit), NPU (Neural Network Processing Unit), DPU (Deep Learning Processing Unit), APU (Accelerated Processing Unit), and GPGPU (General-Purpose Graphics Processing Unit). This embodiment of the application does not make specific limitations on this one, and the following description uses GPGPU as an example.
[0085] Reference Figure 3 The diagram shows a schematic of a GPGPU. A GPGPU is actually an array of Streaming Processor Clusters (SPCs), including, for example,... Figure 3The diagram shows streaming processor clusters 1, ..., M, where M is a positive integer greater than 1. In a graphics processing unit (GPU), one streaming processor cluster processes one computational task, or multiple streaming processor clusters process one computational task. Multiple streaming processor clusters share data through a global cache or global memory.
[0086] like Figure 3 As shown, taking streaming processor cluster 1 as an example, one streaming processor cluster includes multiple computing units, such as... Figure 3 The system is structured as Computation Unit 1, Computation Unit 2, ..., Computation Unit N, where N is a positive integer. Each Computation Unit (CU) performs arithmetic and logical operations other than matrix calculations such as matrix multiplication and convolution, including operations like accumulation, reduction, and standard addition, subtraction, multiplication, and division. A Computation Unit contains multiple cores (also called computational kernels), each including an Arithmetic Logic Unit (ALU), a floating-point unit, etc., which are used to execute specific computational tasks. Furthermore, the Computation Unit also includes registers (e.g., ...). Figure 3 The register file and shared cache in a computing unit are used to store source and destination data related to computing tasks in a hierarchical manner. The shared cache in a computing unit is used to share data between the cores of that computing unit.
[0087] In parallel computing, computational tasks are typically executed by multiple threads. These threads are divided into multiple thread blocks before execution in a general-purpose graphics processor (or parallel computing processor), and then dispatched via a thread block distribution module. Figure 3 (Not shown in the image) Multiple thread blocks are distributed to various computation units. All threads in a thread block must be assigned to the same computation unit for execution. Simultaneously, thread blocks are broken down into minimum execution thread bundles (or simply warps), each containing a fixed number (or less than this fixed number) of threads, for example, 32 threads. Multiple thread blocks can execute in the same computation unit or in different computation units.
[0088] In each computing unit, the thread beam scheduling / distribution module ( Figure 3 (Not shown in the diagram) Thread bundles are scheduled and allocated so that multiple computing cores within the computing unit can run thread bundles. Depending on the number of computing cores in the computing unit, multiple thread bundles within a thread block can be executed concurrently or in a time-sharing manner. Multiple threads within each thread bundle execute the same instructions. Memory execution instructions are issued to the shared cache within the computing unit or further issued to intermediate-level caches, global caches, or global memory for read and write operations, etc.
[0089] like Figure 3As shown, the streaming processor cluster 1 also includes a tensor operation unit, which is used to perform tensor calculations, such as matrix multiplication, convolution operations, etc.
[0090] In one exemplary embodiment, such as Figure 1 As shown, a blocking handling method is provided, including the following steps 102, 104, 106, and 108, wherein:
[0091] Step 102: When a blockage occurs in a pipeline step, determine the blockage type corresponding to the current blockage location.
[0092] In this embodiment, pipeline step blockage refers to a state where the AI Agent, while executing a multi-step task according to a preset process, suspends the task due to an execution anomaly. For example, the blockage information sent by the step executor when a blockage occurs can be used to determine if the current pipeline step is blocked, and the blockage type corresponding to the current blockage location can be determined based on the blockage information sent by the step executor.
[0093] For example, in this application embodiment, the blocking types are divided into two categories: implementation defect types and decision path defect types. Implementation defects mainly refer to engineering implementation-level problems such as code execution exceptions, interface call failures, and abnormal runtime environments; decision path defects specifically refer to decision logic-level problems such as missing rules within skill files, semantic ambiguity, logical conflicts, and circular dependencies.
[0094] Step 104: If the blocking type is a decision path defect type, drive the target decision path corresponding to the current blocking position to execute decisions node by node according to the current blocking context information, and generate a gap record. The gap record includes a gap problem description and a reference document range.
[0095] In this embodiment, when it is determined that the current blockage type belongs to the decision path defect type, the attribution skill file corresponding to the current blockage location can be located, and the target decision path can be obtained from the attribution skill file. The target decision path consists of multiple ordered decision nodes in the attribution skill file, representing the conventional execution logic for the AI Agent to complete the corresponding scenario task. The AI Agent can sequentially traverse each node and make routing / selection / execution decisions based on input parameters.
[0096] After determining the target decision path, the system can drive the decision-making action node by node based on the current blocking context information. During the operation of each node, node verification is performed according to preset executability standards. Once a node is found to be unable to meet the executability standards, the system stops the decision traversal of subsequent nodes, retains the complete decision trajectory, and generates a structured gap record.
[0097] For example, a gap record can contain two types of information: a gap problem description and a range of reference documents. The gap problem description records the specific gap problem existing at the current node, including the gap location, gap type, and gap description. The range of reference documents can be determined in conjunction with the gap type to constrain the boundaries of subsequent data searches and avoid large-scale, aimless searches.
[0098] It should be noted that the embodiments disclosed herein do not specifically limit the specific field format of the gap record or the rules for defining the scope of the reference document. Those skilled in the art can flexibly configure it according to the architecture of the skill knowledge base and the task scenario.
[0099] Step 106: Based on the gap problem description and the scope of reference documents, retrieve the answer, generate the corresponding reference answer, and temporarily repair the target decision path based on the reference answer.
[0100] In this embodiment, the system can analyze the problem by combining the gap description with targeted searches within a defined scope of reference documents to select relevant answers that can solve the current gap problem. In this way, the search process has clear boundary constraints, ensuring that only reference content matching the current scenario is selected, without introducing irrelevant redundant data.
[0101] For example, after retrieving the reference answer, the system will not modify the original skill file stored on the disk, but will only temporarily repair the target decision path runtime copy already loaded in memory. During the repair process, the corresponding logic between the belonging skill file and its associated skill files can be adjusted synchronously to ensure that the repaired decision path logic is smooth and the content is consistent. That is, this temporary repair only takes effect in the current task execution process and will not make any changes to the original files in the skill knowledge base.
[0102] For example, the system can generate executability rule statements based on the reference answer, locate abnormal decision nodes in the memory copy that do not meet the executability criteria (the specific executability criteria will be introduced later and will not be repeated here), replace, supplement or correct the original rule content in the abnormal decision node that is missing, ambiguous, has disordered priority, or has inconsistent boundaries; at the same time, it can also correct the calling relationship, dependency logic and upstream and downstream flow conditions between nodes in the memory copy, thereby eliminating problems such as logical conflicts and dependency mismatches between nodes.
[0103] After completing the above modifications, the system reuses the current blocking context to verify the nodes of the modified memory decision copy. If the abnormal decision nodes meet the executability criteria, there are no errors in the upstream and downstream linkages of the path, and the parent-child boundary logic is consistent, the temporary repair can be determined to be complete. A repaired memory decision copy that can directly participate in the retest can be generated for subsequent path retesting by the re-decision engine. This modification only resides in the process memory of this pipeline task and only serves the subsequent blocking retesting process in this round. It will not change the original skill file content on the disk. Once this round of tasks is terminated and the process is released, the patched node rules and linkage logic in memory will be completely destroyed and restored, that is, the disk knowledge base will always maintain its original state.
[0104] Step 108: After the temporary repair of the target decision path is completed, the target decision path is re-driven to execute decisions node by node according to the current blocking context information. If each node in the target decision path can make a correct decision, the pipeline step execution is resumed.
[0105] In this embodiment, after the temporary memory patching of the target decision path is completed, the system can use the original context information at the time of the blockage (i.e., the current blocking context information) to re-drive the target decision path to execute decisions node by node, thereby verifying the feasibility of the temporary repair scheme, i.e., performing a retest. During the retest phase, the decision logic of all nodes in the decision path will be checked one by one to confirm whether the repair operation will generate new logical conflicts or operational anomalies.
[0106] If all nodes can complete decisions normally and accurately during the retesting phase, it indicates that the temporary repair solution is effective, the current blocking issue has been resolved, and the system can resume subsequent steps of the pipeline to continue the overall task execution. If decision anomalies still exist after retesting, the system will discard the results of this temporary repair and start the next round of repair operations or call the system's original fallback mechanism to handle the blocking issue.
[0107] The blocking handling method provided in this application no longer relies on repeated trial and error or subjective speculation by the agent to handle blocking. Instead, when a blocking of decision path defect type occurs, it drives the target decision path to verify node by node based on the current blocking context information, identifies the real gap, and searches for reference answers in a targeted manner according to the content of the gap and the set reference document range. This avoids erroneous decision logic formed by arbitrary trial and error and subjective speculation from the root, prevents the problem of abnormal paths being used continuously, and can eliminate redundant and invalid information brought about by boundless global search. By reducing the introduction of irrelevant data, it avoids redundant information interfering with decision judgment, thereby improving the accuracy of decision-making. In other words, this application provides an efficient and accurate handling method for decision path type blocking. It can complete the blocking handling based on an automated process of autonomously locating gaps, targetedly searching for information, temporarily repairing and retesting verification. This can effectively shorten the blocking handling time, allowing the pipeline to autonomously resume operation after the blocking is repaired, effectively improving the blocking handling efficiency and blocking repair accuracy during agent execution.
[0108] In one exemplary embodiment, reference is made to Figure 4 As shown, in step 102, when a blockage occurs in a pipeline step, the blockage type corresponding to the current blockage location is determined, which may include steps 402 and 404, wherein:
[0109] Step 402: Receive blocking information reported by the pipeline step executor. The blocking information includes error description, blocking location information, and current blocking context information.
[0110] Step 404: Based on the blocking information, determine the blocking type corresponding to the current blocking location. The blocking type includes implementation defect type or decision path defect type.
[0111] In this embodiment, if a blockage occurs during the operation of the AI Agent pipeline, the step executor will immediately capture the abnormal state of the current task and report the corresponding blockage information. The blockage information is information that can reconstruct the execution environment at the time of the blockage, and may include an error description, blockage location information, and current blockage context information. The error description may include the current task state, the blockage problem, etc. The blockage location information may include the pipeline step identifier and the corresponding belonging skill file path information. The current blockage context information includes the context data of the task runtime.
[0112] The system can classify the causes of current blockages based on blockage information, dividing all pipeline blockage problems into two main categories: implementation defect types and decision path defect types.
[0113] For example, implementation defect types mainly refer to abnormal problems at the program execution level, which may include at least one of compilation errors and logical errors. These problems mostly originate from engineering exceptions in code execution and program operation, and are unrelated to the decision rules within the skill file.
[0114] Decision path defects primarily refer to anomalies at the decision rule level of the skill file, specifically including at least one of the following: missing rules, ambiguity, inconsistency between internal and external boundaries, cyclic dependencies, implicit cross-file dependencies, and undefined operations. Specifically, missing rules mean that a decision node has no rule covering the current input, manifested as no matching entry in the routing table; ambiguity means that multiple rules match simultaneously without priority, manifested as two routing rules being satisfied simultaneously; cyclic dependencies mean that rule A references rule B, and rule B in turn references rule A, manifested as two skill files pointing to each other; implicit cross-file dependencies mean that a rule depends on the content of another file but is not declared, manifested as "see xxx" but "xxx" does not exist or has been changed; inconsistency between internal and external boundaries means that public routing labels contradict internal implementation rules, manifested as inconsistency between parent route instructions and child skill defaults; undefined operations include undefined upgrades and undefined stops, meaning there are no rules on when to stop or upgrade to humans, manifested as no handling strategy after failure.
[0115] In other words, after receiving blocking information reported by the step executor, the system can analyze this information. If the blocking information reflects an anomaly at the program execution level, exhibiting characteristics such as compilation errors or code logic execution errors, it can be identified as an implementation defect. Alternatively, if the blocking information does not reflect program execution errors but exposes problems with the decision rules themselves, such as missing rules, semantic ambiguity, inconsistencies between internal and external boundaries, cyclic dependencies, implicit cross-file dependencies, or undefined operations, it can be identified as a decision path defect. When the blocking type is determined to be a decision path defect, decision path repair can be triggered.
[0116] In one exemplary embodiment, reference is made to Figure 5 As shown, in step 104, the target decision path corresponding to the current blocking position is driven to perform decisions node by node according to the current blocking context information to generate a gap record. This may include steps 502, 504, and 506, wherein:
[0117] Step 502: Determine the skill file corresponding to the current blocking location based on the blocking location information;
[0118] Step 504: Based on the current blocking context information and the attribution skill file, drive the target decision path to execute decisions node by node in sequence, and evaluate the feasibility of each node during the decision execution phase.
[0119] Step 506: When any node fails to meet the executability criteria, terminate the traversal execution of subsequent nodes and generate the corresponding decision trajectory and gap record.
[0120] In this embodiment, the blockage location information may include the step ID of the currently blocked pipeline step and the corresponding attributable skill file path. The step ID uniquely identifies each execution step in the pipeline, used to pinpoint the specific point of blockage; the attributable skill file path directly points to the attributable skill file upon which the current execution step depends. Based on this blockage location information, the system can directly obtain the attributable skill file corresponding to the current blockage location without requiring extensive traversal and matching.
[0121] After locking onto the assigned skill file, the system can, based on the current blocking context information and the complete decision logic preset within that skill file, invoke the target decision path corresponding to the current blocking location. The target decision path consists of multiple ordered decision nodes, and the system triggers the decision-making process of each node one by one according to a predetermined logical order.
[0122] During the operation of each node, the system synchronously evaluates the node against preset executability standards. Executability standards are set according to the business rules in the associated skill document and are used to determine whether the rule information of the current node is complete, the logical relationship is clear, and the operating conditions are met, thereby distinguishing whether the node can normally complete the decision output.
[0123] In one exemplary embodiment, the executability criteria include at least one of the following: whether the rule is executable, whether the priority is explicit, whether the operating conditions are explicit, and whether two independent readers reach the same conclusion.
[0124] In this embodiment, the executableness of a rule is used to verify whether the rule logic configured in the current decision node is complete and closed-loop, without missing content or blank definitions, and capable of completing the corresponding decision action based on existing rules. The explicit priority is used to verify whether the execution priority of each rule is clearly defined when multiple related rules coexist, preventing rule conflicts and disordered execution order. The explicit operation conditions are used to determine whether the triggering conditions and execution constraints corresponding to the node rule are complete and clear, without ambiguous boundaries or undefined scenarios, and capable of adapting to the current pipeline's runtime context for normal triggering. Whether two independent readers reach the same conclusion is verified from the perspective of rule readability and logical determinism, meaning that different subjects, when reading the same node rule content, can obtain consistent decision understanding and execution results, without semantic ambiguity or multiple interpretations.
[0125] In this embodiment, during the node-by-node evaluation of the target decision path, if a node is detected as not meeting the executability criteria, it indicates a decision logic flaw in the current node, which is also the root cause of the pipeline blockage. At this point, the system will not continue executing the decision traversal process of subsequent nodes to avoid generating more invalid execution trajectories and redundant judgments. Simultaneously, the system can retain the complete decision trajectory, recording the entire execution process from path initiation to the abnormal node. Furthermore, it can generate corresponding gap records based on the node's abnormality. These gap records can be used to record the specific problems existing in the current decision node and to limit the scope of reference document retrieval.
[0126] In one exemplary embodiment, reference is made to Figure 6 As shown, step 506, generating the corresponding decision trajectory and gap record, may include steps 602, 604, and 606, wherein:
[0127] Step 602: Based on the decision-making results, generate the corresponding decision trajectory and gap location markers;
[0128] Step 604: Determine the gap type based on the current blocking context information, decision trajectory, and gap location identifier;
[0129] Step 606: Determine the reference document range based on the gap type, and generate gap records based on the gap type and the reference document range.
[0130] In this embodiment, the system continuously records the running status, execution results, and flow of each decision node during the execution of the target decision path node by node. When a node is detected as not meeting the executability criteria and the process terminates, the system can integrate the entire running data to generate a complete decision trajectory. The decision trajectory records the entire flow process from the start of execution to abnormal termination, and can describe the execution status of each normal node and the interruption status of abnormal nodes. Simultaneously, for abnormal nodes that fail verification, the system can generate corresponding gap location identifiers, which can be used to mark the specific node location of the decision defect.
[0131] Since single location information is insufficient to fully define the specific problem of a decision-making defect, the system in this embodiment can comprehensively determine the gap type by combining multi-dimensional information. For example, the gap type can be determined based on the current blocking context information, the decision trajectory, and the gap location identifier. The current blocking context information records the environmental parameters, input conditions, and execution constraints during task execution; the decision trajectory reflects the overall path's flow characteristics; and the gap location identifier identifies the problem node. Analysis based on these three types of information can determine the specific reason for the node's execution failure and obtain the specific type of the current gap, such as missing rules, semantic ambiguity, inconsistent inner and outer boundaries, cyclic dependencies, implicit cross-file dependencies, or undefined operations.
[0132] Different types of gaps correspond to different document categories for compliance requirements and standards. The system can further match the identified gap type with the corresponding knowledge base document category, thus defining the scope of reference document retrieval and avoiding interference from invalid information caused by indiscriminate full-domain searches. After determining the gap type and the scope of reference documents, the system can integrate the gap type and the scope of reference documents to generate a structured gap record.
[0133] In one exemplary embodiment, the above method may further include:
[0134] If a new gap record is generated during the process of re-driving the target decision path node by node according to the current blocking context information, the next round of blocking processing will be carried out based on the new gap record until the target decision path is re-drived and each node in the target decision path can make a correct decision.
[0135] In this embodiment, temporary repair operations may not be able to completely resolve multi-level decision-making defects in complex scenarios. In some blocking scenarios, after the original gap is repaired, new rule defects that were not previously apparent may be exposed during the continued execution of the path. The system will generate a completely new gap record according to the aforementioned node verification logic. When a new gap record is generated during the retesting process, the system will not directly terminate the repair process, but will restart the entire blocking process based on the latest generated gap record. The operations of gap type determination, reference document range delineation, answer retrieval, and temporary repair of the decision path are completed again in sequence, and the full path decision retesting is carried out again.
[0136] This iterative process continues, with each round addressing and retesting the newly exposed gaps until all nodes of the complete target decision path can execute decisions smoothly and accurately. At this point, it is determined that the current path has no decision-making defects, the blocking problem is completely resolved, and the system can resume the subsequent execution steps of the pipeline normally.
[0137] In one exemplary embodiment, the method may further include:
[0138] The reference answer is evaluated. If the evaluation result indicates that the reference answer is a stable and reusable answer, then the reference answer is written into the skill knowledge base based on the repair constraint.
[0139] Repair constraints include at least one of the following:
[0140] Prioritize repairing the skill files corresponding to the target decision-making path;
[0141] Repair the associated files of the skill attribute file;
[0142] Use an executable expression to write the reference answer into at least one of the attribution skill file and the associated file.
[0143] In this embodiment, the temporary repair only applies to the decision path copy in memory, ensuring only the normal operation of the current single task. To achieve autonomous iterative updates of the skill knowledge base, the system can, after retesting and verifying the effectiveness of the repair, conduct attribute evaluation on the retrieved reference answers to determine whether the answer has general adaptability and whether it belongs to a stable rule that can be reused in the long term.
[0144] If the evaluation confirms that the reference answer is only suitable for the specific scenario of this task and belongs to a case-specific solution, the system will not perform any persistent write operations, but will only rely on a temporary memory patch to complete this round of pipeline execution. The repair effect will automatically expire after the task ends. If the evaluation results show that the reference answer is a stable and reusable answer that can adapt to the general decision-making needs of similar scenarios, the system can then write the answer into the skill knowledge base according to the preset repair constraints, completing the permanent update of the decision-making rules.
[0145] In this embodiment, the write-in repair constraints include multiple execution rules. Among them, prioritizing the repair of the attribution skill file corresponding to the target decision path means that the system prioritizes updating the main skill file to which the defective node belongs, fundamentally filling in missing rules and correcting erroneous logic in the decision path to ensure the integrity and fluency of the main path's decision logic. Repairing related files of the attribution skill file means that while updating the main skill file, the system simultaneously adjusts the subsidiary files that have logical or dependent relationships with the main file, ensuring that the rule logic of the attribution file and related files matches each other, avoiding inconsistencies in file logic and data asynchrony. Using executable expressions to write files means that during the write-in process, the system does not directly use the original text content retrieved, but instead transforms the reference answer into rule statements that conform to the skill file specifications and can be directly recognized and executed by the system, ensuring that the updated rules can take effect normally in subsequent task execution.
[0146] By writing the reference answer into the skill knowledge base based on the repair constraints, the same blocking problem can be avoided in the future, and the repair of this decision path can be completely realized.
[0147] It should be understood that although the steps in the flowcharts of the embodiments described above are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the embodiments described above may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages in other steps. It is understood that the steps in different embodiments can be freely combined as needed, and all non-contradictory solutions formed by such combinations are within the scope of protection of this application.
[0148] Based on the same inventive concept, this application also provides a blocking processing system for implementing the blocking processing method described above. The solution provided by this system is similar to the implementation scheme described in the above method; therefore, the specific limitations in one or more blocking processing system embodiments provided below can be found in the limitations of the blocking processing method above, and will not be repeated here.
[0149] In one exemplary embodiment, such as Figure 7 As shown, a blocking processing system is provided, including: a blocking classifier 702, a gap generator 704, a reference retrieval unit 706, and a re-decision engine 708, wherein:
[0150] The blockage classifier 702 is used to determine the blockage type corresponding to the current blockage position when a blockage occurs in a pipeline step.
[0151] Gap generator 704 is used to drive the target decision path corresponding to the current blockage position to execute decisions node by node according to the current blockage context information if the blockage type is a decision path defect type, and generate gap records. The gap records include gap problem descriptions and reference document ranges.
[0152] Reference retrieval unit 706 is used to retrieve answers based on the gap problem description and the scope of reference documents, generate corresponding reference answers, and temporarily repair the target decision path based on the reference answers;
[0153] The re-decision engine 708 is used to re-drive the target decision path node by node to make decisions after the target decision path has been temporarily repaired, based on the current blocking context information. If each node in the target decision path can make a correct decision, the pipeline step execution is resumed.
[0154] The blocking handling system provided in this application no longer relies on repeated trial and error or subjective speculation by the agent to handle blocking. Instead, when a blocking of decision path defect type occurs, it drives the target decision path to verify node by node based on the current blocking context information, identifies the real gap, and searches for reference answers in a targeted manner according to the content of the gap and the set reference document range. This avoids erroneous decision logic formed by arbitrary trial and error and subjective speculation from the root, prevents the problem of abnormal paths being used continuously, and can eliminate redundant and invalid information brought about by boundless global search. By reducing the introduction of irrelevant data, it avoids redundant information interfering with decision judgment, thereby improving the accuracy of decision-making. In other words, this application provides an efficient and accurate handling method for decision path type blocking. It can complete the blocking handling based on an automated process of autonomously locating gaps, targetedly searching for information, temporarily repairing and retesting verification. This can effectively shorten the blocking handling time, allowing the pipeline to autonomously resume operation after the blocking is repaired, effectively improving the blocking handling efficiency and blocking repair accuracy during agent execution.
[0155] In one embodiment, when a blockage occurs in a pipeline step, determining the blockage type corresponding to the current blockage location includes:
[0156] Receive blocking information reported by the pipeline step executor. The blocking information includes error description, blocking location information and current blocking context information.
[0157] Based on the blocking information, determine the blocking type corresponding to the current blocking location. The blocking type includes implementation defect type or decision path defect type.
[0158] In one embodiment, the gap generator includes a run-through engine and a gap detector. Based on the current blocking context information, it drives the target decision path corresponding to the current blocking position to execute decisions node by node, generating gap records, including:
[0159] The dry running engine is used to determine the corresponding skill file for the current blocking position based on the blocking position information; based on the current blocking context information and the corresponding skill file, it drives the target decision path to execute decisions node by node in sequence, and evaluates the feasibility criteria of each node during the decision execution phase; when any node fails to meet the feasibility criteria, it terminates the traversal execution of subsequent nodes, and generates the corresponding decision trajectory and gap position identifier based on the decision execution results.
[0160] The gap detector is used to determine the gap type based on the current blocking context information, decision trajectory, and gap location identifier; determine the reference document range based on the gap type; and generate gap records based on the gap type and reference document range.
[0161] In one embodiment, the re-decision engine is also used for:
[0162] If a new gap record is generated during the process of re-driving the target decision path node by node according to the current blocking context information, the next round of blocking processing will be carried out based on the new gap record until the target decision path is re-drived and each node in the target decision path can make a correct decision.
[0163] In one embodiment, the system further includes:
[0164] Write back to the engine to evaluate the reference answer. If the evaluation result indicates that the reference answer is a stable and reusable answer, then write the reference answer into the skill knowledge base based on the repair constraint.
[0165] Repair constraints include at least one of the following:
[0166] Prioritize repairing the skill files corresponding to the target decision-making path;
[0167] Repair the associated files of the skill attribute file;
[0168] Use an executable expression to write the reference answer into at least one of the attribution skill file and the associated file.
[0169] In one embodiment, the implementation defect type includes at least one of compilation error and logic error, and the decision path defect type includes at least one of rule missing, ambiguity, inconsistency between inner and outer boundaries, cyclic dependency, implicit cross-file dependency, and operation undefined.
[0170] In one embodiment, the executability criteria include at least one of the following: whether the rule is executable, whether the priority is clear, whether the operating conditions are clear, and whether two independent readers reach the same conclusion.
[0171] This application provides a method and system for systematically detecting gap types, locating gap positions, retrieving answers within bounded reference ranges, repairing attribution decision paths, and forcibly re-verifying decisions before resuming the main task when the AI Agent is blocked due to issues such as missing, contradictory, or ambiguous decision paths in its internal knowledge base (skill files) during the execution of a multi-stage automated pipeline of an AI Agent.
[0172] The methods and systems provided in this application are applicable to complex automated task pipelines driven by AI Agents, particularly end-to-end automated development and optimization pipelines for AI chip operators / cores. Multiple sub-skills each possess independent decision paths and reference knowledge, and the AI Agent must follow these paths to make decisions such as routing, pattern selection, and API selection during execution. When these decision paths themselves have defects, the traditional approach is for the AI Agent to bypass the blockage through trial-and-error coding. This leads to the solidification of erroneous implementation paths, the long-term existence of knowledge base defects, and the recurrence of similar problems. The methods and systems provided in this application enable the AI Agent to autonomously complete the closed loop of decision path detection, repair, and verification during runtime.
[0173] The principles and system architecture of the embodiments of this application will be described below:
[0174] In this embodiment, the blockage recovery in the AI Agent execution pipeline is upgraded from a bypass-based trial-and-error approach to a structured repair closed loop. This may include the following repair stages:
[0175] Phase 1: Blockage classification precedes blockage handling. When a pipeline step is blocked, the blockage type is first determined: if it is a simple implementation defect (compilation error, logic bug), the code is directly repaired; if it is a decision path defect (missing rules, ambiguity, contradiction, etc.), a structured repair process for subsequent decision paths is triggered. That is, in this embodiment, the processing paths for the two types of blockages are completely separated.
[0176] Phase Two: Main Process Priority Principle. In this embodiment of the application, the repair process must first complete the decision path (main process) of the skill document to which the current step belongs. Before a real gap appears in the decision path itself, the search scope is not expanded and external references are not consulted, so as to ensure the accuracy of gap location.
[0177] Phase Three: Bounded Retrieval Principle. In this embodiment, after the gap is confirmed, the answer is retrieved only within the pre-defined reference boundary. Each reference must correspond one-to-one with a gap record, and reference roaming is prohibited.
[0178] Phase Four: Process Repair Prioritizes Task Continuation. In this embodiment, after finding the reference answer, the attribution decision path is forcibly repaired first, followed by the consistency of associated files. Then, the same specific input is used to re-determine the path after repair. The main task execution is only resumed after the re-decision is passed.
[0179] Phase 5: Reusable rules are floated up. In this embodiment, if the reference answer is a stable, reusable rule (rather than a one-off case answer), it must be written back into the decision path of the skill knowledge base so that subsequent similar tasks will not encounter the same blockage.
[0180] Based on the above repair phases, referring to Figure 8 and Figure 9 As shown, the blocking processing system provided in this application embodiment may include the following five layers, wherein:
[0181] Pipeline orchestration layer: The pipeline controller is responsible for the overall orchestration of multi-step tasks and schedules the executors of each step in sequence.
[0182] Step execution layer: Each step has its own executor and associated skill file. The associated skill file defines the decision rules, routing logic, and references for that step.
[0183] Blocking Classification Layer: When the step executor reports a blockage, the blocking classifier determines the blocking type. If the blocking type is an implementation defect, the path is directly modified. If the blocking type is a decision path defect, the decision path repairer is triggered.
[0184] The decision path repair engine comprises a gap generator (consisting of a dry-running engine (executing the decision path node by node), a gap detector (identifying gap types), and a structured gap record storage), a reference retrieval engine (querying only within a specified range), a write-back engine (repairing attribution and related files), and a re-decision engine (re-running on the repaired path using the same input). Dry-running refers to a simulated execution process that executes the decision path node by node with specific input but does not actually produce code or modify files. It is used to evaluate the executability of rules at each node, stopping and generating records when a gap is found. A decision path is a series of ordered decision nodes defined in a skill file. The AI Agent sequentially traverses each node, making routing / selection / execution decisions based on input parameters. The decision path is the target object for repair. When a node in the decision path has missing or contradictory rules that cause the AI Agent to block, the subsequent decision path repair process is triggered. An attribution file is the master skill file that owns a decision rule. A rule may be referenced or summarized by multiple files, but only one attribution file is responsible for its authoritative definition. The repair answer must first be written to the attribution file and then propagated to related files to ensure a single source of truth.
[0185] Knowledge base layer: contains the attribution skill file (the main file of the decision path), related skill files (other files that reference or restate the rule), and designated reference documents (external authoritative materials with predefined boundaries).
[0186] The blocking classifier's functions include: determining the root cause type of pipeline step blocking and routing it to the correct processing path. It receives blocking information reported by the step executor (including error description, blocking location, and current blocking context information), and based on this information, determines whether the blocking belongs to a decision path defect (one of six categories: missing rules, ambiguity, contradiction, cyclic dependency, unclear boundaries, and undefined upgrades). If it's an implementation defect (compile error, logic bug, API call error), it routes to the direct code repair process; if it's a decision path defect, it routes to the decision path repair engine, carrying the context information. In other words, the blocking classifier's input is the blocking event, including the step ID, the associated skill path, the current blocking context information, and the error description; the output is the classification result, which takes the value of either an implementation defect or a decision path defect.
[0187] The dry-running engine's functions include: traversing the decision path of the attribution skill file node by node using the current blocking context information, and verifying the executability of the rules at each node. It can parse the decision path structure of the attribution skill file (sequential steps, conditional branches, priority lists, etc.), driven by the specific input that triggers the blocking (such as the specification parameters of a certain operator), and execute the decision node by node. At each node, it evaluates four executability criteria: whether the rule is executable, whether the priority is clear, whether the stopping condition is clear, and whether two independent readers will reach the same conclusion. It stops at the first node that does not meet the executability criteria, generating a gap record. In other words, the dry-running engine's inputs are: the attribution skill file path and the current blocking context information; its outputs are: the decision trajectory and the gap record.
[0188] The gap detector's functions include classifying blockages detected by the engine into specific gap types. It can categorize blockages into one of six gap types, determine the range of reference documents required to address the gap, and generate a structured gap record. The reference document range is a pre-defined set of reference documents allowed during the repair process; documents outside this range cannot be retrieved. The gap type classification can be performed as described in the aforementioned embodiments, and is not specifically limited in this application.
[0189] The reference retriever's functions include retrieving the minimum necessary information for a specific gap record within a predefined reference boundary. It receives gap records, reads their reference document range field to determine the search boundary, reads only the minimum relevant fragments within the boundary, and ensures that each reference corresponds one-to-one with a gap record, prohibiting reference roaming—that is, it does not chain-read documents simply because one reference document mentions another. The reference retriever's input is the gap record, and its output is a summary of the reference answer, linked to the specific gap record.
[0190] The write-back engine's functions include writing answers obtained from reference documents back into the decision path of the skill knowledge base and maintaining consistency across multiple files. During the write-back process, it prioritizes patching the attribution file (the skill file that owns the decision path) and related files, including modifying the reference summary restating the rule, cross-step contracts, parent / child route boundaries, etc. It prioritizes executable statements over descriptive prose, and if the answer is a stable and reusable rule, it is marked as reusable: true to ensure it is written into the decision path rather than remaining only in the current case. In other words, the write-back engine's inputs are: reference answer, gap record, attribution file path, and a list of related files; its output is: patched discrepancy records.
[0191] The re-decision engine's functions include: re-executing the dry run on the repaired decision path using the same specific inputs to verify the correctness of the repair. It can call the dry run engine to re-run on the repaired attribution skill file, using the exact same specific inputs as when the repair was triggered. After several runs pass, it reports to the pipeline controller: "Repair complete, main task can resume." If several runs discover new gaps, it enters the next repair cycle, and the main task is only allowed to resume after all gaps are closed. In other words, the inputs to the re-decision engine are: the repaired attribution skill file and the original specific inputs; the output is: the verification result.
[0192] Reference Figure 10 The diagram illustrates the decision path repair process corresponding to the blocking handling provided in this application embodiment, including the complete process from pipeline step reporting a blockage to repair completion and resumption of execution. The process consists of seven main steps:
[0193] Blockage Classification: First, determine the type of blockage. If the blockage is an implementation defect, directly fix the code and rerun; if the blockage is a decision path defect, execute the main process locking step, i.e., enter the structured repair process. Main Process Locking: Identify the attributing skill file causing the blockage, preserve its execution order, and do not read bypass documents. Dry Run and Gap Detection: Use the same specific input as when the blockage occurred to traverse the decision path node by node, evaluating four executability criteria at each node, stopping at the first node that does not meet the executability criteria. Bounded Reference Retrieval: Read only the minimum necessary fragments within the reference boundaries specified in the gap record; one reference corresponds to one gap. Write Back Answer: First repair the attributing skill file, then repair the associated files to maintain consistency. If the answer is a stable and reusable rule, write it into the skill decision path in the skill knowledge base. Re-decision Verification: Re-run the decision path using the same specific input; if new gaps are found, repair them cyclically. Resume Main Task: Only allow the pipeline to continue after all gaps are closed and the re-decision is passed.
[0194] In this embodiment, after generating the gap record, the system updates the gap record in real time based on the processing results of each step in the decision path repair process. The gap record records a specific blockage point in the decision path, serving as a precise anchor point for subsequent reference retrieval and repair. It is the core data structure in this embodiment during decision path repair, used to transmit precise gap information between the detection, retrieval, repair, and verification stages. Its field list is shown in Table 1 below.
[0195] Table 1
[0196]
[0197] In this embodiment, the gap record serves as the interaction carrier in each stage of gap detection, bounded retrieval, write-back repair, and re-decision verification. For example, after the current node receives and processes the gap record transmitted by the previous node, it can record the output in the gap record, and the next node can continue processing based on this gap record.
[0198] It should be noted that for each node n in the decision path i When evaluating the executability of nodes in a running engine, this can be achieved by calculating a node executability score. The node executability score formula is: E(n i ) = r(n i )*p(n i )*s(n i )*c(n i ).
[0199] Wherein, E(n) i ) is node n i The executability score, with values ranging from [0,1]; r(n i The flag indicates whether the rule is executable, and its value is either 0 or 1; p(n) i The ) indicates whether the priority is explicit, and its value is 0 or 1; s(n i The flag indicates whether the stop / upgrade conditions are explicit; its value is either 0 or 1. i The value ) indicates whether two independent readers reach the same conclusion; it takes the value 0 or 1. When E(n) i When )=0, node n i Marked as a gap. The dry-running engine encounters the first E(n)... i Stop when a node has a ) = 0, and generate a gap record. The reason why the node executability scoring formula uses multiplication instead of addition is that if any one of the four executability criteria is not met, it constitutes a real gap, and there is no situation where "meeting three criteria can compensate for one missing criterion".
[0200] In this embodiment of the application, the constraint rules for bounded retrieval are as follows: The reference document range can be set as B = {b1, b2, ..., b...} k (A predefined set of document paths), the gap set can be represented as G = {g1, g2, ..., g}. m}, then: for each gap g j The search scope is limited to (B) j Belongs to B) (reference document range field in the gap record); Search result A j It must satisfy: Each reference record a (a∈A) j All of these are related to g. j ; Prohibit chain extension: If document b i b was mentioned k+1 (b) i Not belonging to b k+1 ), b must not be k+1 Add to search scope.
[0201] In the embodiments of this application, reference is made to Figure 11 As shown, the patching order followed by the write-back engine is as follows:
[0202] 1. Prioritize Attribution Documents: The attribution skill document containing the decision rule will be patched first. 2. Synchronize Reference Summary: The summary paragraphs in other related documents that restate the rule will be modified accordingly. 3. Align Parent-Child Boundaries: The division of labor boundary descriptions between parent routers and child skills will be modified accordingly. Furthermore, after each layer of patching is completed, a consistency check with the next layer is performed to ensure that public routing labels, internal implementation rules, and upgrade / stop conditions are fully aligned.
[0203] In the embodiments of this application, reference is made to Figure 12 As shown, the re-decision engine defines the complete lifecycle of the repair process through a state machine. The key feature is the loop edge from the new gap to the dry run engine. When the re-decision engine discovers a new gap, the repair process automatically enters the next round until all gaps are closed.
[0204] Figure 13 This embodiment illustrates the complete interactive process from blocking report to resumption of execution. The pipeline controller is responsible for overall scheduling, the blocking classifier classifies blocking and implements route splitting, and when the blocking type is a decision path defect type, the dry run engine and the gap detector collaborate to locate the gap, the reference retrieval engine retrieves the answer within the constraints, the write-back engine maintains multi-file consistency, and the re-decision engine verifies the correctness of the repair.
[0205] To enable those skilled in the art to better understand the embodiments of this application, the embodiments of this application are described below through specific examples. For example, the application scenario is as follows: the implementation in the GPU (Graphics Processing Unit) operator automatic development pipeline is as follows: pipeline step 3 is blocked because the xx-dev router skill file lacks a certain type of tensor (such as the distinction rules between UMA16 and UMA (Unified Memory Architecture)).
[0206] The implementation steps may include:
[0207] The step executor in steps A1 and 3 reports a blocking message: "Unable to determine whether to use UMA16 or UMA tensor type".
[0208] In step A2, the blocking classifier is identified as having a "decision path defect".
[0209] Step A3: The dry running engine loads the home skill file of the xx-dev router and uses the current operator parameters (target_gpu=XX, memtype=UMA) to traverse the routing logic node by node. It stops at the "Tensor Type Selection" node, which does not distinguish between UMA16 on XX and UMA across the die.
[0210] Step A4, gap record generation: {step: "tensor_type_selection", question: "Does UMA on XX default to UMA16?", gap_type: "boundary_mismatch", allowed_references: ["docs / design-doc / xx / uma-spec.md"]}.
[0211] Step A5, refer to the search engine to find the answer in docs / design-doc / xx / uma-spec.md: "The default mapping of UMA for XX is UMA16, and UMA across bare wafers needs to be explicitly labeled".
[0212] Step A6: Write back the tensor selection rules in xx-dev / SKILL.md, the corresponding digest in reference / uma-numa-tensor.md, and the XX-related entries in gpu-kernel-mapper / reference / XX.md.
[0213] Step A7: The re-decision engine reruns the repaired route using the same operator parameters to confirm that it can now correctly route to UMA16.
[0214] Step A8, resume execution of step 3.
[0215] The blocking handling method and system provided in this application have the following performance advantages: structured repair replaces unconstrained trial and error, reducing blocking recovery from an average of 5-10 rounds of trial and error to 1-2 rounds of precise repair; bounded retrieval reduces the amount of reference documents read by more than 80% (only reading the smallest fragment related to the gap, rather than a full scan); automatic write-back for each repair makes the first repair of a similar problem the last.
[0216] It boasts the following technical advantages: a six-category decision path gap classification system, enabling the diagnosis of agent blockages to go from vague "stuck" to precise "a rule missing / ambiguous / contradictory in step N of a certain skill document..."; structured gap records provide a complete repair trajectory, including where the gap is, what references were consulted, what documents were modified, and whether the re-decision was approved, which can meet compliance and quality audit requirements; and a mandatory write-back mechanism ensures that the answers found in individual cases are elevated to system-level rules, directly benefiting subsequent similar tasks.
[0217] It has the following cost advantages: the agent can autonomously repair most decision path defects and only reports to humans when it cannot answer within the reference range, thus reducing human intervention; taking GPU operator development as an example, the number of repeated redoings caused by skill routing errors (average 3 times) is reduced to 0-1 times, shortening the development cycle; the knowledge base is automatically improved during use, reducing the frequency and workload of regular manual review and lowering knowledge maintenance costs.
[0218] The blocking handling method provided in this application is applicable to any AIAgent system driven by skill / knowledge files, and is not limited to GPU operator development; the gap type can be expanded according to domain needs, and the bounded reference boundary can be flexibly configured; the more it is used and the more it is fixed, the more complete the knowledge base becomes, and the agent efficiency can be continuously improved.
[0219] Each module in the aforementioned blocking processing system can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in the processor of a computer device in hardware form or independent of it, or stored in the memory of the computer device in software form, so that the processor can call and execute the operations corresponding to each module.
[0220] In one exemplary embodiment, a computer device is provided, which may be a terminal, and its internal structure diagram may be as follows: Figure 14As shown, the computer device includes a processor, memory, input / output interfaces, a communication interface, a display unit, and an input device. The processor, memory, and input / output interfaces are connected via a system bus, and the communication interface, display unit, and input device are also connected to the system bus via the input / output interfaces. The processor provides computational and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The input / output interfaces are used for exchanging information between the processor and external devices. The communication interface is used for wired or wireless communication with external terminals; wireless communication can be achieved through Wi-Fi, mobile cellular networks, Near Field Communication (NFC), or other technologies. When the computer program is executed by the processor, it implements a blocking processing method.
[0221] Those skilled in the art will understand that Figure 14 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.
[0222] In one embodiment, a computer device is also provided, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps in the above method embodiments.
[0223] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon that, when executed by a processor, implements the steps in the above method embodiments.
[0224] In one embodiment, a computer program product is provided, including a computer program that, when executed by a processor, implements the steps in the above method embodiments.
[0225] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, data stored, data displayed, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of the relevant data must comply with relevant regulations.
[0226] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile memory and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM). The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, artificial intelligence (AI) processors, etc., and are not limited to these.
[0227] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this application.
[0228] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.
Claims
1. A method for handling congestion, characterized in that, Applied to a congestion handling system, the method includes: When a blockage occurs in a pipeline step, determine the type of blockage corresponding to the current blockage location; If the blocking type is a decision path defect type, the target decision path corresponding to the current blocking position is driven to execute decisions node by node according to the current blocking context information, generating a gap record. The gap record includes a gap problem description and a reference document range. Based on the description of the gap problem and the scope of the reference documents, an answer is retrieved, a corresponding reference answer is generated, and the target decision path is temporarily repaired based on the reference answer; After the temporary repair of the target decision path is completed, the target decision path is re-driven to execute decisions node by node according to the current blocking context information. If each node in the target decision path can make a correct decision, the pipeline step execution is resumed.
2. The method according to claim 1, characterized in that, When a blockage occurs in a pipeline step, determining the blockage type corresponding to the current blockage location includes: Receive blocking information reported by the pipeline step executor, the blocking information including error description, blocking location information and current blocking context information; Based on the blocking information, the blocking type corresponding to the current blocking position is determined. The blocking type includes implementation defect type or decision path defect type.
3. The method according to claim 2, characterized in that, The step of driving the target decision path corresponding to the current blocking position to execute decisions node by node based on the current blocking context information and generating a gap record includes: Based on the blockage location information, determine the skill file corresponding to the current blockage location; Based on the current blocking context information and the attributed skill file, the target decision path is driven to execute decisions node by node in sequence, and during the decision execution phase of each node, the executability standard is evaluated for the node. When any of the nodes fails to meet the executability criteria, the traversal of subsequent nodes is terminated, and the corresponding decision trajectory and gap record are generated.
4. The method according to claim 3, characterized in that, The generation of the corresponding decision trajectory and gap record includes: Based on the decision-making process results, generate the corresponding decision trajectory and gap location markers; The gap type is determined based on the current blocking context information, the decision trajectory, and the gap location identifier; The reference document range is determined based on the gap type, and a gap record is generated based on the gap type and the reference document range.
5. The method according to claim 1, characterized in that, The method further includes: If a new gap record is generated during the process of re-driving the target decision path node by node in turn based on the current blocking context information, then the next round of blocking processing will begin based on the new gap record, until the target decision path is re-drived and each node in the target decision path can make a correct decision.
6. The method according to claim 1, characterized in that, The method further includes: The reference answer is evaluated. If the evaluation result indicates that the reference answer is a stable and reusable answer, then the reference answer is written into the skill knowledge base based on the repair constraint. The repair constraints include at least one of the following: Prioritize repairing the attribution skill files corresponding to the target decision path; Repair the associated files of the attributed skill file; An executable expression is used to write the reference answer into at least one of the attribution skill file and the associated file.
7. The method according to claim 2, characterized in that, The implementation defect types include at least one of compilation errors and logical errors, and the decision path defect types include at least one of missing rules, ambiguity, inconsistency between inner and outer boundaries, cyclic dependency, implicit cross-file dependency, and undefined operation.
8. The method according to claim 3, characterized in that, The enforceability criteria include at least one of the following: whether the rule is enforceable, whether the priority is clear, whether the operating conditions are clear, and whether two independent readers reach the same conclusion.
9. A congestion handling system, characterized in that, include: The components include a blocking classifier, a gap generator, a reference retrieval system, and a re-decision engine, among which: The blockage classifier is used to determine the blockage type corresponding to the current blockage location when a blockage occurs in a pipeline step. The gap generator is used to drive the target decision path corresponding to the current blockage position to execute decisions node by node according to the current blockage context information if the blockage type is a decision path defect type, and generate a gap record. The gap record includes a gap problem description and a reference document range. The reference retrieval device is used to retrieve answers based on the gap problem description and the range of reference documents, generate corresponding reference answers, and temporarily repair the target decision path based on the reference answers; The re-decision engine is used to, after completing the temporary repair of the target decision path, re-drive the target decision path to execute decisions node by node according to the current blocking context information. If each node in the target decision path can make a correct decision, the pipeline step execution is resumed.
10. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 8.
11. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 8.
12. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 8.