<commit_before>require 'sg_mailer/configuration_error'
require 'sg_mailer/response_error'
require 'sg_mailer/mail_builder'
require 'sg_mailer/client'
require 'sg_mailer/message_delivery'
require 'sg_mailer/base'

module SGMailer extend self
  attr_accessor :client

  def send(mail)
    raise ConfigurationError if client.nil?

    client.send(mail)
  end
end<commit_msg>Introduce the configuration API<commit_after>require 'sg_mailer/configuration_error'
require 'sg_mailer/response_error'
require 'sg_mailer/mail_builder'
require 'sg_mailer/client'
require 'sg_mailer/message_delivery'
require 'sg_mailer/base'

module SGMailer extend self
  def configure(**options)
    self.client = Client.new(**options)
  end

  def send(mail)
    raise ConfigurationError if client.nil?

    client.send(mail)
  end

  private

  attr_accessor :client
end
{'fraction_non_alphanumeric': 0.08165680473372781, 'fraction_numerical': 0.0, 'mean_word_length': 5.661417322834645, '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': '1407163', 'n_tokens_mistral': 285, 'n_tokens_neox': 276, 'n_words': 62}