v1alpha1

package
v0.41.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 10, 2026 License: Apache-2.0 Imports: 7 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package v1alpha1 holds the factory's Task API (SP3 §4). It shares the maku.ogenki.io group with the Room API but lives in its own package, so the factory's semantics stay outside the rooms core and can be split off without touching it. +kubebuilder:object:generate=true +groupName=maku.ogenki.io

Index

Constants

View Source
const (
	TaskKindCoordination = "coordination"
	TaskKindIntegration  = "integration"
)

The Task kinds coordination adds (MR2); an absent spec.kind is an ordinary work Task.

View Source
const (
	CoordinationPlanAPIVersion = "maku.ogenki.io/v1alpha1"
	CoordinationPlanKind       = "CoordinationPlan"
)

CoordinationPlan's own apiVersion and kind: plan data, not a registered Kind (MR2, MR12).

View Source
const (
	MaxCoordinationHistory             = 16
	MaxCoordinationConfirmations       = 16
	MaxCoordinationAuthorizations      = 16
	MaxCoordinationIntegrationAttempts = 16
	MaxCoordinationIncidents           = 4
	MaxPendingGenerations              = 2
)

The retention caps of a parent's bounded records: a writer appends with AppendNewest, so the oldest goes first and etcd's object stays bounded.

View Source
const (
	PlanningCostSupplied    = "supplied"
	PlanningCostNotSupplied = "notSupplied"
)

The PlanningCost values.

View Source
const (
	ConditionAccepted = "Accepted"

	ReasonNotThisFactory  = "NotThisFactory"  // another factory's object (D15)
	ReasonDefinedTwice    = "DefinedTwice"    // the repository is also in the file (D8)
	ReasonMissingRef      = "MissingRef"      // a reference names no object
	ReasonNoMergePolicy   = "NoMergePolicy"   // a Repository no MergePolicy names
	ReasonDuplicatePolicy = "DuplicatePolicy" // two MergePolicies name one Repository
	ReasonInvalid         = "Invalid"         // the factory's own validation refused it
)

The condition every factory resource carries, and the reasons it is false (factory resources D5, D8, D15).

View Source
const (
	PhaseReceived      = "Received"
	PhaseRejected      = "Rejected"
	PhaseTriaged       = "Triaged"
	PhaseQueued        = "Queued"
	PhaseImplementing  = "Implementing"
	PhaseNoOp          = "NoOp"
	PhaseReviewing     = "Reviewing"
	PhaseAwaitingCI    = "AwaitingCI"
	PhaseAutoMerging   = "AutoMerging"
	PhaseAwaitingHuman = "AwaitingHuman"
	PhaseMerged        = "Merged"
	PhaseVerifying     = "Verifying"
	PhaseDone          = "Done"
	PhaseReverted      = "Reverted"
	PhaseEscalated     = "Escalated"
	PhaseClosed        = "Closed"
	PhaseStopped       = "Stopped"
	// a parent waiting on its children: neither active nor terminal (splitter design SL12)
	PhaseSplit = "Split"
	// a coordination parent waiting on its family: neither active nor terminal (MR2)
	PhaseCoordinating = "Coordinating"
)

Task phases, the §4 state diagram.

View Source
const (
	ModelSourceTier          = "tier"
	ModelSourceReviewerModel = "reviewerModel"
	ModelSourceClassModels   = "classModels"
)

The sources of a run's model (RunProvenance.ModelSource).

View Source
const AnnotationDrill = "agents.ogenki.io/drill"

AnnotationDrill records a maintainer's factory/drill on the PR to revert (human path AM6): its revert is a drill, which the breaker does not count. "true", set by the poller with AnnotationRevert.

View Source
const AnnotationProfileDecision = "agents.ogenki.io/profile-decision"

AnnotationProfileDecision is the harness profile decision (name, source, reason, checks, testFirst as JSON) written in the same update as the spec it applies: a replay whose status write was lost recovers status.profile from it instead of deciding again under a changed config.

View Source
const AnnotationRevert = "agents.ogenki.io/revert"

AnnotationRevert records a maintainer's factory/revert on an auto-merged PR, within the window (§6.4).

View Source
const AnnotationStop = "agents.ogenki.io/stop"

AnnotationStop asks the factory to stop one task (§6.1): "true" set by hand, "label" set by the poller from factory/stop, "superseded" when a re-label replaces an escalated task (R4).

View Source
const LabelCoordinationParent = "agents.ogenki.io/coordination-parent"

LabelCoordinationParent carries a coordination child's or integration Task's parent name (MR2), independent of the splitter's LabelParent so the two lineages never collide.

View Source
const LabelIssue = "agents.ogenki.io/issue"

LabelIssue carries the number of the issue a task narrates on.

View Source
const LabelParent = "agents.ogenki.io/parent"

LabelParent carries a child task's parent's name (splitter design SL14): a family's cost is a selector sum, and the parent finds its children by it.

View Source
const LabelPublishedIssue = "agents.ogenki.io/published-issue"

LabelPublishedIssue carries the number of the issue the factory filed from an investigate task's proposal (RunLore agent-to-agent R9): the poller finds the origin of a started issue by it, in one List, as it finds a task by LabelIssue.

View Source
const SourceKindCoordination = "coordination"

SourceKindCoordination is a parent's and an integration Task's source kind, never api, so the API-sponsored semantics are never borrowed by accident (MR2).

Variables

View Source
var (
	GroupVersion  = schema.GroupVersion{Group: "maku.ogenki.io", Version: "v1alpha1"}
	SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes)
	AddToScheme   = SchemeBuilder.AddToScheme
)

SchemeBuilder uses the apimachinery builder directly: controller-runtime's pkg/scheme.Builder is deprecated for api packages (SA1019, lint budget).

Functions

func ActivePhase

func ActivePhase(p string) bool

ActivePhase is a task in motion: it counts against the active-task cap (§6.2).

func AppendNewest added in v0.38.0

func AppendNewest[T any](s []T, v T, maxLen int) []T

AppendNewest appends v and keeps the newest max records, dropping the oldest first.

func ChildOfLabel

func ChildOfLabel(parentIssue int) string

ChildOfLabel is the GitHub label on a child's issue naming its parent's (SL8): the ledger a rebuild reads, as a follow-up's factory/follow-up-of is.

func ParseChildOf

func ParseChildOf(label string) (int, bool)

ParseChildOf is the parent issue a child-of label names, in its canonical form only.

func Person

func Person(login string) string

Person is the ledger key of a GitHub login (v2 per-person caps D1): GitHub logins are case-insensitive, so the key is lowercased, and a label, a retry and a token name one key.

func SpendsDailyCap added in v0.30.2

func SpendsDailyCap(t *Task, now time.Time) bool

SpendsDailyCap reports whether t counts against the factory's daily task cap (§6.2) on now's UTC day: created that day, past its first reconcile (a phase is set) and not rejected, and not an adopted pull request (R39), which starts no run, and not a coordination parent (MR2), which runs nothing itself: its children and integration Tasks spend their own slots. The reconciler's admission and the API's refusal both read it.

func TerminalPhase

func TerminalPhase(p string) bool

TerminalPhase is a task that has ended: nothing moves it again.

Types

type ApprovalRef added in v0.37.0

type ApprovalRef struct {
	// +kubebuilder:validation:MaxLength=64
	By string `json:"by"`
	// +kubebuilder:validation:MaxLength=64
	Commit string `json:"commit"`
	// +kubebuilder:validation:Enum=older_commit;before_runs_ended
	// +optional
	Stale string `json:"stale,omitempty"`
}

ApprovalRef is a maintainer's APPROVED review as the room shows it: who, the commit approved, and why it is stale: older_commit, newer commits landed since; before_runs_ended, it names the head but came before the task's last pushing run ended. Empty while it is current.

func (*ApprovalRef) DeepCopy added in v0.37.0

func (in *ApprovalRef) DeepCopy() *ApprovalRef

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApprovalRef.

func (*ApprovalRef) DeepCopyInto added in v0.37.0

func (in *ApprovalRef) DeepCopyInto(out *ApprovalRef)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ArtifactConsumer added in v0.38.0

type ArtifactConsumer struct {
	// +kubebuilder:validation:MaxLength=32
	From string `json:"from"`
	// +kubebuilder:validation:MaxLength=64
	Artifact string `json:"artifact"`
	Required bool   `json:"required"`
}

ArtifactConsumer names a producer child's artifact this child requires (MR7).

func (*ArtifactConsumer) DeepCopy added in v0.38.0

func (in *ArtifactConsumer) DeepCopy() *ArtifactConsumer

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ArtifactConsumer.

func (*ArtifactConsumer) DeepCopyInto added in v0.38.0

func (in *ArtifactConsumer) DeepCopyInto(out *ArtifactConsumer)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ArtifactSpec added in v0.38.0

type ArtifactSpec struct {
	// +kubebuilder:validation:Pattern=`^[a-z][a-z0-9-]{0,63}$`
	// +kubebuilder:validation:MaxLength=64
	Name string `json:"name"`
	// The only initial artifact kind.
	// +kubebuilder:validation:Enum=file
	Kind string `json:"kind"`
	// +kubebuilder:validation:MinLength=1
	// +kubebuilder:validation:MaxLength=512
	Path string `json:"path"`
	// +kubebuilder:validation:MaxLength=128
	// +optional
	MediaType string `json:"mediaType,omitempty"`
	// +kubebuilder:validation:Minimum=1
	// +kubebuilder:validation:Maximum=65536
	MaxBytes int64 `json:"maxBytes"`
}

ArtifactSpec is a file a child produces, consumable only at its landed merge commit (MR7).

func (*ArtifactSpec) DeepCopy added in v0.38.0

func (in *ArtifactSpec) DeepCopy() *ArtifactSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ArtifactSpec.

func (*ArtifactSpec) DeepCopyInto added in v0.38.0

