<commit_before>require 'set'
require_relative '../domain/resources/token'
require_relative '../domain/resource_bag'

class Node

  def initialize_copy(orig)
    super

    #need to clone the resource bag as well...
    @resources = @resources.clone()

    #don't need this. takes too much space
    @diagram = nil

  end

end<commit_msg>Add locking behaviour.<commit_after>require 'set'
require_relative '../domain/resources/token'
require_relative '../domain/resource_bag'

class Node

  include Invariant

  def initialize_copy(orig)
    super

    #need to clone the resource bag as well...
    @resources = @resources.clone()

    #don't need this. takes too much space
    @diagram = nil

  end

end
{'fraction_non_alphanumeric': 0.10085227272727272, 'fraction_numerical': 0.0, 'mean_word_length': 3.3251533742331287, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '2794801', 'n_tokens_mistral': 214, 'n_tokens_neox': 201, 'n_words': 67}