code: def history_report(history, config=None, html=True):
      
      if config is None:
          config = ReportConfiguration.load()
      report = HistoryReport(history=history, configuration=config)
      if html:
          return report.render_html()
      else:
          return report.render_json()
docs: Test a model and save a history report.
  
      Parameters
      ----------
      history : memote.HistoryManager
          The manager grants access to previous results.
      config : dict, optional
          The final test report configuration.
      html : bool, optional
          Whether to render the report as full HTML or JSON (default True).