<commit_before>module Hackbot
  module Conversations
    class Mention < Hackbot::Conversations::Channel
      def self.should_start?(event, team)
        event[:type] == 'message' &&
          (event[:text].include?(team[:bot_username]) ||
           event[:text].include?("<@#{team[:bot_username]}>"))
      end

      def start(_event)
        msg_channel 'Did someone mention me?'

        :wait_for_resp
      end

      def wait_for_resp(event)
        if event[:text] =~ /^(no|nope|nah|negative)$/i
          msg_channel 'Oh, I see... :slightly_frowning_face:'
        elsif event[:text] =~ /^(yes|yeah|yah|ya|yup)$/i
          msg_channel "Oh my! I'm so glad to hear... I was getting a little "\
                      'worried for a moment there.'
        end

        :finish
      end
    end
  end
end<commit_msg>Fix Mention should_start? for @mentions<commit_after>module Hackbot
  module Conversations
    class Mention < Hackbot::Conversations::Channel
      def self.should_start?(event, team)
        event[:type] == 'message' &&
          (event[:text].include?(team[:bot_username]) ||
           event[:text].include?("<@#{team[:bot_user_id]}>"))
      end

      def start(_event)
        msg_channel 'Did someone mention me?'

        :wait_for_resp
      end

      def wait_for_resp(event)
        if event[:text] =~ /^(no|nope|nah|negative)$/i
          msg_channel 'Oh, I see... :slightly_frowning_face:'
        elsif event[:text] =~ /^(yes|yeah|yah|ya|yup)$/i
          msg_channel "Oh my! I'm so glad to hear... I was getting a little "\
                      'worried for a moment there.'
        end

        :finish
      end
    end
  end
end
{'fraction_non_alphanumeric': 0.13389121338912133, 'fraction_numerical': 0.0, 'mean_word_length': 2.275929549902153, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '966359', 'n_tokens_mistral': 539, 'n_tokens_neox': 522, 'n_words': 125}