code: def _replace_profiles(file_contents):
      for key, value in profile_mappings.items():
          regex_find = regex_find_base.format(profile_str=key)
          regex_replace = value
          file_contents = re.sub(
              regex_find, regex_replace, file_contents
          )
      return file_contents
  
imports: import sys
  import os
  import re
  import glob
label_desc: Use image node_id 1 for calling a global function with example usage: _replace_profiles(file_contents) and returns: file_contents