TL;DR
NeSyCR (Neurosymbolic Counterfactual Reasoning) is a novel framework that allows robots to successfully execute tasks from video demonstrations even when the deployment environment or robot body changes. By combining the commonsense reasoning of Vision-Language Models (VLMs) with rigorous symbolic verification, it identifies where domain gaps break a plan and automatically rewrites the underlying code policy to ensure success.
What Problem Does This Paper Address?
Video-instructed robotic programming—where a robot watches a video demonstration (often of a human) and generates executable control code—is a powerful paradigm for general-purpose robots. However, it is highly fragile when faced with domain gaps.
When a robot is deployed in the real world, the environment layout, object affordances, or the robot's own physical body (embodiment) will inevitably differ from the video demonstration. For example, a human in a video might easily pick up scattered screws with their fingers, but a robot with a large parallel gripper will fail. Current Vision-Language Models (VLMs) lack the deep causal and procedural understanding required to adapt. They tend to mimic the demonstration too closely, leading to catastrophic failures when physical preconditions are violated.
Methods
NeSyCR solves this by framing cross-domain adaptation as a counterfactual reasoning problem ("How would the task outcome change under these altered conditions, and what actions must change to fix it?"). It operates in two main phases:
- Symbolic World Model Construction: The framework uses a VLM to translate the video demonstration into a sequence of symbolic states (scene graphs) and abduces action operators (preconditions and effects) using a STRIPS-style formalism. A symbolic tool (such as a PDDL validator) verifies these transitions to ensure the generated world model is logically consistent.
- Neurosymbolic Counterfactual Adaptation: Given a new deployment observation, the VLM generates a counterfactual initial state. The symbolic tool then runs a forward simulation of the original plan from this state. When a precondition fails (e.g., a tool is missing or an object is blocked), the VLM steps in to propose alternative actions (inserting, removing, or reordering steps). The symbolic tool iteratively verifies these proposals until a logically sound, adapted procedure is achieved, which is then compiled into a Python code policy.
Datasets
The authors evaluated NeSyCR using both simulation and real-world setups:
- Genesis Simulation Platform: A benchmark consisting of 440 evaluation scenarios split across three complexity levels (Low, Medium, High). It systematically tests five domain factors: Obstruction (interfering objects), Object Affordance (altered states), Kinematic Configuration (robot joint structures), Gripper Type (suction vs. finger gripper), and a Combination of all factors. Tasks included Pick&Place, Sweep, Rotate, and Slide.
- Real-World Evaluation: Conducted on a physical 7-DoF Franka Emika Research 3 robotic arm. The demonstrations consisted of human-performed video recordings of a drawer-organizing task.
Key Insights and Ideas
- The Neurosymbolic Loop: Pure VLM approaches are prone to hallucinating physically impossible actions, while pure symbolic planners struggle with raw visual inputs and open-world common sense. NeSyCR pairs them perfectly: the VLM acts as an intuitive proposal engine, while the symbolic tool acts as an absolute logical filter.
- Procedural Reordering: Instead of just replacing actions one-for-one, NeSyCR can completely reorder a task sequence. If an object needed later in the task obstructs an action needed now, the framework recognizes the cascading incompatibility and restructures the workflow.
- Handling Implicit Constraints: In real-world testing with perpendicular drawers, opening one drawer blocked the other. NeSyCR explicitly encoded this mutual interference as a symbolic precondition, successfully alternating drawer operations where baseline models failed.
Key Results
- Massive Success Rate Improvements: NeSyCR achieved an average 31.14% improvement in task success rate over the strongest baseline, Statler, and significantly outperformed direct demo-to-code methods like Demo2Code.
- Robustness to Domain Gaps: As shown in the paper's analysis, when environmental and physical variations were scaled from "Small" to "Large," NeSyCR maintained a high success rate and low procedure deviation, whereas pure VLM baselines suffered sharp performance drops.
- Real-World Viability: In physical robot deployments under complex constraints, NeSyCR achieved an 87.50% success rate, compared to 50% for Statler and GPT4V-Robotics, and 0% for Demo2Code.
Limitations and Future Work
- Complexity Thresholds: If the task complexity gap between the demonstration and deployment becomes too wide (e.g., requiring too many entirely new subtasks), counterfactual reasoning alone degrades. At a certain point, the original demonstration ceases to provide useful guidance, and a completely new demonstration becomes necessary.
- Future Work: The authors aim to extend this boundary by incorporating causal re-grounding, which would enable the robot to autonomously infer entirely new causal relationships in novel contexts rather than just modifying pre-existing symbolic structures.
Summary updated