code: def snapshot_report(result, config=None, html=True):
      
      if config is None:
          config = ReportConfiguration.load()
      report = SnapshotReport(result=result, configuration=config)
      if html:
          return report.render_html()
      else:
          return report.render_json()
docs: Generate a snapshot report from a result set and configuration.
  
      Parameters
      ----------
      result : memote.MemoteResult
          Nested dictionary structure as returned from the test suite.
      config : dict, optional
          The final test report configuration (default None).
      html : bool, optional
          Whether to render the report as full HTML or JSON (default True).