Token导航 LogoToken导航TokenDH.com
研究检索敏感数据github未标认证来源可访问许可证需确认审计通过

instrumenting-with-mlflow-tracing使用 mlflow 追踪进行检测

Agent Skill

instrumenting-with-mlflow-tracing 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

5,117

周安装

205

GitHub Stars

35

下载量

1,656
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:instrumenting-with-mlflow-tracing(使用 mlflow 追踪进行检测)
来源仓库:https://github.com/mlflow/skills
仓库路径:skills/instrumenting-with-mlflow-tracing
安装命令:
npx skills add https://github.com/mlflow/skills --skill instrumenting-with-mlflow-tracing
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/mlflow/skills --skill instrumenting-with-mlflow-tracing

简介

使用 mlflow 追踪进行检测的技能帮助监控模型运行过程。

  • 它适用于日志记录、性能分析和实验复现等场景。
  • 安装自 mlflow/skills 仓库,集成到主流 AI 宿主平台。
  • 使用前需配置追踪后端,并注意数据存储位置与隐私合规。
  • instrumenting-with-mlflow-tracing 属于研究检索类 Skill,可作为该场景下的辅助能力补充。

SKILL.md

MLflow Tracing Instrumentation Guide

Language-Specific Guides

Based on the user's project, load the appropriate guide:

  • Python projects: Read references/python.md
  • TypeScript/JavaScript projects: Read references/typescript.md

If unclear, check for package.json (TypeScript) or requirements.txt/pyproject.toml (Python) in the project.


What to Trace

Trace these operations (high debugging/observability value):

Operation TypeExamplesWhy Trace
Root operationsMain entry points, top-level pipelines, workflow stepsEnd-to-end latency, input/output logging
LLM callsChat completions, embeddingsToken usage, latency, prompt/response inspection
RetrievalVector DB queries, document fetches, searchRelevance debugging, retrieval quality
Tool/function callsAPI calls, database queries, web searchExternal dependency monitoring, error tracking
Agent decisionsRouting, planning, tool selectionUnderstand agent reasoning and choices
External servicesHTTP APIs, file I/O, message queuesDependency failures, timeout tracking

Skip tracing these (too granular, adds noise):

  • Simple data transformations (dict/list manipulation)
  • String formatting, parsing, validation
  • Configuration loading, environment setup
  • Logging or metric emission
  • Pure utility functions (math, sorting, filtering)

Rule of thumb: Trace operations that are important for debugging and identifying issues in your application.


Verification

After instrumenting the code, always verify that tracing is working.

Planning to evaluate your agent? Tracing must be working before you run agent-evaluation. Complete verification below first.
  1. Run the instrumented code — execute the application or agent so that at least one traced operation fires
  2. Confirm traces are logged — use mlflow.search_traces() or MlflowClient().search_traces() to check that traces appear in the experiment:
import mlflow

traces = mlflow.search_traces(experiment_ids=["<experiment_id>"])
print(f"Found {len(traces)} trace(s)")
assert len(traces) > 0, "No traces were logged — check tracking URI and experiment settings"
  1. Verify spans were captured — confirm the trace contains the expected spans, not just an empty shell:
trace = traces.iloc[0]
spans = mlflow.get_trace(trace.trace_id).data.spans
print(f"Trace has {len(spans)} span(s)")
for span in spans:
    print(f"  - {span.name} ({span.span_type})")
  1. Report the result — tell the user how many traces and spans were found and confirm tracing is working

If no traces appear

Check these in order:

  • Tracking URI not set — is mlflow.set_tracking_uri(...) called before the agent run? Without this, traces go to a local ./mlruns directory instead of the configured server.
  • Autolog warnings — did mlflow.autolog() or framework-specific mlflow.<framework>.autolog() raise any warnings during setup? Check stderr for patching failures.
  • Wrong experiment ID — verify the experiment ID passed to search_traces() matches the experiment active when the code ran (mlflow.get_experiment_by_name(...) to confirm).
  • Network/auth issues — can the process reach the tracking server? Check for connection errors or 401/403 responses in logs.

For automated validation, use agent-evaluation/scripts/validate_tracing_runtime.py.


Feedback Collection

Log user feedback on traces for evaluation, debugging, and fine-tuning. Essential for identifying quality issues in production.

See references/feedback-collection.md for:

  • Recording user ratings and comments with mlflow.log_feedback()
  • Capturing trace IDs to return to clients
  • LLM-as-judge automated evaluation

Reference Documentation

Production Deployment

See references/production.md for:

  • Environment variable configuration
  • Async logging for low-latency applications
  • Sampling configuration (MLFLOW_TRACE_SAMPLING_RATIO)
  • Lightweight SDK (mlflow-tracing)
  • Docker/Kubernetes deployment

Advanced Patterns

See references/advanced-patterns.md for:

  • Async function tracing
  • Multi-threading with context propagation
  • PII redaction with span processors

Distributed Tracing

See references/distributed-tracing.md for:

  • Propagating trace context across services
  • Client/server header APIs

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

34.63%
按下载量换算573

Claude

29.61%
按下载量换算490

Cursor

17.82%
按下载量换算295

Gemini CLI

8.85%
按下载量换算147

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills