Skip to content
Merged
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
6 changes: 3 additions & 3 deletions .github/workflows/released-smoke.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,14 +32,14 @@ jobs:
run: |
npm install --prefix "$RUNNER_TEMP/aictrl-owned-cli" \
--ignore-scripts --no-audit --no-fund \
@aictrl/cli@0.5.4 @aictrl/cli-linux-x64-baseline@0.5.4
node -e 'const fs=require("node:fs"); const root=process.env.RUNNER_TEMP+"/aictrl-owned-cli/node_modules/@aictrl/"; for(const name of ["cli","cli-linux-x64-baseline"]){const p=JSON.parse(fs.readFileSync(root+name+"/package.json","utf8")); if(p.version!=="0.5.4") throw new Error("Unexpected package version"); console.log(p.name+"@"+p.version)}'
@aictrl/cli@0.5.6 @aictrl/cli-linux-x64-baseline@0.5.6
node -e 'const fs=require("node:fs"); const root=process.env.RUNNER_TEMP+"/aictrl-owned-cli/node_modules/@aictrl/"; for(const name of ["cli","cli-linux-x64-baseline"]){const p=JSON.parse(fs.readFileSync(root+name+"/package.json","utf8")); if(p.version!=="0.5.6") throw new Error("Unexpected package version"); console.log(p.name+"@"+p.version)}'
- name: Run owned fixture against released native artifact
shell: bash
run: |
node "$RECIPE_DIR/smoke.mjs" \
--binary "$RUNNER_TEMP/aictrl-owned-cli/node_modules/@aictrl/cli-linux-x64-baseline/bin/aictrl" \
--expected-sha256 f12a54259ae0d77d85fd6d0cfefe1dcc742b95a617ca71e48f4fdfb2575182ee \
--expected-sha256 44af63abe00fad5c371d34fdb7cffd13d7a0c1bf8808706906b2cf1c088d3092 \
--evidence-dir "$RUNNER_TEMP/aictrl-owned-evidence"
- name: Retain only inert fixture evidence
if: always()
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ jobs:
GH_TOKEN: ${{ github.token }}

# Pin a version for reproducible runs; update it when you upgrade.
- run: npm install -g @aictrl/cli@0.5.4
- run: npm install -g @aictrl/cli@0.5.6

# The harness loads AGENTS.md files as instructions, and the pull request can add them.
# Remove them so the review follows only the prompt below.
Expand Down
72 changes: 10 additions & 62 deletions RELEASING.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,12 +54,21 @@
succeeds, inspect the failure before rerunning: npm versions are immutable.
5. Independently install `@aictrl/cli@<version>` in a temporary directory and
verify `./node_modules/.bin/aictrl --version` equals `<version>`.
6. In a separate aictrl application PR, update `docker/executor/Dockerfile` to
6. Refresh the pinned [released consumer smoke](examples/released-smoke/README.md)
in a follow-up CLI PR once the new packages are visible on npm. Update the
package versions and Linux x64 baseline binary SHA-256 in the active workflow,
the example workflow, and the example README's local command. Update the root
README's PR-review recipe to the same version. Update the runner's expected
version and release commit, then run the fixture against a fresh install of
the pinned native package.
7. In a separate aictrl application PR, update `docker/executor/Dockerfile` to
the published version. Build the executor image and rerun the headless
discovery and idle-stream fixtures against its binary. Promote through
`sandbox` before `main`; verify a sandbox review persists MCP findings and
a stalled stream reports a timeout rather than waiting for the job limit.

Record each candidate's verification evidence in its release PR.

## Platform packages

`packages/cli/script/build.ts` builds one binary per OS, CPU and libc, and the
Expand Down Expand Up @@ -101,64 +110,3 @@ Before merging the bump, build the binary with the old and the new Bun and
compare time to first response and RSS: run a one-turn `aictrl run` against a
stub model in a fresh, CPU- and memory-limited container, several times each.
Moving from Bun 1.3.10 to 1.4.3 alone changed them by about 85 ms and 85 MB.

## 0.5.4 candidate

