Target action recognition and refactoring.