class_docstr: A `RequestState` represents a single `Request` made on behalf of an `Instance`.
  It should have all the information that's needed later for a `Metric` to be
  able to understand the `Request` and its `RequestResult`.
code: def render_lines(self) -> List[str]:
      output = [f"train_trial_index: {self.train_trial_index}"]
      if self.reference_index:
          output.append(f"reference_index: {self.reference_index}")
  
      output.append("instance {")
      output.extend(indent_lines(self.instance.render_lines()))
      output.append("}")
  
      # Part of request but render multiline
      output.append("request.prompt {")
      output.extend(
          indent_lines(format_text_lines(self.request.prompt))
      )
      output.append("}")
  
      output.append("request {")
      output.extend(indent_lines(serialize(self.request)))
      output.append("}")
  
      if self.result:
          output.append("result {")
          output.extend(indent_lines(self.result.render_lines()))
          output.append("}")
  
      return output
  
file_path: H2O/h2o_hf/helm/src/helm/benchmark/adaptation/request_state.py
imports: from dataclasses import dataclass
  from typing import Optional, Dict, List
  from helm.benchmark.scenarios.scenario import Instance
  from helm.common.general import indent_lines, format_text_lines, serialize
  from helm.common.request import Request, RequestResult
label_desc: Use image node_id 2 for calling the RequestState obj's underlying member method code with example usage: obj.render_lines() and returns: output