Prerequisites

To log data from your job runs, you need access to an ML Repository (MLRepo). ML Repositories store models, data, artifacts, and prompts and are backed by blob storage like S3, GCS, or Azure Blob Storage.

Grant ML Repository Access to Workspace

To enable your job to log data, you need to grant access to the ML Repository for your workspace:
  1. Go to Platform → Workspaces tab
  2. Edit your workspace
  3. In the “ML Repositories” section, grant access to your ML Repository
  4. Choose appropriate permissions (Viewer or Editor)

Creating Run and Logging Data

A run is used to represent a single ML experiment. You can create a run at the beginning of your script or notebook, log parameters, metrics, artifacts, models, tags and finally end the run. This provides an easy to keep track of all data related to ML experiments. A quick code snippet to create a run and end it:
from truefoundry.ml import get_client

client = get_client()
run = client.create_run(ml_repo="iris-demo", run_name="svm-model")
# Your code here.
run.end()
You can organize multiple runs under a single ml_repo. For example, the run svm-model will be created under the ml_repo iris-demo. Once you’ve created runs and logged data, you can view them in the TrueFoundry dashboard. Navigate to your job in the Platform → Applications tab, click on the job name, and go to the “Job Runs” tab to see all executions with their status, metrics, and parameters.
Job runs dashboard showing multiple runs with different statuses including finished, terminated, and failed runs

Job Runs Dashboard - Example showing multiple runs with different statuses

Logging Different Types of Data

Complete Examples

Here are comprehensive examples that demonstrate how to deploy a job and log data during machine learning training:

Accessing Detailed Run Information

In the Job Runs table, you’ll notice that the “RUN DETAILS” column contains clickable links. When you click on any run details link, you’ll be taken to a comprehensive view of that specific run, which includes:
  • Overview Tab: Key metrics and hyperparameters used in the run
  • Results Tab: Detailed metrics and performance data
  • Models Tab: All logged models with their metadata
  • Artifacts Tab: Files and artifacts associated with the run
Pro Tip: Use the run details view to analyze your experiments, compare different hyperparameter configurations, and track the progress of your machine learning projects over time.