Skip to content

Latest commit

 

History

3 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

AgentSec Trace demo

Local, self-contained observability demonstration: a small script emits a deterministic GenAI trace and the local .NET Aspire dashboard shows the spans, the OpenTelemetry GenAI attributes, and the correlation trace_id.

Usecase

Show a concrete, real trace during the observability part of the talk. The audience sees the actual attribute names used by OpenTelemetry, the model, latency, tokens, tool call, and the same trace_id on every span. No customer data, no external service, no cost.

The demo proves:

  • GenAI operations can be observed with the OpenTelemetry Development-stage semantic conventions.
  • A single trace_id links agent, chat, and tool spans.
  • The local Aspire dashboard is a working OTLP receiver, so an on-premises inner-loop workflow is possible without a paid observability backend.

What is in this repository

Path Purpose
demo/emit_trace.py Python script that emits a deterministic trace via OTLP. Uses the current GenAI attribute names (gen_ai.provider.name, gen_ai.request.model, gen_ai.usage.input_tokens, gen_ai.tool.type, gen_ai.tool.call.arguments).
demo/requirements.txt Pinned Python dependencies (opentelemetry-api, opentelemetry-sdk, opentelemetry-exporter-otlp-proto-grpc).
docker-compose.yml Runs the standalone Aspire dashboard image from Microsoft Container Registry and maps OTLP gRPC to localhost:4317 and the dashboard to localhost:18888.
scripts/run-demo.ps1 One-command demo runner: starts the dashboard, prepares the Python environment, and emits a trace.
scripts/reset-demo.ps1 Stops the dashboard container and discards its state.
PRESENTER-GUIDE.md Non-technical step-by-step live-demo guide.
SECURITY-MODEL.md Honest scope of what this lab does and does not prove.

The script does not call a real language model. This is a deliberate choice: the point of the demo is the trace shape and the correlation, not proving that an LLM produces text. Using deterministic values keeps the on-stage output stable and avoids any dependency on model endpoints or credentials.

Live sequence at a glance

  1. Start Docker Desktop and run scripts\run-demo.ps1.
  2. Open the Aspire dashboard directly at http://localhost:18888/traces. This demo uses Traces only; ignore Structured logs and Metrics.
  3. Open the emitted trace and expand its spans.
  4. Show gen_ai.provider.name, gen_ai.request.model, gen_ai.usage.input_tokens, gen_ai.tool.type, and gen_ai.tool.call.arguments.
  5. Point out the shared trace_id and the sequence of agent -> chat -> tool spans.
  6. Run scripts\reset-demo.ps1 when finished.

The complete presenter script is in PRESENTER-GUIDE.md.

Sources

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages