ワンクリックで
review-tracing-code
Reviews tracing integration code for correctness against the repo's established patterns and checklists.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
メニュー
Reviews tracing integration code for correctness against the repo's established patterns and checklists.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
SOC 職業分類に基づく
| name | review-tracing-code |
| description | Reviews tracing integration code for correctness against the repo's established patterns and checklists. |
| argument-hint | <agent_path> |
| disable-model-invocation | true |
Usage:
/review-tracing-code <agent_path>Example:/review-tracing-code agents/autogen/chat_agent
You are reviewing the MLflow tracing integration code for an agent template to confirm it follows the repo's established patterns and is correctly wired.
You must read every file and check every item yourself. Do not ask the user to review files or run checks. Execute the full checklist and produce the report.
The agent path is: $ARGUMENTS
You also need the package name and coverage level (A, B, or C). If not provided, determine them by reading the agent's pyproject.toml, src/ directory, and tracing.py.
tracing.py exists and follows the patternRead <agent_path>/src/<package>/tracing.py and verify:
logging.getLogger("tracing")check_mlflow_health() is present and matches the reference (retry loop with time budget)enable_tracing() is present with the correct structure:
load_dotenv() firstMLFLOW_TRACKING_URI is not setMLFLOW_HEALTH_CHECK_TIMEOUT supportmlflow.set_tracking_uri(), mlflow.set_experiment(), mlflow.config.enable_async_logging() in that orderLevel A: Verify mlflow.<framework>.autolog() is called. No wrap_func_with_mlflow_trace() should exist.
Level B: Verify:
mlflow.crewai.autolog())LLM_PROVIDER routing map)wrap_func_with_mlflow_trace() function exists with span_type and name parameterswrap_func_with_mlflow_trace() returns original function when MLFLOW_TRACKING_URI is not setLevel C: Verify:
mlflow.openai.autolog())wrap_func_with_mlflow_trace() function existswrap_func_with_mlflow_trace() returns original function when MLFLOW_TRACKING_URI is not setCompare against the reference file for the matching level:
agents/langgraph/react_agent/src/react_agent/tracing.pyagents/crewai/websearch_agent/src/crewai_web_search/tracing.pyagents/vanilla_python/openai_responses_agent/src/openai_responses_agent/tracing.pymain.py wiringRead <agent_path>/main.py and verify:
enable_tracing is imported from <package>.tracingenable_tracing() is called as the first line inside the lifespan() function (before agent initialization)wrap_func_with_mlflow_trace is also importedSkip this section for Level A.
Tool wrapping — find where tools are registered/created and verify:
wrap_func_with_mlflow_trace(..., span_type="tool")name parameter is used when wrapping tool objects (so span names are meaningful)Agent wrapping — find the main agent entry point and verify:
query(), run()) is wrapped with wrap_func_with_mlflow_trace(..., span_type="agent")Streaming path — read _handle_stream in main.py and verify:
main.pymain.py does NOT import mlflow directly — all MLflow interaction goes through tracing.pymlflow.trace() calls appear in main.py — only wrap_func_with_mlflow_trace() from tracing.py.env.example has MLflow variablesRead <agent_path>/.env.example and verify:
MLFLOW_TRACKING_URI, MLFLOW_EXPERIMENT_NAME, MLFLOW_HEALTH_CHECK_TIMEOUT, MLFLOW_HTTP_REQUEST_TIMEOUT, MLFLOW_HTTP_REQUEST_MAX_RETRIESMLFLOW_TRACKING_URI, MLFLOW_TRACKING_TOKEN, MLFLOW_EXPERIMENT_NAME, MLFLOW_TRACKING_INSECURE_TLS, MLFLOW_WORKSPACE, MLFLOW_TRACKING_AUTHREADME.md has tracing documentationRead <agent_path>/README.md and verify:
### Tracing (optional) section existsuv run --extra tracing mlflow server --port 5000 command is documentedMLFLOW_HEALTH_CHECK_TIMEOUT controls wait timepyproject.toml lists MLflow as optionalmlflow>=3.10.0 is in [project.optional-dependencies] under a tracing extra — NOT in core dependenciesMakefile auto-installs MLflow when tracing is enabledrun target uses $${MLFLOW_TRACKING_URI:+--extra tracing} in the uv run commandrun-cli target (if it exists) uses the same flagDockerfile includes the tracing extra (e.g., ".[tracing]" instead of ".")## Code Review Report: <agent_name>
### tracing.py
- Exists: YES / NO
- Follows pattern: YES / NO
- Issues: <list or "None">
### main.py wiring
- enable_tracing() imported: YES / NO
- Called first in lifespan: YES / NO
- Issues: <list or "None">
### Manual wrapping (Level B/C only)
- Tools wrapped: YES / NO / N/A
- Agent entry point wrapped: YES / NO / N/A
- Streaming path covered: YES / NO / N/A
- Issues: <list or "None">
### .env.example
- Local tracing section: YES / NO
- OpenShift tracing section: YES / NO
- Issues: <list or "None">
### README.md
- Tracing (optional) section exists: YES / NO
- Local MLflow config: YES / NO
- OpenShift MLflow config: YES / NO
- MLflow server start step: YES / NO
- Behavioral notes: YES / NO
- Issues: <list or "None">
### pyproject.toml
- MLflow in optional tracing extra: YES / NO
### Makefile
- run target has --extra tracing flag: YES / NO
- run-cli target has --extra tracing flag: YES / NO / N/A
### Dockerfile
- Installs .[tracing] extra: YES / NO
### Overall: PASS / FAIL
If FAIL, specify which skill or step to re-run to fix the issues (e.g., "create-tracing-module — missing graceful degradation", "integrate-tracing Step 9 — .env.example missing OpenShift section", or "integrate-tracing Step 10 — README missing local MLflow install").
Before 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.
Deploy agents to OpenShift with auto-detected cluster config and refresh MLflow tracking tokens.
Add integration deployment tests (health-check on OpenShift) to any agent in the agentic-starter-kits repo — standard, external-registry, or pre-deployed. Creates conftest.py, test_deployment.py, __init__.py, adds test-integration Makefile target, and updates the CI workflow matrix. Use when implementing integration tests, deployment tests, or health-check tests for a new agent.
Validate whether a new agent template or example belongs in the agentic-starter-kits repo. Two modes: idea mode (interactive questionnaire, no code yet) or existing agent mode (auto-extract from code). Produces a GitHub Discussion draft with fit score and recommendations. Use when proposing a new agent, reviewing an existing contribution's fit, or before writing code for a new template.
Add behavioral testing (pytest + EvalHub) to an agent in the agentic-starter-kits repo. Covers runner compatibility, test files, golden queries, thresholds, EvalHub fixture, Containerfile, docs, and MLflow tracing verification. Use when implementing behavioral tests for a new agent or when the user mentions btest, behavioral tests, eval coverage, or test harness integration.
Adds manual MLflow trace wrapping for tool and agent spans in Level B and C agents where autolog doesn't cover everything.
Researches and classifies a framework's MLflow autolog support level (A, B, or C) to determine what manual tracing is needed.