Responsive Planning and Recognition for Closed-Loop Interaction