code: def get_al_samples_from_processed(self, existing_al_ids):
      wanted_apis = self.get_wanted_apis()
      save_me = {}
      for datatype in ["train", "valid", "test"]:
          found = [False] * len(wanted_apis)
          save_me[datatype] = {}
          for episode in self.get_gsgd_episodes_for_datatype(datatype):
              if episode.extras["dialogue_id"] in existing_al_ids.get(
                  datatype, []
              ):
                  if self.opt["cumulative_al"]:
                      save_me[datatype][
                          episode.extras["dialogue_id"]
                      ] = episode.goal_calls_utt
                  continue
              here = False
              for idx, val in enumerate(found):
                  if not val and not here:
                      here = True
                      for api_name_slots in wanted_apis[idx]:
                          api_name = api_name_slots[0]
                          slots = api_name_slots[1]
                          if api_name in episode.goal_calls_utt:
                              for slot in slots:
                                  if slot not in episode.goal_calls_utt:
                                      here = False
                          else:
                              here = False
                      if here:
                          found[idx] = True
                          save_me[datatype][
                              episode.extras["dialogue_id"]
                          ] = episode.goal_calls_utt
      return save_me
  
imports: from parlai.core.params import ParlaiParser
  from parlai.core.script import ParlaiScript, register_script
  from parlai.tasks.google_sgd_simulation_splits.agents import GoogleSgdOutDomainParser
  from parlai.core.tod.tod_agents import TodStructuredDataParser
  import parlai
  import os
  import json
  import random
label_desc: Use image node_id 4 for calling the GetAlSamplesForGsgdScript obj's underlying member method code with example usage: obj.get_al_samples_from_processed(existing_al_ids) and returns: save_me