Manage Tasks & Tasksets
Manage Tasks & Tasksets
A task is a stored, reusable definition of an agent-eval unit of work: an intent (what the agent
should do), the inputs it receives, and the metrics that score it. A taskset is a named grouping
of tasks. Both are first-class entities in the Evaluator plugin, addressed by workspace/name and
managed through the nemo_platform SDK.
Use stored tasks and tasksets when you want to define an evaluation unit once and reference it across runs, share it across a team, or assemble suites — rather than re-declaring the intent, inputs, and metrics inline every time.
Concepts
Both are addressed by workspace/name. Names are unique within a workspace, limited to 255
characters, and must match ^[\w\-\.]+$.
Tasks and tasksets support create, retrieve, list, and delete — there is no update. To change a stored task or taskset, delete it and create a new one, or store a new version under a different name.
Initialize the SDK
Manage Tasks
A task scores its output with metrics. Store the metric first, then reference it from the task by
workspace/name. See Manage Metrics for the
metric classes and options.
Send the task as a TaskInput (the authorable subset of a task) and address it by name on create.
Reference the stored metric with a MetricRef (workspace/name, or a bare name resolved against
the task’s workspace). The service returns the stored Task.
TaskInput fields
A stored task holds metric references only. Any inline metric bundle you pass on create is stored
as a content-addressed derived metric, and the task record is normalized to reference it. This is
why stored.metrics always comes back as a list of MetricRef references.
Retrieve, list, and delete
sort accepts name, created_at, or updated_at, each optionally prefixed with - for
descending order.
Manage Tasksets
A taskset references existing tasks by workspace/name. All referenced tasks must already exist when
the taskset is created; a missing or duplicate reference is rejected.
TasksetInput fields
Retrieve, list, and delete
Deleting a taskset does not delete its member tasks — a taskset only holds references.
Run an evaluation over a taskset
An agent evaluation is submitted with an AgentEvalInputSpec, whose tasks field is either an
inline list of tasks or a reference to a stored taskset. Referencing a taskset lets you keep the
task definitions in one place and evaluate the whole set by name, instead of inlining every task on
each run.
When the job runs, the taskset reference is resolved: its member tasks are loaded, and each task’s stored metric references are hydrated into runnable metrics — exactly as if you had inlined them. The same spec is submitted as the agent-evaluate job input; see Agent Evaluation for the full run, target, and results flow.
The inline form remains available for one-off tasks — swap tasks=TasksetRef(...) for
tasks=[AgentEvalTaskInput(...), ...].
Stored tasks carry no grader-only reference (held-out ground truth): that field lives only on inline
AgentEvalTaskInput. Taskset-driven tasks therefore run with an empty reference, so use a taskset
when your metrics score the agent’s output directly rather than against per-task held-out data.
Async usage
AsyncNeMoPlatform exposes the same surface; await each call.
Workspaces and projects
Every method accepts an optional workspace argument that overrides the client’s default workspace.
On create, an optional project argument associates the task or taskset with a project. When you
omit workspace, the client’s configured workspace is used.
REST API
The SDK resources are a thin client over the Evaluator plugin REST API, mounted under
/apis/evaluator/v2/workspaces/{workspace}:
Creating a name that already exists returns 409. An invalid metric reference (task) or a missing or
duplicate task reference (taskset) returns 422. Retrieving or deleting a name that does not exist
returns 404.
Related Topics
- Manage Metrics - Define and reuse the metrics that score a task
- SDK Resources - Run and submit evaluations through the Evaluator plugin
- Agent Evaluation - How agent-eval tasks are executed and scored