Dagger.Artifact (dagger v1.0.0-beta.19)

Copy Markdown View Source

One workspace value with a complete path and all required dimension keys. Reading metadata does not evaluate the value. Different addresses remain distinct even if they return the same object.

Summary

Functions

The arguments accepted by the artifact field.

The description of the field that supplies this artifact.

The module name, collection keys, and full path key in the artifact type dimension.

The directives carried by this artifact.

A unique identifier for this Artifact.

A module load failure, or an empty string if discovery succeeded.

The installed module name.

Ordered, literal fields to follow. Entrypoint targets use their shorthand.

The artifact's DAG address, such as dag://engine-dev/playground.

Evaluate the target in the workspace that supplied this artifact.

The workspace this artifact was discovered in; its address is relative to it. Null for an artifact without a workspace, such as one of an LLM's bound tool objects (see LLM.artifacts).

Types

t()

@type t() :: %Dagger.Artifact{client: term(), query_builder: term()}

Functions

arguments(artifact)

@spec arguments(t()) :: {:ok, [Dagger.FunctionArg.t()]} | {:error, term()}

The arguments accepted by the artifact field.

description(artifact)

@spec description(t()) :: {:ok, String.t()} | {:error, term()}

The description of the field that supplies this artifact.

dimension_keys(artifact)

@spec dimension_keys(t()) ::
  {:ok, [Dagger.ArtifactDimensionKey.t()]} | {:error, term()}

The module name, collection keys, and full path key in the artifact type dimension.

directives(artifact)

@spec directives(t()) :: {:ok, [String.t()]} | {:error, term()}

The directives carried by this artifact.

id(artifact)

@spec id(t()) :: {:ok, String.t()} | {:error, term()}

A unique identifier for this Artifact.

load_error(artifact)

@spec load_error(t()) :: {:ok, String.t()} | {:error, term()}

A module load failure, or an empty string if discovery succeeded.

module_name(artifact)

@spec module_name(t()) :: {:ok, String.t()} | {:error, term()}

The installed module name.

path(artifact)

@spec path(t()) :: {:ok, [String.t()]} | {:error, term()}

Ordered, literal fields to follow. Entrypoint targets use their shorthand.

uri(artifact, optional_args \\ [])

@spec uri(t(),
  absolute: boolean() | nil,
  dimension_keys: boolean() | nil,
  type_assertion: boolean() | nil
) :: {:ok, String.t()} | {:error, term()}

The artifact's DAG address, such as dag://engine-dev/playground.

value(artifact, arguments)

@spec value(t(), Dagger.JSON.t()) :: Dagger.Node.t()

Evaluate the target in the workspace that supplied this artifact.

workspace(artifact)

@spec workspace(t()) :: {:ok, Dagger.Workspace.t() | nil} | {:error, term()}

The workspace this artifact was discovered in; its address is relative to it. Null for an artifact without a workspace, such as one of an LLM's bound tool objects (see LLM.artifacts).