Skip to content

Conversation

@HarshithReddy01
Copy link

@HarshithReddy01 HarshithReddy01 commented Jan 20, 2026

Summary

Fixes a 404 Not Found error in Azure OpenAI Graders by ensuring evals.create()
is called using the Azure AI Foundry project endpoint when azure_ai_project
is provided.

Root Cause

The evaluation workflow always used the grader's Azure OpenAI client
(endpoint: *.openai.azure.com). However, the evals.create() API is only available
via Azure AI Foundry projects (endpoint: *.services.ai.azure.com), causing 404 errors
in both the SDK and the Azure AI Foundry portal.

Fix

  • Use AIProjectClient.get_openai_client() when azure_ai_project is provided
  • Pass azure_ai_project through the evaluation pipeline via kwargs
  • Preserve existing behavior when azure_ai_project is not provided

Files Changed

  • azure/ai/evaluation/_evaluate/_evaluate_aoai.py - Added Foundry client logic in _begin_single_aoai_evaluation()
  • azure/ai/evaluation/_evaluate/_evaluate.py - Pass azure_ai_project in kwargs to AOAI evaluation functions

Backward Compatibility

No breaking changes. Existing workflows continue to use the grader client
when azure_ai_project is not specified.

Checklist

  • No breaking changes
  • Code follows project style guidelines
  • CHANGELOG update (not required for bug fix)
  • Contribution guidelines read

@HarshithReddy01 HarshithReddy01 requested a review from a team as a code owner January 20, 2026 20:41
@github-actions
Copy link

Thank you for your contribution @HarshithReddy01! We will review the pull request and get back to you soon.

@github-actions github-actions bot added Community Contribution Community members are working on the issue customer-reported Issues that are reported by GitHub users external to the Azure organization. Evaluation Issues related to the client library for Azure AI Evaluation labels Jan 20, 2026
@HarshithReddy01
Copy link
Author

@microsoft-github-policy-service agree

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Community Contribution Community members are working on the issue customer-reported Issues that are reported by GitHub users external to the Azure organization. Evaluation Issues related to the client library for Azure AI Evaluation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant