code: def flesch_kincaid_grade_level() -> EvaluationMetric:
      """
      This function will create a metric for calculating `flesch kincaid grade level`_ using
      `textstat`_.
  
      This metric outputs a number that approximates the grade level needed to comprehend the text,
      which will likely range from around 0 to 15 (although it is not limited to this range).
  
      Aggregations calculated for this metric:
          - mean
  
      .. _flesch kincaid grade level:
          https://en.wikipedia.org/wiki/Flesch%E2%80%93Kincaid_readability_tests#Flesch%E2%80%93Kincaid_grade_level
      .. _textstat: https://pypi.org/project/textstat/
      """
      return make_metric(
          eval_fn=_flesch_kincaid_eval_fn,
          greater_is_better=False,
          name="flesch_kincaid_grade_level",
          version="v1",
      )
  
imports: from mlflow.metrics.base import MetricValue
  from mlflow.metrics.metric_definitions import _accuracy_eval_fn, _ari_eval_fn, _f1_score_eval_fn, _flesch_kincaid_eval_fn, _mae_eval_fn, _mape_eval_fn, _max_error_eval_fn, _mse_eval_fn, _ndcg_at_k_eval_fn, _precision_at_k_eval_fn, _precision_eval_fn, _r2_score_eval_fn, _recall_at_k_eval_fn, _recall_eval_fn, _rmse_eval_fn, _rouge1_eval_fn, _rouge2_eval_fn, _rougeL_eval_fn, _rougeLsum_eval_fn, _token_count_eval_fn, _toxicity_eval_fn
  from mlflow.models import EvaluationMetric, make_metric
  from mlflow.utils.annotations import experimental
label_desc: Use image node_id 4 for calling a global function with example usage: flesch_kincaid_grade_level() and returns: make_metric