Building a Scalable ML Platform with Metaflow for Distributed LLM Training

autodesk · Tech · year n/a · source Agentic: no · promotional bias: low · source-backed · extracted with prompt 0.5.4 (schema v2)

Generated from extraction.json — do not edit by hand. Every claim cites verbatim source evidence; stated means the quote directly asserts the claim, implied means it supports it indirectly.

Problem

Domain: Enterprise ML platform for distributed LLM training

Autodesk needed a unified ML platform that data scientists would actually adopt, replacing bespoke team platforms while supporting reproducible workflows, AWS-managed execution, secure personal IDE instances, production deployment, distributed GPU training, and high-performance storage/networking for large models and datasets.

Constraints:

Architecture

Autodesk built AMP around Metaflow and AWS. Users enter through an AM Studio UI backed by SageMaker Studio, SSO, team project domains, and personal Studio instances. Metaflow orchestrates data prep, training, evaluation, versioning, and reproducible experiments, running AWS Batch jobs and production Step Functions. Distributed training uses Metaflow's parallel decorator, AWS Batch multi-node jobs, curated framework examples, GPU profiling, CloudWatch dashboards, and a custom Ray parallel decorator that creates transient Ray clusters. For HPC scale, Autodesk hardened EFA-enabled AMIs and integrated FSx for Lustre with S3 for low-latency training data access.

Diagram confidence: reconstructed (reconstructed from prose).

flowchart LR
  data-scientist[Data Scientist] --> am-studio[AM Studio]
  am-studio[AM Studio] --> sso[SSO]
  am-studio[AM Studio] --> metaflow[Metaflow]
  metaflow[Metaflow] --> aws-batch[AWS Batch]
  metaflow[Metaflow] --> step-functions[Step Functions]
  metaflow[Metaflow] --> metadata-service[Metadata Service]
  metaflow[Metaflow] --> ray-parallel-decorator[Ray Parallel Decorator]
  ray-parallel-decorator[Ray Parallel Decorator] --> ray-cluster[Ray Cluster]
  ray-cluster[Ray Cluster] --> aws-batch[AWS Batch]
  aws-batch[AWS Batch] --> gpu-nodes[GPU Nodes]
  gpu-nodes[GPU Nodes] --> cloudwatch[CloudWatch]
  gpu-nodes[GPU Nodes] --> efa-networking[EFA Networking]
  gpu-nodes[GPU Nodes] --> fsx-for-lustre[FSx for Lustre]
  step-functions[Step Functions] --> jenkins-lambda[Jenkins Lambda]
Drag to pan · scroll or use +/− to zoom · reconstructed from the source's described component topology

Components

Component Role Interacts with
Data Scientist Autodesk user building, training, evaluating, and deploying ML workflows. AM Studio
AM Studio Managed IDE and productivity suite based on SageMaker Studio. Data Scientist, Metaflow, SSO
SSO Authentication and authorization for data scientists and team project domains. AM Studio
Metaflow Workflow orchestration, versioning, experiment tracking, parallel execution, and production deployment abstraction. AM Studio, AWS Batch, Step Functions, Metadata Service, Ray Parallel Decorator
Metadata Service Metaflow metadata endpoint used for lineage, tags, experiment tracking, and production validation. Metaflow
AWS Batch Managed compute backend for scaling workflows, multi-node training, and Ray clusters. Metaflow, Ray Cluster, GPU Nodes, EFA Networking
Ray Parallel Decorator Custom Metaflow decorator that provisions Ray clusters through AWS Batch. Metaflow, Ray Cluster
Ray Cluster Transient driver/worker cluster for distributed Ray Train applications. Ray Parallel Decorator, AWS Batch, GPU Nodes
GPU Nodes A10/A100 GPU compute nodes for distributed model training. AWS Batch, CloudWatch, EFA Networking, FSx for Lustre
CloudWatch Dashboards for GPU and CPU utilization when users do not use Metaflow GPU profiling. GPU Nodes
Step Functions Production orchestrator for compiled Metaflow flows. Metaflow, Jenkins Lambda
Jenkins Lambda CI/CD bridge that validates PRs and invokes production Step Functions. Step Functions, Metaflow
EFA Networking Elastic Fabric Adapter networking for low-latency inter-node communication. AWS Batch, GPU Nodes
FSx for Lustre High-performance parallel filesystem synced with S3 for training data access. GPU Nodes

