code: def _create_flags(self, kw):
          
  
          flags = {}
          for k in kw.keys():
              flags[k] = kw[k]
              flags[k.lower()] = flags[k]
          return flags
docs: this clones the kw dict, adding a lower-case version of every key
          (duplicated in circuit.py; consider putting in util?)