Skip to content

Agent target traces samples#46300

Open
shrutiyer wants to merge 10 commits intomainfrom
shruti/agent-target-traces-samples
Open

Agent target traces samples#46300
shrutiyer wants to merge 10 commits intomainfrom
shruti/agent-target-traces-samples

Conversation

@shrutiyer
Copy link
Copy Markdown
Contributor

@shrutiyer shrutiyer commented Apr 14, 2026

Description

Add a new agent as target evaluation sample
Enhance the previous sample with an additional scenario for querying agents

All SDK Contribution checklist:

  • The pull request does not introduce [breaking changes]
  • CHANGELOG is updated for new features, bug fixes or other significant changes.
  • I have read the contribution guidelines.

General Guidelines and Best Practices

  • [x ] Title of the pull request is clear and informative.
  • There are a small number of commits, each of which have an informative message. This means that previously merged commits do not appear in the history of the PR. For more information on cleaning up the commits in your PR, see this page.

Testing Guidelines

  • Pull request includes test coverage for the included changes.

Updated the sample script to support additional command-line arguments for trace evaluations, including agent ID and trace IDs. Modified the lookback hours default value and improved the overall structure for better clarity.
This sample demonstrates how to run Azure AI Evaluations against a hosted agent using the azure_ai_target_completions data source, evaluating agents live with built-in quality and safety evaluators.
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the Azure AI Projects evaluation samples to better support “agent traces as evaluation inputs” scenarios and adds a new sample for evaluating a hosted agent live as the evaluation target.

Changes:

  • Enhanced sample_evaluations_builtin_with_traces.py to support multiple invocation modes (default App Insights query, server-side --agent-id, and explicit --trace-ids) plus new CLI flags.
  • Added sample_evaluations_agent_as_target.py demonstrating live agent evaluation via azure_ai_target_completions.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 5 comments.

File Description
sdk/ai/azure-ai-projects/samples/evaluations/sample_evaluations_builtin_with_traces.py Adds CLI-driven modes for trace-based evaluations and tweaks defaults/metadata/cleanup behavior.
sdk/ai/azure-ai-projects/samples/evaluations/sample_evaluations_agent_as_target.py New sample showing how to run evaluations where the target is a hosted agent invoked live.

shrutiyer and others added 3 commits April 14, 2026 14:35
Add two new evaluation samples:

- sample_evaluations_builtin_with_traces.py: Trace-based evaluation with
  three modes (client-side App Insights query, server-side agent ID, and
  explicit trace IDs)
- sample_evaluations_agent_as_target.py: Live agent evaluation using
  azure_ai_target_completions data source

Both samples use the azure_ai_evaluator config pattern with builtin
intent_resolution and task_adherence evaluators.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@shrutiyer shrutiyer requested a review from a team as a code owner April 15, 2026 20:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants