code: def test_make_genai_metric_failure():
      example = EvaluationExample(
          input="input",
          output="output",
          score=4,
          justification="justification",
          grading_context={"targets": "ground_truth"},
      )
      import pandas as pd
  
      with pytest.raises(
          MlflowException,
          match=re.escape(
              "Failed to find evaluation model for version v-latest."
              " Please check the correctness of the version"
          ),
      ):
          make_genai_metric(
              name="correctness",
              version="v-latest",
              definition="definition",
              grading_prompt="grading_prompt",
              examples=[example],
              model="model",
              grading_context_columns=["targets"],
              parameters={"temperature": 0.0},
              greater_is_better=True,
              aggregations=["mean"],
          )
  
      with mock.patch.object(
          model_utils,
          "score_model_on_payload",
          return_value=properly_formatted_openai_response1,
      ):
          custom_metric2 = make_genai_metric(
              name="correctness",
              version="v1",
              definition="definition",
              grading_prompt="grading_prompt",
              examples=[example],
              model="openai:/gpt-3.5-turbo",
              grading_context_columns=["targets"],
              parameters={"temperature": 0.0},
              greater_is_better=True,
              aggregations=["random-fake"],
          )
          with pytest.raises(
              MlflowException,
              match=re.escape("Invalid aggregate option random-fake"),
          ):
              custom_metric2.eval_fn(
                  pd.Series(["predictions"]),
                  {},
                  pd.Series(["What is MLflow?"]),
                  pd.Series(["truth"]),
              )
  
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 6 for calling a global function with example usage: test_make_genai_metric_failure() without return types