recovery-behavior-tree

Designs Nav2 recovery behavior trees for stuck detection and navigation failure resolution.

Updated Aug 16, 2026
One-click install
npx skills add https://github.com/three1324/yeonjinautomotive --skill recovery-behavior-tree-three1324
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: recovery-behavior-tree
Source: https://github.com/three1324/yeonjinautomotive/tree/main/.claude/skills/recovery-behavior-tree
Command: npx skills add https://github.com/three1324/yeonjinautomotive --skill recovery-behavior-tree-three1324

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Autonomous robots get stuck when navigation fails due to obstacles, bad costmaps, or unreachable goals. This Skill provides proven behavior tree patterns for building recovery sequences that detect failures and escalate through corrective actions automatically. ## Core Features & Use Cases - RecoveryNode Patterns: Complete XML templates for Nav2's RecoveryNode architecture, wrapping normal navigation with fallback recovery branches. - Escalating Recovery Strategies: RoundRobin sequences cycling through costmap clearing, spinning, waiting, and backing up with increasing aggressiveness. - Common Mistake Prevention: Documents pitfalls like infinite recovery loops, blocking waits, and missing GoalUpdated circuit breakers. - Use Case: A warehouse robot repeatedly fails to reach a goal because a pallet blocks its path. Use this Skill to build a behavior tree that clears costmaps, spins to update sensor readings, waits for the obstacle to move, and backs up as a last resort. ## Quick Start Ask the AI to design a Nav2 recovery behavior tree with escalating fallback strategies for a robot that gets stuck on unexpected obstacles.

Frequently Asked Questions about recovery-behavior-tree

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I build a recovery behavior tree in Nav2?

Use a RecoveryNode with two children: the normal navigation pipeline on the left and recovery actions on the right. When navigation fails, the recovery branch runs actions like clearing costmaps, spinning, or backing up, then retries navigation up to the configured number_of_retries.

What is the difference between PipelineSequence and Sequence in Nav2?

PipelineSequence re-ticks all previous children when a later child is ticked, enabling the planner to re-plan while the controller follows the path. A standard Sequence ticks children strictly in order without re-execution, so it cannot support continuous replanning.

Why does my Nav2 recovery loop run forever?

Infinite recovery loops happen when recovery always succeeds but navigation always fails, such as with an unreachable goal. Set number_of_retries to a reasonable value like 3-6 and let failure propagate to a higher-level tree that can select a different goal.

How do I cancel recovery when a new goal arrives?

Place a GoalUpdated node as the first child of a ReactiveFallback wrapping your recovery actions. When a new goal arrives, GoalUpdated returns SUCCESS, short-circuiting the recovery so the tree immediately retries navigation toward the new goal.

What recovery actions does Nav2 support for stuck robots?

Nav2 provides ClearEntireCostmap for resetting global and local costmaps, Spin for rotating in place, Wait for pausing while obstacles clear, and BackUp for reversing a fixed distance. These are typically cycled through a RoundRobin node with escalating aggressiveness.