Prepare and test your skills

Prepare and test your skills

Free sample question with answers and detailed explanation below. The Professional Machine Learning Engineer practice bank has an additional 974 practice questions.Try 10 free realistic questions: instant score, no credit card, and no account required.
Your team is building an automated continuous training pipeline on Agent Platform Pipelines using the Kubeflow Pipelines (KFP) v2 SDK. During testing, you observe several bottlenecks and reliability gaps:
ParDo transforms create duplicate temporary outputs.CustomTrainingJobOp tasks to re-execute from scratch, and deployment lacks metric gating.Which implementation strategy should you adopt to ensure idempotency, fault tolerance, conditional deployment, and cost-efficient execution?
.after() dependencies, configure a single pipeline-wide machine type, and pass mutually exclusive dsl.If/dsl.Else model outputs directly to downstream components without OneOf. Replace execution caching with manual Cloud Storage marker files checked by dsl.ExitHandler, and route Dataflow ParDo outputs through a single-key GroupByKey to prevent parallel worker retries.This configuration forces strictly sequential DAG execution using .after() dependencies, applies a single pipeline-wide hardware profile, omits dsl.OneOf when merging conditional branches, replaces native caching with manual marker files, and forces Dataflow ParDo outputs through a single-key GroupByKey.
dsl.If and dsl.Else blocks (such as uploading a brand-new model versus uploading a version to an existing parent model) cannot have both branch outputs wired directly into a downstream component. dsl.OneOf is required to unify the active artifact reference at runtime..after() across all steps prevents independent tasks—such as deployment infrastructure validation and model evaluation—from executing in parallel. Similarly, routing all elements through a single-key GroupByKey creates a severe hot-key bottleneck, forcing execution onto a single worker thread and causing backpressure.dsl.ExitHandler and wastes resources: dsl.ExitHandler is designed for post-execution cleanup or failure notifications (such as VertexNotificationEmailOp), not as a substitute for Agent Platform Pipelines execution caching. Applying one pipeline-wide machine type also wastes expensive resources on lightweight steps.OneOf across conditional ModelUploadOp branches causes type and wiring conflicts when compiling the KFP DAG.GroupByKey defeat horizontal autoscaling and dynamic work rebalancing in Dataflow.All downstream tasks strictly depended on a single sequential chain without conditional branching and required aggregating records under a genuinely distributed key space using Combine.PerKey. For multi-branch ML workflows, native OneOf, per-component specs, and execution caching are essential.
DoFn transforms to persist intermediate state in local temporary files across worker retries, and use standard Python if/else statements inside the @dsl.pipeline function to gate deployment.Packaging all stages into a single shared container with a uniform GPU spec attempts to simplify environment management, while relying on local temporary files inside DoFn transforms, standard Python if/else statements, and disabled caching tries to manage execution flow imperatively.
DoFn is invoked, how elements are bundled, or how many worker instances are created, and it may run backup copies of tasks. Relying on mutable state or non-unique temporary files on local worker disks causes race conditions, data corruption, and duplicate records during worker retries.if/else statements inside a @dsl.pipeline function are evaluated at pipeline compile time, not at runtime. They cannot inspect runtime evaluation metrics produced by an upstream evaluation component to conditionally gate ModelDeployOp.CustomTrainingJobOp steps to re-run from scratch after any downstream failure.dsl.If, dsl.Else, and OneOf primitives rather than native Python conditionals.You were prototyping a tiny, single-step script without distributed Dataflow transforms, runtime conditional deployment, or heterogeneous compute needs. For production MLOps pipelines, per-component containers, pure DoFn functions, KFP control flows, and execution caching are required.
dsl.ExitHandler notifications in Agent Platform Pipelines. Author Dataflow DoFn transforms as deterministic pure functions without non-unique temporary files, run independent validation tasks in parallel, and use dsl.If/dsl.Else with OneOf to gate model registration and deployment.Combining containerized Kubeflow Pipelines (KFP) v2 components on Agent Platform Pipelines with stateless Dataflow transforms creates a modular, fault-tolerant, and cost-optimized ML workflow. Each stage runs in an isolated runtime with explicit input/output contracts, while Vertex ML Metadata tracks intermediate artifacts and execution states across runs.
DoFn transforms as deterministic pure functions without hidden state or non-unique temporary files ensures that automatic worker retries produce identical results without corrupting outputs. Configuring component-level retries, a failure policy, and a dsl.ExitHandler notification task automates recovery from transient errors and alerts engineers when unrecoverable failures occur.CustomTrainingJobOp while lightweight evaluation tasks run on smaller CPU instances.dsl.If and dsl.Else blocks merged with dsl.OneOf dynamically handles new versus versioned model registration (ModelUploadOp) and acts as a conditional gate so ModelDeployOp runs only when evaluation metrics surpass baseline thresholds.Unlike monolithic containers, static Python branching, or manual state flags, this design leverages native KFP v2 control flows, managed caching, and Apache Beam execution guarantees together. It directly eliminates duplicate preprocessing writes, wasted GPU allocation, redundant retraining costs, and unsafe model promotions.
:latest container tags. Disable component retries in favor of a strict fail-fast policy for transient failures, evaluate candidate models on the training split to maximize cache hits, and execute ModelDeployOp in parallel with offline validation without conditional branching.This design pairs Cloud Workflows with scheduled Agent Platform Workbench notebooks, uses Classic Dataflow templates with mutable :latest container tags, disables component retries in favor of fail-fast termination, evaluates models on training data, and deploys unconditionally in parallel with validation.
:latest container tags allows unverified image changes to enter production; production pipelines should use Flex Templates (or custom containers) pinned by immutable cryptographic SHA digests (@sha256:...). Scheduled Workbench notebooks also couple execution to monolithic VMs without native per-step Vertex ML Metadata lineage or component caching.ModelDeployOp unconditionally in parallel with offline validation allows unverified or degraded challenger models to serve live traffic before passing quality gates.dsl.If, dsl.ExitHandler).You were building a lightweight, non-ML infrastructure automation sequence via Cloud Workflows without requiring ML metadata tracking, distributed data preprocessing guarantees, or automated validation gates before production deployment.
Answer them yourself and get your score the moment you finish. No account needed.
Full access includes
Keep the momentum going with these hand-picked practice scenarios
Last updated Validated