Plan and manage an Azure AI solution 1.4 Implement responsible AI across generative AI and agentic systems

You want to view trace timelines and spans for an application built on a Foundry project.

Study guide skill: Implement auditing through trace logging, provenance metadata, and approval workflows

Question B1-012

You want to view trace timelines and spans for an application built on a Foundry project. The Tracing page asks you to enable tracing first. What must you do?

Select one answer.

  • A Turn on content recording in the content filter
  • B Create a Log Analytics workspace and enable diagnostic settings on the model deployment
  • C Deploy an Azure Monitor agent on the app's virtual machine
  • D Associate an Azure Application Insights resource with the Foundry resource ✓ Correct answer

Answer: D

Foundry stores traces in Azure Application Insights using OpenTelemetry. New resources don't provision Application Insights automatically, so you associate an existing one or create one for the Foundry resource. Diagnostic settings and agents collect platform logs and metrics, not the application traces shown on the Tracing page.

Deep dive

How it works

Foundry tracing is built on OpenTelemetry, and the traces are stored in Azure Application Insights. That's why the Tracing page asks you to enable tracing first: new Foundry resources don't provision Application Insights automatically. You associate an existing Application Insights resource, or create a new one, once per Foundry resource.

The setup flow:

  1. In the Foundry portal, open your project and select Tracing.
  2. If no Application Insights resource is associated with your Foundry resource, associate one. To reuse an existing one, pick it from the drop-down and select Connect. (You need at least contributor access to the Foundry resource to connect an existing one.)
  3. Instrument your app. Optionally, set OTEL_INSTRUMENTATION_GENAI_CAPTURE_MESSAGE_CONTENT to true to capture message content, and get the connection string from Project > Tracing > Manage data source.

Once connected, distributed tracing captures the execution flow of your app: LLM calls, tool invocations, agent decisions and dependencies between services. That's the timeline-and-spans view the question asks for. The same Application Insights integration also powers Foundry's dashboards for token consumption, latency, error rates and quality scores.

The other options, and when you'd use them

  • Turn on content recording in the content filter: Capturing message content is an optional instrumentation step in your app, set with an OpenTelemetry environment variable. It isn't a content filter setting, and it doesn't create the Application Insights connection that tracing needs.
  • Create a Log Analytics workspace and enable diagnostic settings on the deployment: Diagnostic settings collect resource logs and send platform metrics and the activity log to destinations. Foundry traces, by contrast, are stored in the Application Insights resource associated with the Foundry resource.
  • Deploy an Azure Monitor agent on the app's VM: The Azure Monitor Agent collects monitoring data from the guest operating system of virtual machines. Foundry traces come from OpenTelemetry instrumentation in your app, sent to the associated Application Insights resource.

Exam tip

"Tracing page says enable tracing" means you associate Application Insights with the Foundry resource. Remember the pair: OpenTelemetry for instrumentation, Application Insights for storage.

References

Last reviewed:

Ready to test yourself? The quiz asks this and every other AI-103 question, with instant feedback. Practice this in a quiz →

All Plan and manage questions · AI-103 study guide

Thanks for your feedback!