code: def second_level(keys):
      """Return a dictionary with the nested keys, e.g. returns {'I':['a', 'b']} when keys=['I.a', 'I.b']"""
      sub_keys = {}
      for key in keys:
          if "." in key:
              left, right = key.split(".", 1)
              sub_keys.setdefault(left, []).append(right)
  
      return sub_keys
  
file_path: jupytext/src/jupytext/metadata_filter.py
imports: from copy import copy
  from .cell_metadata import _JUPYTEXT_CELL_METADATA, is_valid_metadata_key
label_desc: Use image node_id 5 for calling a global function with example usage: second_level(keys) and returns: sub_keys