<commit_before>class Subject 
  include Mongoid::Document
  include Randomizer


  field :name, type: String
  field :url , type: String
  field :random_no , type: Float
  field :classification_count, type: Integer, default: 0
  field :retire_count, type: Integer, default: 0
  field :state , type: String, default: "active"
  field :type,   type: String, default: "root" 
  field :metadata,   type: Hash



  has_and_belongs_to_many :workflows, inverse_of: nil
  has_one :parent_subject, :class_name => "Subject"

  def increment_retire_count_by(no)
    retire_count += 1
    save
    retire! if retire_count > workflow.retire_limit
  end

  def retire!
    state="inactive"
    save
  end
end

<commit_msg>non protected word for meta_data<commit_after>class Subject 
  include Mongoid::Document
  include Randomizer


  field :name, type: String
  field :url , type: String
  field :random_no , type: Float
  field :classification_count, type: Integer, default: 0
  field :retire_count, type: Integer, default: 0
  field :state , type: String, default: "active"
  field :type,   type: String, default: "root" 
  field :meta_data,   type: Hash



  has_and_belongs_to_many :workflows, inverse_of: nil
  has_one :parent_subject, :class_name => "Subject"

  def increment_retire_count_by(no)
    retire_count += 1
    save
    retire! if retire_count > workflow.retire_limit
  end

  def retire!
    state="inactive"
    save
  end
end


{'fraction_non_alphanumeric': 0.08635097493036212, 'fraction_numerical': 0.004178272980501393, 'mean_word_length': 3.9381443298969074, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, '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': '5285376', 'n_tokens_mistral': 491, 'n_tokens_neox': 465, 'n_words': 144}