func (in *ArtifactSpec) DeepCopyInto(out *ArtifactSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Budget

type Budget struct {
	// +kubebuilder:validation:Enum=light;standard;frontier
	// +optional
	Tier string `json:"tier,omitempty"`
	// +kubebuilder:validation:MaxLength=64
	// +optional
	Model string `json:"model,omitempty"`
	// The per-run cap; SP1's XRD refuses more than the gateway ceiling (C3).
	// +kubebuilder:validation:Maximum=5000000
	// +optional
	RunTokens int64 `json:"runTokens,omitempty"`
	// +optional
	TaskTokens int64 `json:"taskTokens,omitempty"`
	// +kubebuilder:validation:Maximum=480
	// +optional
	RunMinutes int64 `json:"runMinutes,omitempty"`
	// The USD caps in micro-dollars (OD-6 (b)): a run's, and the task's in place of TaskTokens
	// while every run of the task is priced. 0: the token caps.
	// +kubebuilder:validation:Minimum=0
	// +optional
	RunMicroUSD int64 `json:"runMicroUSD,omitempty"`
	// +kubebuilder:validation:Minimum=0
	// +optional
	TaskMicroUSD int64 `json:"taskMicroUSD,omitempty"`
}

Budget is the task's tier and caps, resolved at triage.

func (*Budget) DeepCopy

func (in *Budget) DeepCopy() *Budget

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Budget.

func (*Budget) DeepCopyInto

func (in *Budget) DeepCopyInto(out *Budget)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ChildAuthorization added in v0.38.0

type ChildAuthorization struct {
	// +kubebuilder:validation:MaxLength=32
	ChildID string `json:"childID"`
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{64}$`
	// +kubebuilder:validation:MaxLength=64
	ChildFingerprint string `json:"childFingerprint"`
	// +kubebuilder:validation:Minimum=1
	PlanVersion int32 `json:"planVersion"`
	// +kubebuilder:validation:MaxLength=128
	Actor string `json:"actor"`
	// +kubebuilder:validation:Pattern=`^[A-Za-z0-9-]+/[A-Za-z0-9._-]+$`
	// +kubebuilder:validation:MaxLength=140
	Repository string `json:"repository"`
	// The maintainer's GitHub permission on Repository when they authorized.
	// +kubebuilder:validation:Enum=write;maintain;admin
	Permission string `json:"permission"`
	// The repository's fence file blob on its default branch when they authorized.
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{40}$`
	// +kubebuilder:validation:MaxLength=40
	FenceSHA    string      `json:"fenceSHA"`
	ConfirmedAt metav1.Time `json:"confirmedAt"`
}

ChildAuthorization is a child repository's linked maintainer authorizing one child fingerprint, with the write permission and fence read at that time (MR5, MR6).

func (*ChildAuthorization) DeepCopy added in v0.38.0

func (in *ChildAuthorization) DeepCopy() *ChildAuthorization

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ChildAuthorization.

func (*ChildAuthorization) DeepCopyInto added in v0.38.0

func (in *ChildAuthorization) DeepCopyInto(out *ChildAuthorization)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ClassStatus added in v0.41.0

type ClassStatus struct {
	// +kubebuilder:validation:MaxLength=63
	Name string `json:"name"`
	// +kubebuilder:validation:Enum=live;shadow;unarmed
	Mode string `json:"mode"`
	// +kubebuilder:validation:MaxLength=63
	LastDecision   string       `json:"lastDecision,omitempty"`
	LastDecisionAt *metav1.Time `json:"lastDecisionAt,omitempty"`
}

ClassStatus is one class's mode and last decision (D10, narrowed for v1).

func (*ClassStatus) DeepCopy added in v0.41.0

func (in *ClassStatus) DeepCopy() *ClassStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClassStatus.

func (*ClassStatus) DeepCopyInto added in v0.41.0

func (in *ClassStatus) DeepCopyInto(out *ClassStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Classification

type Classification struct {
	// +kubebuilder:validation:Enum=light;standard;frontier
	Tier string `json:"tier"`
	// 0.0–1.0, as a string: CRDs avoid floats.
	// +kubebuilder:validation:MaxLength=16
	// +optional
	Confidence string `json:"confidence,omitempty"`
	// +kubebuilder:validation:MaxLength=128
	Classifier string `json:"classifier"`
	// +kubebuilder:validation:Enum=none;default;static
	Fallback string `json:"fallback"`
	// +kubebuilder:validation:MaxItems=16
	// +optional
	Shadow []ShadowVerdict `json:"shadow,omitempty"`
	// OD-14: forced to tier-frontier whatever the classifier said.
	// +optional
	Control bool `json:"control,omitempty"`
	// Scored when the task ends (§7): under, over or fit.
	// +kubebuilder:validation:MaxLength=16
	// +optional
	Fit string `json:"fit,omitempty"`
}

Classification is the complexity classifier's verdict on the task (C7).

func (*Classification) DeepCopy

func (in *Classification) DeepCopy() *Classification

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Classification.

func (*Classification) DeepCopyInto

func (in *Classification) DeepCopyInto(out *Classification)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ConfigGenerations added in v0.41.0

type ConfigGenerations struct {
	Factory     int64 `json:"factory,omitempty"`
	Repository  int64 `json:"repository,omitempty"`
	MergePolicy int64 `json:"mergePolicy,omitempty"`
}

ConfigGenerations are the generations of the factory's resources a task was triaged under (factory resources D5): recorded, not pinned. Zero means the file.

func (*ConfigGenerations) DeepCopy added in v0.41.0

func (in *ConfigGenerations) DeepCopy() *ConfigGenerations

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConfigGenerations.

func (*ConfigGenerations) DeepCopyInto added in v0.41.0

func (in *ConfigGenerations) DeepCopyInto(out *ConfigGenerations)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ContractStatus

type ContractStatus struct {
	// +kubebuilder:validation:MaxLength=253
	RunID string `json:"runId"`
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{40}$`
	// +kubebuilder:validation:MaxLength=40
	Commit string `json:"commit"`
	// +kubebuilder:validation:MinItems=1
	// +kubebuilder:validation:MaxItems=50
	// +kubebuilder:validation:items:MaxLength=512
	Files []string `json:"files"`
	// +kubebuilder:validation:MinItems=1
	// +kubebuilder:validation:MaxItems=50
	// +kubebuilder:validation:items:MaxLength=512
	IDs []string `json:"ids"`
}

ContractStatus is the tester's commit, its files and the test ids it names.

func (*ContractStatus) DeepCopy

func (in *ContractStatus) DeepCopy() *ContractStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ContractStatus.

func (*ContractStatus) DeepCopyInto

func (in *ContractStatus) DeepCopyInto(out *ContractStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type CoordinationAcceptance added in v0.38.0

type CoordinationAcceptance struct {
	// +kubebuilder:validation:Pattern=`^[a-z2-7]{8}$`
	// +kubebuilder:validation:MaxLength=8
	IntegrationTask string `json:"integrationTask"`
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{64}$`
	// +kubebuilder:validation:MaxLength=64
	ManifestHash string      `json:"manifestHash"`
	AcceptedAt   metav1.Time `json:"acceptedAt"`
}

CoordinationAcceptance is the passing final integration over every child's merge commit.

func (*CoordinationAcceptance) DeepCopy added in v0.38.0

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CoordinationAcceptance.

func (*CoordinationAcceptance) DeepCopyInto added in v0.38.0

func (in *CoordinationAcceptance) DeepCopyInto(out *CoordinationAcceptance)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type CoordinationBudgetStatus added in v0.38.0

type CoordinationBudgetStatus struct {
	// +kubebuilder:validation:Minimum=0
	PlanningMicroUSD int64 `json:"planningMicroUSD"`
	// +kubebuilder:validation:Minimum=0
	TotalMicroUSD int64 `json:"totalMicroUSD"`
	// +kubebuilder:validation:Minimum=0
	AllocatedMicroUSD int64 `json:"allocatedMicroUSD"`
	// The planning attempts' cost as the shared intake route reconciled it, summed over distinct
	// attempts; at confirmation reserved plus settled fits planningMicroUSD (MR8).
	// +kubebuilder:validation:Minimum=0
	// +optional
	PlanningReservedMicroUSD int64 `json:"planningReservedMicroUSD,omitempty"`
	// +kubebuilder:validation:Minimum=0
	// +optional
	PlanningSettledMicroUSD int64 `json:"planningSettledMicroUSD,omitempty"`
	// PlanningCost is supplied when the newest attempt carried its reservation or settlement
	// identifiers, notSupplied when the shared contract gave none: never an invented AgentRun id.
	// +kubebuilder:validation:Enum=supplied;notSupplied
	// +optional
	PlanningCost string `json:"planningCost,omitempty"`
	// The planning attempts already counted, newest last, so a replayed attempt counts once.
	// +kubebuilder:validation:MaxItems=16
	// +kubebuilder:validation:items:MaxLength=128
	// +optional
	PlanningAttempts []string `json:"planningAttempts,omitempty"`
}

CoordinationBudgetStatus is the family's confirmed lifetime ceiling and its static allocations (MR8); per-run spend stays on the ledger and the runs.

func (*CoordinationBudgetStatus) DeepCopy added in v0.38.0

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CoordinationBudgetStatus.

func (*CoordinationBudgetStatus) DeepCopyInto added in v0.38.0

func (in *CoordinationBudgetStatus) DeepCopyInto(out *CoordinationBudgetStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type CoordinationChild added in v0.38.0

type CoordinationChild struct {
	// +kubebuilder:validation:Pattern=`^[a-z][a-z0-9-]{0,31}$`
	// +kubebuilder:validation:MaxLength=32
	ID string `json:"id"`
	// +kubebuilder:validation:Pattern=`^[A-Za-z0-9-]+/[A-Za-z0-9._-]+$`
	// +kubebuilder:validation:MaxLength=140
	Repository string `json:"repository"`
	// The linked maintainer who authorizes this child, github:<login> (MR5).
	// +kubebuilder:validation:Pattern=`^github:[A-Za-z0-9][A-Za-z0-9-]{0,38}$`
	// +kubebuilder:validation:MaxLength=46
	Maintainer string `json:"maintainer"`
	// +kubebuilder:validation:MaxLength=1024
	// +optional
	Rationale string `json:"rationale,omitempty"`
	// Resolved from the repository's own allowance, never declared by the plan.
	// +kubebuilder:validation:MaxLength=64
	Class string `json:"class"`
	// +kubebuilder:validation:Enum=light;standard;frontier
	Tier string `json:"tier"`
	// Derived from the class's harness, in its order.
	// +kubebuilder:validation:MinItems=1
	// +kubebuilder:validation:MaxItems=4
	// +kubebuilder:validation:items:Enum=implementer;reviewer;tester;triager
	Roles []string `json:"roles"`
	// The lifetime allocation across every generation and retry of the child (MR8).
	// +kubebuilder:validation:Minimum=0
	// +kubebuilder:validation:Maximum=1000000000
	BudgetMicroUSD int64     `json:"budgetMicroUSD"`
	Scope          TaskScope `json:"scope"`
	// +kubebuilder:validation:MaxItems=8
	// +optional
	Produces []ArtifactSpec `json:"produces,omitempty"`
	// The child ids whose landing orders this child's admission (MR7).
	// +kubebuilder:validation:MaxItems=1
	// +kubebuilder:validation:items:MaxLength=32
	// +optional
	DependsOn []string `json:"dependsOn,omitempty"`
	// +kubebuilder:validation:MaxItems=8
	// +optional
	Consumes []ArtifactConsumer `json:"consumes,omitempty"`
}

CoordinationChild is one repository-local change of the plan, with its own maintainer, resolved class, roles and lifetime allocation (MR5, MR8). +kubebuilder:validation:XValidation:rule="!has(self.produces) || self.produces.all(a, self.produces.exists_one(b, b.name == a.name))",message="an artifact name is unique within its child"

func (*CoordinationChild) DeepCopy added in v0.38.0

func (in *CoordinationChild) DeepCopy() *CoordinationChild

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CoordinationChild.

func (*CoordinationChild) DeepCopyInto added in v0.38.0

func (in *CoordinationChild) DeepCopyInto(out *CoordinationChild)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type CoordinationChildStatus added in v0.38.0

type CoordinationChildStatus struct {
	// +kubebuilder:validation:MaxLength=32
	ID string `json:"id"`
	// +kubebuilder:validation:Pattern=`^[A-Za-z0-9-]+/[A-Za-z0-9._-]+$`
	// +kubebuilder:validation:MaxLength=140
	Repository string `json:"repository"`
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{64}$`
	// +kubebuilder:validation:MaxLength=64
	// +optional
	Fingerprint string `json:"fingerprint,omitempty"`
	// +kubebuilder:validation:Minimum=0
	// +optional
	Issue int `json:"issue,omitempty"`
	// +kubebuilder:validation:Pattern=`^[a-z2-7]{8}$`
	// +kubebuilder:validation:MaxLength=8
	// +optional
	Task string `json:"task,omitempty"`
	// +kubebuilder:validation:Minimum=0
	// +optional
	Generation int32 `json:"generation,omitempty"`
	// +kubebuilder:validation:MaxLength=32
	// +optional
	Phase string `json:"phase,omitempty"`
	// +kubebuilder:validation:MaxLength=64
	// +optional
	Reason string `json:"reason,omitempty"`
	// +kubebuilder:validation:Minimum=0
	// +optional
	AllocationMicroUSD int64 `json:"allocationMicroUSD,omitempty"`
	// +optional
	IntegrationRelease *IntegrationRelease `json:"integrationRelease,omitempty"`
}

CoordinationChildStatus is a parent's lineage record of one child: its newest generation.

func (*CoordinationChildStatus) DeepCopy added in v0.38.0

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CoordinationChildStatus.

func (*CoordinationChildStatus) DeepCopyInto added in v0.38.0

func (in *CoordinationChildStatus) DeepCopyInto(out *CoordinationChildStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type CoordinationIncident added in v0.38.0

type CoordinationIncident struct {
	// +kubebuilder:validation:MaxLength=32
	ChildID string `json:"childID"`
	// +kubebuilder:validation:MaxLength=64
	Reason string `json:"reason"`
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{40}$`
	// +kubebuilder:validation:MaxLength=40
	// +optional
	MergeCommitSHA string      `json:"mergeCommitSHA,omitempty"`
	At             metav1.Time `json:"at"`
}

CoordinationIncident is a child's revert after its parent is Done: recorded, never reopening the parent (MR11).

func (*CoordinationIncident) DeepCopy added in v0.38.0

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CoordinationIncident.

func (*CoordinationIncident) DeepCopyInto added in v0.38.0

func (in *CoordinationIncident) DeepCopyInto(out *CoordinationIncident)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type CoordinationParent added in v0.38.0

type CoordinationParent struct {
	// +kubebuilder:validation:Pattern=`^[a-z2-7]{8}$`
	// +kubebuilder:validation:MaxLength=8
	Task string `json:"task"`
	// +kubebuilder:validation:Minimum=1
	PlanVersion int32 `json:"planVersion"`
	// +kubebuilder:validation:Pattern=`^[a-z][a-z0-9-]{0,31}$`
	// +kubebuilder:validation:MaxLength=32
	// +optional
	ChildID string `json:"childID,omitempty"`
}

CoordinationParent is a child's or an integration Task's lineage, fixed at creation: a child names its childID, an integration Task none (MR2).

func (*CoordinationParent) DeepCopy added in v0.38.0

func (in *CoordinationParent) DeepCopy() *CoordinationParent

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CoordinationParent.

func (*CoordinationParent) DeepCopyInto added in v0.38.0

func (in *CoordinationParent) DeepCopyInto(out *CoordinationParent)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type CoordinationPlan added in v0.38.0

type CoordinationPlan struct {
	// +kubebuilder:validation:Enum="maku.ogenki.io/v1alpha1"
	APIVersion string `json:"apiVersion"`
	// +kubebuilder:validation:Enum=CoordinationPlan
	Kind string `json:"kind"`
	// The stable draft and parent Task id, a C2 id.
	// +kubebuilder:validation:Pattern=`^[a-z2-7]{8}$`
	// +kubebuilder:validation:MaxLength=8
	ID string `json:"id"`
	// +kubebuilder:validation:MinLength=1
	// +kubebuilder:validation:MaxLength=200
	Title string `json:"title"`
	// Strictly +1 per accepted edit.
	// +kubebuilder:validation:Minimum=1
	Version int32               `json:"version"`
	Primary CoordinationPrimary `json:"primary"`
	// At most two children (MR1); a plan-mode draft may hold one.
	// +kubebuilder:validation:MinItems=1
	// +kubebuilder:validation:MaxItems=2
	Children []CoordinationChild `json:"children"`
	// The child ids in merge order.
	// +kubebuilder:validation:MaxItems=2
	// +kubebuilder:validation:items:MaxLength=32
	// +optional
	MergeOrder  []string               `json:"mergeOrder,omitempty"`
	Integration IntegrationPlan        `json:"integration"`
	Budget      CoordinationPlanBudget `json:"budget"`
}

CoordinationPlan is the full, versioned plan snapshot every interface exchanges (MR4, MR12). Validation, canonical hashing and materiality live in internal/factory/coordination; the CRD holds only the bounds and the invariants every mode shares. +kubebuilder:validation:XValidation:rule="self.children.exists(c, c.repository == self.primary.repository)",message="primary.repository is one child repository (MR3)" +kubebuilder:validation:XValidation:rule="self.children.all(a, self.children.exists_one(b, b.id == a.id))",message="a child id is unique" +kubebuilder:validation:XValidation:rule="self.children.all(a, self.children.exists_one(b, b.repository == a.repository))",message="a repository holds one child (MR1)" +kubebuilder:validation:XValidation:rule="!has(self.mergeOrder) || self.mergeOrder.all(id, self.children.exists(c, c.id == id))",message="mergeOrder names only children"

func (*CoordinationPlan) DeepCopy added in v0.38.0

func (in *CoordinationPlan) DeepCopy() *CoordinationPlan

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CoordinationPlan.

func (*CoordinationPlan) DeepCopyInto added in v0.38.0

func (in *CoordinationPlan) DeepCopyInto(out *CoordinationPlan)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type CoordinationPlanBudget added in v0.38.0

type CoordinationPlanBudget struct {
	// +kubebuilder:validation:Minimum=0
	// +kubebuilder:validation:Maximum=1000000000
	PlanningMicroUSD int64 `json:"planningMicroUSD"`
	// +kubebuilder:validation:Minimum=0
	// +kubebuilder:validation:Maximum=1000000000
	TotalMicroUSD int64 `json:"totalMicroUSD"`
}

CoordinationPlanBudget is the family's planning allocation and lifetime ceiling (MR8).

func (*CoordinationPlanBudget) DeepCopy added in v0.38.0

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CoordinationPlanBudget.

func (*CoordinationPlanBudget) DeepCopyInto added in v0.38.0

func (in *CoordinationPlanBudget) DeepCopyInto(out *CoordinationPlanBudget)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type CoordinationPlanVersion added in v0.38.0

type CoordinationPlanVersion struct {
	// +kubebuilder:validation:Minimum=1
	Version int32 `json:"version"`
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{64}$`
	// +kubebuilder:validation:MaxLength=64
	PlanHash   string      `json:"planHash"`
	AcceptedAt metav1.Time `json:"acceptedAt"`
}

CoordinationPlanVersion is one accepted plan version.

func (*CoordinationPlanVersion) DeepCopy added in v0.38.0

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CoordinationPlanVersion.

func (*CoordinationPlanVersion) DeepCopyInto added in v0.38.0

func (in *CoordinationPlanVersion) DeepCopyInto(out *CoordinationPlanVersion)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type CoordinationPrimary added in v0.38.0

type CoordinationPrimary struct {
	// +kubebuilder:validation:Pattern=`^[A-Za-z0-9-]+/[A-Za-z0-9._-]+$`
	// +kubebuilder:validation:MaxLength=140
	Repository string `json:"repository"`
	// +kubebuilder:validation:MaxLength=1024
	// +optional
	Rationale string `json:"rationale,omitempty"`
}

CoordinationPrimary is the user-confirmed primary repository: a child's, where the parent issue and the integration check live (MR3). Changing it starts a new parent.

func (*CoordinationPrimary) DeepCopy added in v0.38.0

func (in *CoordinationPrimary) DeepCopy() *CoordinationPrimary

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CoordinationPrimary.

func (*CoordinationPrimary) DeepCopyInto added in v0.38.0

func (in *CoordinationPrimary) DeepCopyInto(out *CoordinationPrimary)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type CoordinationSpec added in v0.38.0

type CoordinationSpec struct {
	// +kubebuilder:validation:XValidation:rule="self == 2",message="maxChildren is 2 in this release (MR1)"
	MaxChildren int32 `json:"maxChildren"`
	// +kubebuilder:validation:XValidation:rule="self",message="publicOnly is true in this release (MR16)"
	PublicOnly bool `json:"publicOnly"`
}

CoordinationSpec is a parent's switch values, fixed at creation (MR1, MR16).

func (*CoordinationSpec) DeepCopy added in v0.38.0

func (in *CoordinationSpec) DeepCopy() *CoordinationSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CoordinationSpec.

func (*CoordinationSpec) DeepCopyInto added in v0.38.0

func (in *CoordinationSpec) DeepCopyInto(out *CoordinationSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type CoordinationStatus added in v0.38.0

type CoordinationStatus struct {
	// +kubebuilder:validation:Minimum=1
	// +optional
	PlanVersion int32 `json:"planVersion,omitempty"`

	// +kubebuilder:validation:Pattern=`^[a-z][a-z0-9-]{0,31}$`
	// +kubebuilder:validation:MaxLength=32
	// +optional
	ChildID string `json:"childID,omitempty"`
	// +kubebuilder:validation:Minimum=0
	// +optional
	AllocationMicroUSD int64 `json:"allocationMicroUSD,omitempty"`
	// The head integration last accepted for this child: stale once the PR head moves (MR9).
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{40}$`
	// +kubebuilder:validation:MaxLength=40
	// +optional
	IntegrationAcceptedHead string `json:"integrationAcceptedHead,omitempty"`

	// The current full plan snapshot.
	// +optional
	Plan *CoordinationPlan `json:"plan,omitempty"`
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{64}$`
	// +kubebuilder:validation:MaxLength=64
	// +optional
	PlanHash string `json:"planHash,omitempty"`
	// The accepted versions, newest last; full snapshots are reposted on the parent issue.
	// +kubebuilder:validation:MaxItems=16
	// +optional
	History []CoordinationPlanVersion `json:"history,omitempty"`
	// +kubebuilder:validation:MaxItems=16
	// +optional
	Confirmations []ParentConfirmation `json:"confirmations,omitempty"`
	// +kubebuilder:validation:MaxItems=16
	// +optional
	Authorizations []ChildAuthorization `json:"authorizations,omitempty"`
	// +optional
	Budget *CoordinationBudgetStatus `json:"budget,omitempty"`
	// +kubebuilder:validation:MaxItems=2
	// +optional
	Children []CoordinationChildStatus `json:"children,omitempty"`
	// +kubebuilder:validation:MaxItems=16
	// +optional
	Artifacts []LandedArtifact `json:"artifacts,omitempty"`
	// +kubebuilder:validation:MaxItems=16
	// +optional
	IntegrationAttempts []IntegrationAttempt `json:"integrationAttempts,omitempty"`
	// The child ids in the order their pull requests landed.
	// +kubebuilder:validation:MaxItems=2
	// +kubebuilder:validation:items:MaxLength=32
	// +optional
	MergeOrder []string `json:"mergeOrder,omitempty"`
	// The final integration that let the parent be Done (MR10).
	// +optional
	Acceptance *CoordinationAcceptance `json:"acceptance,omitempty"`
	// +optional
	Recovery *RecoveryProposal `json:"recovery,omitempty"`
	// +kubebuilder:validation:MaxItems=4
	// +optional
	Incidents []CoordinationIncident `json:"incidents,omitempty"`
	// Affected generations waiting for their old generation to stop and its reservation to be
	// accounted before a replacement starts.
	// +kubebuilder:validation:MaxItems=2
	// +optional
	PendingGenerations []PendingGeneration `json:"pendingGenerations,omitempty"`
}

CoordinationStatus is a bounded union. A parent keeps the plan, its hash and version, bounded confirmation history, budget, child lineage, artifacts, integration attempts, landing order, final acceptance, the one recovery proposal, incidents and at most two generation barriers. A child keeps only {planVersion, childID, allocationMicroUSD, integrationAcceptedHead}: lineage, never a second parent or split record (MR2). +kubebuilder:validation:XValidation:rule="!has(self.childID) || (!has(self.plan) && !has(self.planHash) && !has(self.history) && !has(self.confirmations) && !has(self.authorizations) && !has(self.budget) && !has(self.children) && !has(self.artifacts) && !has(self.integrationAttempts) && !has(self.mergeOrder) && !has(self.acceptance) && !has(self.recovery) && !has(self.incidents) && !has(self.pendingGenerations))",message="a child's status.coordination is lineage only" +kubebuilder:validation:XValidation:rule="has(self.childID) || (!has(self.allocationMicroUSD) && !has(self.integrationAcceptedHead))",message="an allocation and an accepted head are a child's"

func (*CoordinationStatus) DeepCopy added in v0.38.0

func (in *CoordinationStatus) DeepCopy() *CoordinationStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CoordinationStatus.

func (*CoordinationStatus) DeepCopyInto added in v0.38.0

func (in *CoordinationStatus) DeepCopyInto(out *CoordinationStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Factory added in v0.41.0

type Factory struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`
	Spec              FactorySpec   `json:"spec,omitempty"`
	Status            FactoryStatus `json:"status,omitempty"`
}

Factory is one factory's catalogue (D3). Its name is config.factory, the fence's (D15).

+kubebuilder:object:root=true +kubebuilder:subresource:status +kubebuilder:resource:scope=Namespaced +kubebuilder:printcolumn:name=Accepted,type=string,JSONPath=`.status.conditions[?(@.type=="Accepted")].status` +kubebuilder:printcolumn:name=Ready,type=string,JSONPath=`.status.conditions[?(@.type=="Ready")].status` +kubebuilder:printcolumn:name=Repos,type=integer,JSONPath=`.status.repositories` +kubebuilder:printcolumn:name=Stopped,type=boolean,JSONPath=`.status.stopped` +kubebuilder:printcolumn:name=Age,type=date,JSONPath=`.metadata.creationTimestamp`

func (*Factory) DeepCopy added in v0.41.0

func (in *Factory) DeepCopy() *Factory

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Factory.

func (*Factory) DeepCopyInto added in v0.41.0

func (in *Factory) DeepCopyInto(out *Factory)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Factory) DeepCopyObject added in v0.41.0

func (in *Factory) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type FactoryList added in v0.41.0

type FactoryList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []Factory `json:"items"`
}

FactoryList is a list of Factory.

+kubebuilder:object:root=true

func (*FactoryList) DeepCopy added in v0.41.0

func (in *FactoryList) DeepCopy() *FactoryList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FactoryList.

func (*FactoryList) DeepCopyInto added in v0.41.0

func (in *FactoryList) DeepCopyInto(out *FactoryList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*FactoryList) DeepCopyObject added in v0.41.0

func (in *FactoryList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type FactorySpec added in v0.41.0

type FactorySpec struct {
	Control  config.Control  `json:"control,omitzero"`
	Defaults config.Defaults `json:"defaults,omitzero"`
	Triage   FactoryTriage   `json:"triage,omitzero"`
	// +kubebuilder:validation:MaxProperties=16
	Tiers map[string]config.Tier `json:"tiers,omitempty"`
	// +kubebuilder:validation:MaxProperties=16
	Templates map[string]config.Template `json:"templates,omitempty"`
	Caps      config.Caps                `json:"caps,omitzero"`
	Budgets   config.Budgets             `json:"budgets,omitzero"`
	Facts     config.Facts               `json:"facts,omitzero"`
	Brief     config.Brief               `json:"brief,omitzero"`
	Resume    config.Resume              `json:"resume,omitzero"`
	Scoper    config.Scoper              `json:"scoper,omitzero"`
	// +kubebuilder:validation:MaxProperties=32
	Loops map[string]config.Loop `json:"loops,omitempty"`
	// +kubebuilder:validation:MaxProperties=16
	HarnessProfiles map[string]config.HarnessProfile `json:"harnessProfiles,omitempty"`
	MergeGuardrails config.MergeGuardrails           `json:"mergeGuardrails,omitzero"`
	// Evaluation is the team evaluation's cohort share and mode, read per decision.
	Evaluation config.Evaluation `json:"evaluation,omitzero"`
	// +kubebuilder:validation:MaxProperties=32
	Prices map[string]config.Price `json:"prices,omitempty"`
}

FactorySpec is the factory's catalogue (D3, D12), in today's config keys. prices is today's meter.prices: the meter's URL and queries stay in the values.

func (*FactorySpec) DeepCopy added in v0.41.0

func (in *FactorySpec) DeepCopy() *FactorySpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FactorySpec.

func (*FactorySpec) DeepCopyInto added in v0.41.0

func (in *FactorySpec) DeepCopyInto(out *FactorySpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type FactoryStatus added in v0.41.0

type FactoryStatus struct {
	ObservedGeneration int64 `json:"observedGeneration,omitempty"`
	// +listType=map
	// +listMapKey=type
	// +kubebuilder:validation:MaxItems=8
	Conditions []metav1.Condition `json:"conditions,omitempty"`
	// Always serialized, zero included: the printer columns read them.
	// +optional
	// +kubebuilder:validation:Minimum=0
	Repositories int `json:"repositories"`
	// +optional
	Stopped bool `json:"stopped"`
}

FactoryStatus is what the factory made of its Factory (D11, narrowed for v1).

func (*FactoryStatus) DeepCopy added in v0.41.0

func (in *FactoryStatus) DeepCopy() *FactoryStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FactoryStatus.

func (*FactoryStatus) DeepCopyInto added in v0.41.0

func (in *FactoryStatus) DeepCopyInto(out *FactoryStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type FactoryTriage added in v0.41.0

type FactoryTriage struct {
	// +kubebuilder:validation:Minimum=0
	// +kubebuilder:validation:Maximum=100
	ControlPercent int `json:"controlPercent,omitempty"`
}

FactoryTriage is the live part of triage (D12): the classifier's URL stays in the values.

func (*FactoryTriage) DeepCopy added in v0.41.0

func (in *FactoryTriage) DeepCopy() *FactoryTriage

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FactoryTriage.

func (*FactoryTriage) DeepCopyInto added in v0.41.0

func (in *FactoryTriage) DeepCopyInto(out *FactoryTriage)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type FactsLedger

type FactsLedger struct {
	// +kubebuilder:validation:Minimum=1
	Seq int64 `json:"seq"`
	// +kubebuilder:validation:MaxLength=16
	Hash string `json:"hash"`
	// +optional
	Posted bool `json:"posted,omitempty"`
}

FactsLedger is which facts a room seq carries, and whether the broker has them.

func (*FactsLedger) DeepCopy

func (in *FactsLedger) DeepCopy() *FactsLedger

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FactsLedger.

func (*FactsLedger) DeepCopyInto

func (in *FactsLedger) DeepCopyInto(out *FactsLedger)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Finding

type Finding struct {
	// The Markdown file on main that holds the link.
	// +kubebuilder:validation:MinLength=1
	// +kubebuilder:validation:MaxLength=512
	File string `json:"file"`
	// The link target, an https URL.
	// +kubebuilder:validation:MinLength=1
	// +kubebuilder:validation:MaxLength=2048
	// +kubebuilder:validation:Pattern=`^https://`
	URL string `json:"url"`
	// The Wayback Machine's closest snapshot of URL, an https://web.archive.org/web/ URL; empty
	// when it has none.
	// +kubebuilder:validation:MaxLength=2048
	// +kubebuilder:validation:Pattern=`^https://web\.archive\.org/web/`
	// +optional
	Archive string `json:"archive,omitempty"`
}

Finding is one dead external link two consecutive detector runs on main reported (MC5).

func (*Finding) DeepCopy

func (in *Finding) DeepCopy() *Finding

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Finding.

func (*Finding) DeepCopyInto

func (in *Finding) DeepCopyInto(out *Finding)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type IntegrationAttempt added in v0.38.0

type IntegrationAttempt struct {
	// +kubebuilder:validation:Pattern=`^[a-z2-7]{8}$`
	// +kubebuilder:validation:MaxLength=8
	Task string `json:"task"`
	// +kubebuilder:validation:Enum=beforeDependentMerge;final
	Purpose string `json:"purpose"`
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{64}$`
	// +kubebuilder:validation:MaxLength=64
	PlanHash string `json:"planHash"`
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{64}$`
	// +kubebuilder:validation:MaxLength=64
	// +optional
	ManifestHash string `json:"manifestHash,omitempty"`
	// +kubebuilder:validation:Enum=pending;passed;failed
	State string `json:"state"`
	// +kubebuilder:validation:MaxLength=64
	// +optional
	Reason string `json:"reason,omitempty"`
	// +kubebuilder:validation:MaxItems=2
	Subjects []IntegrationSubject `json:"subjects"`
	// +kubebuilder:validation:Minimum=0
	// +optional
	RunMicroUSD int64 `json:"runMicroUSD,omitempty"`
	// +kubebuilder:validation:Minimum=0
	// +optional
	CostMicroUSD int64 `json:"costMicroUSD,omitempty"`
}

IntegrationAttempt is a parent's record of one integration Task.

func (*IntegrationAttempt) DeepCopy added in v0.38.0

func (in *IntegrationAttempt) DeepCopy() *IntegrationAttempt

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IntegrationAttempt.

func (*IntegrationAttempt) DeepCopyInto added in v0.38.0

func (in *IntegrationAttempt) DeepCopyInto(out *IntegrationAttempt)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type IntegrationPlan added in v0.38.0

type IntegrationPlan struct {
	// +kubebuilder:validation:Enum=triager
	Role string `json:"role"`
	// Nil is true: a dependent merge waits for a passing integration (MR9). Read it through
	// EffectiveBeforeDependents.
	// +optional
	BeforeDependents *bool `json:"beforeDependents,omitempty"`
	// +kubebuilder:validation:MaxLength=1024
	// +optional
	BeforeDependentsRationale string `json:"beforeDependentsRationale,omitempty"`
	// +kubebuilder:validation:Minimum=0
	// +kubebuilder:validation:Maximum=1000000000
	RunMicroUSD int64 `json:"runMicroUSD"`
	// +kubebuilder:validation:Minimum=1
	// +kubebuilder:validation:Maximum=16
	MaxRuns int32 `json:"maxRuns"`
	// +kubebuilder:validation:MinItems=1
	// +kubebuilder:validation:MaxItems=5
	Acceptance []TaskAcceptance `json:"acceptance"`
}

IntegrationPlan is the family's read-only acceptance, run by triager in the primary repository (MR10, MR17). +kubebuilder:validation:XValidation:rule="!has(self.beforeDependents) || self.beforeDependents || (has(self.beforeDependentsRationale) && size(self.beforeDependentsRationale) > 0)",message="beforeDependents: false needs a rationale"

func (*IntegrationPlan) DeepCopy added in v0.38.0

func (in *IntegrationPlan) DeepCopy() *IntegrationPlan

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IntegrationPlan.

func (*IntegrationPlan) DeepCopyInto added in v0.38.0

func (in *IntegrationPlan) DeepCopyInto(out *IntegrationPlan)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (IntegrationPlan) EffectiveBeforeDependents added in v0.38.0

func (p IntegrationPlan) EffectiveBeforeDependents() bool

EffectiveBeforeDependents is BeforeDependents with its default, true.

type IntegrationRelease added in v0.38.0

type IntegrationRelease struct {
	// +kubebuilder:validation:MaxLength=32
	ChildID string `json:"childID"`
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{40}$`
	// +kubebuilder:validation:MaxLength=40
	HeadSHA string `json:"headSHA"`
	// +kubebuilder:validation:Pattern=`^[a-z2-7]{8}$`
	// +kubebuilder:validation:MaxLength=8
	IntegrationTask string `json:"integrationTask"`
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{64}$`
	// +kubebuilder:validation:MaxLength=64
	ManifestHash string `json:"manifestHash"`
}

IntegrationRelease is a passing integration's release of one exact dependent head to that repository's own gate. A head change makes it stale; it is never a merge approval (MR9).

func (*IntegrationRelease) DeepCopy added in v0.38.0

func (in *IntegrationRelease) DeepCopy() *IntegrationRelease

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IntegrationRelease.

func (*IntegrationRelease) DeepCopyInto added in v0.38.0

func (in *IntegrationRelease) DeepCopyInto(out *IntegrationRelease)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type IntegrationResult added in v0.38.0

type IntegrationResult struct {
	// +kubebuilder:validation:Enum=pending;passed;failed
	State string `json:"state"`
	// +kubebuilder:validation:MaxLength=64
	// +optional
	Reason string `json:"reason,omitempty"`
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{64}$`
	// +kubebuilder:validation:MaxLength=64
	// +optional
	ManifestHash string `json:"manifestHash,omitempty"`
}

IntegrationResult is an integration Task's outcome, valid only for its immutable subjects (MR10).

func (*IntegrationResult) DeepCopy added in v0.38.0

func (in *IntegrationResult) DeepCopy() *IntegrationResult

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IntegrationResult.

func (*IntegrationResult) DeepCopyInto added in v0.38.0

func (in *IntegrationResult) DeepCopyInto(out *IntegrationResult)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type IntegrationSpec added in v0.38.0

type IntegrationSpec struct {
	// +kubebuilder:validation:Enum=beforeDependentMerge;final
	Purpose string `json:"purpose"`
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{64}$`
	// +kubebuilder:validation:MaxLength=64
	PlanHash string `json:"planHash"`
	// +kubebuilder:validation:MinItems=1
	// +kubebuilder:validation:MaxItems=2
	Subjects []IntegrationSubject `json:"subjects"`
}

IntegrationSpec is an integration Task's immutable manifest inputs (MR10).

func (*IntegrationSpec) DeepCopy added in v0.38.0

func (in *IntegrationSpec) DeepCopy() *IntegrationSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IntegrationSpec.

func (*IntegrationSpec) DeepCopyInto added in v0.38.0

func (in *IntegrationSpec) DeepCopyInto(out *IntegrationSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type IntegrationSubject added in v0.38.0

type IntegrationSubject struct {
	// +kubebuilder:validation:MaxLength=32
	ChildID string `json:"childID"`
	// +kubebuilder:validation:Pattern=`^[A-Za-z0-9-]+/[A-Za-z0-9._-]+$`
	// +kubebuilder:validation:MaxLength=140
	Repository string `json:"repository"`
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{40}$`
	// +kubebuilder:validation:MaxLength=40
	// +optional
	HeadSHA string `json:"headSHA,omitempty"`
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{40}$`
	// +kubebuilder:validation:MaxLength=40
	// +optional
	MergeCommitSHA string `json:"mergeCommitSHA,omitempty"`
}

IntegrationSubject is one child at an exact commit: a PR head before its merge, or its landed merge commit, never both. +kubebuilder:validation:XValidation:rule="has(self.headSHA) != has(self.mergeCommitSHA)",message="an integration subject names exactly one of headSHA or mergeCommitSHA"

func (*IntegrationSubject) DeepCopy added in v0.38.0

func (in *IntegrationSubject) DeepCopy() *IntegrationSubject

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IntegrationSubject.

func (*IntegrationSubject) DeepCopyInto added in v0.38.0

func (in *IntegrationSubject) DeepCopyInto(out *IntegrationSubject)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type LandedArtifact added in v0.38.0

type LandedArtifact struct {
	// +kubebuilder:validation:MaxLength=32
	ChildID string `json:"childID"`
	// +kubebuilder:validation:MaxLength=64
	Name string `json:"name"`
	// +kubebuilder:validation:Pattern=`^[A-Za-z0-9-]+/[A-Za-z0-9._-]+$`
	// +kubebuilder:validation:MaxLength=140
	Repository string `json:"repository"`
	// +kubebuilder:validation:MinLength=1
	// +kubebuilder:validation:MaxLength=512
	Path string `json:"path"`
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{40}$`
	// +kubebuilder:validation:MaxLength=40
	MergeCommitSHA string `json:"mergeCommitSHA"`
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{40}$`
	// +kubebuilder:validation:MaxLength=40
	BlobSHA string `json:"blobSHA"`
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{64}$`
	// +kubebuilder:validation:MaxLength=64
	ContentSHA256 string `json:"contentSHA256"`
	// +kubebuilder:validation:Minimum=0
	// +kubebuilder:validation:Maximum=65536
	SizeBytes int64 `json:"sizeBytes"`
}

LandedArtifact is a produced file as read at the producer's landed merge commit: the only thing a dependency consumes (MR7).

func (*LandedArtifact) DeepCopy added in v0.38.0

func (in *LandedArtifact) DeepCopy() *LandedArtifact

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LandedArtifact.

func (*LandedArtifact) DeepCopyInto added in v0.38.0

func (in *LandedArtifact) DeepCopyInto(out *LandedArtifact)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Loop

type Loop struct {
	// +kubebuilder:validation:Minimum=1
	// +kubebuilder:validation:Maximum=500
	StallSteps int32 `json:"stallSteps"`
	// +kubebuilder:validation:Minimum=0
	// +kubebuilder:validation:Maximum=5
	Continuations int32 `json:"continuations"`
	// The judge's alias; empty: no judge. mistral-light, the one provider alias a judge may take
	// (v3 F15, F3), is a public task's only.
	// +kubebuilder:validation:Enum=agent-default;tier-light;tier-standard;tier-frontier;mistral-light
	// +optional
	JudgeModel string `json:"judgeModel,omitempty"`
}

Loop is a task's loop policy, every value resolved at triage.

func (*Loop) DeepCopy

func (in *Loop) DeepCopy() *Loop

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Loop.

func (*Loop) DeepCopyInto

func (in *Loop) DeepCopyInto(out *Loop)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type MergePolicy added in v0.41.0

type MergePolicy struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`
	Spec              MergePolicySpec   `json:"spec"`
	Status            MergePolicyStatus `json:"status,omitempty"`
}

MergePolicy is one repository's merge policy (D3, D4).

+kubebuilder:object:root=true +kubebuilder:subresource:status +kubebuilder:resource:scope=Namespaced +kubebuilder:printcolumn:name=Repo,type=string,JSONPath=`.spec.repositoryRef` +kubebuilder:printcolumn:name=Authority,type=string,JSONPath=`.status.authority` +kubebuilder:printcolumn:name=Classes,type=integer,JSONPath=`.status.classCount` +kubebuilder:printcolumn:name=Live,type=integer,JSONPath=`.status.liveCount` +kubebuilder:printcolumn:name=Accepted,type=string,JSONPath=`.status.conditions[?(@.type=="Accepted")].status` +kubebuilder:printcolumn:name=Age,type=date,JSONPath=`.metadata.creationTimestamp`

func (*MergePolicy) DeepCopy added in v0.41.0

func (in *MergePolicy) DeepCopy() *MergePolicy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MergePolicy.

func (*MergePolicy) DeepCopyInto added in v0.41.0

func (in *MergePolicy) DeepCopyInto(out *MergePolicy)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*MergePolicy) DeepCopyObject added in v0.41.0

func (in *MergePolicy) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type MergePolicyList added in v0.41.0

type MergePolicyList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []MergePolicy `json:"items"`
}

MergePolicyList is a list of MergePolicy.

+kubebuilder:object:root=true

func (*MergePolicyList) DeepCopy added in v0.41.0

func (in *MergePolicyList) DeepCopy() *MergePolicyList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MergePolicyList.

func (*MergePolicyList) DeepCopyInto added in v0.41.0

func (in *MergePolicyList) DeepCopyInto(out *MergePolicyList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*MergePolicyList) DeepCopyObject added in v0.41.0

func (in *MergePolicyList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type MergePolicySpec added in v0.41.0

type MergePolicySpec struct {
	// +kubebuilder:validation:MaxLength=253
	// +kubebuilder:validation:MinLength=1
	RepositoryRef string `json:"repositoryRef"`
	// +kubebuilder:validation:MaxProperties=32
	// +kubebuilder:validation:XValidation:rule="self.all(k, !((has(self[k].live) && self[k].live) && (has(self[k].shadow) && self[k].shadow)))",message="a class is live or shadow, never both"
	Classes map[string]config.Class `json:"classes,omitempty"`
	Merge   config.Merge            `json:"merge,omitzero"`
}

MergePolicySpec is one repository's classes and merge rules (D3, D4): today's repositories[].classes and merge, unchanged in shape.

+kubebuilder:validation:XValidation:rule="!has(oldSelf.repositoryRef) || self.repositoryRef == oldSelf.repositoryRef",message="spec.repositoryRef is fixed once set"

func (*MergePolicySpec) DeepCopy added in v0.41.0

func (in *MergePolicySpec) DeepCopy() *MergePolicySpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MergePolicySpec.

func (*MergePolicySpec) DeepCopyInto added in v0.41.0

func (in *MergePolicySpec) DeepCopyInto(out *MergePolicySpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type MergePolicyStatus added in v0.41.0

type MergePolicyStatus struct {
	ObservedGeneration int64 `json:"observedGeneration,omitempty"`
	// +listType=map
	// +listMapKey=type
	// +kubebuilder:validation:MaxItems=8
	Conditions []metav1.Condition `json:"conditions,omitempty"`
	// +kubebuilder:validation:Enum=central;repository
	Authority string `json:"authority,omitempty"`
	// ClassCount and LiveCount are always serialized, zero included: the printer columns read them.
	// +optional
	// +kubebuilder:validation:Minimum=0
	ClassCount int `json:"classCount"`
	// +optional
	// +kubebuilder:validation:Minimum=0
	LiveCount int `json:"liveCount"`
	// +kubebuilder:validation:MaxItems=32
	Classes []ClassStatus `json:"classes,omitempty"`
}

MergePolicyStatus is what the factory made of its MergePolicy and of the repository's file (D10).

func (*MergePolicyStatus) DeepCopy added in v0.41.0

func (in *MergePolicyStatus) DeepCopy() *MergePolicyStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MergePolicyStatus.

func (*MergePolicyStatus) DeepCopyInto added in v0.41.0

func (in *MergePolicyStatus) DeepCopyInto(out *MergePolicyStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type MonitorStatus

type MonitorStatus struct {
	Since metav1.Time `json:"since"`
	// +kubebuilder:validation:Enum="";healthy;regression;inconclusive
	// +optional
	Main string `json:"main,omitempty"`
	// +kubebuilder:validation:Enum="";healthy;regression;inconclusive
	// +optional
	Oracle string `json:"oracle,omitempty"`
	// +kubebuilder:validation:Enum="";healthy;regression;inconclusive
	// +optional
	Flux string `json:"flux,omitempty"`
	// +kubebuilder:validation:Enum="";healthy;regression;inconclusive
	// +optional
	Verdict string `json:"verdict,omitempty"`
	// Later pull requests that fixed this merge (MC8).
	// +kubebuilder:validation:MaxItems=16
	// +optional
	FollowUps []int `json:"followUps,omitempty"`
	// The last follow-up read could not say (a failed read, no blame, an omitted patch, a
	// truncated search): the watch cannot end healthy while it holds.
	// +optional
	FollowUpsUnread bool `json:"followUpsUnread,omitempty"`
	// The detector runs read after the merge (R37).
	// +kubebuilder:validation:MaxItems=8
	// +optional
	OracleRuns []int64 `json:"oracleRuns,omitempty"`
	// The Flux source's fetch time the first pass that saw it hold the merge commit (R33): an upper
	// bound on when the merge was applied. The blame window and the settle time end `within` later.
	// +optional
	Applied *metav1.Time `json:"applied,omitempty"`
	// Where the Flux blame window starts: the source's fetch time when the first observed revision
	// is the merge commit, else the merge's own time (the merge was fetched somewhere before Applied).
	// +optional
	BlameFrom *metav1.Time `json:"blameFrom,omitempty"`
	// The Flux objects found not Ready in the window, kind/namespace/name, the first five.
	// +kubebuilder:validation:MaxItems=5
	// +kubebuilder:validation:items:MaxLength=320
	// +optional
	FluxBlamed []string `json:"fluxBlamed,omitempty"`
	// The verdict comment is on the pull request.
	// +optional
	Posted bool `json:"posted,omitempty"`
	// RunLore's verdict on this fix (RA11), recorded by POST /v1/tasks/{task}/verification.
	// +optional
	Verification *Verification `json:"verification,omitempty"`
	// The verification signal: healthy for resolved, regression for persisting, inconclusive when
	// the window closed with no verdict. Set only for a merge whose origin is an internal
	// principal that verifies (R12).
	// +kubebuilder:validation:Enum="";healthy;regression;inconclusive
	// +optional
	Verified string `json:"verified,omitempty"`
	// The follow-up issue filed when RunLore's verdict was persisting (RA12), filed once.
	// +optional
	FollowUpIssue int `json:"followUpIssue,omitempty"`
}

MonitorStatus is one merge's watch. A signal is "" while open, then healthy, regression or inconclusive; Verdict is set at the first regression, or when every signal is final.

func (*MonitorStatus) DeepCopy

func (in *MonitorStatus) DeepCopy() *MonitorStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MonitorStatus.

func (*MonitorStatus) DeepCopyInto

func (in *MonitorStatus) DeepCopyInto(out *MonitorStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Narration

type Narration struct {
	// +kubebuilder:validation:MaxLength=128
	Key string `json:"key"`
	// The issue or PR it goes to; 0 waits for the task's first target (a profile announcement
	// queued before a schedule's task has a pull request).
	// +kubebuilder:validation:Minimum=0
	Number int `json:"number"`
	// The factory's own words, never text a user wrote.
	// +kubebuilder:validation:MaxLength=4096
	Body string `json:"body"`
}

Narration is one pending comment. Its key is the comment's idempotency key: in status.narrated once posted, and in the comment's marker, which a retry finds when a post landed but failed.

func (*Narration) DeepCopy

func (in *Narration) DeepCopy() *Narration

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Narration.

func (*Narration) DeepCopyInto

func (in *Narration) DeepCopyInto(out *Narration)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Parent

type Parent struct {
	// +kubebuilder:validation:Pattern=`^[a-z2-7]{8}$`
	// +kubebuilder:validation:MaxLength=8
	Task string `json:"task"`
	// +kubebuilder:validation:Minimum=1
	Issue int `json:"issue"`
	// +kubebuilder:validation:Minimum=1
	// +kubebuilder:validation:Maximum=5
	Index int32 `json:"index"`
	// +kubebuilder:validation:Minimum=2
	// +kubebuilder:validation:Maximum=5
	Of int32 `json:"of"`
}

Parent names a child's parent task and issue, and which part of how many it is (SL5). +kubebuilder:validation:XValidation:rule="self.index <= self.of",message="a part's index is at most its count"

func (*Parent) DeepCopy

func (in *Parent) DeepCopy() *Parent

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Parent.

func (*Parent) DeepCopyInto

func (in *Parent) DeepCopyInto(out *Parent)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ParentConfirmation added in v0.38.0

type ParentConfirmation struct {
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{64}$`
	// +kubebuilder:validation:MaxLength=64
	PlanHash string `json:"planHash"`
	// The authenticated principal that confirmed.
	// +kubebuilder:validation:MaxLength=128
	Actor string `json:"actor"`
	// +kubebuilder:validation:Pattern=`^[A-Za-z0-9][A-Za-z0-9-]{0,38}$`
	// +kubebuilder:validation:MaxLength=39
	LinkedGitHubLogin string      `json:"linkedGitHubLogin"`
	ConfirmedAt       metav1.Time `json:"confirmedAt"`
}

ParentConfirmation is a primary maintainer's confirmation of one plan hash. It authorizes no child (MR5).

func (*ParentConfirmation) DeepCopy added in v0.38.0

func (in *ParentConfirmation) DeepCopy() *ParentConfirmation

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ParentConfirmation.

func (*ParentConfirmation) DeepCopyInto added in v0.38.0

func (in *ParentConfirmation) DeepCopyInto(out *ParentConfirmation)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PendingGeneration added in v0.38.0

type PendingGeneration struct {
	// +kubebuilder:validation:MaxLength=32
	ChildID string `json:"childID"`
	// The generation waiting to start.
	// +kubebuilder:validation:Minimum=1
	Generation int32 `json:"generation"`
	// +kubebuilder:validation:Minimum=1
	PlanVersion int32 `json:"planVersion"`
	// The old generation's Task, stopping.
	// +kubebuilder:validation:Pattern=`^[a-z2-7]{8}$`
	// +kubebuilder:validation:MaxLength=8
	// +optional
	StoppingTask string `json:"stoppingTask,omitempty"`
}

PendingGeneration is one affected child's replacement barrier after a material edit.

func (*PendingGeneration) DeepCopy added in v0.38.0

func (in *PendingGeneration) DeepCopy() *PendingGeneration

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PendingGeneration.

func (*PendingGeneration) DeepCopyInto added in v0.38.0

func (in *PendingGeneration) DeepCopyInto(out *PendingGeneration)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ProfileStatus added in v0.41.0

type ProfileStatus struct {
	// +kubebuilder:validation:MaxLength=63
	Name string `json:"name"`
	// +kubebuilder:validation:Enum=label;floor;control;scoper;escalation
	Source string `json:"source"`
	// +kubebuilder:validation:Enum=labeled;control;treatment
	Cohort string `json:"cohort"`
	// +kubebuilder:validation:MaxLength=32
	// +optional
	Reason string `json:"reason,omitempty"`
	// +kubebuilder:validation:MaxLength=63
	// +optional
	Recommended string `json:"recommended,omitempty"`
	// +kubebuilder:validation:MaxLength=200
	// +optional
	Why string `json:"why,omitempty"`
	// +optional
	Checks bool `json:"checks,omitempty"`
	// +optional
	TestFirst bool `json:"testFirst,omitempty"`
	// +optional
	Resolved bool `json:"resolved,omitempty"`
	// +optional
	Counted bool `json:"counted,omitempty"`
}

ProfileStatus is the harness profile a task runs under and how it was chosen. Checks and TestFirst are frozen here: a profile removed from config later changes nothing.

func (*ProfileStatus) DeepCopy added in v0.41.0

func (in *ProfileStatus) DeepCopy() *ProfileStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ProfileStatus.

func (*ProfileStatus) DeepCopyInto added in v0.41.0

func (in *ProfileStatus) DeepCopyInto(out *ProfileStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Published

type Published struct {
	// The number of the issue the factory created.
	// +kubebuilder:validation:Minimum=1
	Issue int `json:"issue"`
	// The maintainer login whose label asked for it, lowercased.
	// +kubebuilder:validation:MaxLength=64
	By string `json:"by"`
	// When the issue was filed.
	At metav1.Time `json:"at"`
	// The verdict evidence of the fix task named by EvidenceFor, internal like this task (R11).
	// +kubebuilder:validation:MaxLength=16384
	// +optional
	Evidence string `json:"evidence,omitempty"`
	// The fix task the evidence is for.
	// +kubebuilder:validation:Pattern=`^[a-z2-7]{8}$`
	// +kubebuilder:validation:MaxLength=8
	// +optional
	EvidenceFor string `json:"evidenceFor,omitempty"`
	// The class inferred from the proposal's paths at publish (K4), which the fix task's
	// spec.predictedClass copies.
	// +kubebuilder:validation:MaxLength=64
	// +optional
	Class string `json:"class,omitempty"`
}

Published records the issue the factory filed from an investigate task's proposal (RA9): once per task, by a maintainer's factory/publish.

func (*Published) DeepCopy

func (in *Published) DeepCopy() *Published

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Published.

func (*Published) DeepCopyInto

func (in *Published) DeepCopyInto(out *Published)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PullRequestRef

type PullRequestRef struct {
	Number int `json:"number"`
	// +kubebuilder:validation:MaxLength=2048
	URL string `json:"url"`
	// +kubebuilder:validation:MaxLength=128
	// +optional
	NodeID string `json:"nodeID,omitempty"`
	// The head when the pull request was found, then the head the merge gate last acted on: merged,
	// or handed to a human (N1: a push after the hand-off keeps it with the human).
	// +kubebuilder:validation:MaxLength=64
	// +optional
	HeadSHA string `json:"headSHA,omitempty"`
	// The head the merge gate last decided "arm" or "shadow" on. An adopted merge of any other
	// head (Renovate's automerge of a head the gate refused or never read) is not watched.
	// +kubebuilder:validation:MaxLength=64
	// +optional
	DecidedHeadSHA string `json:"decidedHeadSHA,omitempty"`
	// +kubebuilder:validation:MaxLength=64
	// +optional
	MergeCommitSHA string `json:"mergeCommitSHA,omitempty"`
	// +kubebuilder:validation:MaxLength=64
	// +optional
	MergedBy string `json:"mergedBy,omitempty"`
	// +optional
	AutoMerged bool `json:"autoMerged,omitempty"`
	// HumanCommits is never cleared: one human commit makes the merge merged_human, not accepted.
	// +optional
	HumanCommits bool `json:"humanCommits,omitempty"`
	// MergedHow says who judged the merge the merger made (human path AM1): "class", the class's
	// own conditions (AutoMerged), or "approved", a maintainer's approval of the head, named in
	// ApprovedBy. Empty for a merge the merger did not make.
	// +kubebuilder:validation:Enum=class;approved
	// +optional
	MergedHow string `json:"mergedHow,omitempty"`
	// ApprovedBy is the maintainer whose approval of the head the merger merged on (AM1); empty
	// unless MergedHow is "approved".
	// +kubebuilder:validation:MaxLength=64
	// +optional
	ApprovedBy string `json:"approvedBy,omitempty"`
	// +optional
	ArmedAt *metav1.Time `json:"armedAt,omitempty"`
	// +optional
	MergedAt *metav1.Time `json:"mergedAt,omitempty"`
	// HandedOffAt is the first hand-off to a human (AM9): the start of the hand-off to merge
	// histogram. Set once, by the first entry to AwaitingHuman with a pull request.
	// +optional
	HandedOffAt *metav1.Time `json:"handedOffAt,omitempty"`
	// HandedOffReason is the reason of the first hand-off to a human (AM9), the histogram's label.
	// +kubebuilder:validation:MaxLength=64
	// +optional
	HandedOffReason string `json:"handedOffReason,omitempty"`
	// +optional
	RevertNumber int `json:"revertNumber,omitempty"`
	// Drill: the revert was a maintainer's drill (AM6); the breaker does not count it.
	// +optional
	Drill bool `json:"drill,omitempty"`
	// Grant is the saved approval grant the merger's merge was authorized under, "<id>:<version>"
	// (merge policy stage 5): a revert of the merge disables it. Empty when no grant was used.
	// +kubebuilder:validation:Pattern=`^[a-z2-7]{26}:[1-9][0-9]{0,8}$`
	// +kubebuilder:validation:MaxLength=36
	// +optional
	Grant string `json:"grant,omitempty"`
	// +kubebuilder:validation:MaxLength=64
	// +optional
	Author string `json:"author,omitempty"`
	// Everyone who has submitted a review, oldest first.
	// +kubebuilder:validation:MaxItems=16
	// +kubebuilder:validation:items:MaxLength=64
	// +optional
	Reviewers []string `json:"reviewers,omitempty"`
	// Approval is a maintainer's approval an AwaitingHuman agents pull request shows with
	// merge.approveToMerge off, for the room's facts and narration. It never changes the reason, so
	// every return and by-hand guidance stands. Cleared when no maintainer's approval stands (a
	// dismissal, a veto) and by the task's next transition.
	// +optional
	Approval *ApprovalRef `json:"approval,omitempty"`
}

PullRequestRef is the task's pull request and what happened to it.

func (*PullRequestRef) DeepCopy

func (in *PullRequestRef) DeepCopy() *PullRequestRef

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PullRequestRef.

func (*PullRequestRef) DeepCopyInto

func (in *PullRequestRef) DeepCopyInto(out *PullRequestRef)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type RecoveryProposal added in v0.38.0

type RecoveryProposal struct {
	// +kubebuilder:validation:Enum=retry_child;resume_child;revise_plan;increase_budget;retry_producer;retry_dependent;retry_integration;rerun_integration;authorize_child
	Code string `json:"code"`
	// +kubebuilder:validation:MaxLength=32
	// +optional
	ChildID string `json:"childID,omitempty"`
	// +kubebuilder:validation:Pattern=`^[a-z2-7]{8}$`
	// +kubebuilder:validation:MaxLength=8
	// +optional
	IntegrationTask string `json:"integrationTask,omitempty"`
	// +kubebuilder:validation:MaxLength=64
	Reason string `json:"reason"`
	// +kubebuilder:validation:Minimum=1
	PlanVersion          int32       `json:"planVersion"`
	RequiresConfirmation bool        `json:"requiresConfirmation"`
	CreatedAt            metav1.Time `json:"createdAt"`
}

RecoveryProposal is the one deterministic next action a failure proposes, never a playbook and never executed by the parent (MR11).

func (*RecoveryProposal) DeepCopy added in v0.38.0

func (in *RecoveryProposal) DeepCopy() *RecoveryProposal

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RecoveryProposal.

func (*RecoveryProposal) DeepCopyInto added in v0.38.0

func (in *RecoveryProposal) DeepCopyInto(out *RecoveryProposal)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Repository added in v0.41.0

type Repository struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`
	Spec              RepositorySpec   `json:"spec"`
	Status            RepositoryStatus `json:"status,omitempty"`
}

Repository is one repository a Factory serves (D3).

+kubebuilder:object:root=true +kubebuilder:subresource:status +kubebuilder:resource:scope=Namespaced +kubebuilder:printcolumn:name=Repo,type=string,JSONPath=`.spec.repository` +kubebuilder:printcolumn:name=Factory,type=string,JSONPath=`.spec.factoryRef` +kubebuilder:printcolumn:name=Accepted,type=string,JSONPath=`.status.conditions[?(@.type=="Accepted")].status` +kubebuilder:printcolumn:name=Connected,type=string,JSONPath=`.status.conditions[?(@.type=="Connected")].status` +kubebuilder:printcolumn:name=Age,type=date,JSONPath=`.metadata.creationTimestamp`

func (*Repository) DeepCopy added in v0.41.0

func (in *Repository) DeepCopy() *Repository

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Repository.

func (*Repository) DeepCopyInto added in v0.41.0

func (in *Repository) DeepCopyInto(out *Repository)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Repository) DeepCopyObject added in v0.41.0

func (in *Repository) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type RepositoryList added in v0.41.0

type RepositoryList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []Repository `json:"items"`
}

RepositoryList is a list of Repository.

+kubebuilder:object:root=true

func (*RepositoryList) DeepCopy added in v0.41.0

func (in *RepositoryList) DeepCopy() *RepositoryList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RepositoryList.

func (*RepositoryList) DeepCopyInto added in v0.41.0

func (in *RepositoryList) DeepCopyInto(out *RepositoryList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*RepositoryList) DeepCopyObject added in v0.41.0

func (in *RepositoryList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type RepositorySpec added in v0.41.0

type RepositorySpec struct {
	// +kubebuilder:validation:MaxLength=63
	// +kubebuilder:validation:MinLength=1
	FactoryRef string `json:"factoryRef"`
	// Repository is owner/name on GitHub.
	// +kubebuilder:validation:MaxLength=140
	// +kubebuilder:validation:Pattern=`^[A-Za-z0-9-]+/[A-Za-z0-9._-]+$`
	Repository string `json:"repository"`
	// +kubebuilder:validation:MaxItems=32
	// +kubebuilder:validation:items:MaxLength=39
	Maintainers []string `json:"maintainers,omitempty"`
	// +kubebuilder:validation:MaxLength=50
	TriggerLabel string        `json:"triggerLabel,omitempty"`
	Checks       config.Checks `json:"checks,omitzero"`
	// +kubebuilder:validation:MaxItems=16
	Schedules []config.Schedule `json:"schedules,omitempty"`
	// +kubebuilder:validation:Enum=central;repository
	ClassAuthority string `json:"classAuthority,omitempty"`
}

RepositorySpec is one repository served (D3): today's repositories[] entry less its classes and merge block, which are its MergePolicy's.

+kubebuilder:validation:XValidation:rule="!has(oldSelf.factoryRef) || self.factoryRef == oldSelf.factoryRef",message="spec.factoryRef is fixed once set" +kubebuilder:validation:XValidation:rule="!has(oldSelf.repository) || self.repository == oldSelf.repository",message="spec.repository is fixed once set"

func (*RepositorySpec) DeepCopy added in v0.41.0

func (in *RepositorySpec) DeepCopy() *RepositorySpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RepositorySpec.

func (*RepositorySpec) DeepCopyInto added in v0.41.0

func (in *RepositorySpec) DeepCopyInto(out *RepositorySpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type RepositoryStatus added in v0.41.0

type RepositoryStatus struct {
	ObservedGeneration int64 `json:"observedGeneration,omitempty"`
	// +listType=map
	// +listMapKey=type
	// +kubebuilder:validation:MaxItems=8
	Conditions []metav1.Condition `json:"conditions,omitempty"`
	// MergePolicy names the MergePolicy that applies.
	// +kubebuilder:validation:MaxLength=253
	MergePolicy string `json:"mergePolicy,omitempty"`
}

RepositoryStatus is what the factory made of its Repository (D11, narrowed for v1).

func (*RepositoryStatus) DeepCopy added in v0.41.0

func (in *RepositoryStatus) DeepCopy() *RepositoryStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RepositoryStatus.

func (*RepositoryStatus) DeepCopyInto added in v0.41.0

func (in *RepositoryStatus) DeepCopyInto(out *RepositoryStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type RunProvenance

type RunProvenance struct {
	// The factory build that created the claim (version.Version), from its CREATE-only annotation.
	// +kubebuilder:validation:MaxLength=64
	// +optional
	FactoryVersion string `json:"factoryVersion,omitempty"`
	// The CompositionRevision Crossplane bound the claim to, as first read.
	// +kubebuilder:validation:MaxLength=253
	// +optional
	CompositionRevision string `json:"compositionRevision,omitempty"`
	// The harness container's imageID, <repository>@sha256:<digest>, as the composition read it
	// from the run's pod.
	// +kubebuilder:validation:MaxLength=320
	// +optional
	HarnessImage string `json:"harnessImage,omitempty"`
	// The models that served the run, as the meter read gen_ai_request_model; sorted.
	// +kubebuilder:validation:MaxItems=8
	// +kubebuilder:validation:items:MaxLength=64
	// +optional
	ServedModels []string `json:"servedModels,omitempty"`
	// Which config chose the run's model (v3 F15, F3): the tier's model, the template's
	// reviewerModel, or the class's loops.<class>.models (a public task only), set at creation.
	// +kubebuilder:validation:Enum=tier;reviewerModel;classModels
	// +optional
	ModelSource string `json:"modelSource,omitempty"`
}

RunProvenance is what a run ran on (R10). The reconciler fills each field once, from the run's claim or the meter, and never changes it; ServedModels only grows. Empty: not known yet, or the claim predates the field — never a guess.

func (*RunProvenance) DeepCopy

func (in *RunProvenance) DeepCopy() *RunProvenance

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RunProvenance.

func (*RunProvenance) DeepCopyInto

func (in *RunProvenance) DeepCopyInto(out *RunProvenance)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (RunProvenance) IsZero

func (p RunProvenance) IsZero() bool

IsZero reports whether no fact the room shows is known yet: ModelSource is the factory's own record, set at creation, and never makes a run's provenance a room fact on its own.

type RunRecord

type RunRecord struct {
	// +kubebuilder:validation:Pattern=`^[a-z2-7]{8}$`
	// +kubebuilder:validation:MaxLength=8
	ID string `json:"id"`
	// +kubebuilder:validation:Enum=implementer;reviewer;tester;triager
	Role string `json:"role"`
	// Why the run exists.
	// +kubebuilder:validation:Enum=initial;review;human;ci;retry;resume;escalation
	Trigger string `json:"trigger"`
	// +optional
	Round int32 `json:"round,omitempty"`
	// +kubebuilder:validation:MaxLength=64
	// +optional
	Phase string `json:"phase,omitempty"`
	// The room's end reason (SP2 P15), else the AgentRun's.
	// +kubebuilder:validation:MaxLength=1024
	// +optional
	Reason string `json:"reason,omitempty"`
	// +kubebuilder:validation:MaxLength=32
	// +optional
	Verdict string `json:"verdict,omitempty"`
	// +optional
	Tokens int64 `json:"tokens,omitempty"`
	// The run's cost in micro-dollars, cache reads at their own rate, as the meter priced it.
	// +optional
	CostMicroUSD int64 `json:"costMicroUSD,omitempty"`
	// Why the meter could not price the run: its task is then held to TaskTokens.
	// +kubebuilder:validation:Enum=unpriced;untyped
	// +optional
	Unpriced string `json:"unpriced,omitempty"`
	// The person the run was charged to beside the fleet (v2 per-person caps D2), github:<login>;
	// empty when per-person caps were off or no person caused it.
	// +kubebuilder:validation:MaxLength=64
	// +optional
	ChargedTo string `json:"chargedTo,omitempty"`
	// The room's lastSeq when the run was created: verdicts are read after it.
	// +optional
	StartSeq int64 `json:"startSeq,omitempty"`
	// The pull request's head a reviewer or tester run was given: its approve counts for that
	// commit only, and only while the head has not moved. On an implementer run started on an
	// existing pull request, the head it started from: a revision's narration lists what it changed.
	// +kubebuilder:validation:MaxLength=64
	// +optional
	HeadSHA string `json:"headSHA,omitempty"`
	// +optional
	Started *metav1.Time `json:"started,omitempty"`
	// +optional
	Finished *metav1.Time `json:"finished,omitempty"`
	// What the run ran on (R10), each field filled once as it becomes known.
	// +optional
	Provenance RunProvenance `json:"provenance,omitempty"`
}

RunRecord is one AgentRun the task started.

func (*RunRecord) DeepCopy

func (in *RunRecord) DeepCopy() *RunRecord

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RunRecord.

func (*RunRecord) DeepCopyInto

func (in *RunRecord) DeepCopyInto(out *RunRecord)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ScopeStatus

type ScopeStatus struct {
	// +kubebuilder:validation:Enum=ready;question;assumed;missing;failed
	State string `json:"state"`
	// +kubebuilder:validation:Minimum=0
	// +optional
	Seq int64 `json:"seq,omitempty"`
}

ScopeStatus is the scoper's outcome on its task.

func (*ScopeStatus) DeepCopy

func (in *ScopeStatus) DeepCopy() *ScopeStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ScopeStatus.

func (*ScopeStatus) DeepCopyInto

func (in *ScopeStatus) DeepCopyInto(out *ScopeStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ShadowVerdict

type ShadowVerdict struct {
	// +kubebuilder:validation:MaxLength=128
	Classifier string `json:"classifier"`
	// +kubebuilder:validation:MaxLength=16
	Tier string `json:"tier"`
	// +kubebuilder:validation:MaxLength=16
	// +optional
	Confidence string `json:"confidence,omitempty"`
}

ShadowVerdict is a classifier consulted in shadow: recorded, never acted on.

func (*ShadowVerdict) DeepCopy

func (in *ShadowVerdict) DeepCopy() *ShadowVerdict

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ShadowVerdict.

func (*ShadowVerdict) DeepCopyInto

func (in *ShadowVerdict) DeepCopyInto(out *ShadowVerdict)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Source

type Source struct {
	// adopt: another author's pull request the factory decides (merge gate MC10).
	// coordination: a coordination parent or integration Task (MR2); a child is an issue.
	// +kubebuilder:validation:Enum=issue;runlore;schedule;api;adopt;coordination
	Kind string `json:"kind"`
	// Smana/cloud-native-ref#2112 (owner/name#<n>), runlore:<alert>/<resource>, or the schedule name.
	// +kubebuilder:validation:MaxLength=512
	Ref string `json:"ref"`
	// +kubebuilder:validation:MaxLength=512
	Key string `json:"key"`
	// github:<login> (an adopted pull request's author too), system:runlore or system:scheduler.
	// +kubebuilder:validation:MaxLength=128
	RequestedBy string `json:"requestedBy"`
	// untrusted text is fenced as data for the harness (T1).
	// +kubebuilder:validation:Enum=untrusted;trusted
	Trust string `json:"trust"`
	// +kubebuilder:validation:Pattern=`^[a-f0-9]{64}$`
	// +kubebuilder:validation:MaxLength=64
	ContentSHA256 string `json:"contentSHA256"`
	// The maintainer accountable for an api task, as a ledger key (F4, R8): github:<login>.
	// +kubebuilder:validation:Pattern=`^github:[a-z0-9][a-z0-9-]{0,38}$`
	// +kubebuilder:validation:MaxLength=46
	// +optional
	Sponsor string `json:"sponsor,omitempty"`
	// The external user a link made the sponsor (R9): slack:<team>/<user>.
	// +kubebuilder:validation:Pattern=`^slack:T[A-Z0-9]{2,20}/[UW][A-Z0-9]{2,20}$`
	// +kubebuilder:validation:MaxLength=64
	// +optional
	OnBehalfOf string `json:"onBehalfOf,omitempty"`
}

Source is where the task came from and how far its text is trusted. No rule holds the whole source: the splitter's inherit() rewrites contentSHA256 of a re-labelled part, so only the fields F4 adds, and the kind, are held (C1). +kubebuilder:validation:XValidation:rule="self.kind != 'api' || (has(self.sponsor) && size(self.sponsor) > 0)",message="an api task names its sponsor" +kubebuilder:validation:XValidation:rule="self.kind == 'api' || (!has(self.sponsor) && !has(self.onBehalfOf))",message="only an api task has a sponsor" +kubebuilder:validation:XValidation:rule="self.kind == oldSelf.kind",message="a task's source kind never changes" +kubebuilder:validation:XValidation:rule="has(self.sponsor) == has(oldSelf.sponsor) && (!has(self.sponsor) || self.sponsor == oldSelf.sponsor)",message="source.sponsor never changes" +kubebuilder:validation:XValidation:rule="has(self.onBehalfOf) == has(oldSelf.onBehalfOf) && (!has(self.onBehalfOf) || self.onBehalfOf == oldSelf.onBehalfOf)",message="source.onBehalfOf never changes"

func (*Source) DeepCopy

func (in *Source) DeepCopy() *Source

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Source.

func (*Source) DeepCopyInto

func (in *Source) DeepCopyInto(out *Source)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type SplitChild

type SplitChild struct {
	// +kubebuilder:validation:Minimum=1
	// +kubebuilder:validation:Maximum=5
	Index int32 `json:"index"`
	// +kubebuilder:validation:Minimum=1
	Issue int `json:"issue"`
	// +kubebuilder:validation:Pattern=`^[a-z2-7]{8}$`
	// +kubebuilder:validation:MaxLength=8
	Task string `json:"task"`
	// +kubebuilder:validation:Enum=landed;dropped;reverted
	// +optional
	Outcome string `json:"outcome,omitempty"`
}

SplitChild is one opened part.

func (*SplitChild) DeepCopy

func (in *SplitChild) DeepCopy() *SplitChild

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SplitChild.

func (*SplitChild) DeepCopyInto

func (in *SplitChild) DeepCopyInto(out *SplitChild)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type SplitSpec

type SplitSpec struct {
	// +kubebuilder:validation:Minimum=2
	// +kubebuilder:validation:Maximum=5
	MaxChildren int32 `json:"maxChildren"`
	// The family's cap in micro-dollars (SL10): the parent's and every child's runs together.
	// +kubebuilder:validation:Minimum=1
	FamilyMicroUSD int64 `json:"familyMicroUSD"`
	// +kubebuilder:validation:Enum=light;standard;frontier
	ChildTier string `json:"childTier"`
}

SplitSpec is the split a task's scoper is offered (SL3), resolved at triage.

func (*SplitSpec) DeepCopy

func (in *SplitSpec) DeepCopy() *SplitSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SplitSpec.

func (*SplitSpec) DeepCopyInto

func (in *SplitSpec) DeepCopyInto(out *SplitSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type SplitStatus

type SplitStatus struct {
	// +kubebuilder:validation:Enum=proposed;approved;declined;superseded;expired;ignored
	State string `json:"state"`
	// The room seq of the handoff that carries the split.
	// +kubebuilder:validation:Minimum=1
	Seq int64 `json:"seq"`
	// How many parts the proposed split holds; 0 for an ignored one.
	// +kubebuilder:validation:Minimum=0
	// +kubebuilder:validation:Maximum=5
	// +optional
	Of int32 `json:"of,omitempty"`
	// The maintainer whose /factory split approved it, github:<login>: every child's payer (SL11).
	// +kubebuilder:validation:MaxLength=64
	// +optional
	ApprovedBy string `json:"approvedBy,omitempty"`
	// The parts opened so far, in order, each with its newest generation's task.
	// +kubebuilder:validation:MaxItems=5
	// +optional
	Children []SplitChild `json:"children,omitempty"`
}

SplitStatus is a split as its parent keeps it (SL14).

func (*SplitStatus) DeepCopy

func (in *SplitStatus) DeepCopy() *SplitStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SplitStatus.

func (*SplitStatus) DeepCopyInto

func (in *SplitStatus) DeepCopyInto(out *SplitStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type StatusComment added in v0.41.1

type StatusComment struct {
	// +optional
	ID int64 `json:"id,omitempty"`
	// +kubebuilder:validation:MaxLength=4096
	// +optional
	Body string `json:"body,omitempty"`
	// Inactive means this Task no longer owes status updates after a permanent refusal or an
	// ownership stand-down. It does not mean the last remote write succeeded; ID and Body keep
	// their last successful values.
	// +optional
	Inactive bool `json:"inactive,omitempty"`
}

StatusComment is the durable identity, last successful body and activity of a task's issue status comment.

func (*StatusComment) DeepCopy added in v0.41.1

func (in *StatusComment) DeepCopy() *StatusComment

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new StatusComment.

func (*StatusComment) DeepCopyInto added in v0.41.1

func (in *StatusComment) DeepCopyInto(out *StatusComment)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Steering

type Steering struct {
	// +kubebuilder:validation:MaxLength=256
	Path string `json:"path"`
	// The note's git blob sha on the default branch.
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{40}$`
	// +kubebuilder:validation:MaxLength=40
	SHA string `json:"sha"`
	// +kubebuilder:validation:MaxLength=2048
	Text string `json:"text"`
}

Steering is a steering note as triage read it: every run of the task sees these bytes.

func (*Steering) DeepCopy

func (in *Steering) DeepCopy() *Steering

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Steering.

func (*Steering) DeepCopyInto

func (in *Steering) DeepCopyInto(out *Steering)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Task

type Task struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`
	Spec              TaskSpec   `json:"spec"`
	Status            TaskStatus `json:"status,omitempty"`
}

Task is one unit of factory work (SP3 §4). The factory creates it at runtime and never commits it to Git. Its name derives from the idempotency key, so AlreadyExists is the dedup. +kubebuilder:object:root=true +kubebuilder:subresource:status +kubebuilder:resource:scope=Namespaced +kubebuilder:printcolumn:name="Phase",type=string,JSONPath=`.status.phase` +kubebuilder:printcolumn:name="Source",type=string,JSONPath=`.spec.source.ref` +kubebuilder:printcolumn:name="Class",type=string,JSONPath=`.spec.predictedClass` +kubebuilder:printcolumn:name="Template",type=string,JSONPath=`.spec.template` +kubebuilder:printcolumn:name="PR",type=string,JSONPath=`.status.pullRequest.url` +kubebuilder:printcolumn:name="Tokens",type=integer,JSONPath=`.status.usage.tokens` +kubebuilder:validation:XValidation:rule="self.metadata.name.matches('^[a-z2-7]{8}$')",message="a Task is named with a C2 id: 8 characters of [a-z2-7]" +kubebuilder:validation:XValidation:rule="!has(self.spec.kind) || self.spec.kind != 'coordination' || !has(self.status) || (!has(self.status.nextRole) && !has(self.status.nextTrigger) && !has(self.status.pullRequest) && !has(self.status.runs))",message="a coordination parent has no run, pull request, next role or next trigger (MR2)" +kubebuilder:validation:XValidation:rule="!has(self.spec.kind) || self.spec.kind != 'integration' || !has(self.status) || !has(self.status.pullRequest)",message="an integration task has no implementation pull request (MR10)" +kubebuilder:validation:XValidation:rule="!has(self.spec.kind) || self.spec.kind != 'integration' || !has(self.status) || !has(self.status.runs) || self.status.runs.all(r, r.role == 'triager')",message="an integration task runs only triager (MR10, MR17)" +kubebuilder:validation:XValidation:rule="!has(self.status) || !has(self.status.phase) || self.status.phase != 'Coordinating' || (has(self.spec.kind) && self.spec.kind == 'coordination')",message="only a coordination parent is Coordinating" +kubebuilder:validation:XValidation:rule="!has(self.status) || !has(self.status.coordination) || (has(self.status.coordination.childID) ? (!has(self.spec.kind) && has(self.spec.coordinationParent) && has(self.spec.coordinationParent.childID) && self.status.coordination.childID == self.spec.coordinationParent.childID) : (has(self.spec.kind) && self.spec.kind == 'coordination'))",message="status.coordination is a parent's record, or a child's lineage under its own childID" +kubebuilder:validation:XValidation:rule="!has(self.status) || !has(self.status.result) || (has(self.spec.kind) && self.spec.kind == 'integration')",message="status.result is an integration task's"

func (*Task) DeepCopy

func (in *Task) DeepCopy() *Task

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Task.

func (*Task) DeepCopyInto

func (in *Task) DeepCopyInto(out *Task)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Task) DeepCopyObject

func (in *Task) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*Task) Payer

func (t *Task) Payer() string

Payer is the person the task's next run is charged to beside the fleet (D2): the maintainer whose /factory retry sent it back, else an api task's sponsored principal (R7), else the labeller; "" for a task no person or principal started.

func (*Task) Sponsored

func (t *Task) Sponsored() string

Sponsored is the api task's principal (F4): the ledger key its runs are charged to beside the fleet whatever per-person caps say (R7); "" for any other task.

type TaskAcceptance

type TaskAcceptance struct {
	// +kubebuilder:validation:MinLength=1
	// +kubebuilder:validation:MaxLength=300
	Check string `json:"check"`
	// +kubebuilder:validation:MinLength=1
	// +kubebuilder:validation:MaxLength=200
	Proves string `json:"proves"`
}

TaskAcceptance is one acceptance check of a part.

func (*TaskAcceptance) DeepCopy

func (in *TaskAcceptance) DeepCopy() *TaskAcceptance

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TaskAcceptance.

func (*TaskAcceptance) DeepCopyInto

func (in *TaskAcceptance) DeepCopyInto(out *TaskAcceptance)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type TaskList

type TaskList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []Task `json:"items"`
}

TaskList is a list of Tasks. +kubebuilder:object:root=true

func (*TaskList) DeepCopy

func (in *TaskList) DeepCopy() *TaskList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TaskList.

func (*TaskList) DeepCopyInto

func (in *TaskList) DeepCopyInto(out *TaskList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*TaskList) DeepCopyObject

func (in *TaskList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type TaskScope

type TaskScope struct {
	// +kubebuilder:validation:Enum=ready
	State string `json:"state"`
	// +kubebuilder:validation:MinLength=1
	// +kubebuilder:validation:MaxLength=1000
	Task string `json:"task"`
	// +kubebuilder:validation:MinItems=1
	// +kubebuilder:validation:MaxItems=10
	// +kubebuilder:validation:items:MaxLength=200
	Touches []string `json:"touches"`
	// +kubebuilder:validation:MaxItems=10
	// +kubebuilder:validation:items:MaxLength=200
	// +optional
	Leave []string `json:"leave,omitempty"`
	// +kubebuilder:validation:MinItems=1
	// +kubebuilder:validation:MaxItems=7
	// +kubebuilder:validation:items:MaxLength=300
	Plan []string `json:"plan"`
	// +kubebuilder:validation:MaxItems=5
	// +kubebuilder:validation:items:MaxLength=300
	// +optional
	Assumptions []string `json:"assumptions,omitempty"`
	// +kubebuilder:validation:MinItems=1
	// +kubebuilder:validation:MaxItems=5
	Acceptance []TaskAcceptance `json:"acceptance"`
}

TaskScope mirrors envelope.Scope, with its bounds, in state ready (a part never asks): the CRD cannot import the envelope.

func (*TaskScope) DeepCopy

func (in *TaskScope) DeepCopy() *TaskScope

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TaskScope.

func (*TaskScope) DeepCopyInto

func (in *TaskScope) DeepCopyInto(out *TaskScope)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type TaskSpec

type TaskSpec struct {
	// Kind is coordination for a parent and integration for an integration attempt (MR2); absent,
	// the Task is an ordinary work Task, a coordination child included.
	// +kubebuilder:validation:Enum=coordination;integration
	// +optional
	Kind   string `json:"kind,omitempty"`
	Source Source `json:"source"`
	// +kubebuilder:validation:Pattern=`^[A-Za-z0-9-]+/[A-Za-z0-9._-]+$`
	// +kubebuilder:validation:MaxLength=140
	Repository string `json:"repository"`
	// The issue the factory narrates on; 0 for a task without one (R28).
	// +kubebuilder:validation:Minimum=0
	// +optional
	Issue int `json:"issue,omitempty"`
	// The issue's author on GitHub, for the room list's "mine" filter.
	// +kubebuilder:validation:MaxLength=64
	// +optional
	IssueAuthor string `json:"issueAuthor,omitempty"`
	// The snapshot. Admission caps it at caps.maxTextBytes (R6); this bound only protects etcd.
	// +kubebuilder:validation:MaxLength=65536
	Text string `json:"text"`
	// Every run of the task gets it as spec.dataClass (C3, OD-13).
	// +kubebuilder:validation:Enum=public;internal
	DataClass string `json:"dataClass"`
	// Intent, not authority: it picks team and budget; only policy-bot merges (§2).
	// +kubebuilder:validation:MaxLength=64
	// +optional
	PredictedClass string `json:"predictedClass,omitempty"`
	// +kubebuilder:validation:Enum=solo;pair;trio;investigate
	// +optional
	Template string `json:"template,omitempty"`
	// +optional
	Budget Budget `json:"budget,omitempty"`
	// The loop policy its implementer runs get as spec.loop, resolved from loops.<class> at
	// triage so a config change never moves a task already triaged (loops design L2, L3). Unset:
	// the loop is off for the task's class.
	// +optional
	Loop *Loop `json:"loop,omitempty"`
	// The findings an oracle class's probe made this task of (merge gate classes MC6): what the
	// run is asked to fix, and what the gate's oracle checks the head no longer holds.
	// +kubebuilder:validation:MaxItems=16
	// +optional
	Findings []Finding `json:"findings,omitempty"`
	// The class's scope mode (scoper design SC2), fixed at triage so a config change never moves a
	// task already triaged. Empty: triaged before the scoper existed, which reads as off.
	// +kubebuilder:validation:Enum=off;steering;scoper
	// +optional
	ScopeMode string `json:"scopeMode,omitempty"`
	// The class's steering note, read on the default branch at triage (SC3); unset for none.
	// +optional
	Steering *Steering `json:"steering,omitempty"`
	// The request's ceiling in micro-USD (F4, R5): triage caps the task and each run under it. Set
	// on api tasks only; 0 elsewhere.
	// +kubebuilder:validation:Minimum=0
	// +kubebuilder:validation:Maximum=1000000000
	// +kubebuilder:validation:XValidation:rule="self == oldSelf",message="maxMicroUSD never changes"
	// +optional
	MaxMicroUSD int64 `json:"maxMicroUSD,omitempty"`
	// Search offers its implementer runs the search tool (v3 feature 5, ST9), read from
	// loops.<class>.search at triage so a config change never moves a task already triaged; every
	// implementer claim of the task carries spec.loop.search.
	// +optional
	Search bool `json:"search,omitempty"`
	// The split the scoper may offer (splitter design SL3), recorded at triage when the class's row
	// has one and C7's own tier is frontier; unset: no split offered.
	// +optional
	Split *SplitSpec `json:"split,omitempty"`
	// The parent this task is a part of (SL5), fixed at creation; unset for any other task.
	// +optional
	Parent *Parent `json:"parent,omitempty"`
	// This child's part of its parent's task (SL5): one scope of the approved split, fixed once set.
	// +optional
	Scope *TaskScope `json:"scope,omitempty"`
	// Origin is the investigate task whose published issue this task was started from (RunLore
	// agent-to-agent RA9): set by the issue poller from that task's status.published, never from
	// issue text, so nothing a person or an agent writes can forge one.
	// +kubebuilder:validation:Pattern=`^[a-z2-7]{8}$`
	// +kubebuilder:validation:MaxLength=8
	// +kubebuilder:validation:XValidation:rule="self == oldSelf",message="origin never changes"
	// +optional
	Origin string `json:"origin,omitempty"`
	// Coordination is a parent's switch values (MR1, MR16), fixed at creation.
	// +optional
	Coordination *CoordinationSpec `json:"coordination,omitempty"`
	// CoordinationParent is a child's or an integration Task's parent (MR2), fixed at creation.
	// +optional
	CoordinationParent *CoordinationParent `json:"coordinationParent,omitempty"`
	// Integration is an integration Task's exact subjects (MR10), fixed at creation.
	// +optional
	Integration *IntegrationSpec `json:"integration,omitempty"`
	// CoordinationArtifacts are the landed references a dependent child was created with (MR7).
	// +kubebuilder:validation:MaxItems=8
	// +optional
	CoordinationArtifacts []LandedArtifact `json:"coordinationArtifacts,omitempty"`
}

TaskSpec is what the task was asked to do, fixed at admission. +kubebuilder:validation:XValidation:rule="has(self.parent) == has(oldSelf.parent) && (!has(self.parent) || self.parent == oldSelf.parent)",message="spec.parent is fixed at creation" +kubebuilder:validation:XValidation:rule="has(self.origin) == has(oldSelf.origin)",message="spec.origin is fixed at creation" +kubebuilder:validation:XValidation:rule="!has(oldSelf.scope) || (has(self.scope) && self.scope == oldSelf.scope)",message="spec.scope never changes once set" +kubebuilder:validation:XValidation:rule="self.source.kind != 'api' || (has(self.maxMicroUSD) && self.maxMicroUSD > 0)",message="an api task carries maxMicroUSD" +kubebuilder:validation:XValidation:rule="self.source.kind != 'api' || !has(self.budget) || (has(self.maxMicroUSD) && (!has(self.budget.runMicroUSD) || self.budget.runMicroUSD <= self.maxMicroUSD) && (!has(self.budget.taskMicroUSD) || self.budget.taskMicroUSD <= self.maxMicroUSD))",message="an api task's budget stays under its ceiling" +kubebuilder:validation:XValidation:rule="!has(self.loop) || !has(self.loop.judgeModel) || self.loop.judgeModel != 'mistral-light' || self.dataClass == 'public'",message="a provider judgeModel is a public task's only" +kubebuilder:validation:XValidation:rule="has(self.kind) == has(oldSelf.kind) && (!has(self.kind) || self.kind == oldSelf.kind)",message="spec.kind is fixed at creation" +kubebuilder:validation:XValidation:rule="has(self.coordinationParent) == has(oldSelf.coordinationParent) && (!has(self.coordinationParent) || self.coordinationParent == oldSelf.coordinationParent)",message="spec.coordinationParent is fixed at creation" +kubebuilder:validation:XValidation:rule="has(self.coordination) == has(oldSelf.coordination) && (!has(self.coordination) || self.coordination == oldSelf.coordination)",message="spec.coordination is fixed at creation" +kubebuilder:validation:XValidation:rule="has(self.integration) == has(oldSelf.integration) && (!has(self.integration) || self.integration == oldSelf.integration)",message="spec.integration is fixed at creation" +kubebuilder:validation:XValidation:rule="has(self.coordinationArtifacts) == has(oldSelf.coordinationArtifacts) && (!has(self.coordinationArtifacts) || self.coordinationArtifacts == oldSelf.coordinationArtifacts)",message="spec.coordinationArtifacts are fixed at creation" +kubebuilder:validation:XValidation:rule="has(self.kind) == (self.source.kind == 'coordination')",message="a coordination or integration task, and only one, has source kind coordination (MR2)" +kubebuilder:validation:XValidation:rule="has(self.coordination) == (has(self.kind) && self.kind == 'coordination')",message="a coordination parent, and only one, has spec.coordination" +kubebuilder:validation:XValidation:rule="has(self.integration) == (has(self.kind) && self.kind == 'integration')",message="an integration task, and only one, has spec.integration" +kubebuilder:validation:XValidation:rule="!has(self.kind) || self.kind != 'coordination' || (!has(self.template) && (!has(self.budget) || (!has(self.budget.tier) && !has(self.budget.model) && !has(self.budget.runTokens) && !has(self.budget.taskTokens) && !has(self.budget.runMinutes) && !has(self.budget.runMicroUSD) && !has(self.budget.taskMicroUSD))))",message="a coordination parent has no template, tier or implementation budget (MR2)" +kubebuilder:validation:XValidation:rule="!has(self.kind) || self.kind != 'coordination' || (!has(self.coordinationParent) && !has(self.parent) && !has(self.split) && !has(self.scope))",message="a coordination parent has no lineage or scope of its own (MR2)" +kubebuilder:validation:XValidation:rule="!has(self.coordinationParent) || has(self.kind) || has(self.coordinationParent.childID)",message="a coordination child names its childID" +kubebuilder:validation:XValidation:rule="!has(self.coordinationParent) || has(self.kind) || (!has(self.parent) && !has(self.split))",message="a coordination child is never a splitter part: no spec.parent, no spec.split (MR2)" +kubebuilder:validation:XValidation:rule="!has(self.coordinationParent) || has(self.kind) || self.source.kind == 'issue'",message="a coordination child is an issue task" +kubebuilder:validation:XValidation:rule="!has(self.kind) || self.kind != 'integration' || (has(self.coordinationParent) && !has(self.coordinationParent.childID) && !has(self.parent) && !has(self.split) && !has(self.scope))",message="an integration task names its parent and no childID (MR10)" +kubebuilder:validation:XValidation:rule="!has(self.coordinationArtifacts) || (has(self.coordinationParent) && !has(self.kind))",message="only a coordination child consumes landed artifacts (MR7)" +kubebuilder:validation:XValidation:rule="(!has(self.kind) && !has(self.coordinationParent)) || self.dataClass == 'public'",message="a coordination family is public only (MR16)"

func (*TaskSpec) DeepCopy

func (in *TaskSpec) DeepCopy() *TaskSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TaskSpec.

func (*TaskSpec) DeepCopyInto

func (in *TaskSpec) DeepCopyInto(out *TaskSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type TaskStatus

type TaskStatus struct {
	// +kubebuilder:validation:Enum=Received;Rejected;Triaged;Queued;Implementing;NoOp;Reviewing;AwaitingCI;AutoMerging;AwaitingHuman;Merged;Verifying;Done;Reverted;Escalated;Closed;Stopped;Split;Coordinating
	// +optional
	Phase string `json:"phase,omitempty"`
	// +kubebuilder:validation:MaxLength=1024
	// +optional
	Reason string `json:"reason,omitempty"`
	// +optional
	PhaseSince *metav1.Time `json:"phaseSince,omitempty"`
	// The C7 answer, recorded as-is (§2).
	// +optional
	Classification *Classification `json:"classification,omitempty"`
	// The harness profile frozen at triage and the evaluation cohort; absent for a class without a harness.
	// +optional
	Profile *ProfileStatus `json:"profile,omitempty"`
	// +kubebuilder:validation:MaxItems=256
	// +optional
	Runs []RunRecord `json:"runs,omitempty"`
	// +kubebuilder:validation:MaxLength=253
	// +optional
	RoomRef string `json:"roomRef,omitempty"`
	// +optional
	PullRequest *PullRequestRef `json:"pullRequest,omitempty"`
	// The post-merge monitor (merge gate classes MC7), for a class that declares one: each signal's
	// reading and the verdict, the worst of them. Unset until the task ends merged.
	// +optional
	Monitor *MonitorStatus `json:"monitor,omitempty"`
	// The issue the factory filed from this investigate task's proposal (RA9), once.
	// +optional
	Published *Published `json:"published,omitempty"`
	// +optional
	Usage Usage `json:"usage,omitempty"`
	// The task's usage has settled (R49): the meter's late readings have had their window, and
	// the total is final. Written once, with the one TaskTokens the settle records.
	// +optional
	UsageSettled bool `json:"usageSettled,omitempty"`
	// The task's first end (R34): the settle window counts from it, and Outcome is what it ended
	// as. A later Reverted revises neither.
	// +optional
	EndedAt *metav1.Time `json:"endedAt,omitempty"`
	// +kubebuilder:validation:Enum=accepted;merged_human;no_op;closed;stopped;rejected;reverted;failed
	// +optional
	Outcome string `json:"outcome,omitempty"`
	// A split's part whose outcome the team evaluation counts, under its parent's profile (R32):
	// written at its triage when the parent has one. Its merge's provenance is read for the mark
	// (R39), never for the parent.
	// +optional
	Evaluated bool `json:"evaluated,omitempty"`
	// +optional
	ReviewRounds int32 `json:"reviewRounds,omitempty"`
	// +optional
	FixRuns int32 `json:"fixRuns,omitempty"`
	// FixRuns when the escalation step queued the task's run under its richer profile: the step
	// grants a fresh allowance, so merge.fixRuns counts from here (R33).
	// +optional
	FixRunsBeforeStep int32 `json:"fixRunsBeforeStep,omitempty"`
	// Re-runs of a cancelled required check, capped by merge.checkReruns. A cancelled check is
	// not a failure, so it never spends a fix run.
	// +optional
	CheckReruns int32 `json:"checkReruns,omitempty"`
	// The head CheckReruns counts against: a new head resets it.
	// +kubebuilder:validation:MaxLength=64
	// +optional
	CheckRerunsHead string `json:"checkRerunsHead,omitempty"`
	// +optional
	Retries int32 `json:"retries,omitempty"`
	// RetriedBy is the maintainer whose /factory retry sent the task back, github:<login>: the
	// person its later runs are charged to (v2 per-person caps D2). Empty: the labeller.
	// +kubebuilder:validation:MaxLength=64
	// +optional
	RetriedBy string `json:"retriedBy,omitempty"`
	// Automatic resumes of runs lost to their infrastructure (disruption design §4), every role
	// counted; capped by the config's resume.maxPerTask.
	// +kubebuilder:validation:Minimum=0
	// +optional
	Resumes int32 `json:"resumes,omitempty"`
	// Returns from a transient AwaitingHuman hand-off to the merge gate (N1), every cause
	// counted; capped by the reconciler, so a flapping input cannot loop the gate.
	// +kubebuilder:validation:Minimum=0
	// +optional
	GateReentries int32 `json:"gateReentries,omitempty"`
	// The effective verdict of the last review: approve, changes or none.
	// +kubebuilder:validation:MaxLength=32
	// +optional
	Verdict string `json:"verdict,omitempty"`
	// Idempotency keys of the comments already posted (R22), and of the room messages
	// (room/<seq>/<key>). narrate trims the oldest: a display list, not a ledger (ruling SK).
	// +listType=set
	// +kubebuilder:validation:MaxItems=512
	// +kubebuilder:validation:items:MaxLength=512
	// +optional
	Narrated []string `json:"narrated,omitempty"`
	// Comments the task owes its issue or PR (ruling SO): written with the transition that caused
	// them, removed once posted. A task with any left is reconciled even after it ends.
	// +kubebuilder:validation:MaxItems=16
	// +optional
	Outbox []Narration `json:"outbox,omitempty"`
	// StatusComment is the issue's one live status comment and its last successful remote body.
	// +optional
	StatusComment *StatusComment `json:"statusComment,omitempty"`
	// The last clientSeq the task took for a task_state message or its facts in its room (ruling
	// SK). The broker keeps one message per clientSeq, so the ledger is its own field, never trimmed
	// like narrated, and only rises: the next message is roomSeq + 1, persisted before it is posted.
	// +kubebuilder:validation:Minimum=0
	// +kubebuilder:validation:XValidation:rule="self >= oldSelf",message="roomSeq never goes down: the broker would drop a reused clientSeq"
	// +optional
	RoomSeq int64 `json:"roomSeq,omitempty"`
	// The task facts last written to the room: their seq comes from the roomSeq ledger (ruling SK).
	// +optional
	Facts *FactsLedger `json:"facts,omitempty"`
	// The trigger of the next implementer run, set when the task goes back to Queued (Δ5) and
	// cleared once that run exists.
	// +kubebuilder:validation:Enum=initial;review;human;ci;retry;resume;escalation
	// +optional
	NextTrigger string `json:"nextTrigger,omitempty"`
	// The scoper's outcome (scoper design SC12), set once when its run ends and kept when the task
	// later stops: ready, question, assumed, missing or failed, and the seq of the handoff that
	// carries the scope (0 for none). Unset: no scoper ran, or it has not ended.
	// +optional
	Scope *ScopeStatus `json:"scope,omitempty"`
	// The test contract (v3 feature 4, TF4, R14): the tester run's commit on agent/<task> as GitHub
	// recorded it, its test files and ids. Set once, when the tester's push is read; every implementer
	// run is held to it and the merge gate requires merge.contractCheck (rows 2b, 2c).
	// +optional
	Contract *ContractStatus `json:"contract,omitempty"`
	// The split's record on its parent (splitter design SL14): set when the scoper hands one off.
	// +optional
	Split *SplitStatus `json:"split,omitempty"`
	// The verifier the task went back to Queued for (§3): the next reviewer or tester run starts
	// there, behind the caps and the human-driver rule (C4). Cleared once that run exists.
	// +kubebuilder:validation:Enum=reviewer;tester
	// +optional
	NextRole string `json:"nextRole,omitempty"`
	// GitHub review and comment ids already acted on (Δ5, commands). The reconciler trims the oldest.
	// +listType=set
	// +kubebuilder:validation:MaxItems=512
	// +optional
	Handled []int64 `json:"handled,omitempty"`
	// The config that triaged the task: the circuit breaker resets with a new one (§6.4).
	// +kubebuilder:validation:MaxLength=64
	// +optional
	ConfigHash string `json:"configHash,omitempty"`
	// The generations of the factory's resources the task was triaged under (factory resources
	// D5): recorded, not pinned. Unset when every generation is zero (the file served it).
	// +optional
	ConfigGenerations *ConfigGenerations `json:"configGenerations,omitempty"`
	// The last room event seen for the running run (stuck detection, §6.3).
	// +optional
	LastActivity *metav1.Time `json:"lastActivity,omitempty"`
	// The task's root span (R46): minted at acceptance, exported once when the task ends.
	// +optional
	Trace *TraceRef `json:"trace,omitempty"`
	// Coordination is a parent's family record or a child's lineage (MR2).
	// +optional
	Coordination *CoordinationStatus `json:"coordination,omitempty"`
	// Result is an integration Task's outcome (MR10).
	// +optional
	Result *IntegrationResult `json:"result,omitempty"`
}

TaskStatus is the task's audit record: the whole §4 record, including the fields later phases fill. +kubebuilder:validation:XValidation:rule="!has(oldSelf.trace) || has(self.trace)",message="a task's trace is never removed: its runs are parented on it" +kubebuilder:validation:XValidation:rule="!has(oldSelf.usageSettled) || !oldSelf.usageSettled || (has(self.usageSettled) && self.usageSettled)",message="settled usage stays settled"

func (*TaskStatus) DeepCopy

func (in *TaskStatus) DeepCopy() *TaskStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TaskStatus.

func (*TaskStatus) DeepCopyInto

func (in *TaskStatus) DeepCopyInto(out *TaskStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type TraceRef

type TraceRef struct {
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{32}$`
	// +kubebuilder:validation:MaxLength=32
	// +kubebuilder:validation:XValidation:rule="self != '00000000000000000000000000000000'",message="an all-zero trace id is invalid W3C"
	TraceID string `json:"traceID"`
	// +kubebuilder:validation:Pattern=`^[0-9a-f]{16}$`
	// +kubebuilder:validation:MaxLength=16
	// +kubebuilder:validation:XValidation:rule="self != '0000000000000000'",message="an all-zero span id is invalid W3C"
	SpanID string `json:"spanID"`
	// +optional
	Exported bool `json:"exported,omitempty"`
	// The collector refused the span for a day after the task ended: given up, never retried (ST2).
	// +optional
	ExportAbandoned bool `json:"exportAbandoned,omitempty"`
}

TraceRef names the task's root span; the factory exports it from these ids at the end (R46). The ids never change once minted: every run of the task is parented on them. +kubebuilder:validation:XValidation:rule="self.traceID == oldSelf.traceID && self.spanID == oldSelf.spanID",message="a task's trace ids never change" +kubebuilder:validation:XValidation:rule="!has(oldSelf.exported) || !oldSelf.exported || (has(self.exported) && self.exported)",message="an exported span stays exported"

func (*TraceRef) DeepCopy

func (in *TraceRef) DeepCopy() *TraceRef

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TraceRef.

func (*TraceRef) DeepCopyInto

func (in *TraceRef) DeepCopyInto(out *TraceRef)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Usage

type Usage struct {
	// Σ of the task's run usage; it never drops (SP1 §2).
	// +optional
	Tokens int64 `json:"tokens,omitempty"`
	// Σ of the task's run costs, in micro-dollars.
	// +optional
	CostMicroUSD int64 `json:"costMicroUSD,omitempty"`
}

Usage is the task's token spend.

func (*Usage) DeepCopy

func (in *Usage) DeepCopy() *Usage

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Usage.

func (*Usage) DeepCopyInto

func (in *Usage) DeepCopyInto(out *Usage)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Verification

type Verification struct {
	// +kubebuilder:validation:Enum=resolved;persisting
	Verdict string        `json:"verdict"`
	Alert   VerifiedAlert `json:"alert"`
	// When the principal checked.
	CheckedAt metav1.Time `json:"checkedAt"`
	// When the factory recorded it.
	RecordedAt metav1.Time `json:"recordedAt"`
	// The principal that sent it, system:<name>.
	// +kubebuilder:validation:MaxLength=64
	By string `json:"by"`
}

Verification is an internal principal's verdict on the fix its proposal led to (RA11).

func (*Verification) DeepCopy

func (in *Verification) DeepCopy() *Verification

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Verification.

func (*Verification) DeepCopyInto

func (in *Verification) DeepCopyInto(out *Verification)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type VerifiedAlert

type VerifiedAlert struct {
	// +kubebuilder:validation:MaxLength=256
	Name          string `json:"name"`
	FiringAtMerge bool   `json:"firingAtMerge"`
	FiringNow     bool   `json:"firingNow"`
}

VerifiedAlert is the alert a verdict is about.

func (*VerifiedAlert) DeepCopy

func (in *VerifiedAlert) DeepCopy() *VerifiedAlert

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VerifiedAlert.

func (*VerifiedAlert) DeepCopyInto

func (in *VerifiedAlert) DeepCopyInto(out *VerifiedAlert)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL