code: def test_make_genai_metric_multiple():
      custom_metric = make_genai_metric(
          name="correctness",
          version="v1",
          definition=example_definition,
          grading_prompt=example_grading_prompt,
          examples=[mlflow_example],
          model="gateway:/gpt-3.5-turbo",
          grading_context_columns=["targets"],
          parameters={"temperature": 0.0},
          greater_is_better=True,
          aggregations=["mean", "variance", "p90"],
      )
  
      # Use side_effect to specify multiple return values
      with mock.patch.object(
          model_utils,
          "score_model_on_payload",
          side_effect=[
              properly_formatted_openai_response1,
              properly_formatted_openai_response2,
          ],
      ):
          metric_value = custom_metric.eval_fn(
              pd.Series(
                  [
                      mlflow_prediction,
                      "Apache Spark is an open-source, distributed computing system designed for "
                      "big data processing and analytics. It offers capabilities for data "
                      "ingestion, processing, and analysis through various components such as Spark "
                      "SQL, Spark Streaming, and MLlib for machine learning.",
                  ],
              ),
              {},
              pd.Series(["What is MLflow?", "What is Spark?"]),
              pd.Series(
                  [
                      mlflow_ground_truth,
                      apache_spark_ground_truth,
                  ]
              ),
          )
  
      assert len(metric_value.scores) == 2
      assert set(metric_value.scores) == {3, 2}
      assert len(metric_value.justifications) == 2
      assert set(metric_value.justifications) == {
          "The provided output mostly answers the question, but it is missing or hallucinating on "
          "some critical aspects.  Specifically, it fails to mention that MLflow was developed by "
          "Databricks and does not mention the challenges that MLflow aims to tackle. Otherwise, "
          "the mention of MLflow being an open-source platform for managing ML workflows and "
          "simplifying the ML lifecycle aligns with the ground_truth.",
          "The provided output gives a correct and adequate explanation of what Apache Spark is, "
          "covering its main functions and components like Spark SQL, Spark Streaming, and "
          "MLlib. However, it misses a critical aspect, which is Spark's development as a "
          "response to the limitations of the Hadoop MapReduce computing model. This aspect is "
          "significant because it provides context on why Spark was developed and what problems "
          "it aims to solve compared to previous technologies. Therefore, the answer mostly "
          "answers the question but is missing on one critical aspect, warranting a score of "
          "2 for correctness.",
      }
      assert metric_value.aggregate_results == {
          "mean": 2.5,
          "variance": 0.25,
          "p90": 2.9,
      }
  
imports: import inspect
  import re
  from unittest import mock
  import numpy
  import pandas
  import pytest
  from mlflow.exceptions import MlflowException
  from mlflow.metrics.genai import EvaluationExample, model_utils
  from mlflow.metrics.genai.genai_metric import _extract_score_and_justification, _format_args_string, make_genai_metric
  from mlflow.metrics.genai.metric_definitions import answer_correctness, answer_relevance, answer_similarity, faithfulness, relevance
  from mlflow.metrics.genai.prompts.v1 import AnswerCorrectnessMetric, AnswerRelevanceMetric, AnswerSimilarityMetric, FaithfulnessMetric, RelevanceMetric
label_desc: Use image node_id 5 for calling a global function with example usage: test_make_genai_metric_multiple() without return types