class_docstr: Frozen-encoder coreference model.
class_docstr_tok: ["Frozen-encoder","coreference","model","."]
code: def predict_minibatch(self, inputs: list[JsonDict]):
      edges = self._make_edges(inputs, show_progress=False)
      edge_preds = list(self.classifier.predict(edges.examples))
      # Re-pack outputs to align with inputs.
      preds = [{"coref": [], "tokens": ex["tokens"]} for ex in inputs]
      for edge, ep in zip(edges.examples, edge_preds):
          orig_input = inputs[edge["src_idx"]]
          orig_edge = orig_input["coref"][edge["edge_idx"]]
          new_edge = EdgeLabel(
              span1=orig_edge.span1,
              span2=orig_edge.span2,
              label=ep["proba"],
          )
          preds[edge["src_idx"]]["coref"].append(new_edge)
      for ex, p in zip(inputs, preds):
          # Choose an answer if there are only two target edges.
          if len(p["coref"]) == 2 and "answer" in ex:
              probas = np.array([ep.label for ep in p["coref"]])
              # Renormalize as a binary choice.
              p["pred_answer"] = probas / np.sum(probas)
          # Otherwise, it's ok for this field to be missing;
          # metrics will safely ignore.
      return preds
  
imports: import os
  from absl import logging
  from lit_nlp.api import dtypes
  from lit_nlp.api import model
  from lit_nlp.api import types
  from lit_nlp.examples.coref import edge_predictor
  from lit_nlp.examples.coref import encoders
  from lit_nlp.examples.coref.datasets import winogender
  from lit_nlp.lib import utils
  import numpy
  import tqdm
label_desc: Use image node_id 7 for calling the FrozenEncoderCoref obj's underlying member method code with example usage: obj.predict_minibatch(inputs) and returns: preds