Motion control method, robot, electronic device, and computer program product
By embedding a selective residual learning module into the VLA model, the action hidden representation is adaptively corrected, which solves the problem of VLA model failing to grasp in complex environments, improves the success rate of robot tasks and reduces system complexity.
Patent Information
- Application Number
- CN202611348966.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-08-31
- Publication Date
- 2026-11-24
AI Technical Summary
Existing VLA models suffer from problems such as motion hiding representation deviating from the success region due to environmental changes and object pose deviations in robot manipulation tasks, leading to grasping failures. Existing control methods are unable to effectively address these issues, and the introduction of additional modules increases inference latency and system complexity.
By embedding a selective residual learning module into the VLA model, residual adjustment is adaptively and selectively enabled or disabled through routers and residual experts. This locally corrects the action-hidden representation, maintains the reliable output of the base model, and avoids introducing additional detection modules.
It improves the robot's success rate in complex environments and long-term tasks, reduces system complexity and inference latency, and maintains the reliable behavior of the base model.
Smart Images

Figure CN123149983A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of computer technology, specifically to a motion control method, a robot, an electronic device, and a computer program product. Background Technology
[0002] Vision-Language-Action (VLA) models are widely used in robot control tasks. The reasoning process is usually as follows: obtain the current visual observation and language task instructions, generate action hidden representations through the model backbone, and then convert the action hidden representations into robot control actions by the action output module.
[0003] However, in actual deployment and inference, the action hidden representation generated by the VLA model backbone may deviate from the area covered by the successful demonstration due to factors such as environmental changes, object pose deviations, and contact errors. This can lead to the action output module generating incorrect actions. For example, in a grasping task, even a small positioning deviation can cause the grasping to fail. This deviation accumulates in subsequent actions, eventually leading to task failure.
[0004] Existing control methods, when faced with the above situations, typically rely on the generalization ability of the base model itself and fine-tune it using successful demonstration data. However, this approach is limited by the coverage of successful demonstration data and struggles to handle various failure-related states that arise during deployment. Some methods attempt to introduce additional failure detection modules or recovery planners during inference, but these external modules require additional computational resources and model loading, increasing inference latency and system complexity. Other methods apply uniform, fixed post-processing or corrections to all inputs, but this introduces unnecessary perturbations into otherwise reliable, normal states, ultimately reducing overall performance. Summary of the Invention
[0005] This application provides an action control method, robot, electronic device, and computer program product. During VLA model inference, residual adjustment is automatically and selectively enabled or disabled based on the current hidden representation. This maintains the original output of the base model in a reliable state and performs localized, limited-amplitude corrections to the hidden representation in a deviating state, thereby improving the accuracy of the inference results without adding additional external detection modules or recovery planners.
[0006] An embodiment of this application provides a motion control method, including: The system acquires observation data and task instructions, inputs them into the model backbone of the trained control model, and generates a hidden representation of the current action. The control model includes a model backbone, a selective residual learning module, and an action output module. The selective residual learning module includes a router, an empty residual branch, and at least one residual expert. During the training of the control model, the parameters of the model backbone and the action output module are frozen, and the training data of the control model includes failure trajectories. The failure trajectories are used to train the selective residual learning module so that the selective residual learning module learns the action adjustment direction and residual branch selection strategy.
[0007] Hides the current action input to the router, generating a branch selection signal; When the branch selection signal represents the selection of the empty residual branch, the current action hidden representation is input to the action output module; When the branch selection signal characterization selects at least one target residual expert from the residual experts, the candidate residual quantity is generated based on the current action hiding representation by the target residual expert; and the current action hiding representation and the candidate residual quantity are superimposed to form a candidate representation, and the candidate representation is input to the action output module; The action output module generates action prediction results based on the current hidden or candidate action representation.
[0008] In this way, during inference, the system adaptively chooses to maintain the original output of the base model or perform local, limited-amplitude corrections on the hidden representation based on the current action hidden representation, achieving selective correction of the base model's output. In a reliable state, the original output of the base model is maintained, avoiding unnecessary perturbations. In a failed, correlated state, residual experts perform local, limited-amplitude corrections on the hidden representation, eliminating the need for additional failure detection modules or recovery planners. This effectively improves the success rate of the control model in complex environments and long-term tasks while maintaining the reliable behavior of the base model, reducing system complexity and inference latency.
[0009] In one possible implementation, the router includes a normalization layer and a linear classification header; The steps for hiding the current action input to the router and generating a branch selection signal include: The current action hidden representation is normalized by a normalization layer to generate a normalized current action hidden representation; The hierarchical normalized representation of the current action is mapped using a linear classification head. Each category has a quantity. The number of residual experts; according to Each classification score generates the selection probability of choosing the empty residual branch and the residual expert; The branch selection signal is output based on the selection probability.
[0010] In this way, the router function is achieved through the combination of a normalization layer and a linear classification head. The normalization layer eliminates scale differences between different hidden representations, making subsequent classification processing more stable. The linear classification head maps the normalized representation to... The router generates branch selection signals by calculating classification scores. Its simple structure and low computational overhead enable it to quickly and accurately determine the category of the current state, providing a reliable basis for subsequent branch selection.
[0011] In one possible implementation, the control model is trained in the following manner: Acquire successful demonstration hidden representations and deployment trajectory data. Successful demonstration hidden representations are generated by a pre-trained base model from the visual observations and language task instructions in the successful demonstrations and are associated with the target actions in the successful demonstrations. Deployment trajectory data includes action blocks that are synchronously saved by the pre-trained base model when it is executed in the target task environment, as well as trajectory-level task execution results associated with the action blocks. Based on deployment trajectory data, a reliable representation set and a failure association representation set are determined. The reliable representation set corresponds to the action blocks of the basic model in a reliable execution state, and the failure association representation set corresponds to the action blocks of the basic model in a deviated execution state. A local success prototype is constructed based on a set of reliable representations. The local success prototype is an aggregation of reliable representations that are adjacent in representation space to action blocks in the set of failure-associated representations. The control model is obtained by setting a selective residual learning module between the model backbone of the basic model and the action output module. By using the successful demonstration hidden representation, the reliable representation set, the failure association representation set, and the local success prototype, the selective residual learning module in the control model is trained to obtain the trained control model.
[0012] In this way, a failure-driven asymmetric supervised training method is used to jointly train a selective residual learning module by utilizing failed deployment trajectories with only trajectory-level task execution result labels, combined with successful demonstration hidden representations, reliable representation sets, failure association representation sets, and local success prototypes. During training, the parameters of the model backbone and action output modules remain frozen, with only a small number of parameters of the router and residual experts being updated, resulting in high training efficiency. There is no need to provide corrective actions for each action block of failed trajectories, nor is online interaction or manual intervention required, thus reducing data collection and labeling costs. Furthermore, the failure origin segmentation avoids trajectory-level failure labels incorrectly covering reliable prefixes.
[0013] In one possible implementation, the steps of determining the reliable representation set and the failure-associated representation set based on deployment trajectory data include: Based on the execution results of trajectory-level tasks, determine the action blocks of successful trajectories in the deployed trajectory data; Perform time-series analysis on the failed trajectories in the deployment trajectory data to determine the earliest failure starting point in the action block of the failed trajectory that can still be corrected through subsequent action adjustments. Action blocks with indices lower than the failure start point in the failed trajectory, and action blocks in the successful trajectory in the deployment trajectory data, are included in the reliable representation set. Action blocks with indices greater than or equal to the failure start point in the failure trajectory are included in the failure association representation set.
[0014] In this way, by performing temporal analysis on the failed trajectory to determine the failure starting point, and dividing the action hidden representation into a reliable representation set and a failure-related representation set based on the failure starting point, fine-grained processing of trajectory-level failure result labels is achieved. The reliable prefix before the failure starting point is assigned to the reliable representation set, used to supervise the model in maintaining its basic strategy. The failure starting point and the failure-related representations after it are assigned to the failure-related representation set, used to supervise the model in learning residual adjustment. This avoids the pollution of the supervision signal caused by labeling the entire trajectory as a failure, making training more accurate and effective.
[0015] In one possible implementation, the residual expert is a lightweight neural network whose parameters are zero-initialized at the start of training so that the initial output is close to zero, thereby ensuring that the initial behavior of the selective residual learning module is consistent with the base model.
[0016] In this way, by initializing the downprojection of the residual experts with zero, the outputs of each non-empty residual expert are close to zero at the start of training, thus ensuring that the initial behavior of the selective residual learning module is consistent with the base model. Even if the router incorrectly selects a residual expert in the early stages of training, the candidate representations generated by the residual expert are almost identical to the original hidden representations, without disrupting the existing correct behavior of the base model. This provides a stable starting point for the training process, which is beneficial for model convergence.
[0017] In one possible implementation, the steps of constructing a locally successful prototype based on a set of reliable representations include: From the reliable representation set, extract the representation of the reliable success trajectory according to the task, normalize the representation of the reliable success trajectory, and construct a normalized reliable success prototype pool. For each failure association representation in the failure association representation set, the failure association representation is normalized, and a preset number of neighboring representations are retrieved from the normalized reliable success prototype pool of the corresponding task. The median of each coordinate of the neighboring representations is taken to obtain the local success prototype.
[0018] In this way, by retrieving neighboring representations from a pool of reliable successful prototypes and constructing local successful prototypes by taking the median for each coordinate, a local corrective reference for failure-related representations is provided within the same task and operational stage. Using the median instead of the mean for aggregation resists interference from a few abnormal neighboring points, making the constructed local successful prototypes more robust and representative.
[0019] In one possible implementation, during the process of training the selective residual learning module in the control model using the successful demonstration hidden representation, the reliable representation set, the failure association representation set, and the local success prototype, to generate the control model, the loss function used includes at least one of the following: Successful demonstration of supervised loss is used to measure the error between the candidate residuals output by the residual expert and the target action; The reliable state preservation loss is used to prompt the representation in the reliable representation set to select an empty residual branch; The failure representation redirection loss is used to encourage the representations in the failure-associated representation set to select residual experts and move closer to the local success prototype. Residual amplitude constraint loss is used to limit the norm of candidate residual quantities output by residual experts.
[0020] Thus, multi-objective training of the selective residual learning module is achieved through the joint optimization of successful demonstration supervision loss, reliable state preservation loss, failure representation redirection loss, and residual magnitude constraint loss. Successful demonstration supervision loss ensures the correctness of the residual correction direction, reliable state preservation loss protects the reliable behavior of the basic strategy, failure representation redirection loss guides the router to activate experts and generate effective corrections in failure states, and residual magnitude constraint loss limits the correction magnitude. These four losses work together to enable the model to possess adaptive correction capabilities while maintaining basic performance.
[0021] In one possible implementation, the calculation of the successful demonstration supervision loss includes: Calculate the basic candidate error and the residual expert candidate error. The basic candidate error is the error between the candidate representation corresponding to the empty residual branch and the target action. The residual expert candidate error is the error between the candidate representation corresponding to the residual expert and the target action. Expert responsibility weights are generated based on residual expert candidate errors, and these expert responsibility weights are negatively correlated with residual expert candidate errors. The expert action supervision loss is obtained by weighting and summing the residual expert candidate errors according to the expert responsibility weight.
[0022] In this way, differentiated supervision of successful demonstrations is achieved by calculating the basic candidate error and the residual expert candidate error, and generating expert responsibility weights based on the candidate errors. The expert responsibility weights are negatively correlated with the candidate errors, allowing better-performing residual experts to receive higher learning weights. During the warm-up phase, responsibility weights are forced to be allocated only among non-empty residual experts, preventing all training samples from being routed to empty residual branches too early, and ensuring that each zero-initialized residual expert can obtain effective action supervision from successful demonstrations.
[0023] In one possible implementation, the reliable state preservation loss includes: The log-likelihood term is used to improve the probability of reliably representing the selection of the empty residual branch; The residual energy penalty term is used to penalize the product of the routing probability of each non-empty branch and the residual energy of the non-empty branch when selecting a non-empty residual branch for a reliable representation.
[0024] In this way, the probability of selecting an empty residual branch is increased by the log-likelihood term, while the residual energy penalty term is used to penalize the residual energy when a non-empty branch is mistakenly selected. This ensures that the model prioritizes maintaining the hidden representation of the basic action in a reliable state and minimizes the disturbance caused by the mistaken selection of a non-empty branch. This effectively protects the existing reliable behavior of the basic policy and prevents the addition of modules from causing unnecessary interference to the normal state.
[0025] In one possible implementation, failure indicates that the redirection loss includes: The routing cross-entropy term is used to make the route destination represented by the failed association close to the output probability distribution of the router; The distance improvement interval term is used to ensure that the distance improvement between the candidate representation corresponding to the selected residual expert and the local success prototype is not less than a preset interval.
[0026] In this way, the routing cross-entropy term makes the routing target of the failed association representation close to the output probability distribution of the router, while the distance improvement interval term ensures that the distance improvement between the candidate representation corresponding to the selected residual expert and the local success prototype is not less than the preset interval. This prompts the failed association representation to select an appropriate residual expert and move closer to the local success prototype of the same task, ensuring the directionality and effectiveness of residual adjustment, and making the corrected hidden representation closer to the ideal representation in the successful state.
[0027] This application also provides a robot, including a controller; The controller is configured to perform the control method described above.
[0028] This application also provides an electronic device, including: a memory for storing instructions; and a processor for calling the instructions stored in the memory to execute the above-described control method.
[0029] This application also provides a computer program product, which, when read and executed by a computer, causes the above-described control method to be executed.
[0030] This application provides an action control method, robot, electronic device, and computer program product. The control method includes: acquiring observation data and task instructions; inputting the observation data and task instructions into the model backbone of a trained control model to generate a current action hidden representation; inputting the current action hidden representation into a router to generate a branch selection signal; if the branch selection signal indicates that an empty residual branch is selected, inputting the current action hidden representation into an action output module; if the branch selection signal indicates that a target residual expert among at least one residual expert is selected, generating a candidate residual quantity based on the current action hidden representation through the target residual expert; and superimposing the current action hidden representation and the candidate residual quantity to form a candidate representation, and inputting the candidate representation into the action output module; the action output module generates an action prediction result based on the current action hidden representation or the candidate representation.
[0031] The motion control method, robot, electronic device, and computer program product provided in this application's embodiments, during the inference process, adaptively choose to maintain the original output of the base model or perform local, limited-amplitude corrections on the hidden representation based on the current motion hidden representation, achieving selective correction of the base model's output. In a reliable state, the original output of the base model is maintained, avoiding unnecessary disturbances. In a failure-related state, residual experts perform local, limited-amplitude corrections on the hidden representation, eliminating the need for additional failure detection modules or recovery planners. Thus, while maintaining the reliable behavior of the base model, the success rate of the control model's execution in complex environments and long-term tasks is effectively improved, reducing system complexity and inference latency. Attached Figure Description
[0032] To more clearly illustrate the implementation methods in the embodiments of this application or related technologies, the accompanying drawings used in the description of the embodiments or related technologies will be briefly introduced below. Obviously, the accompanying drawings described below are some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings.
[0033] Figure 1 A flowchart illustrating the motion control method provided in an embodiment of this application; Figure 2 A schematic diagram of the router structure and branch selection logic provided in the embodiments of this application; Figure 3 A schematic flowchart illustrating the control model training method provided in this application embodiment; Figure 4A flowchart illustrating the method for partitioning the reliable representation set and the failure association representation set provided in this application embodiment; Figure 5 A schematic diagram of the action block timing partitioning for a reliable success trajectory provided in the embodiments of this application; Figure 6 A schematic diagram of the action block timing partitioning of the failed deployment trajectory provided in the embodiments of this application; Figure 7 A flowchart illustrating the partially successful prototype construction method provided in this application embodiment; Figure 8 A schematic diagram illustrating the calculation process of successful demonstration monitoring loss provided in this application embodiment. Detailed Implementation
[0034] To enable those skilled in the art to better understand the technical solutions in this application, the technical solutions in the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments in this application, all other embodiments obtained by those of ordinary skill in the art without creative effort should fall within the scope of protection of this application.
[0035] It should be noted that many specific details are set forth in the following description in order to provide a full understanding of this application. However, this application may also be implemented in other ways different from those described herein. Therefore, the scope of protection of this application is not limited to the specific embodiments disclosed below.
[0036] This application provides an action control method, robot, electronic device, and computer program product, aiming to solve the problem that existing VLA models deviate from the successful region due to environmental changes and other factors during deployment. This solution embeds a lightweight selective residual learning module within the model to achieve adaptive and selective adjustment of the action hidden representation. This effectively corrects action generation in deviated states while maintaining the model's original reliable behavior, improving the model's robustness and task success rate in complex environments.
[0037] This application provides an embodiment of a motion control method, such as... Figure 1 As shown, it includes steps S110 to S150.
[0038] Step S110: Acquire observation data and task instructions, input the observation data and task instructions into the model backbone of the trained control model, and generate the current action hidden representation.
[0039] The control model includes a model backbone, a selective residual learning module, and an action output module. The selective residual learning module includes a router, an empty residual branch, and at least one residual expert. During the training of the control model, the parameters of the model backbone and the action output module are kept frozen.
[0040] The training data for the control model includes failure trajectories, which are used to train the selective residual learning module (SLM) to learn action adjustment directions and residual branch selection strategies. Each failure trajectory is generated by the frozen base vision-language-action model during deployment in the target task environment, and the corresponding action hidden representation is saved synchronously when each action block is generated. After trajectory execution, a trajectory-level task execution result label is recorded for the entire trajectory; failure trajectories do not need to provide correct correction actions for each action block.
[0041] The motion control method provided in this application is applied to a robot equipped with a vision sensor. For example, an RGB-D (Red Green Blue-Depth) camera mounted above the robot's work area, a wrist camera mounted on the robot's actuator arm, or a camera mounted on the robot's head.
[0042] The robot collects current observation data using its onboard vision sensors. For example, the observation data might be an image containing the object to be grasped. It also acquires task instructions input by the user, such as placing the red square into the blue box.
[0043] The observation data and task instructions are input into a pre-trained control model. The backbone of the control model performs a normal forward computation, forming the current action hidden representation before the action output module. For example, the model backbone is the backbone network of a pre-trained basic vision-language-action model. The parameters of the backbone network are frozen during training, and the current action hidden representation carries the current visual context, task semantics, and action generation information.
[0044] In this embodiment, the model backbone can adopt a vision-language-action model with a Transformer architecture, a diffusion architecture, or an autoregressive architecture. For a model containing... An action block with an action token is formed, and the model backbone forms a hidden state for the action token during the normal forward process of the action block. And hide the state of the action token. By performing mean processing, we obtain the current action hidden representation at the action block level, which represents the overall state of the action block and is used for routing decisions. .
[0045] .
[0046] in, For the first A trajectory in an action block Observations at the location, For language task instructions, As the frozen model backbone, This represents the number of action tokens within the action block.
[0047] Step S120: Hide the current action input to the router and generate a branch selection signal.
[0048] The selective residual learning module for the control model includes a router, an empty residual branch, and at least one residual expert. This module is positioned between the frozen model backbone and the frozen action output module. The router receives the current action hidden representation, processes it, and outputs a branch selection signal. This signal indicates whether subsequent processing should select the empty residual branch or a target residual expert from at least one residual expert.
[0049] Branch selection signals are used to determine the next step in processing the current action hiding representation. Through learning, the router can identify whether the current action hiding representation is in a reliable state or a failed, correlated state. A reliable state refers to a common state that the control model can handle correctly, while a failed, correlated state refers to a deviating state where the control model is prone to errors.
[0050] Step S130: When the branch selection signal indicates that an empty residual branch is selected, the current action hiding representation is input to the action output module.
[0051] If the router determines that the current state is reliable, the generated branch selection signal indicates that the empty residual branch should be selected. The empty residual branch is a special path that does not modify the hidden representation of the current input action; the residual output by the empty residual branch is zero. In this case, the original current action hiding representation is passed to the downstream action output module unchanged.
[0052] Step S140: When the branch selection signal characterization selects at least one target residual expert among the residual experts, the target residual expert generates a candidate residual quantity based on the current action hiding representation; and the current action hiding representation and the candidate residual quantity are superimposed to form a candidate representation, and the candidate representation is input to the action output module.
[0053] If the router determines that the current state is a failed association state, the generated branch selection signal indicates the selection of a specific target residual expert. For example, the target residual expert is the... Each residual expert is one of several pre-trained lightweight neural networks, and each residual expert is responsible for handling one or a class of typical failure modes. For example, failure modes include grasping offset, misplacement, etc.
[0054] No. Individual Disability Expert Hiding the current action And hide the representation based on the current action. Generate candidate residuals : , .
[0055] , .
[0056] Among them, candidate residuals It is a vector representing the direction and magnitude of the corrections needed to be made to the current action's hidden representation. Candidate representations corresponding to empty residual branches (i.e., hidden representations of the current action) itself), For the first Candidate representations corresponding to each residual expert.
[0057] The control model hides the representation of the current action. With candidate residuals Superimposed to form candidate representations and will represent the candidate Input to the frozen action output module.
[0058] The original current action hidden representation is vector-added with the candidate residual to form a candidate representation. The candidate representation is a local and targeted modification of the original hidden representation, making the modified candidate representation closer to the ideal representation in the successful state. Finally, the modified candidate representation is input into the action output module.
[0059] In some embodiments, the selective residual learning module includes multiple residual experts, each of whom learns adjustment directions for different bias patterns or different task stages.
[0060] Step S150: The action output module generates an action prediction result based on the current hidden or candidate action representation.
[0061] The frozen action output module receives input from the selective residual learning module. When the action output module receives the current action hidden representation, it generates a basic action prediction result based on that representation. When the action output module receives candidate representations, it generates a corrected action prediction result based on those candidate representations. The action output module can employ linear projection. ,Right now: .
[0062] in, For the final hidden representation input to the action output module, under the empty residual branch Under the residual expert When the motion output module is not a linear projection, it can be... Replace with the corresponding frozen motion output mapping. The generated motion prediction results may include continuous joint movements, gripper commands, motion tokens, target pose, trajectory, or other control parameters.
[0063] The robot executes all control steps of the action block corresponding to the action prediction result, or only executes the first few control steps, and then regenerates the next action block using the updated observations, thus forming a rolling closed loop of observation, routing, action generation, execution and new observations.
[0064] The action control method provided in this application, during inference, adaptively selects to maintain the original output of the base model or perform local, limited-amplitude corrections on the hidden representation based on the current action hidden representation, thus achieving selective correction of the base model output. In a reliable state, the original output of the base model is maintained, avoiding unnecessary disturbances. In a failed, correlated state, the hidden representation is locally, with limited amplitude corrections, through residual experts, eliminating the need for additional failure detection modules or recovery planners. Therefore, while maintaining the reliable behavior of the base model, this effectively improves the success rate of the control model in complex environments and long-term tasks, reducing system complexity and inference latency.
[0065] In some embodiments, the router includes a normalization layer and a linear classification header. For example... Figure 2 As shown, the steps of hiding the current action input to the router and generating a branch selection signal include steps S210 to S240.
[0066] Step S210: Normalize the current action hidden representation through a normalization layer to generate a normalized current action hidden representation.
[0067] The normalization layer is used to standardize the input action hidden representation to eliminate scale differences between different representations, making subsequent classification processing more stable.
[0068] One way to implement a normalization layer is through layer normalization. Of course, in practical applications, other normalization methods that can achieve similar functions can also be used.
[0069] Step S220: Map the layer-normalized hidden representation of the current action to the linear classification head. Each category score, The number of residual experts.
[0070] The normalized hidden representation of the current action is mapped using a linear classification head. Each classification score, for example, is a logits vector. For the number of residual experts, Each logits vector corresponds to One residual expert and one empty residual branch.
[0071] Step S230, according to Each classification score generates the selection probability of choosing the empty residual branch and the residual expert.
[0072] according to Each classification score is used to generate the selection probabilities for choosing the null residual branch and the residual expert using the Softmax function.
[0073] The selection probability distribution output by the router is as follows: .
[0074] .
[0075] .
[0076] in, This represents the probability of selecting the empty residual branch. Indicates the selection of the first The probability of a residual expert These are the trainable parameters of the router. This indicates a normalization operation.
[0077] During online inference, the router uses sparse Top-1 routing, selecting the path with the highest probability. : .
[0078] when , ;when , ,in, The index for the selected branch.
[0079] Step S240: Output the branch selection signal based on the selection probability.
[0080] Based on the selection probability distribution, the router outputs a branch selection signal, which indicates the selection of the empty residual branch. ) or select the first Individual residual experts ( ).
[0081] In this way, the router function is achieved through the combination of a normalization layer and a linear classification head. The normalization layer eliminates scale differences between different hidden representations, making subsequent classification processing more stable. The linear classification head maps the normalized representation to... The router generates a branch selection signal by constructing a logits vector. Its simple structure and low computational overhead enable it to quickly and accurately determine the current state's category, providing a reliable basis for subsequent branch selection.
[0082] In some embodiments, such as Figure 3 As shown, the control model is trained using the methods in steps S310 to S350.
[0083] Step S310: Obtain successful demonstration hidden representation and deployment trajectory data.
[0084] Each successful demonstration in the successful demonstration set includes at least a visual observation, a language task instruction, and a target action. The hidden representation of a successful demonstration is generated from the visual observation and language task instruction in the successful demonstration using the backbone of a pre-trained base model and is associated with the target action in the successful demonstration.
[0085] The deployment trajectory data is synchronously saved by the pre-trained base model during deployment in the target task environment. This includes action blocks synchronously saved during the execution of the pre-trained base model in the target task environment, as well as the trajectory-level task execution results associated with the action blocks. Each time the base model generates an action block based on the current observation and task instructions, it synchronously acquires and saves the hidden action state before the action output module during the same normal forward computation, while also recording the trajectory number, task identifier, action block index, observation, task instructions, and the generated action block. After the trajectory execution is complete, trajectory-level task execution result labels are recorded for the entire trajectory. .For example, This indicates that the target task has been successfully completed. This indicates that the target task was not successfully completed.
[0086] Specifically, in collecting the first When deploying a trajectory, the frozen model backbone According to the action block Observation at the location and instructions Perform normal forward computation and form the action token hidden state. If an action block contains Each action token has its state hidden during the same forward deployment process that generates the action block. The mean is applied to form an action hidden representation that represents the overall state of the action block and is used for routing decisions. And hide the action representation Saved synchronously with the action block index: , .
[0087] in, This represents the core parameters of the model (frozen during training). For summation index.
[0088] Step S320: Based on the deployment trajectory data, determine the reliable representation set and the failure association representation set.
[0089] Offline time-series analysis is performed on the deployment trajectory. For successful trajectories, the reliability of the execution process is determined, and a reliability indicator for the successful trajectory is obtained. .For example, This indicates reliable success. This indicates an unreliable success. For a failure trajectory, identify the earliest point of failure that can still be corrected through subsequent actions. ,Right now For the first Index of the action block that marks the starting point of a failed trajectory.
[0090] Based on the above time series analysis results, the action hiding representations synchronously saved during deployment are divided into reliable representation sets. The set associated with failure : .
[0091] .
[0092] Reliable representation set It consists of action blocks from reliable successful trajectories and action blocks preceding the failure initiation point; the failure association representation set. It consists of the action block at the failure starting point and the action blocks following the failure starting point. Prefixes in the failure trajectory that have not yet shown correctable biases are used to supervise the model to maintain the basic strategy, while the action blocks at the failure starting point and following the failure starting point are used to supervise the model to learn residual adjustment, avoiding trajectory-level failure result label errors covering the entire trajectory.
[0093] Step S330: Construct a local success prototype based on a reliable representation set.
[0094] A local success prototype is an aggregation of reliable representations that are spatially adjacent to the action block in the set of failure-associated representations. In other words, by constructing a local success prototype, we can find the most similar reliable success state in the same task for the current failure-associated state, as a local reference that the hidden representation should be close to.
[0095] Extract the action block of the reliable success trajectory from the reliable representation set, i.e., satisfy... and This indicates that a reliable and successful prototype pool is built according to the task. : .
[0096] in, For the first The task identifier for each trajectory, although the reliable prefix of a failed trajectory belongs to the reliable representation set, does not enter the reliable success prototype pool. Successful trajectories judged as unreliable also do not enter the reliable success prototype pool.
[0097] For any failed association representation in the set of failed association representations Constructing a locally successful prototype The process includes: first, performing L2 normalization on the query representation and the pool representation (adding positive numbers to the normalization denominator). To avoid division by zero): , .
[0098] Then from the normalized prototype pool of the corresponding task Search Each nearest neighbor is represented, and the median is taken for each coordinate: , .
[0099] in, This represents the number of nearest neighbors. This indicates taking the median of the coordinates of the vector.
[0100] The Euclidean distance in the normalized representation space is defined as: .
[0101] Local success prototype As the current query representation changes, it provides a localized corrective reference for the current failed association status, within the same task and operation phase.
[0102] Step S340: Obtain the control model. The control model is obtained by setting a selective residual learning module between the model backbone of the basic model and the action output module.
[0103] The residual learning module includes a router, an empty residual branch, and... Each residual expert is trained. During training, the parameters of the model backbone and action output modules are frozen, and only the newly added router and residual experts are trained.
[0104] Step S350: Using the successful demonstration hidden representation, the reliable representation set, the failure association representation set, and the local success prototype, train the selective residual learning module in the control model to obtain the trained control model.
[0105] A failure-driven asymmetric supervised learning paradigm is employed, trained in conjunction with the following supervisory signals. This successfully demonstrates methods for supervising residual experts to generate candidate residuals with correct action semantics. A reliable representation set is used to supervise the router's selection of empty residual branches, learning when to maintain the base policy. A failure-associated representation set and a locally successful prototype of the same task are used to supervise the router's selection of the appropriate residual expert and to learn the residual adjustment direction, learning when and how to intervene; simultaneously, the adjustment range is limited by residual magnitude constraints.
[0106] It should be noted that during training, only the newly added router and residual expert parameters are updated; the backbone of the base model and the action output module remain frozen. After training, the output router and residual expert parameters can be directly used for online inference.
[0107] In this way, a failure-driven asymmetric supervised training method is used to jointly train a selective residual learning module by utilizing failed deployment trajectories with only trajectory-level task execution result labels, combined with successful demonstration hidden representations, reliable representation sets, failure association representation sets, and local success prototypes. During training, the parameters of the model backbone and action output modules remain frozen, with only a small number of parameters of the router and residual experts being updated, resulting in high training efficiency. There is no need to provide corrective actions for each action block of failed trajectories, nor is online interaction or manual intervention required, thus reducing data collection and labeling costs. Furthermore, the failure origin segmentation avoids trajectory-level failure labels incorrectly covering reliable prefixes.
[0108] In some embodiments, such as Figure 4 As shown, the steps for determining the reliable representation set and the failure association representation set based on deployment trajectory data include steps S410 to S440.
[0109] Step S410: Based on the execution results of the trajectory-level task, determine the action blocks of the successful trajectories in the deployed trajectory data.
[0110] Based on the trajectory-level task execution results, identify the action blocks of successful trajectories in the deployment trajectory data. For successful trajectories, further determine whether the execution process is reliable. If there are instances of retrying after a failed capture, obvious collisions, recovery after incorrect placement, prolonged pauses, or other substantial intermediate deviations, the successful trajectory is marked as an unreliable successful trajectory and will not be used to construct a reliable successful prototype. Short-term motion jitter that does not affect task progress can be disregarded as an exclusion criterion.
[0111] Step S420: Perform time-series analysis on the failed trajectories in the deployment trajectory data to determine the earliest failure starting point in the action block of the failed trajectory that can still be corrected through subsequent action adjustments.
[0112] The temporal analysis can be performed using visual language models, manual annotation, rule-based judgment, change point detection, anomaly detection, or a multimodal model integrating vision, force, touch, and proprioception. For trajectories where the failure origin cannot be reliably determined, an uncertainty flag can be output, and the process can be handled by exclusion, expanding the conservative failure range, or manual review. The failure origin is the earliest deviation action block that appears and can still be corrected through subsequent action adjustments, not the moment when the task has irreversibly failed.
[0113] Step S430: The action blocks with indices less than the failure start point in the failed trajectory, and the action blocks in the successful trajectory in the deployment trajectory data, are included in the reliable representation set.
[0114] Step S440: Action blocks with indices greater than or equal to the failure start point in the failure trajectory are included in the failure association representation set.
[0115] To more clearly illustrate the construction of a locally successful prototype, combined with Figure 5 and Figure 6 As shown, the temporal partitioning of the failure trajectory and the construction process of the local success prototype in the embodiments of this application are fully explained.
[0116] like Figure 5 The diagram illustrates the temporal partitioning of action blocks in a reliable success trajectory. A reliable success trajectory contains a continuous sequence of action blocks from the initial action block t0 to the final action block t9, with each action block generating a corresponding action hidden representation during model inference. A failed deployment trajectory also contains multiple continuous action blocks, but a deviation begins at a certain action block; this deviation action block is the aforementioned failure starting point. The failure starting point is the earliest deviation action block that appears and can still be corrected through subsequent action adjustments, not the moment when the task has irreversibly failed.
[0117] like Figure 6 As shown, the failed deployment trajectory is divided into two regions, with the failure starting point as the boundary. The action hidden representations corresponding to the action blocks (i.e., reliable prefixes) before the failure starting point are included in the reliable representation set. Action blocks preceding the failure initiation point reflect the internal characteristics of the base model under normal operating conditions and should be preserved rather than modified. The action hidden representations corresponding to the failure initiation point and the action blocks following it (i.e., failure-related suffixes) are categorized into the failure-related representation set. The failure starting point and the action blocks following it reflect the deviation state where the base model begins to malfunction, and are objects that need to be intervened by residual adjustment. By transforming coarse trajectory-level failure labels into fine-grained action block-level partitions, the accuracy of the supervision signal is ensured, thus avoiding the mislabeling of all action blocks in the entire failure trajectory as failures.
[0118] The local success prototype construction process is based on a reliable success prototype pool and goes through three steps in sequence: L2 normalization, KNN (K-Nearest Neighbors) retrieval for the same task, and median aggregation of coordinates. Finally, it outputs the local success prototype corresponding to the current failure association representation.
[0119] Specifically, firstly, action-hidden representations of reliable successful trajectories are extracted from the reliable representation set according to the task, constructing a reliable success prototype pool. For each representation in the reliable success prototype pool and the failure association representation to be queried, L2 normalization is performed to eliminate scale differences between different representations, making subsequent distance metrics more reasonable. L2 normalization is achieved by dividing the vector by the L2 norm (adding a positive number to the denominator). To avoid division by zero, the normalized representation is located on the unit hypersphere, where the Euclidean distance and cosine distance are consistent.
[0120] Secondly, for the current failure association representation, it is retrieved from the normalized reliable success prototype pool of the corresponding task. The nearest neighbor representation. For a preset positive integer (e.g.) =20), representing the number of neighbors retrieved. Neighbor retrieval is based on Euclidean distance in the normalized representation space, that is, calculating the Euclidean distance between the normalized vector of the current failed association representation and each normalized vector in the prototype pool, and selecting the one with the smallest distance. Each representation is used as a neighborhood set. By limiting retrieval to the same task scope, the consistency between the prototype reference and the semantics of the current task is ensured.
[0121] Finally, for the retrieved The median of each nearest neighbor is taken to obtain the local success prototype. Specifically, for each dimension of the representation vector, the median of that dimension is taken. The median value is taken after sorting the nearest neighbors, thus forming the complete prototype vector. Using the median instead of the mean for aggregation can effectively resist the interference of a few abnormal neighbors, making the constructed locally successful prototype more robust and representative.
[0122] The locally successful prototype has the following characteristics:
[0123] First, the local success prototype changes dynamically with the failure associated with the current query, rather than remaining fixed. The failure representation in the approaching object stage will mainly refer to the approach state in the success trajectory, while the failure representation in the grabbing or placing stage will mainly refer to the success state of the corresponding stage, thus avoiding the problem of mixing different operation stages in a single task center.
[0124] Second, the local success prototype provides an explicit geometric correction reference for the failure representation. In the normalized representation space, the local success prototype represents the position that a successful internal representation should be in the vicinity of the current failure state. The goal of the candidate residuals generated by the residual experts is to make the corrected candidate representations closer to the local success prototype.
[0125] Third, since the local success prototype relies only on the representation of the reliable success trajectory, the local success prototype construction process does not require the failure trajectory to provide any corrective action, thus significantly reducing the cost of data acquisition and annotation.
[0126] Through the aforementioned temporal partitioning and prototype construction mechanism, the technical solution of this application transforms failed deployment trajectories with only trajectory-level task execution result labels into fine-grained training signals that can be used for supervised learning. A reliable representation set is used to supervise the router in selecting empty residual branches under reliable conditions, while a failure association representation set, combined with a local success prototype, is used to supervise the router in selecting appropriate residual experts and learning residual adjustment directions under failure conditions. This achieves effective training of the selective residual learning module without requiring the failed trajectory to provide correct action-by-action block actions.
[0127] In this way, by performing temporal analysis on the failed trajectory to determine the failure starting point, and dividing the action hidden representation into a reliable representation set and a failure-related representation set based on the failure starting point, fine-grained processing of trajectory-level failure result labels is achieved. The reliable prefix before the failure starting point is assigned to the reliable representation set, used to supervise the model in maintaining its basic strategy. The failure starting point and the failure-related representations after it are assigned to the failure-related representation set, used to supervise the model in learning residual adjustment. This avoids the pollution of the supervision signal caused by labeling the entire trajectory as a failure, making training more accurate and effective.
[0128] In some embodiments, the residual experts are lightweight neural networks. In a preferred embodiment, each residual expert is a SwiGLU bottleneck multilayer perceptron. Gated projection. and projection Will Dimensions are represented as mappings to Dimension, downward projection Remapping back The output of the residual expert is: .
[0129] in, and The dimension is , The dimension is ,symbol This indicates element-wise multiplication. For the bottleneck layer dimension; This is the activation function for the Sigmoid Linear Unit.
[0130] The parameters of the residual expert are initialized to near zero at the start of training, specifically by lower projection. Zero initialization is used, ensuring that the outputs of each non-empty residual expert are close to zero at the start of training. This ensures that the initial behavior of the selective residual learning module is consistent with the base model. Therefore, even if the router incorrectly selects a residual expert in the early stages of training, the candidate representation generated by that expert will be almost identical to the original hidden representation, without disrupting the existing correct behavior of the base model.
[0131] In this way, by initializing the downprojection of the residual experts with zero, the outputs of each non-empty residual expert are close to zero at the start of training, thus ensuring that the initial behavior of the selective residual learning module is consistent with the base model. Even if the router incorrectly selects a residual expert in the early stages of training, the candidate representations generated by the residual expert are almost identical to the original hidden representations, without disrupting the existing correct behavior of the base model. This provides a stable starting point for the training process, which is beneficial for model convergence.
[0132] In some embodiments, such as Figure 7 As shown, the steps for constructing a local success prototype based on a reliable representation set include steps S710 to S720.
[0133] Step S710: Extract the representation of the reliable success trajectory from the reliable representation set according to the task, normalize the representation of the reliable success trajectory, and construct the normalized reliable success prototype pool.
[0134] Specifically, L2 normalization is used to represent reliable success trajectories, and the normalization formula is as follows: ,in, It should be a positive number to avoid division by zero.
[0135] Step S720: For the failure association representations in the failure association representation set, normalize the failure association representations, and retrieve a preset number of neighboring representations from the normalized reliable success prototype pool of the corresponding task. Take the median of each coordinate of the neighboring representations to obtain the local success prototype.
[0136] Among them, a preset number (e.g.,) are retrieved from the normalized reliable successful prototype pool of the corresponding task. The nearest neighbor representation of ) .
[0137] By taking the median of each of the Kn nearest neighbors, we obtain the local success prototype: .
[0138] Using the median instead of the mean for aggregation effectively resists interference from a few abnormal neighboring points, making the constructed local success prototype more robust and representative. The local success prototype changes with the current query representation; failure representations in the approach-to-object stage mainly refer to the approach state in the success trajectory, while failure representations in the grab or place stage mainly refer to the success state of the corresponding stage, thus avoiding a single task center mixing different operation stages.
[0139] In this way, by retrieving neighboring representations from a pool of reliable successful prototypes and constructing local successful prototypes by taking the median for each coordinate, a local corrective reference for failure-related representations is provided within the same task and operational stage. Using the median instead of the mean for aggregation resists interference from a few abnormal neighboring points, making the constructed local successful prototypes more robust and representative.
[0140] In some embodiments, during the training of the selective residual learning module in the control model using the successful demonstration hidden representation, the reliable representation set, the failure association representation set, and the local success prototype, the loss function used includes at least one of the following: successful demonstration supervision loss, reliable state preservation loss, failure representation redirection loss, and residual magnitude constraint loss.
[0141] Among them, the successful demonstration supervision loss is used to measure the error between the candidate residual output by the residual expert and the target action, ensuring that the correction direction generated by the residual expert is correct and can lead to a successful action.
[0142] The reliable state preservation loss is used to encourage the representations in the reliable representation set to choose empty residual branches, thus encouraging the router to not intervene when encountering a reliable state, thereby protecting the inherent performance of the underlying model.
[0143] The failure representation redirection loss is used to encourage representations in the failure associated representation set to select residual experts and move closer to the local success prototype. On the one hand, it guides the router to activate experts in the failure state, and on the other hand, it guides the activated experts to generate residuals that can pull the hidden representations toward the success prototype.
[0144] The residual magnitude constraint loss is used to limit the norm of the candidate residuals output by the residual expert, ensuring that the magnitude of the correction is local and limited, and preventing over-correction from causing new problems.
[0145] During training, the above losses are weighted and summed, and the total loss is: .
[0146] .
[0147] in, To successfully demonstrate and monitor losses, To maintain a reliable state, Failure indicates the loss from redirection. For residual amplitude constraint loss, , , The weights are non-negative.
[0148] Thus, multi-objective training of the selective residual learning module is achieved through the joint optimization of successful demonstration supervision loss, reliable state preservation loss, failure representation redirection loss, and residual magnitude constraint loss. Successful demonstration supervision loss ensures the correctness of the residual correction direction, reliable state preservation loss protects the reliable behavior of the basic strategy, failure representation redirection loss guides the router to activate experts and generate effective corrections in failure states, and residual magnitude constraint loss limits the correction magnitude. These four losses work together to enable the model to possess adaptive correction capabilities while maintaining basic performance.
[0149] In some embodiments, such as Figure 8 As shown, the calculation of the monitoring loss for a successful demonstration includes steps S810 to S830.
[0150] Step S810: Calculate the basic candidate error and the residual expert candidate error.
[0151] Among them, the basic candidate error is the error between the candidate representation corresponding to the empty residual branch and the target action, and the residual expert candidate error is the error between the candidate representation corresponding to the residual expert and the target action.
[0152] Calculate the basic candidate error and the residual expert candidate error, assuming the projection of the freeze action is... The target action is u. The empty residual branch corresponds to the basic candidate. Residual expert corresponding candidate .
[0153] Basic candidate error and the One residual candidate error for: .
[0154] ,in, .
[0155] Step S820: Generate expert responsibility weights based on residual expert candidate errors. The expert responsibility weights are negatively correlated with residual expert candidate errors.
[0156] Expert responsibility weights are generated based on the residual expert candidate errors, and these weights are negatively correlated with the residual expert candidate errors. This is done according to the positive temperature hyperparameter. Convert the action error of non-empty residual candidates into expert responsibility weights. : .
[0157] Step S830: The expert action supervision loss is obtained by weighting and summing the residual expert candidate errors according to the expert responsibility weight.
[0158] The expert action supervision loss is obtained by weighting and summing the residual expert candidate errors according to the expert responsibility weights. .symbol This indicates that the gradient operator is stopped, and the expert responsibility weights are only used as weights and are not backpropagated through the weights themselves. .
[0159] If none of the non-empty residual candidates are better than the base candidate, then the demonstration route target selects the empty residual branch; otherwise, the residual experts are selected according to their responsibility weights. Assign responsibility weights. Let... As an indicator function, a sample route target vector is provided. Defined as: , , .
[0160] .
[0161] .
[0162] in, To balance cross-entropy between categories, This demonstrates the route loss weights.
[0163] During the initial preheating stage, let This makes the weight of responsibility only applicable to The assignment is done among non-empty residual experts, meaning empty residual branches are disabled during the initial warm-up phase. After the warm-up, empty residual branches are allowed to be selected according to the above formula. The purpose of the warm-up phase is to avoid all training samples being routed to empty residual branches too early, so that each residual expert with zero initialization can obtain action supervision from successful demonstrations.
[0164] In this way, differentiated supervision of successful demonstrations is achieved by calculating the basic candidate error and the residual expert candidate error, and generating expert responsibility weights based on the candidate errors. The expert responsibility weights are negatively correlated with the candidate errors, allowing better-performing residual experts to receive higher learning weights. During the warm-up phase, responsibility weights are forced to be allocated only among non-empty residual experts, preventing all training samples from being routed to empty residual branches too early, and ensuring that each zero-initialized residual expert can obtain effective action supervision from successful demonstrations.
[0165] In some embodiments, reliable state retention loss Includes: log-likelihood term The residual energy penalty term and the log-likelihood term are used to increase the probability of a reliable representation selecting an empty residual branch: The residual energy penalty term is used to penalize the product of the routing probability of each non-empty branch and the residual energy of the non-empty branch when selecting a non-empty residual branch for a reliable representation: .
[0166] The expression for the loss integrity of reliable state maintenance is: .
[0167] The reliable state preservation loss prioritizes preserving the hidden representation of basic actions in reliable states and minimizes the disturbances caused by erroneous selection of non-empty branches, thereby protecting the existing reliable behavior of the basic policy.
[0168] In this way, the probability of selecting an empty residual branch is increased by the log-likelihood term, while the residual energy penalty term is used to penalize the residual energy when a non-empty branch is mistakenly selected. This ensures that the model prioritizes maintaining the hidden representation of the basic action in a reliable state and minimizes the disturbance caused by the mistaken selection of a non-empty branch. This effectively protects the existing reliable behavior of the basic policy and prevents the addition of modules from causing unnecessary interference to the normal state.
[0169] In some embodiments, failure indicates a redirection loss. This includes: route cross-entropy term and distance improvement interval term.
[0170] Routing cross-entropy term This is used to make the routing target of the failure association representation approximate the output probability distribution of the router.
[0171] In a unified normalized representation space, compare the current action hidden representation to the local success prototype before and after applying candidate residuals. The distance changes. Let... For the first The improvement in the prototype distance of each candidate; if the candidate represents If the representation h is closer to the local success prototype than the original representation h, then Then, subtract the residual magnitude cost from the improvement amount to obtain the candidate utility. : .
[0172] .
[0173] .
[0174] ,in, .
[0175] When the maximum efficiency does not exceed the threshold m, the target route selects an empty residual branch; otherwise, a residual expert soft responsibility is generated based on the efficiency and positive temperature T. , As the routing target for stopping gradients.
[0176] The routing cross-entropy term is: .
[0177] Distance Improvement Interval Item This is used to ensure that the improvement in distance between the candidate representation corresponding to the selected residual expert and the local success prototype is not less than a preset interval. .
[0178] in, express .
[0179] Failure indicates that the redirection loss is: .
[0180] in, The residual magnitude cost weight; The utility threshold is T; T is the positive temperature. This is the interval threshold; The interval loss weights are used.
[0181] Failure indicates that redirection loss prompts the selection of appropriate residual experts and a move towards a locally successful prototype of the same task, while ensuring the directionality and effectiveness of residual adjustment.
[0182] In this way, the routing cross-entropy term makes the routing target of the failed association representation close to the output probability distribution of the router, while the distance improvement interval term ensures that the distance improvement between the candidate representation corresponding to the selected residual expert and the local success prototype is not less than the preset interval. This prompts the failed association representation to select an appropriate residual expert and move closer to the local success prototype of the same task, ensuring the directionality and effectiveness of residual adjustment, and making the corrected hidden representation closer to the ideal representation in the successful state.
[0183] This application also provides a robot, which includes a controller configured to execute the control method described above.
[0184] For example, a robot includes sensors, a controller, and actuators. Sensors collect observation data and transmit it to the controller. The controller runs a trained control model, executes the control methods described above, and generates motion prediction results. Actuators (such as robot joint motors, grippers, etc.) perform the actions corresponding to the motion prediction results.
[0185] In a specific example, the robot employs a dual-arm manipulator platform consisting of two six-DOF robotic arms and two parallel grippers. Visual observation is provided by a camera mounted above the robot's workspace and two RGB cameras mounted on the two robotic wrists respectively. Inference runs online on the GPU (Graphics Processing Unit). For example, the control model predicts a dual-arm joint space motion and gripper commands comprising 50 control steps each time. It executes the first 25 control steps and then predicts the next action block based on the updated visual observation, thus forming a rolling closed-loop control.
[0186] The robot can perform long-term tasks, such as sorting color blocks, placing objects in designated positions, stacking bowls, and folding cloth. By applying the control method of this application, it can exhibit stronger robustness and task completion ability when facing environmental changes and unexpected disturbances.
[0187] This application also provides an electronic device, which includes a memory and a processor. The memory stores instructions. The processor invokes the instructions stored in the memory to execute the aforementioned control method.
[0188] The memory can be used to store successful demonstration data, deployment trajectory data, trained router parameters, and residual expert parameters. The processor executes instructions stored in the memory to implement the aforementioned control method.
[0189] This application also provides a computer program product, which causes the above-described control method to be executed when a computer reads and executes the computer program product.
[0190] The computer program product can be a software package or SDK (Software Development Kit), or it can be a computer program stored on a computer-readable storage medium (such as a USB flash drive, solid-state drive, optical disc, or cloud storage space).
Claims
1. A motion control method, characterized in that, include: Acquire observation data and task instructions, input the observation data and task instructions into the model backbone of the trained control model, and generate a hidden representation of the current action; wherein, the control model includes the model backbone, a selective residual learning module, and an action output module, the selective residual learning module includes a router, an empty residual branch, and at least one residual expert, the parameters of the model backbone and the action output module are kept frozen during the training of the control model, and the training data of the control model includes failure trajectories, the failure trajectories are used to train the selective residual learning module so that the selective residual learning module learns the action adjustment direction and residual branch selection strategy; The current action is hidden from input to the router, generating a branch selection signal; When the branch selection signal indicates that the empty residual branch is selected, the current action hiding representation is input to the action output module; When the branch selection signal characterizes the selection of a target residual expert among the at least one residual experts, a candidate residual quantity is generated by the target residual expert based on the current action concealment representation; and the current action concealment representation and the candidate residual quantity are superimposed to form a candidate representation, and the candidate representation is input to the action output module; The action output module generates an action prediction result based on the current action hidden representation or the candidate representation.
2. The control method according to claim 1, characterized in that, The router includes a normalization layer and a linear classification header; The step of hiding the current action input to the router and generating a branch selection signal includes: The normalization layer is used to normalize the current action hidden representation to generate a normalized current action hidden representation. The linear classification head maps the hierarchical normalized current action hidden representation to... Each category score, The number of residual experts; according to The classification scores are used to generate selection probabilities for selecting the empty residual branch and the residual expert. The branch selection signal is output based on the selection probability.
3. The control method according to claim 1, characterized in that, The control model was trained using the following method: Acquire successful demonstration hidden representations and deployment trajectory data. The successful demonstration hidden representations are generated by a pre-trained base model from the visual observations and language task instructions in the successful demonstrations and are associated with the target actions in the successful demonstrations. The deployment trajectory data includes action blocks that are synchronously saved by the pre-trained base model when it is executed in the target task environment, as well as trajectory-level task execution results associated with the action blocks. Based on the deployment trajectory data, a reliable representation set and a failure association representation set are determined. The reliable representation set corresponds to the action block of the basic model in a reliable execution state, and the failure association representation set corresponds to the action block of the basic model in a deviated execution state. A local success prototype is constructed based on the reliable representation set, wherein the local success prototype is an aggregation of reliable representations that are spatially adjacent to the action blocks in the failure-associated representation set; The control model is obtained by setting a selective residual learning module between the model backbone of the basic model and the action output module; Using the successful demonstration hidden representation, the reliable representation set, the failure association representation set, and the local success prototype, the selective residual learning module in the control model is trained to obtain the trained control model.
4. The control method according to claim 3, characterized in that, The step of determining the reliable representation set and the failure association representation set based on the deployment trajectory data includes: Based on the execution results of the trajectory-level task, determine the action blocks of the successful trajectories in the deployed trajectory data; Perform time-series analysis on the failed trajectories in the deployment trajectory data to determine the earliest failure starting point in the action block of the failed trajectory that can still be corrected by subsequent action adjustments. Action blocks with indices less than the failure starting point in the failed trajectory, and action blocks in the successful trajectory in the deployment trajectory data, are included in the reliable representation set. Action blocks with indices greater than or equal to the failure starting point in the failure trajectory are included in the failure association representation set.
5. The control method according to claim 3, characterized in that, The residual expert is a lightweight neural network. The parameters of the residual expert are initialized to zero at the beginning of training so that the initial output is close to zero, so that the initial behavior of the selective residual learning module is consistent with the base model.
6. The control method according to claim 3, characterized in that, The step of constructing a local success prototype based on the reliable representation set includes: From the set of reliable representations, the representations of reliable success trajectories are extracted according to the task, and the representations of the reliable success trajectories are normalized to construct a normalized reliable success prototype pool. For the failure association representations in the failure association representation set, the failure association representations are normalized, and a preset number of neighboring representations are retrieved from the normalized reliable success prototype pool of the corresponding task. The median of each coordinate of the neighboring representations is taken to obtain the local success prototype.
7. The control method according to claim 3, characterized in that, In the process of training the selective residual learning module in the control model and generating the control model using the successful demonstration hidden representation, the reliable representation set, the failure association representation set, and the local success prototype, the loss function used includes at least one of the following: Successful demonstration of supervised loss is used to measure the error between the candidate residual output by the residual expert and the target action; A reliable state preservation loss is used to prompt a representation in the reliable representation set to select the empty residual branch; The failure represents a redirection loss, which is used to prompt the representations in the set of failure-associated representations to select the residual expert and move closer to the local success prototype; The residual magnitude constraint loss is used to limit the norm of the candidate residuals output by the residual expert.
8. The control method according to claim 7, characterized in that, The calculation of the successful demonstration supervision loss includes: Calculate the basic candidate error and the residual expert candidate error, wherein the basic candidate error is the error between the candidate representation corresponding to the empty residual branch and the target action, and the residual expert candidate error is the error between the candidate representation corresponding to the residual expert and the target action; Expert responsibility weights are generated based on the residual expert candidate errors, and the expert responsibility weights are negatively correlated with the residual expert candidate errors; The expert action supervision loss is obtained by weighting and summing the residual expert candidate errors according to the expert responsibility weights.
9. The control method according to claim 7, characterized in that, The reliable state maintenance loss includes: The log-likelihood term is used to increase the probability of reliably representing the selection of the empty residual branch; The residual energy penalty term is used to penalize the product of the routing probability of each non-empty branch and the residual energy of the non-empty branch when selecting a non-empty residual branch for a reliable representation.
10. The control method according to claim 7, characterized in that, The failure indicates that the redirection loss includes: The routing cross-entropy term is used to make the route destination represented by the failed association close to the output probability distribution of the router; The distance improvement interval term is used to ensure that the distance improvement between the candidate representation corresponding to the selected residual expert and the local success prototype is not less than a preset interval.
11. A robot, characterized in that, Including the controller; The controller is configured to perform the control method according to any one of claims 1 to 10.
12. An electronic device, characterized in that, include: Memory, used to store instructions; A processor is configured to invoke instructions stored in the memory to execute the control method according to any one of claims 1 to 10.
13. A computer program product, characterized in that, When the computer reads and executes the computer program product, the control method of any one of claims 1 to 10 is executed.