Data flow

A data scientist logs into AM Studio through SSO, launches a personal SageMaker Studio instance, writes a Metaflow pipeline, runs training/evaluation through AWS Batch, monitors GPU/CPU utilization in Metaflow UI or CloudWatch, and can promote a prod-ready run through GitHub, Jenkins, Lambda, and Step Functions. For Ray jobs, Metaflow creates a transient Ray cluster on AWS Batch, runs the Ray application, and shuts it down after completion.

3 supporting quotes
“access Studio users interact with a UI which in turn spins up their own personal Studio instances um once they are logged into the studio various tools um metap is one of those tools uh users can leverage to create and orchestrate ml pipelines run”transcript, stated
“users can leverage to create and orchestrate ml pipelines run reproducible experiments perform training a scale”transcript, stated
“during execution metap starts the transient Ray cluster runs the ray application and then subsequently shuts down the cluster”transcript, stated

Why this architecture

Autodesk chose Metaflow because it unified orchestration, compute, versioning, reproducibility, and AWS Batch integration while offering a user experience strong enough to move teams off bespoke platforms. AWS Batch handled infrastructure, Ray handled distributed hardware usage, EFA mitigated inter-node bottlenecks, and FSx for Lustre avoided repeated S3 reads for terabyte-scale training data.

3 supporting quotes
“we evaluated a lot of different orchestration tools but landed on metaflow as we like that it could be used um for a variety of different applications”transcript, stated
“human human Centric ux uh one of our biggest worries would be building tooling that wouldn't be adopted or used by our users”transcript, stated
“cluster so um batch handles the infrastructure setting up the drivers and workers while Ray optimizes Hardware usage um so we use um existing abstractions from the parallel decorator and then teamed up with outer bounds to introduce um a ray parallel decorator”transcript, stated

Models used: 3 billion parameter model · 6 billion GPT-J model · DeepSpeed · Ray Train · PyTorch Lightning · Hugging Face Accelerate · TensorFlow Distributed

Scale

Alternatives considered (roads not taken)

Let teams keep bespoke ML platforms

Rejected because: Existing tech debt meant the new platform needed strong UX to motivate migration.

“debt in our organization so some users already have their own bespoke Emma platform so they was going um for them to adopt a our approach it would need to have really strong ux um so that they feel more motivated to transition to our platform than their own bespoke MMO”transcript, stated
“to adopt a our approach it would need to have really strong ux um so that they feel more motivated to transition to our platform than their own bespoke MMO platforms um so this is a highle overview of how we've integrated metaflow into our managed IDE um and we're using stagemaker Studio for our”transcript, stated

Treat Ray as competing with Metaflow

Rejected because: The team realized Ray was complementary: Batch handled infrastructure and Ray optimized hardware usage.

“Ray doesn't necessarily compete with metap they are um very much complimentary of each other so actually the more apt comparison would be raise VM launcher versus aw batch so uh what I was curious to see is if we could run a ray cluster using AWS batch uh”transcript, stated
“cluster so um batch handles the infrastructure setting up the drivers and workers while Ray optimizes Hardware usage um so we use um existing abstractions from the parallel decorator and then teamed up with outer bounds to introduce um a ray parallel decorator”transcript, stated

Read terabytes of training data directly from S3 into memory or disk

Rejected because: FSx for Lustre gives parallel low-latency access synced with S3.

“that instead of reading it in directly from S3 and saving and saving it to memory or dis space um we can instead use FSX for lusters to sync with S3 and then the user can pull in the data from the file system directly um it's also a parallel file system so it handles”transcript, stated
“use FSX for lusters to sync with S3 and then the user can pull in the data from the file system directly um it's also a parallel file system so it handles simultaneous access from the multiple nodes of the HBC cluster and then um we integrated metlow with FSX for luster um”transcript, stated

Patterns

durable-execution (workflow)

Metaflow versions flow runs, data snapshots, artifacts, and experiments, then compiles prod flows into Step Functions.

“version pretty much everything um including flow runs data snapshots artifacts and it keeps track of all the flows and experiments”transcript, stated
“it is deployed um as a step function or compiled as a step function”transcript, stated

batch-offline-processing (training)

