<commit_before>
require 'ezcrypto'
require 'ezsig'

module Bixby
class Agent

module Crypto

    # create crypto keypair and save in config folder
    def create_keypair
      init_config_dir()
      pair = EzCrypto::Signer.generate
      File.open(private_key_file, 'w') { |out| out.write(pair.private_key.to_s) }
      File.open(public_key_file, 'w') { |out| out.write(pair.public_key.to_s) }
    end

    def private_key_file
      File.join(self.config_dir, "id_rsa")
    end

    def public_key_file
      File.join(self.config_dir, "id_rsa.pub")
    end

    def keypair
      @keypair ||= EzCrypto::Signer.from_file(private_key_file)
    end

    def public_key
      self.keypair.public_key.to_s
    end

    def private_key
      self.keypair.private_key.to_s
    end

end # Crypto

end # Agent
end # Bixby<commit_msg>fixed indentation to two spaces<commit_after>
require 'ezcrypto'
require 'ezsig'

module Bixby
class Agent

module Crypto

  # create crypto keypair and save in config folder
  def create_keypair
    init_config_dir()
    pair = EzCrypto::Signer.generate
    File.open(private_key_file, 'w') { |out| out.write(pair.private_key.to_s) }
    File.open(public_key_file, 'w') { |out| out.write(pair.public_key.to_s) }
  end

  def private_key_file
    File.join(self.config_dir, "id_rsa")
  end

  def public_key_file
    File.join(self.config_dir, "id_rsa.pub")
  end

  def keypair
    @keypair ||= EzCrypto::Signer.from_file(private_key_file)
  end

  def public_key
    self.keypair.public_key.to_s
  end

  def private_key
    self.keypair.private_key.to_s
  end

end # Crypto

end # Agent
end # Bixby
{'fraction_non_alphanumeric': 0.0945945945945946, 'fraction_numerical': 0.0, 'mean_word_length': 3.320954907161804, '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': '4807232', 'n_tokens_mistral': 628, 'n_tokens_neox': 603, 'n_words': 127}