Add protocol detector logic