AWS Batch multi-node jobs run distributed training through Metaflow parallel decorators.

“metapo parallel decorator uh which runs aw spatch multi node parallel jobs to run distri trading”transcript, stated

observability-tracing (operations)

Metaflow UI, GPU profiling, CloudWatch dashboards, and node logs expose distributed training progress and utilization.

“we monitor the GPU CPU utilization of our distributed training jobs using um the metap guei”transcript, stated
“we also provide out of the box cloudwatch dashboards as well that show the GPU um CPU utilization”transcript, stated

latency-optimization (infrastructure)

EFA and FSx for Lustre reduce inter-node communication and training data access bottlenecks.

“EFA will play a huge role in mitigating that bottleneck”transcript, stated
“FSX for luster and that provides low latency access to um data”transcript, stated

Tradeoffs

Choose Metaflow as the orchestration backbone

Chose Metaflow over Other orchestration tools and bespoke platforms.

Rationale: Metaflow covered data, compute, orchestration, versioning, AWS Batch integration, reproducibility, and experiment tracking with a user-friendly workflow.

“landed on metaflow as we like that it could be used um for a variety of different applications”transcript, stated
“reproducible experiments are the bread and butter of metaflow”transcript, stated

Integrate Ray through Metaflow rather than replacing Metaflow

Chose Ray parallel decorator on Metaflow/AWS Batch over Separate Ray launcher path.

Rationale: This kept Ray available to users without fragmenting the managed training platform.

“Ray doesn't necessarily compete with metap they are um very much complimentary of each other”transcript, stated
“users just need to insert their Ray code in the step”transcript, stated

Use FSx for Lustre with S3

Chose Parallel filesystem synced with S3 over Direct S3 reads into memory or disk.

Rationale: FSx improved low-latency, simultaneous multi-node access for terabytes of training data.

“parallel file system so it handles simultaneous access from the multiple nodes of the HBC cluster”transcript, stated
“user can pull in the data from the file system directly”transcript, stated

Gotchas (what bit them)

A technically strong platform can fail if users do not adopt it.

Root cause: Some teams already had bespoke ML platforms, so switching required strong UX.

Resolution: Autodesk centered the platform around AM Studio, personal Studio instances, and familiar Metaflow workflows.

“one of our biggest worries would be building tooling that wouldn't be adopted or used by our users”transcript, stated
“it would need to have really strong ux”transcript, stated

Ray integration was initially a blocker for a research team.

Root cause: A team had invested in Ray while the platform had already chosen Metaflow.

Resolution: Autodesk built a Ray parallel decorator so Metaflow could orchestrate transient Ray clusters on AWS Batch.

“a little bit of a blocker because we needed to figure out a way to integrate Ray with our manage training infrastructure powered by metaflow”transcript, stated
“we discovered that it was in fact possible to use metap to orchestrate the creation of the ray cluster”transcript, stated

Larger models made inter-node communication a bottleneck.

Root cause: Distributed training nodes must exchange data and synchronize model updates.

Resolution: The team security-hardened EFA-enabled deep learning AMIs and integrated them with AWS Batch.

“when working with larger models and enormous amounts of data internode communication um becomes a huge bottleneck”transcript, stated
“security Harden the Deep learning Ami the aw has that comes with the EA driver installed”transcript, stated

Evaluation

Autodesk validates flows through unit tests, optional flow runs, prod-ready tags, metadata checks, GPU/CPU utilization monitoring, CloudWatch dashboards, and distributed training benchmarks.

Metrics: GPU utilization · CPU utilization · node logs · flow run metadata tags · training time for 6B model · number of GPU nodes

3 supporting quotes
“runs unit tests uh for the individual modules with um Pi test optionally runs the flow itself”transcript, stated
“checks that the corresponding flow has um the appropriate tag”transcript, stated
“we monitor the GPU CPU utilization of our distributed training jobs”transcript, stated

Outcomes

The transcript frames the platform as early, with 50 users, but shows a roadmap toward hundreds or thousands of nodes and terabytes of training data.

3 supporting quotes
“we recently just rolled out to 50 users”transcript, stated
“fine tuning job completed in about 50 minutes um just using 16 A10 um GPU nodes”transcript, stated
“a way forward to scale up to hundreds or thousands of nodes with low latency inter node communication”transcript, stated