Skip to content

MLflow post-run export: take the tracking URI and token from the environment like W&B #5499

Open

Description

@prokotg

Use cases, pain points, and background

A post-run W&B export can take its API key from the environment (WANDB_API_KEY), so a submit config only needs wandb_project (#4974). MLflow does not behave the same way. The MLflow SDK reads MLFLOW_TRACKING_URI and MLFLOW_TRACKING_TOKEN itself, and the token is already ambient for the post-run export, but MLflowExportConfig still requires the tracking URI and the experiment name as settings, so the URI has to be written into the submit config or on the command line. The two backends should handle credentials and endpoints the same way. Raised in review of #4974.

Description

Let a post-run MLflow export take the tracking URI and the token from the environment, the way the W&B export takes its key.

Design

  • MLflowExportConfig would get the same kind of readiness rule as WandbExportConfig.is_available: the tracking URI becomes optional when it is supplied by the environment.
  • Care is needed with the URI. If neither a setting nor MLFLOW_TRACKING_URI is set, MlflowClient falls back to a local store, so an export that was meant for a tracking server would quietly write to a local directory. The exporter should fail with a clear message when it ends up with no URI.
  • gym eval submit validates on the submitting machine, which does not see the job's environment. For a submit config the check has to look at driver.env (for example MLFLOW_TRACKING_URI: host:MLFLOW_TRACKING_URI), or the exporter has to do the check at run time.

Out of scope

  • Changing the live MLflow exporter's activation rules.
  • Credentials as export settings in a submit config (they stay in driver.env).

Acceptance Criteria

  • A post-run MLflow export with only the experiment name set works when MLFLOW_TRACKING_URI is in the environment, and fails with a clear error when it is not.
  • gym eval submit accepts such a config when driver.env provides the URI, and rejects it with an actionable message when nothing does.
  • An explicit URI setting still takes precedence over the environment.
  • Tests cover both the accepted and the rejected cases, and the docs say which variables are read.

Activity

  1. added
    feature
    area:evaluation
    on Nov 3, 2026
  2. self-assigned this
    on Nov 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Platformarea:evaluationfeature

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions