Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
d66cf88
docs(release): specify the judged release contract
instruktai-author[bot] Nov 26, 2026
b4728cf
docs(release): align the judged release contract with the revised PRD
instruktai-author[bot] Nov 26, 2026
6ed45d3
docs(release): state judged release outcomes as the workflow's handoff
instruktai-author[bot] Nov 26, 2026
def7e07
docs(release): fold the human's settled release decisions into the co…
instruktai-author[bot] Nov 27, 2026
f047a15
docs(release): align judged release contract with PRD review fixes
instruktai-author[bot] Nov 27, 2026
671450b
docs(release): clarify trusted default-branch guard and refusal outcome
instruktai-author[bot] Nov 27, 2026
fad4f4f
docs(third-party): port and re-verify release workflow vendor research
instruktai-author[bot] Nov 28, 2026
6aa7f05
docs(release): add domain spec and judged-release architecture design
instruktai-author[bot] Nov 28, 2026
ea25e10
docs(third-party): align vendor facts and remove CI prescriptions
instruktai-author[bot] Nov 28, 2026
5a81810
docs(release): remediate architecture review pass-1 findings
instruktai-author[bot] Nov 28, 2026
c79b9a3
Merge remote-tracking branch 'origin/main' into intelligence-operated…
Morriz Dec 4, 2026
4618b23
docs(release): reconcile judged-release architecture with current pol…
instruktai-author[bot] Dec 4, 2026
f916c2f
feat(judged-release): add static prompts and strict JSON Schemas
instruktai-author[bot] Dec 4, 2026
24a807b
feat(judged-release): implement pure-data judge_logic.py helper
instruktai-author[bot] Dec 4, 2026
fa22e73
feat(judged-release): add guard, install-tool, and capture Bash scripts
instruktai-author[bot] Dec 4, 2026
223aacd
feat(judged-release): add provider execution, Codex auth-stream, and …
instruktai-author[bot] Dec 4, 2026
85ab974
feat(judged-release): add judged-release.yml workflow and actionlint …
instruktai-author[bot] Dec 4, 2026
6e0b864
docs(judged-release): add catalog entry and caller setup guide to REA…
instruktai-author[bot] Dec 4, 2026
a5d8a3b
docs(release): correct secret-passing contract, prune copied config, …
instruktai-author[bot] Dec 4, 2026
7c70490
docs(release): repair declaration-owner references after design pruning
instruktai-author[bot] Dec 4, 2026
636f19f
fix(judged-release): retain closed domain StrEnums on ReleaseHandoff
instruktai-author[bot] Dec 4, 2026
4b6877f
refactor(judged-release): consolidate exact-secret redaction in judge…
instruktai-author[bot] Dec 4, 2026
cb797da
fix(judged-release): separate Codex settlement from freshness and sur…
instruktai-author[bot] Dec 4, 2026
0704a9e
docs(judged-release): switch Codex caller guide to named secret mapping
instruktai-author[bot] Dec 4, 2026
e619761
docs(release): align judged release spec with Claude-only and mandato…
instruktai-author[bot] Dec 4, 2026
1b0bc28
docs(release): simplify domain spec and architecture to Claude-only w…
instruktai-author[bot] Dec 4, 2026
dff415f
docs(release): classify claude binary cache as derived state and fix …
instruktai-author[bot] Dec 4, 2026
086ff42
refactor(judged-release): remove Codex scripts and scope summary prom…
instruktai-author[bot] Dec 4, 2026
198e01a
Simplify judge_logic.py for Claude-only workflow and mandatory summaries
instruktai-author[bot] Dec 4, 2026
167ebe9
Simplify guard, install-tool, and capture for Claude-only workflow
instruktai-author[bot] Dec 4, 2026
2596740
Simplify run-claude and decide for single-provider mandatory-summary …
instruktai-author[bot] Dec 4, 2026
55343cf
Simplify judged-release workflow to 4-job Claude-only DAG and update …
instruktai-author[bot] Dec 4, 2026
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
5 changes: 5 additions & 0 deletions .github/actionlint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,8 @@ paths:
.github/workflows/company-skill-check.yml:
ignore:
- 'property "workflow_(repository|sha)" is not defined'
.github/workflows/judged-release.yml:
ignore:
# Same job-context properties: scripts/judged-release is checked out from
# the commit this reusable workflow was loaded from.
- 'property "workflow_(repository|sha)" is not defined'
192 changes: 192 additions & 0 deletions .github/workflows/judged-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,192 @@
name: judged-release

# Intelligence-operated release decisioning: fail-closed default-branch guard,
# pinned commit capture, read-only native Claude CLI judging, mandatory
# user-facing release summaries, SemVer stepping, and same-run handoff.

on:
workflow_call:
inputs:
operation: { description: 'release or dry-run', type: string, default: 'release' }
version: { description: 'Optional explicit stable SemVer (X.Y.Z or <tag-prefix>X.Y.Z); requires summary', type: string, default: '' }
summary: { description: 'User-facing release summary paired with version; requires version', type: string, default: '' }
initial-version: { description: 'Declared stable SemVer (X.Y.Z) for first release when version is empty', type: string, default: '' }
tag-prefix: { description: 'Git-tag-safe prefix for completed releases and tag output', type: string, default: 'v' }
claude-model: { description: 'Optional Claude model identifier override', type: string, default: '' }
secrets:
CLAUDE_CODE_OAUTH_TOKEN: { description: 'Long-lived Claude subscription OAuth token', required: false }
outputs:
released:
value: ${{ jobs.decide.outputs.released || 'false' }}
version:
value: ${{ jobs.decide.outputs.version || '' }}
tag:
value: ${{ jobs.decide.outputs.tag || '' }}
commit:
value: ${{ jobs.guard.outputs.captured_sha || '' }}
dry-run:
value: ${{ jobs.decide.outputs.dry_run || 'false' }}
decision-mode:
value: ${{ jobs.decide.outputs.decision_mode || '' }}
classification:
value: ${{ jobs.decide.outputs.classification || '' }}
baseline-version:
value: ${{ jobs.decide.outputs.baseline_version || '' }}
baseline-commit:
value: ${{ jobs.decide.outputs.baseline_commit || '' }}
notes-artifact:
value: ${{ jobs.decide.outputs.notes_artifact || '' }}
notes-truncated-for-github-release:
value: ${{ jobs.decide.outputs.notes_truncated_for_github_release || 'false' }}

permissions: {}

jobs:
guard:
name: admission guard
runs-on: ubuntu-latest
timeout-minutes: 5
permissions: { contents: read }
outputs:
captured_sha: ${{ steps.guard.outputs.captured_sha }}
default_branch: ${{ steps.guard.outputs.default_branch }}
operation: ${{ steps.guard.outputs.operation }}
tag_prefix: ${{ steps.guard.outputs.tag_prefix }}
claude_model: ${{ steps.guard.outputs.claude_model }}
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with: { repository: "${{ job.workflow_repository }}", ref: "${{ job.workflow_sha }}", path: .judged-release, sparse-checkout: scripts/judged-release, persist-credentials: false }
- id: guard
env:
EVENT_NAME: ${{ github.event_name }}
DEFAULT_BRANCH: ${{ github.event.repository.default_branch }}
GITHUB_REF: ${{ github.ref }}
GITHUB_SHA: ${{ github.sha }}
OPERATION: ${{ inputs.operation }}
VERSION_INPUT: ${{ inputs.version }}
SUMMARY_INPUT: ${{ inputs.summary }}
CLAUDE_MODEL: ${{ inputs.claude-model }}
TAG_PREFIX: ${{ inputs.tag-prefix }}
run: .judged-release/scripts/judged-release/guard.sh

capture:
name: capture baseline and evidence
needs: [guard]
runs-on: ubuntu-latest
timeout-minutes: 10
permissions: { contents: read }
outputs:
decision_mode: ${{ steps.capture.outputs.decision_mode }}
ai_task: ${{ steps.capture.outputs.ai_task }}
baseline_version: ${{ steps.capture.outputs.baseline_version }}
baseline_commit: ${{ steps.capture.outputs.baseline_commit }}
declared_version: ${{ steps.capture.outputs.declared_version }}
stated_version: ${{ steps.capture.outputs.stated_version }}
commit_count: ${{ steps.capture.outputs.commit_count }}
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with: { repository: "${{ job.workflow_repository }}", ref: "${{ job.workflow_sha }}", path: .judged-release, sparse-checkout: scripts/judged-release, persist-credentials: false }
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with: { ref: "${{ needs.guard.outputs.captured_sha }}", path: src, fetch-depth: 0, persist-credentials: false }
- id: capture
env:
REPO_DIR: src
SCRIPTS_DIR: .judged-release/scripts/judged-release
OUT_DIR: ${{ runner.temp }}/evidence
REPO: ${{ github.repository }}
CAPTURED_SHA: ${{ needs.guard.outputs.captured_sha }}
TAG_PREFIX: ${{ needs.guard.outputs.tag_prefix }}
VERSION_INPUT: ${{ inputs.version }}
INITIAL_VERSION_INPUT: ${{ inputs.initial-version }}
GITHUB_TOKEN: ${{ github.token }}
run: .judged-release/scripts/judged-release/capture.sh
- if: steps.capture.outputs.decision_mode != 'no-change'
uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2
with: { name: "judged-release-evidence-${{ github.run_id }}-${{ github.run_attempt }}", path: "${{ runner.temp }}/evidence", include-hidden-files: true, retention-days: 7, if-no-files-found: error }

judge:
name: judge (claude)
needs: [guard, capture]
if: needs.capture.outputs.ai_task != 'none'
runs-on: ubuntu-latest
continue-on-error: true
timeout-minutes: 15
permissions: { contents: read }
outputs: { valid: "${{ steps.run.outputs.valid || 'false' }}" }
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with: { repository: "${{ job.workflow_repository }}", ref: "${{ job.workflow_sha }}", path: .judged-release, sparse-checkout: scripts/judged-release, persist-credentials: false }
- uses: actions/download-artifact@9000827ccba6bdab643e8b6fd33ac0654aef8333 # v8.0.2
with: { name: "judged-release-evidence-${{ github.run_id }}-${{ github.run_attempt }}", path: "${{ runner.temp }}/evidence" }
- uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
with: { path: "${{ runner.temp }}/tool-cache/claude", key: claude-linux-x64-2.1.332-a2df1f41bb00250992926420d0063f89b127cb81abdd284dbefb80c50ff1d026 }
- env: { TOOL_CACHE_DIR: "${{ runner.temp }}/tool-cache/claude", TOOL_BIN_DIR: "${{ runner.temp }}/tool-bin" }
run: .judged-release/scripts/judged-release/install-tool.sh claude
- id: run
env:
SCRIPTS_DIR: .judged-release/scripts/judged-release
EVIDENCE_DIR: ${{ runner.temp }}/evidence
ATTEMPT_DIR: ${{ runner.temp }}/attempt
TOOL_BIN_DIR: ${{ runner.temp }}/tool-bin
AI_TASK: ${{ needs.capture.outputs.ai_task }}
CLAUDE_MODEL: ${{ needs.guard.outputs.claude_model }}
CLAUDE_CODE_OAUTH_TOKEN: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}
TIMEOUT_SECS: '720'
run: .judged-release/scripts/judged-release/run-claude.sh
- if: always() && !cancelled()
uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2
with: { name: "judged-release-attempt-${{ github.run_id }}-${{ github.run_attempt }}", path: "${{ runner.temp }}/attempt", retention-days: 7, if-no-files-found: ignore }

decide:
name: decide version and handoff
needs: [guard, capture, judge]
if: always() && !cancelled() && needs.capture.result == 'success'
runs-on: ubuntu-latest
timeout-minutes: 5
permissions: { contents: read }
outputs:
released: ${{ steps.decide.outputs.released }}
version: ${{ steps.decide.outputs.version }}
tag: ${{ steps.decide.outputs.tag }}
dry_run: ${{ steps.decide.outputs.dry_run }}
decision_mode: ${{ steps.decide.outputs.decision_mode }}
classification: ${{ steps.decide.outputs.classification }}
baseline_version: ${{ steps.decide.outputs.baseline_version }}
baseline_commit: ${{ steps.decide.outputs.baseline_commit }}
notes_artifact: ${{ steps.decide.outputs.notes_artifact }}
notes_truncated_for_github_release: ${{ steps.decide.outputs.notes_truncated_for_github_release }}
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with: { repository: "${{ job.workflow_repository }}", ref: "${{ job.workflow_sha }}", path: .judged-release, sparse-checkout: scripts/judged-release, persist-credentials: false }
- if: needs.capture.outputs.decision_mode != 'no-change'
uses: actions/download-artifact@9000827ccba6bdab643e8b6fd33ac0654aef8333 # v8.0.2
with: { name: "judged-release-evidence-${{ github.run_id }}-${{ github.run_attempt }}", path: "${{ runner.temp }}/work/evidence" }
- if: needs.judge.result != 'skipped'
continue-on-error: true
uses: actions/download-artifact@9000827ccba6bdab643e8b6fd33ac0654aef8333 # v8.0.2
with: { name: "judged-release-attempt-${{ github.run_id }}-${{ github.run_attempt }}", path: "${{ runner.temp }}/work/attempt" }
- id: decide
env:
SCRIPTS_DIR: .judged-release/scripts/judged-release
WORK_DIR: ${{ runner.temp }}/work
OUT_DIR: ${{ runner.temp }}/handoff
REPO: ${{ github.repository }}
CAPTURED_SHA: ${{ needs.guard.outputs.captured_sha }}
OPERATION: ${{ needs.guard.outputs.operation }}
TAG_PREFIX: ${{ needs.guard.outputs.tag_prefix }}
DECISION_MODE: ${{ needs.capture.outputs.decision_mode }}
AI_TASK: ${{ needs.capture.outputs.ai_task }}
BASELINE_VERSION: ${{ needs.capture.outputs.baseline_version }}
BASELINE_COMMIT: ${{ needs.capture.outputs.baseline_commit }}
DECLARED_VERSION: ${{ needs.capture.outputs.declared_version }}
STATED_VERSION: ${{ needs.capture.outputs.stated_version }}
SUMMARY_INPUT: ${{ inputs.summary }}
CLAUDE_CODE_OAUTH_TOKEN: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}
GITHUB_TOKEN: ${{ github.token }}
JUDGE_RESULT: ${{ needs.judge.result }}
JUDGE_VALID: ${{ needs.judge.outputs.valid }}
NOTES_ARTIFACT: judged-release-notes-${{ github.run_id }}-${{ github.run_attempt }}
run: .judged-release/scripts/judged-release/decide.sh
- if: steps.decide.outputs.released == 'true'
uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2
with: { name: "${{ steps.decide.outputs.notes_artifact }}", path: "${{ runner.temp }}/handoff", retention-days: 30, if-no-files-found: error }
62 changes: 62 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ toolchain, pipelines just push buttons.
| `bench.yml` | CodSpeed benchmarks (Rust, Python) with regression reports on PRs (see below) |
| `company-skill.yml` | Render a company's knowledge into its committed `AGENTS.md` and its Claude plugin, publish when changed (see below) |
| `company-skill-check.yml` | Validate a company's knowledge documents on a pull request, read access only (see below) |
| `judged-release.yml` | Intelligence-operated release judgment via Claude subscription, mandatory release summary, SemVer decision, and same-run handoff (see below) |

