Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 14 additions & 13 deletions .criteria/workflows/bootstrap/bootstrap.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -29,58 +29,59 @@
# click Approve on the PR in GitHub (branch protection forbids self-
# approval), then approve the workflow node to continue.

workflow "bootstrap" {
workflow {

name = "bootstrap"
version = "1"
initial_state = "preflight"
target_state = "done"
}

policy {
max_total_steps = 5000
policy {
max_total_steps = 5000
}
}

variable "workstream_file" {
type = "string"
type = string
default = ""
description = "Path to the workstream markdown file to process, relative to project_dir."
}

variable "project_dir" {
type = "string"
type = string
default = ""
description = "Absolute path to the criteria engine project root."
}

variable "max_retries" {
type = "number"
type = number
default = 3
description = "Maximum developer/owner cycles before requesting operator assistance inside develop."
}

variable "base_branch" {
type = "string"
type = string
default = "adapter-v2"
description = "Integration branch all workstream PRs target. Use 'main' for post-release workstreams (WS41+)."
}

variable "require_workflow_approval" {
type = "string"
type = string
default = "false"
description = "Set to 'true' to require explicit workflow-node approval before merge. Default false suits feature-branch work; set true when targeting main."
}

variable "developer_model" {
type = "string"
type = string
default = "claude-sonnet-4.6"
}

variable "reviewer_model" {
type = "string"
type = string
default = "gpt-5.4"
}

variable "pr_reviewer_model" {
type = "string"
type = string
default = "gpt-5.5"
}

Expand Down
29 changes: 15 additions & 14 deletions .criteria/workflows/develop/main.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -24,62 +24,63 @@
# that defaults to "failed" and is flipped to "ok" only along the success
# path. The parent (bootstrap.hcl) switches on this status.

workflow "develop" {
workflow {

name = "develop"
version = "1"
initial_state = "prepare_branch"
target_state = "returned"
}

policy {
max_total_steps = 500
policy {
max_total_steps = 500
}
}

variable "workstream_file" {
type = "string"
type = string
default = ""
description = "Path to the workstream markdown file, relative to project_dir."
}

variable "max_retries" {
type = "number"
type = number
default = 3
description = "Maximum developer→owner cycles before requesting operator assistance."
}

variable "project_dir" {
type = "string"
type = string
default = ""
description = "Absolute path to the criteria engine project root."
}

variable "developer_model" {
type = "string"
type = string
default = "claude-sonnet-4.6"
}

variable "reviewer_model" {
type = "string"
type = string
default = "gpt-5.4"
}

variable "base_branch" {
type = "string"
type = string
default = "adapter-v2"
description = "Integration branch to branch from and diff against."
}

shared_variable "cycle_count" {
type = "number"
type = number
value = 0
}

shared_variable "terminal_status" {
type = "string"
type = string
value = "failed"
}

output "status" {
type = "string"
type = string
value = shared.terminal_status
}

Expand Down
19 changes: 10 additions & 9 deletions .criteria/workflows/develop/review_axis/main.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -17,34 +17,35 @@
# failure for aggregation purposes, which triggers `on_failure="abort"` and
# cancels sibling reviewers mid-review.

workflow "review_axis" {
workflow {

name = "review_axis"
version = "1"
initial_state = "select_reviewer"
target_state = "failed"
}

policy {
max_total_steps = 60
policy {
max_total_steps = 60
}
}

variable "review_kind" {
type = "string"
type = string
default = ""
description = "Review axis: security, quality, workstream, or api_compat."
}

variable "workstream_file" {
type = "string"
type = string
default = ""
}

variable "project_dir" {
type = "string"
type = string
default = ""
}

variable "reviewer_model" {
type = "string"
type = string
default = "gpt-5.4"
}

Expand Down
29 changes: 15 additions & 14 deletions .criteria/workflows/pr_review/main.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -34,62 +34,63 @@
# (internal/engine/node_step.go:477-480). The status output defaults to
# "failed" and is flipped to "ok" only on the merge-and-sync success path.

workflow "pr_review" {
workflow {

name = "pr_review"
version = "1"
initial_state = "open_pr"
target_state = "returned"
}

policy {
max_total_steps = 300
policy {
max_total_steps = 300
}
}

variable "workstream_file" {
type = "string"
type = string
default = ""
}

variable "project_dir" {
type = "string"
type = string
default = ""
}

variable "max_review_attempts" {
type = "number"
type = number
default = 2
description = "Number of pr_reviewer escalations before returning `escalated` to the parent."
}

variable "pr_reviewer_model" {
type = "string"
type = string
default = "gpt-5.5"
description = "Model for the cold PR reviewer."
}

variable "base_branch" {
type = "string"
type = string
default = "adapter-v2"
description = "Integration branch that workstream PRs target. Used for PR base, sync, and diff."
}

variable "require_workflow_approval" {
type = "string"
type = string
default = "false"
description = "Set to 'true' to require explicit workflow-node approval before merge (for main-targeting PRs). Default 'false' uses async GitHub approval polling."
}

shared_variable "review_attempts" {
type = "number"
type = number
value = 0
}

shared_variable "terminal_status" {
type = "string"
type = string
value = "failed"
}

output "status" {
type = "string"
type = string
value = shared.terminal_status
}

Expand Down
Loading
Loading