Skip to content

Commit 3bbc8fb

Browse files
authored
doc-string updates (Azure#41457)
1 parent ddf423f commit 3bbc8fb

File tree

14 files changed

+46
-42
lines changed

14 files changed

+46
-42
lines changed

sdk/evaluation/azure-ai-evaluation/azure/ai/evaluation/_evaluate/_evaluate.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -721,8 +721,9 @@ def evaluate(
721721
:keyword output_path: The local folder or file path to save evaluation results to if set. If folder path is provided
722722
the results will be saved to a file named `evaluation_results.json` in the folder.
723723
:paramtype output_path: Optional[str]
724-
:keyword azure_ai_project: Logs evaluation results to AI Studio if set.
725-
:paramtype azure_ai_project: Optional[~azure.ai.evaluation.AzureAIProject]
724+
:keyword azure_ai_project: The Azure AI project, which can either be a string representing the project endpoint
725+
or an instance of AzureAIProject. It contains subscription id, resource group, and project name.
726+
:paramtype azure_ai_project: Optional[Union[str, ~azure.ai.evaluation.AzureAIProject]]
726727
:keyword fail_on_evaluator_errors: Whether or not the evaluation should cancel early with an EvaluationException
727728
if ANY evaluator fails during their evaluation.
728729
Defaults to false, which means that evaluations will continue regardless of failures.

sdk/evaluation/azure-ai-evaluation/azure/ai/evaluation/_evaluators/_code_vulnerability/_code_vulnerability.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,9 @@ class CodeVulnerabilityEvaluator(RaiServiceEvaluatorBase[Union[str, bool]]):
4949
5050
:param credential: The credential for connecting to Azure AI project. Required
5151
:type credential: ~azure.core.credentials.TokenCredential
52-
:param azure_ai_project: The scope of the Azure AI project.
53-
It contains subscription id, resource group, and project name.
54-
:type azure_ai_project: ~azure.ai.evaluation.AzureAIProject
52+
:param azure_ai_project: The Azure AI project, which can either be a string representing the project endpoint
53+
or an instance of AzureAIProject. It contains subscription id, resource group, and project name.
54+
:type azure_ai_project: Union[str, ~azure.ai.evaluation.AzureAIProject]
5555
:param kwargs: Additional arguments to pass to the evaluator.
5656
:type kwargs: Any
5757

sdk/evaluation/azure-ai-evaluation/azure/ai/evaluation/_evaluators/_content_safety/_content_safety.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@ class ContentSafetyEvaluator(MultiEvaluatorBase[Union[str, float]]):
2222
2323
:param credential: The credential for connecting to Azure AI project. Required
2424
:type credential: ~azure.core.credentials.TokenCredential
25-
:param azure_ai_project: The scope of the Azure AI project.
26-
It contains subscription id, resource group, and project name.
27-
:type azure_ai_project: ~azure.ai.evaluation.AzureAIProject
25+
:param azure_ai_project: The Azure AI project, which can either be a string representing the project endpoint
26+
or an instance of AzureAIProject. It contains subscription id, resource group, and project name.
27+
:type azure_ai_project: Union[str, ~azure.ai.evaluation.AzureAIProject]
2828
:param violence_threshold: The threshold for violence evaluation. Default is 3.
2929
:type violence_threshold: int
3030
:param sexual_threshold: The threshold for sexual content evaluation. Default is 3.

sdk/evaluation/azure-ai-evaluation/azure/ai/evaluation/_evaluators/_content_safety/_hate_unfairness.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,9 @@ class HateUnfairnessEvaluator(RaiServiceEvaluatorBase[Union[str, float]]):
4545
4646
:param credential: The credential for connecting to Azure AI project. Required
4747
:type credential: ~azure.core.credentials.TokenCredential
48-
:param azure_ai_project: The scope of the Azure AI project.
49-
It contains subscription id, resource group, and project name.
50-
:type azure_ai_project: ~azure.ai.evaluation.AzureAIProject
48+
:param azure_ai_project: The Azure AI project, which can either be a string representing the project endpoint
49+
or an instance of AzureAIProject. It contains subscription id, resource group, and project name.
50+
:type azure_ai_project: Union[str, ~azure.ai.evaluation.AzureAIProject]
5151
:param threshold: The threshold for the HateUnfairness evaluator. Default is 3.
5252
:type threshold: int
5353

sdk/evaluation/azure-ai-evaluation/azure/ai/evaluation/_evaluators/_content_safety/_self_harm.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,9 +39,9 @@ class SelfHarmEvaluator(RaiServiceEvaluatorBase[Union[str, float]]):
3939
4040
:param credential: The credential for connecting to Azure AI project. Required
4141
:type credential: ~azure.core.credentials.TokenCredential
42-
:param azure_ai_project: The scope of the Azure AI project.
43-
It contains subscription id, resource group, and project name.
44-
:type azure_ai_project: ~azure.ai.evaluation.AzureAIProject
42+
:param azure_ai_project: The Azure AI project, which can either be a string representing the project endpoint
43+
or an instance of AzureAIProject. It contains subscription id, resource group, and project name.
44+
:type azure_ai_project: Union[str, ~azure.ai.evaluation.AzureAIProject]
4545
:param threshold: The threshold for the SelfHarm evaluator. Default is 3.
4646
:type threshold: int
4747

sdk/evaluation/azure-ai-evaluation/azure/ai/evaluation/_evaluators/_content_safety/_sexual.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,9 @@ class SexualEvaluator(RaiServiceEvaluatorBase[Union[str, float]]):
4141
4242
:param credential: The credential for connecting to Azure AI project. Required
4343
:type credential: ~azure.core.credentials.TokenCredential
44-
:param azure_ai_project: The scope of the Azure AI project.
45-
It contains subscription id, resource group, and project name.
46-
:type azure_ai_project: ~azure.ai.evaluation.AzureAIProject
44+
:param azure_ai_project: The Azure AI project, which can either be a string representing the project endpoint
45+
or an instance of AzureAIProject. It contains subscription id, resource group, and project name.
46+
:type azure_ai_project: Union[str, ~azure.ai.evaluation.AzureAIProject]
4747
:param threshold: The threshold for the Sexual evaluator. Default is 3.
4848
:type threshold: int
4949

sdk/evaluation/azure-ai-evaluation/azure/ai/evaluation/_evaluators/_content_safety/_violence.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,9 @@ class ViolenceEvaluator(RaiServiceEvaluatorBase[Union[str, float]]):
4141
4242
:param credential: The credential for connecting to Azure AI project. Required
4343
:type credential: ~azure.core.credentials.TokenCredential
44-
:param azure_ai_project: The scope of the Azure AI project.
45-
It contains subscription id, resource group, and project name.
46-
:type azure_ai_project: ~azure.ai.evaluation.AzureAIProject
44+
:param azure_ai_project: The Azure AI project, which can either be a string representing the project endpoint
45+
or an instance of AzureAIProject. It contains subscription id, resource group, and project name.
46+
:type azure_ai_project: Union[str, ~azure.ai.evaluation.AzureAIProject]
4747
:param threshold: The threshold for the Violence evaluator. Default is 3.
4848
:type threshold: int
4949

sdk/evaluation/azure-ai-evaluation/azure/ai/evaluation/_evaluators/_eci/_eci.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@ class ECIEvaluator(RaiServiceEvaluatorBase):
2222
2323
:param credential: The credential for connecting to Azure AI project. Required
2424
:type credential: ~azure.core.credentials.TokenCredential
25-
:param azure_ai_project: The scope of the Azure AI project.
26-
It contains subscription id, resource group, and project name.
27-
:type azure_ai_project: ~azure.ai.evaluation.AzureAIProject
25+
:param azure_ai_project: The Azure AI project, which can either be a string representing the project endpoint
26+
or an instance of AzureAIProject. It contains subscription id, resource group, and project name.
27+
:type azure_ai_project: Union[str, ~azure.ai.evaluation.AzureAIProject]
2828
:return: Whether or not ECI was found in the response without a disclaimer, with AI-generated reasoning
2929
:rtype: Dict[str, str]
3030

sdk/evaluation/azure-ai-evaluation/azure/ai/evaluation/_evaluators/_protected_material/_protected_material.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,10 @@ class ProtectedMaterialEvaluator(RaiServiceEvaluatorBase[Union[str, bool]]):
2525
2626
:param credential: The credential required for connecting to the Azure AI project.
2727
:type credential: ~azure.core.credentials.TokenCredential
28-
:param azure_ai_project: The scope of the Azure AI project, containing the subscription ID,
29-
resource group, and project name.
30-
:type azure_ai_project: ~azure.ai.evaluation.AzureAIProject
31-
28+
:param azure_ai_project: The Azure AI project, which can either be a string representing the project endpoint
29+
or an instance of AzureAIProject. It contains subscription id, resource group, and project name.
30+
:type azure_ai_project: Union[str, ~azure.ai.evaluation.AzureAIProject]
31+
3232
.. admonition:: Example:
3333
3434
.. literalinclude:: ../samples/evaluation_samples_evaluate.py

sdk/evaluation/azure-ai-evaluation/azure/ai/evaluation/_evaluators/_service_groundedness/_service_groundedness.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,9 @@ class GroundednessProEvaluator(RaiServiceEvaluatorBase[Union[str, bool]]):
2424
2525
:param credential: The credential for connecting to Azure AI project. Required
2626
:type credential: ~azure.core.credentials.TokenCredential
27-
:param azure_ai_project: The scope of the Azure AI project.
28-
It contains subscription id, resource group, and project name.
29-
:type azure_ai_project: ~azure.ai.evaluation.AzureAIProject
27+
:param azure_ai_project: The Azure AI project, which can either be a string representing the project endpoint
28+
or an instance of AzureAIProject. It contains subscription id, resource group, and project name.
29+
:type azure_ai_project: Union[str, ~azure.ai.evaluation.AzureAIProject]
3030
:param threshold: The threshold for the groundedness pro evaluator. Default is 5.
3131
:type threshold: int
3232
:param kwargs: Additional arguments to pass to the evaluator.

0 commit comments

Comments
 (0)