class_docstr: Data Processor for SGD dialogues.
  
  More information at https://arxiv.org/abs/1909.05855
  
  ***Downloading the dataset***
      #   git clone https://github.com/google-research-datasets/dstc8-schema-guided-dialogue.git
  
  ***Data format***
  SGD data comes with a JSON schema file and dialogue files for each dataset split. 
  
  In the following we will show an example for a service entry in the schema file.
  * service_name
  * description
  * slots
      * name
      * description
      * is_categorical
      * possible values
  * intents
      * name
      * description
      * required_slots (not used)
      * is_transactional (not used)
      * optional_slots (not used)
      * result_slots (not used)
  
  
  In the following we will show an example for a dialogue. 
  * dialogue_id
  * services
  * turns
      * frames
          * actions
              * act
              * slot
              * values
          * service
          * slots
              * exclusive_end
              * slot
              * start
          * state
              * active_intent
              * requeste_slots
              * slot_values 
      * speaker - [USER, SYSTEM]
      * utterance
docstr: Updates dialogue state
  Args:
      current_state: slot values pairs for the current dialogue turn
      prev_state: slot values pairs for the previous dialogue turns
  Returns:
      state_update: slot values pairs that are added/updated during the current dialogue turn
docstr_tok: ["Updates","dialogue","state","Args",":","current_state",":","slot","values","pairs","for","the","current","dialogue","turn","prev_state",":","slot","values","pairs","for","the","previous","dialogue","turns","Returns",":","state_update",":","slot","values","pairs","that","are","added\/updated","during","the","current","dialogue","turn"]
code: def _get_state_update(
      self, current_state: dict, prev_state: dict
  ) -> dict:
      """
      Updates dialogue state
      Args:
          current_state: slot values pairs for the current dialogue turn
          prev_state: slot values pairs for the previous dialogue turns
      Returns:
          state_update: slot values pairs that are added/updated during the current dialogue turn
      """
      state_update = dict(current_state)
      for slot, values in current_state.items():
          if slot in prev_state and prev_state[slot][0] in values:
              # Remove the slot from state if its value didn't change.
              state_update.pop(slot)
      return state_update
  
imports: import collections
  import json
  import os
  import pickle
  import re
  from typing import List
  from nemo.collections.nlp.data.dialogue.data_processor.data_processor import DialogueDataProcessor
  from nemo.collections.nlp.data.dialogue.input_example.input_example import DialogueInputExample
  from nemo.collections.nlp.data.dialogue.sgd.schema import Schema
  from nemo.utils import logging
  from nemo.utils.get_rank import is_global_rank_zero
label_desc: Use image node_id 11 for calling the DialogueSGDDataProcessor obj's underlying member method code with example usage: obj._get_state_update(current_state, prev_state) and returns: state_update