This repo's own workflows, not for callers: `release.yml` (releases this
repo, see "Releasing"), `actionlint.yml`, `self-test.yml`,
Expand Down Expand Up @@ -436,6 +437,67 @@ jobs:
`company-<slug>`. Put every workflow that pushes to the default branch in one
concurrency group, so they queue instead of racing.

## Intelligence-operated releases: `judged-release.yml`

Evaluates default-branch changes since the last completed GitHub Release via a
pinned, read-only native Claude Code CLI (`CLAUDE_CODE_OAUTH_TOKEN`, created
with `claude setup-token`), computes the next SemVer (`<1.0.0` maps `major` and
`minor` to the next minor; `1.0.0` requires an explicit `version`), and hands
version, captured commit, and release notes to caller jobs in the same run.

Every released run produces a non-blank user-facing summary alongside the
release commit list — automatic runs fail closed if Claude cannot produce one,
and maintainer-stated runs must pass both `version` and `summary` together (an
unpaired input fails fast in `guard`, and a valid pair bypasses Claude while
still assembling the full commit list). Runs fail closed outside trusted
default-branch triggers (`schedule`, `push` to default branch,
`workflow_dispatch`). No GitHub Environment setup is required, and the reusable
workflow requires only `permissions: { contents: read }`.

Callers serialize with a non-cancelling `concurrency` group, compose after
checks via `needs:`, publish non-draft, non-prerelease `<tag-prefix>X.Y.Z`
releases at `needs.release.outputs.commit`, and skip publication when
`needs.release.outputs.dry-run == 'true'`.

```yaml
name: release

on:
schedule: [{ cron: '0 6 * * *' }]
workflow_dispatch:
inputs:
operation: { description: 'release or dry-run', type: choice, options: [release, dry-run], default: release }
version: { description: 'Optional explicit SemVer (requires summary)', type: string, default: '' }
summary: { description: 'User-facing release summary (requires version)', type: string, default: '' }

concurrency: { group: release, cancel-in-progress: false }
permissions: { contents: read }

jobs:
checks:
uses: InstruktAI/workflows/.github/workflows/ci-rust.yml@v1
release:
needs: [checks]
permissions: { contents: read }
uses: InstruktAI/workflows/.github/workflows/judged-release.yml@v1
with:
operation: ${{ inputs.operation || 'release' }}
version: ${{ inputs.version || '' }}
summary: ${{ inputs.summary || '' }}
initial-version: '0.1.0'
secrets:
CLAUDE_CODE_OAUTH_TOKEN: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}
publish:
needs: [release]
if: needs.release.outputs.released == 'true' && needs.release.outputs.dry-run != 'true'
runs-on: ubuntu-latest
permissions: { contents: write }
steps:
- uses: actions/download-artifact@9000827ccba6bdab643e8b6fd33ac0654aef8333 # v8.0.2
with: { name: "${{ needs.release.outputs.notes-artifact }}", path: release-handoff }
# Build at commit, tag with tag, publish github-release-body.md (full release-notes.md + release-handoff.json).
```

## Releasing this repository

`release.yml` (Actions → release → Run workflow on `main`, `version` vX.Y.Z)
Expand Down
Loading
Loading