You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: file_metadata_listener.rb
    path of file: ./repos/hyrax/app/services/hyrax/listeners
    
    the code of the file until where you have to start completion: # frozen_string_literal: true

module Hyrax
  module Listeners
    ##
    #
    
      def on_file_characterized(event)
        file_set = event[:file_set]

        case file_set
        when ActiveFedora::Base # ActiveFedora
          CreateDerivativesJob
            .perform_later(file_set, event[:file_id], event[:path_hint])
        else
          ValkyrieCreateDerivativesJob
            .perform_later(file_set.id.to_s, event[:file_id])
        end