Skip to main content
Drift CLI accepts two types of input: natural language prompts and slash commands. Natural language prompts are interpreted by the AI Agent. Slash commands execute immediately without AI processing.

Slash Commands

CommandDescription
/helpShow comprehensive help with all commands and usage examples
/versionDisplay the current Drift CLI version
/updateUpdate Drift CLI to the latest available version
/psShow all running background processes (ROS2 nodes, Gazebo, etc.)
/clearClear the terminal screen
/exitExit Drift CLI

CLI Flags

These flags are used when launching Drift from your shell (not from the drift> prompt):
FlagDescription
drift --helpShow help information
drift initInitialize a new Drift project in the current directory
drift simulateStart a simulation directly (skips the interactive prompt)
drift -c "<prompt>"Run a single prompt non-interactively and exit

drift init

Run drift init in an empty directory to scaffold a new project. Drift will set up the workspace structure it expects — including ROS2 package layout and configuration — so that subsequent prompts inside the drift> shell have a clean starting point. Use this when you want to start a project in a specific directory rather than letting Drift create the workspace from the first prompt.
mkdir my-robot && cd my-robot
drift init
drift  # open the interactive shell in the initialized project

drift simulate

Run drift simulate to launch a simulation from the command line without entering the interactive drift> shell. This is useful for scripting or CI scenarios where you want to start a pre-built simulation non-interactively.
drift simulate
If no project is found in the current directory, Drift will prompt you to run drift init first.

drift -c "<prompt>"

Run a single prompt non-interactively — Drift executes the task, auto-approves all steps, and exits cleanly when done. Useful for CI pipelines, batch testing, or quick one-offs from a script.
drift -c "create a ROS2 package called sensor_fusion with ament_python build type"
drift -c "add a lidar to my robot's URDF at position 0 0 0.3"
drift -c "build the workspace and run the tests"

Natural Language Commands

At the drift> prompt, you can type any request in plain English. Here are the main categories:

Create

ExampleWhat it does
create a differential drive robot with a lidar and cameraGenerates URDF with wheel geometry, sensor mounts, Gazebo plugins, and launch files
create a six-axis manipulator with a gripperScaffolds full robot description with controller configs and launch files
create a warehouse environmentGenerates a Gazebo world file with warehouse objects
setup a pick-and-place simulationCreates a complete simulation with robot, world, and launch files

Modify

ExampleWhat it does
add a lidar sensor to my robot at position 0 0 0.3 and rebuildUpdates URDF, configures Gazebo plugin, rebuilds workspace
add an IMU sensor and update the launch file to bridge the IMU topicEdits URDF, bridge config, and launch file in one coordinated change
change the gripper to a suction cupUpdates the robot’s end effector configuration
add obstacles to my worldModifies the Gazebo world file

Launch

ExampleWhat it does
launch my robot in Gazebo with the warehouse world and open RVizStarts Gazebo, spawns robot, opens RViz with the right config, bridges topics
create a launch file that starts Gazebo, spawns my robot, and bridges cmd_vel and odomGenerates a correct Python launch file with TimerAction for spawn and ros_gz_bridge

Inspect

ExampleWhat it does
what topics is my robot publishing?Lists all active ROS2 topics
echo the lidar scan dataStreams live output from the specified topic
set the max_velocity parameter on the navigation node to 1.5Sets a ROS2 node parameter directly
run ros2 doctorChecks your ROS2 environment for common issues

Build

ExampleWhat it does
build my workspace and fix any errorsRuns colcon, reads errors, edits CMakeLists.txt / package.xml / setup.py as needed
what went wrong with the last build?Analyzes build output and explains the root cause
find all launch files in my workspaceSearches across packages and lists matching files

Debug

ExampleWhat it does
why is my robot not moving when I publish to cmd_vel?Checks topic connections, QoS compatibility, and controller chain
why isn't my camera publishing images?Inspects topic list, sensor config, and Gazebo plugin setup
my robot spawns but falls through the ground — fix itValidates URDF inertia tensors and collision geometry

Quick Reference

What you needWhat to say
New robot projectcreate a mobile robot with differential drive and a depth camera
Fix a broken buildbuild my workspace and fix the errors
Debug simulationmy robot spawns but doesn't move — figure out why
Sensor setupadd a 2D lidar to my robot and bridge it to ROS2
Launch configurationgenerate a launch file for my robot in Gazebo with RViz
ROS2 inspectionlist all active topics and show me what /camera/image_raw is publishing
Parameter tuningset the PID gains on the left wheel controller to P=10 I=0.1 D=0.5
File operationsfind all launch files in my workspace and show me which ones use Gazebo
Quick automationdrift -c "create a test world with 10 random obstacles"

Execution Control

Pausing mid-execution

Press ESC at any point during a multi-step execution to pause. Drift remembers exactly what’s been completed and what’s still pending — nothing is lost. When paused, you’ll be prompted to choose how to proceed:
OptionWhat it does
Approve this stepRun the next pending command and pause again
Approve all (this task)Continue without interruption until the current task is done
Approve all (session)Run everything for the rest of the session without asking
CancelStop execution and return to the drift> prompt
This gives you full control over how much autonomy Drift has — step through carefully when trying something new, or let it run freely once you’re confident.

Auto-Update

When a new version is available, Drift shows a notification on startup:
ℹ️ A new version (x.x.x) is available. Type /update to install.
Run /update to install the latest version.