- **Why a patch bump (0.5.4):** the range `v0.5.3..97cc5be868` is four PRs,
#233, #234, #235 and the test-only #237. They change the system prompt and
add the GPT-6 family, which CLAUDE.md treats as patch-level model support,
and fix a flaky test. No CLI flag,
command, config key or NDJSON event field is removed, and `schemaVersion`
stays `"1"`. One model option is removed: with an API key, `gpt-6-astra`
and `gpt-6.1-sol` no longer offer the `none` effort variant, which OpenAI
rejects for them, so no working configuration loses it (#234).
- **System prompt:** every model except Codex sign-in sessions now gets one
shared base prompt, `default.txt` (#233 trims it and renames it from
`qwen.txt`; #235 removes `anthropic.txt`, `beast.txt`, `gemini.txt` and
`trinity.txt`). Codex sign-in still sends `codex_header.txt` as
`instructions`. Gemini, Claude and GPT were not re-validated on the final
wording; only `zai-coding-plan/glm-5.3` was (see the CHANGELOG).
- **Defaults:** with nothing configured or recently used, an OpenAI-only setup
defaults to `gpt-6.1-sol` (was `gpt-5.6-terra`), and the small model is
`gpt-6-luna` (#234).
- **Published package set:** unchanged from 0.5.3 (the 7 packages above).
- **Bun:** the binary must embed `Bun v1.4.3`.
- Evidence, on the release commit with Bun 1.4.3 (on `e88ed7f432`; after the
rebase onto #237 the full suite and step-2 list were run again):
- step-2 regressions: 95 pass, 0 fail (8 files);
- `bun test --timeout 30000` (packages/cli): 1809 pass, 6 skip, 0 fail
(1815 tests, 148 files), the same after the rebase onto #237; the
formerly flaky `handles filenames with # character` test (fixed by #237)
also passes alone in a clean `env -i CI=true` environment;
- `bun turbo typecheck --force`: 6/6;
- `AICTRL_VERSION=0.5.4 AICTRL_BUILD_SINGLE=true bun turbo build --force`
(CI's build): 3/3 tasks, builds only `cli-linux-x64-baseline`;
`aictrl --version` prints `0.5.4` and the binary embeds `Bun v1.4.3`;
- the five binary-capable `aictrl run` suites with `AICTRL_TEST_BINARY` set
to that binary: 21 pass, 0 fail;
- `wrapper-binary-resolution`, the NDJSON schema tests (`run-schema-v1`,
`events-command`, `run-user-message`, `run-event-race`), `bun-version-pin`
and the prompt tests (`system`, `llm`, `headless-prompt-budget`): 76 pass,
0 fail;
- a one-turn `aictrl run --format json` of that binary against a stub
OpenAI-compatible endpoint, with isolated `HOME`/XDG dirs: exit 0, one
model request, 10 events, `schemaVersion` `"1"`, both terminal statuses
`completed`; the request's single system message starts with the trimmed
`default.txt` (2,602 chars), including the new Task-tool and
rejected-call lines, followed by the environment block;
- `AICTRL_VERSION=0.5.4 bun run build` builds the 7 targets. `npm pack` of
each platform package gives `bin/aictrl` (`aictrl.exe` on windows),
`bin/aictrl.map`, `LICENSE` and a `package.json` whose `os`, `cpu` and
`libc` match the table. publish.yml's manifest step, run on a copy, writes
exactly those 7 names at `0.5.4` into `optionalDependencies`; the wrapper
tarball has 4 files, 18.3 kB unpacked.
- not repeated from 0.5.3: the local-registry (verdaccio) publish, the
visibility step and the fresh-container installs. `bin/aictrl`,
`script/build.ts` and `publish.yml` are unchanged in `v0.5.3..97cc5be868`,
and the tarballs above match 0.5.3's except for the version, so those
checks would exercise the same code. The publish workflow's visibility
gate and install smoke, and the clean `npm install` in step 5, still check
0.5.4 itself after merge.

Publication and executor promotion are separate gates. Preparing this candidate
PR does not publish npm packages or deploy an executor image.
10 changes: 5 additions & 5 deletions examples/released-smoke/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Released CLI consumer-contract smoke

A credential-free companion to the [real-provider PR review recipe](../../README.md#2-drop-in-github-actions-pr-review-split-secret-pattern). This runs published **0.5.4**, rather than building repository source. A scripted loopback provider requests a real file read and checks the returned bytes. It tests CLI integration, JSON events and failure handling; it does not measure model coding quality or establish safety for untrusted checkouts.
A credential-free companion to the [real-provider PR review recipe](../../README.md#2-drop-in-github-actions-pr-review-split-secret-pattern). It runs the published **0.5.6** binary. A scripted loopback provider requests a real file read and checks the returned bytes. It tests CLI integration, JSON events and failure handling; it does not measure model coding quality or establish safety for untrusted checkouts.

## Run locally

Expand All @@ -9,10 +9,10 @@ Use Node **20.20.2** and the published Linux x64 baseline native package. Packag
```bash
CLI_DIR=$(mktemp -d)
npm install --prefix "$CLI_DIR" --ignore-scripts --no-audit --no-fund \
@aictrl/cli@0.5.4 @aictrl/cli-linux-x64-baseline@0.5.4
@aictrl/cli@0.5.6 @aictrl/cli-linux-x64-baseline@0.5.6
node examples/released-smoke/smoke.mjs \
--binary "$CLI_DIR/node_modules/@aictrl/cli-linux-x64-baseline/bin/aictrl" \
--expected-sha256 f12a54259ae0d77d85fd6d0cfefe1dcc742b95a617ca71e48f4fdfb2575182ee \
--expected-sha256 44af63abe00fad5c371d34fdb7cffd13d7a0c1bf8808706906b2cf1c088d3092 \
--evidence-dir "$CLI_DIR/evidence"
```

Expand All @@ -26,6 +26,6 @@ The [active workflow](../../.github/workflows/released-smoke.yml) runs on change

Neither workflow runs on `pull_request` or `pull_request_target`. The npm setup step uses network access; the CI job does not enforce no-egress isolation. The local transport binds only an ephemeral loopback port. Environment and tool restrictions are not an operating-system sandbox.

Released instruction discovery is imperfect ([#250](https://github.com/aictrl-dev/cli/issues/250)), so the runner rejects ancestor `AGENTS.md` and `.opencode/AGENTS.md` files before launching the CLI. Closed stdin avoids [#210](https://github.com/aictrl-dev/cli/issues/210). Ambient shell/config execution concerns remain [#245](https://github.com/aictrl-dev/cli/issues/245); use only this owned fixture, not an unknown PR checkout.
The runner launches the CLI in a temporary workspace. Before launch it rejects `AGENTS.md` and `.opencode/AGENTS.md` in that workspace or any of its parent directories to avoid loading ambient instructions. Closed stdin avoids [#210](https://github.com/aictrl-dev/cli/issues/210). Ambient shell/config execution concerns remain [#245](https://github.com/aictrl-dev/cli/issues/245); use only this owned fixture, not an unknown PR checkout.

The runner passed local acceptance against the pinned released artifact. GitHub Actions execution must be checked separately; adding the workflow alone is not evidence of a successful CI run.
Check the GitHub Actions run for CI results against the pinned binary.
8 changes: 4 additions & 4 deletions examples/released-smoke/smoke.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@ let pendingFailure
let signalVersion = 0
const report = {
recipe: marker,
expectedVersion: "0.5.4",
releaseSourceCommit: "6c661f4cf3e3d555a0f290bc22e071c6de4bd19b",
expectedVersion: "0.5.6",
releaseSourceCommit: "7d4c1f77f6df656ec7238453da953ef0bfa41a4e",
startedUTC: new Date().toISOString(),
nodeVersion: process.version,
binary,
Expand Down Expand Up @@ -221,7 +221,7 @@ try {
["home", "data", "config", "cache", "state"].map((name) => [name, path.join(root, name)]),
)
await Promise.all([workspace, ...Object.values(dirs)].map((dir) => mkdir(dir)))
// v0.5.4 still discovers nested instruction files despite the config flag.
// Keep host and repository instructions out of the owned fixture.
for (let directory = workspace; ; directory = path.dirname(directory)) {
for (const name of ["AGENTS.md", ".opencode/AGENTS.md"]) {
const instruction = path.join(directory, name)
Expand Down Expand Up @@ -317,7 +317,7 @@ try {
report.config = config
const version = await run("version", ["--version"], env, workspace)
assert.equal(version.code, 0)
assert.equal(version.stdout.trim(), "0.5.4", "Released native version")
assert.equal(version.stdout.trim(), report.expectedVersion, "Released native version")
assert.equal(requests.length, 0, "Version command must not call the model")
const prompt = `${marker}: Read fixture.txt, then report the fixture result.`
const positive = await run(
Expand Down
6 changes: 3 additions & 3 deletions examples/released-smoke/workflow.example.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,14 @@ jobs:
run: |
npm install --prefix "$RUNNER_TEMP/aictrl-owned-cli" \
--ignore-scripts --no-audit --no-fund \
@aictrl/cli@0.5.4 @aictrl/cli-linux-x64-baseline@0.5.4
node -e 'const fs=require("node:fs"); const root=process.env.RUNNER_TEMP+"/aictrl-owned-cli/node_modules/@aictrl/"; for(const name of ["cli","cli-linux-x64-baseline"]){const p=JSON.parse(fs.readFileSync(root+name+"/package.json","utf8")); if(p.version!=="0.5.4") throw new Error("Unexpected package version"); console.log(p.name+"@"+p.version)}'
@aictrl/cli@0.5.6 @aictrl/cli-linux-x64-baseline@0.5.6
node -e 'const fs=require("node:fs"); const root=process.env.RUNNER_TEMP+"/aictrl-owned-cli/node_modules/@aictrl/"; for(const name of ["cli","cli-linux-x64-baseline"]){const p=JSON.parse(fs.readFileSync(root+name+"/package.json","utf8")); if(p.version!=="0.5.6") throw new Error("Unexpected package version"); console.log(p.name+"@"+p.version)}'
- name: Run owned fixture against released native artifact
shell: bash
run: |
node "$RECIPE_DIR/smoke.mjs" \
--binary "$RUNNER_TEMP/aictrl-owned-cli/node_modules/@aictrl/cli-linux-x64-baseline/bin/aictrl" \
--expected-sha256 f12a54259ae0d77d85fd6d0cfefe1dcc742b95a617ca71e48f4fdfb2575182ee \
--expected-sha256 44af63abe00fad5c371d34fdb7cffd13d7a0c1bf8808706906b2cf1c088d3092 \
--evidence-dir "$RUNNER_TEMP/aictrl-owned-evidence"
- name: Retain only inert fixture evidence
if: always()
Expand Down
Loading