code: def load_jsonl_log(path):
      """
      Given jsonl log, returns list containing tuples
      of (question, was_answer_to_questopm_correct)
      """
      all_examples = []
      with open(path, "r") as f:
          for line in f:
              line = json.loads(line)
              if (
                  "spec" in line.keys()
                  or "final_report" in line.keys()
                  or line["type"] != "metrics"
              ):
                  continue
  
              q = line["data"]["prompt"][2]["content"]
  
              correct = line["data"]["correct"]
              correct = int(correct)  # Cast to 0/1
  
              all_examples.append((q, correct))
  
      return all_examples
  
file_path: evals/evals/elsuite/sandbagging/scripts/consistency_plots.py
imports: import argparse
  import glob
  import json
  import os
  from pathlib import Path
  from typing import Sequence
  import matplotlib.pyplot
label_desc: Use image node_id 1 for calling a global function with example usage: load_jsonl_log(path) and returns: all_examples