code: def analyze_frames(cls, workdir):
          '''generate draft from recorded frames'''
          record = cls(None, workdir)
          obj = {}
          with open(os.path.join(workdir, 'frames', 'frames.json')) as f:
              obj = json.load(f)
          record.device_info = obj['device']
          record.frames = obj['frames']
          record.analyze_all()
          record.save(f analyze_frames(cls, workdir):
          '''generate draft from recorded frames'''
          record = cls(None, workdir)
          obj = {}
          with open(os.path.join(workdir, 'frames', 'frames.json')) as f:
              obj = json.load(f)
          record.device_info = obj['device']
          record.frames = obj['frames']
          record.analyze_all()
          record.save()
docs: generate draft from recorded frames