First-class artifact info: Literal.artifact_id + Outputs.produced_artifacts - #7760
Merged
Merged
Conversation
…ifacts Replaces the implicit metadata-key contract (magic "_ua"/"_uap" keys in Literal.metadata carrying JSON payloads that SDKs and backends had to keep in sync) with typed fields, split by lifecycle: - core.ArtifactVersionId (ArtifactKey + version), core.ArtifactCard (hoisted from artifact.Card, same shape), and core.ArtifactInfo (description, user_metadata, card) — the descriptive payload shared by the production declaration and the stored spec, deliberately excluding identity so the two can never drift. - core.Literal.artifact_id: the value's artifact identity, stamped once at registration and on artifact-bound inputs; travels with the value through every copy and participates in cache-key hashing by design. - task.ProducedArtifact + Outputs.produced_artifacts: the transient registration declaration (output name, artifact name, optional version, info, declared type) — an action-scoped instruction that never enters the value stream. Field 3 on Outputs because outputs.pb blobs are sometimes cross-decoded as task.Inputs, where field 2 is context. - artifact.ArtifactSpec now nests the descriptive payload as core.ArtifactInfo (value/type/source stay top-level); artifact.Card is removed in favor of core.ArtifactCard. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
wild-endeavor
approved these changes
Aug 4, 2026
| } | ||
|
|
||
| // Only valid for triggers | ||
| message ArtifactBindingData { |
| @@ -14,6 +15,42 @@ message ArtifactKey { | |||
| string org = 4; | |||
Contributor
There was a problem hiding this comment.
should we add validation to these fields?
kumare3
added a commit
that referenced
this pull request
Aug 4, 2026
* Add artifact trigger automation: TYPE_ARTIFACT + ArtifactTrigger Third TriggerAutomationSpec automation type: fire a run when a new version of the named artifact is created. ArtifactTrigger carries the watched artifact name, an optional exact-version pin, and the task input the artifact's value binds to at fire time (mirroring Schedule.kickoff_time_input_arg). Also adds RUN_SOURCE_ARTIFACT_TRIGGER so artifact-triggered runs carry their provenance. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> * First-class artifact info: Literal.artifact_id + Outputs.produced_artifacts (#7760) Replaces the implicit metadata-key contract (magic "_ua"/"_uap" keys in Literal.metadata carrying JSON payloads that SDKs and backends had to keep in sync) with typed fields, split by lifecycle: - core.ArtifactVersionId (ArtifactKey + version), core.ArtifactCard (hoisted from artifact.Card, same shape), and core.ArtifactInfo (description, user_metadata, card) — the descriptive payload shared by the production declaration and the stored spec, deliberately excluding identity so the two can never drift. - core.Literal.artifact_id: the value's artifact identity, stamped once at registration and on artifact-bound inputs; travels with the value through every copy and participates in cache-key hashing by design. - task.ProducedArtifact + Outputs.produced_artifacts: the transient registration declaration (output name, artifact name, optional version, info, declared type) — an action-scoped instruction that never enters the value stream. Field 3 on Outputs because outputs.pb blobs are sometimes cross-decoded as task.Inputs, where field 2 is context. - artifact.ArtifactSpec now nests the descriptive payload as core.ArtifactInfo (value/type/source stay top-level); artifact.Card is removed in favor of core.ArtifactCard. Co-authored-by: Ketan Umare <kumare3@users.noreply.github.com> Co-authored-by: Claude Fable 5 <noreply@anthropic.com> --------- Co-authored-by: Ketan Umare <kumare3@users.noreply.github.com> Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
kumare3
added a commit
to flyteorg/flyte-sdk
that referenced
this pull request
Aug 4, 2026
…act_id
Replaces the magic literal-metadata keys ("_ua"/"_uap") with the typed fields
from flyteorg/flyte#7760, split by lifecycle:
- Producing: convert_from_native_to_outputs emits ProducedArtifact
declarations on the Outputs envelope (output name, artifact name, optional
version, ArtifactInfo, and the declared LiteralType — the SDK is
authoritative for it). The output literal itself carries nothing; the
compact-JSON codec and both metadata-key constants are deleted.
- Consuming: artifact-bound run inputs get the typed Literal.artifact_id
(core.ArtifactVersionId) — value-intrinsic identity, per-element for
collections, no string parsing.
- ArtifactSpec restructure: create() nests description/user_metadata/card as
spec.info (core.ArtifactInfo); the card type is the hoisted
core.ArtifactCard.
- Display: artifact_annotation reads the typed identity;
produced_artifact_annotation renders envelope declarations (Outputs repr and
ActionOutputs annotate from both).
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Stacked on #7749. Replaces the implicit metadata-key contract (magic
_ua/_uapkeys insideLiteral.metadatacarrying JSON payloads that the Python SDK and Go backends must keep byte-in-sync) with typed fields, split by lifecycle:Identity → the value (permanent, value-intrinsic):
core.ArtifactVersionId { ArtifactKey key; string version; }— minimal identity, deliberately not the v1-heritageArtifactID(no partition machinery)core.Literal.artifact_id— stamped once at artifact registration (and on artifact-bound inputs); travels with the value through every copy; participates in cache-key hashing by design (two versions of an artifact are distinct inputs even when bytes coincide)Registration declaration → the output envelope (transient, slot-scoped):
task.ProducedArtifact { output, name, version?, core.ArtifactInfo info, core.LiteralType type }+task.Outputs.produced_artifacts = 3— an action-scoped instruction that never enters the value stream or downstream hashes. Field 3 (not 2) becauseoutputs.pbblobs are cross-decoded astask.Inputs, where field 2 iscontext. The declaredtypemakes the declaration self-contained (backends no longer need a task-interface lookup with a silent nil-type drop).Shared descriptive payload:
core.ArtifactInfo { description, user_metadata, card }+core.ArtifactCard(hoisted fromartifact.Card, identical shape) — used verbatim by bothtask.ProducedArtifact.infoand the restructuredartifact.ArtifactSpec { value, type, info, source }, and excluding identity so declaration and spec can never drift.Consumers (union cloud leaseworker/artifact service, flyte-sdk) migrate in their respective stacks; the metadata keys are deleted outright there since the artifact stack is unreleased.
🤖 Generated with Claude Code
main