From agentic-starter-kits-skills
Creates the tracing.py module with enable_tracing(), health check, and framework-specific autolog configuration.
How this skill is triggered — by the user, by Claude, or both
Slash command
/agentic-starter-kits-skills:create-tracing-module <agent_path> [framework]<agent_path> [framework]The summary Claude sees in its skill listing — used to decide when to auto-load this skill
> **Usage:** `/create-tracing-module <agent_path>`
tracing.py)Usage:
/create-tracing-module <agent_path>Example:/create-tracing-module agents/autogen/chat_agent
You are creating the tracing.py file for a new agent template, following this repo's established patterns.
The agent path is: $ARGUMENTS
You also need the framework name (e.g., autogen, langgraph, crewai) and the autolog support report (which classifies the framework as Level A, B, or C). The framework may be included as a second word in $ARGUMENTS. If not provided, determine it from the agent's pyproject.toml dependencies.
If the autolog report is not available in the current conversation context, invoke the check-autolog-support skill (i.e., /agentic-starter-kits-skills:check-autolog-support) with the framework name to produce the report before continuing.
Read tracing.md at the repo root for the full tracing architecture, design principles, and how each existing agent integrates with MLflow.
Read the reference tracing.py that matches the coverage level. These are the source of truth — follow their patterns exactly:
agents/langgraph/react_agent/src/react_agent/tracing.pyagents/google/adk/src/adk_agent/tracing.pyagents/crewai/websearch_agent/src/crewai_web_search/tracing.pyagents/vanilla_python/openai_responses_agent/src/openai_responses_agent/tracing.pyCreate the file at: <agent_path>/src/<package_name>/tracing.py
The <package_name> is the Python package name — find it by looking at the existing src/ directory or pyproject.toml [tool.setuptools.packages.find].
Copy these exactly from the reference file — they are identical across all agents:
logging.getLogger("tracing") with handler)check_mlflow_health() function (retry loop with time budget)enable_tracing() skeleton (load_dotenv, MLFLOW_TRACKING_URI check, health check with graceful degradation, set_tracking_uri, set_experiment, enable_async_logging)The only parts that differ between levels are inside enable_tracing() and whether wrap_func_with_mlflow_trace() exists:
Level A (autolog variant) — Read the LangGraph reference. Adapt by:
import mlflow.langchain / mlflow.langchain.autolog() with the correct module for the new framework (from the autolog report)wrap_func_with_mlflow_trace() neededLevel A (OTel variant) — Read the Google ADK reference. Use this when the framework has no mlflow.<framework>.autolog() but natively emits OpenTelemetry spans. Adapt by:
TracerProvider with OTLPSpanExporter pointing at {tracking_uri}/v1/tracesx-mlflow-experiment-id header (get it from mlflow.set_experiment())--backend-store-uri sqlite:///mlflow.db)opentelemetry-exporter-otlp-proto-httpwrap_func_with_mlflow_trace() neededLevel B — Read the CrewAI reference. Adapt by:
mlflow.crewai → mlflow.<new_framework>)provider_autolog_map + LLM_PROVIDER routingwrap_func_with_mlflow_trace() as-is (with name parameter)Level C — Read the Vanilla Python reference. Adapt by:
wrap_func_with_mlflow_trace() as-isAfter creating the file, verify:
check_mlflow_health() is identical to the referenceenable_tracing() has graceful degradation (returns on unreachable server, doesn't crash)enable_tracing() / wrap_func_with_mlflow_trace(), not at module top)wrap_func_with_mlflow_trace() returns the original function unchanged when MLFLOW_TRACKING_URI is not setenable_async_logging() is called before autologBefore finishing, check whether this skill file needs updating. If any of the following are true, propose the specific changes to the user and only update this file if they approve:
If nothing needed changing, move on.
Provides a checklist for code reviews covering functionality, security, performance, maintainability, tests, and quality. Use for pull requests, audits, team standards, and developer training.
npx claudepluginhub red-hat-data-services/agentic-starter-kits-skills --plugin agentic-starter-kits-skills