|
| 1 | +# -*- coding: utf-8 -*- |
| 2 | + |
| 3 | +# Copyright 2024 Google LLC |
| 4 | +# |
| 5 | +# Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 | +# you may not use this file except in compliance with the License. |
| 7 | +# You may obtain a copy of the License at |
| 8 | +# |
| 9 | +# http://www.apache.org/licenses/LICENSE-2.0 |
| 10 | +# |
| 11 | +# Unless required by applicable law or agreed to in writing, software |
| 12 | +# distributed under the License is distributed on an "AS IS" BASIS, |
| 13 | +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 | +# See the License for the specific language governing permissions and |
| 15 | +# limitations under the License. |
| 16 | +# |
| 17 | +"""Evaluation Metrics Module.""" |
| 18 | + |
| 19 | +from vertexai.evaluation.metrics import _base |
| 20 | +from vertexai.evaluation.metrics import _rouge |
| 21 | +from vertexai.evaluation.metrics import ( |
| 22 | + metric_prompt_template, |
| 23 | +) |
| 24 | +from vertexai.evaluation.metrics import ( |
| 25 | + metric_prompt_template_examples, |
| 26 | +) |
| 27 | +from vertexai.evaluation.metrics import pairwise_metric |
| 28 | +from vertexai.evaluation.metrics import pointwise_metric |
| 29 | + |
| 30 | + |
| 31 | +PairwiseMetric = pairwise_metric.PairwiseMetric |
| 32 | +PointwiseMetric = pointwise_metric.PointwiseMetric |
| 33 | +CustomMetric = _base.CustomMetric |
| 34 | +PairwiseMetricPromptTemplate = metric_prompt_template.PairwiseMetricPromptTemplate |
| 35 | +PointwiseMetricPromptTemplate = metric_prompt_template.PointwiseMetricPromptTemplate |
| 36 | +MetricPromptTemplateExamples = ( |
| 37 | + metric_prompt_template_examples.MetricPromptTemplateExamples |
| 38 | +) |
| 39 | +Rouge = _rouge.Rouge |
| 40 | + |
| 41 | + |
| 42 | +__all__ = [ |
| 43 | + "CustomMetric", |
| 44 | + "PairwiseMetric", |
| 45 | + "PointwiseMetric", |
| 46 | + "PairwiseMetricPromptTemplate", |
| 47 | + "PointwiseMetricPromptTemplate", |
| 48 | + "MetricPromptTemplateExamples", |
| 49 | + "Rouge", |
| 50 | +] |
0 commit comments