test(runner-e2e): attended Antigravity swarm cells; docs and qualification ledger

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
DottaandClaude Opus 5.5 committed 2026-11-23 23:04:54 -06:00
1 parent 417c695a9a
commit fbeeb9d249
10 files changed
+175 -13

No files matched your search

+3 -1
View File
@@ -46,7 +46,9 @@ pending-permission Stop and provider-loss oracles. Separate
check one exact-model receipt per model ID. Chat and instruction evals can run
under Antigravity with `--profile runner-acpx-antigravity`. Registration is not a
live pass; pending cells need a company-bound candidate grant that the harness
stages itself.
stages itself. The explicit-only [Antigravity swarm suite](../tests/runner-e2e/SUITES.md#google-antigravity-swarm)
lists five attended native `/swarm` cells; they run through a live recipe, not
an automated executor.
The public directory calls full-product testing **E2E tests**. Suites describe
what is tested; deployment targets describe which app instance was tested.
@@ -77,9 +77,8 @@ These are two different features. The pinned 1.5.2 ACP server offers neither.
A second distribution, Google's Antigravity CLI (`agy`) 1.5.15, build
`1.5.15-5514532022517760`, is pinned for darwin-arm64, linux-x64 and
linux-arm64 in `packages/paperclip-runner/antigravity-cli-distributions.json`.
It is the planned route for native `/swarm`. This step adds only the pin,
`paperclipai runtime setup antigravity-cli` and a launch resolver. No route
selection, driver or command detection exists yet, so nothing runs the CLI.
It is the route for native `/swarm` (experimental, off by default; see
"/swarm on the Antigravity CLI" below).
- **Experimental.** It is not part of the registry-server profile above and
changes none of its pins, its admission patch or its qualification state.
@@ -165,7 +164,7 @@ API-key route or Daytona remain NOT RUN, not failed and not passed.
| Qualification suite | All 24 `antigravity-qualification` cells, local and Daytona | NOT RUN |
| Evals under the native Runner | Applicable Product E2E and chat cases run with Antigravity; numbers recorded | NOT RUN |
| Image pull and startup time | Daytona image with the Linux closure, measured cold | NOT RUN |
| Swarm (`/swarm`) | Native swarm starts from a task | Not supported by 1.5.2 (2026-11-23): not advertised, no swarm tools. A live `/swarm` task ran as a plain request |
| Swarm (`/swarm`) | Native swarm starts from a task | Built on the Antigravity CLI route behind the off-by-default flag; fake-CLI tests pass. Live local proof pending (recipe below). The registry server 1.5.2 still has no swarm |
### First live tasks (2026-11-23, local, Google sign-in)
@@ -312,3 +311,61 @@ provider-death fixtures now target the store and per-launch directory layout.
Claude and OpenCode, and Test refuses the path. Kimi, Copilot and Pi do not
run there either. Closing it needs a plugin SDK contract change plus a Cloud
plugin and image change.
## /swarm on the Antigravity CLI (2026-11-24)
What exists:
- **Trusted start.** The task composer reads a leading `/swarm` with the shared
`parseLeadingUserCommand` rule and sends a structured `nativeCommand: "swarm"`
with the request text. The server accepts it only from a signed-in user,
records `issue.antigravity_swarm_requested` in the activity log and marks the
assignee's wake. Pasted, quoted, agent or API text stays text and is still
neutralised for the registry server.
- **Flag.** `instance.experimental.enableAntigravitySwarm` (Settings,
Experimental, "Google Antigravity swarm"). Off by default. No Cloud policy in Core.
- **Refusals, in plain language, before anything runs:** flag off, not an
Antigravity assignee, a chat, Plan mode, a remote or cloud environment, a
Gemini API key (no auto mode), an unpinned platform, extra tool servers.
- **Driver.** `antigravity-swarm-*.ts` in the Runner. In place of the registry
patch receipt it verifies identity and version, the instruction channel, the
task folder as `cwd`, Paperclip's bridge as the only MCP server, `auto` mode
and the exact model by read-back, and fails closed on any later change. One
fresh session per run; at most one swarm per run; Paperclip delegation tools
are removed from the bridge for the swarm turn.
- **Governance.** Helpers act in Antigravity's `auto` mode. The driver stops
the swarm on any visible change outside the task folder (file tools and shell
write targets, with `..`, `~`, `$HOME` and symlinks resolved), refuses every
permission prompt except Paperclip's own tools, and shows what changed in the
task folder. It does not settle on the first `end_turn` while helpers may run.
- **Not confined by Paperclip.** Helper tool calls never reach the client, and
Paperclip's local process sandbox does not wrap Runner harnesses, so helper
shell commands are confined only by the CLI (workspace plus temp directories).
- **Credentials.** On macOS the CLI uses its own Google sign-in from the login
keychain (the real HOME), not Paperclip's stored Google connection. CLI state
lives in a private `--gemini-dir`. Terms: a legal read of the consumer terms'
third-party-tool clause is pending.
- **Usage.** One total from the coordinator, labelled as including the helpers.
<a id="swarm-live-proof"></a>
### /swarm live proof (local, attended)
Setup: a local instance from the swarm branch, a Google sign-in connection, an
Antigravity agent on `gemini-3.8-flash-low`, `paperclipai runtime setup
antigravity-cli` run as the Paperclip user, the Antigravity CLI signed in on
this computer, and the experimental flag on. Then, on a task for that agent:
1. `/swarm two helpers: one writes a.txt containing A, one writes b.txt
containing B; a verifier checks both`: native swarm, both files in the task
folder, task Done, activity log names the swarm.
2. The same, then Stop mid-swarm: run cancelled, no `agy` process left.
3. The same, then kill the `agy` process mid-swarm, then Retry: a fresh swarm
runs in the same folder; nothing posted twice.
4. An ordinary follow-up comment after a swarm: runs normally (fresh session).
5. Flag off, `/swarm ...`: the composer shows "Swarm is not turned on ..." and
nothing is posted or run.
| Gate | Result |
| --- | --- |
| Unit and fake-CLI tests (driver, guard, paths, route, server, composer) | Passed |
| Live steps 1-5 | NOT RUN (pending) |
+17
View File
@@ -1724,6 +1724,23 @@ pnpm test:e2e:runner -- --id antigravity-qualification.runner-acpx-antigravity.l
pnpm test:e2e:runner -- --suite antigravity-qualification --environment daytona --max-automatic-retries 0
```
### Google Antigravity swarm
`antigravity-swarm` (5 cells, local only) lists the native `/swarm` behaviours
on the Antigravity CLI route: `two-helpers-and-verifier`, `stop-mid-swarm`,
`process-loss-retry`, `follow-up-after-swarm` and `flag-off-refusal`. It needs
the experimental flag, `paperclipai runtime setup antigravity-cli` and the
Antigravity CLI's own Google sign-in on the computer. It is explicit-only,
never part of `--all` or CI matrix jobs, and has no automated executor yet: the
launcher refuses its cells and points at the attended
[live recipe](../../doc/plans/2026-11-22-antigravity-qualification.md#swarm-live-proof).
Deterministic coverage lives in the Runner's fake-CLI tests
(`packages/paperclip-runner/test-fixtures/antigravity-cli/fake-agy-acp.mjs`).
```sh
pnpm test:e2e:runner -- --list --suite antigravity-swarm
```
### Google Antigravity model lineups
`antigravity-model-lineup` (14 cells) and `antigravity-model-lineup-gemini4`
@@ -0,0 +1,56 @@
import { createHash } from "node:crypto";
import { readFileSync } from "node:fs";
import type { EnvironmentFixture, RunnerProfileFixture, RunnerSuiteFixture, RunnerTaskFixture } from "./types.js";
/**
* Google Antigravity native `/swarm` (Antigravity CLI route). Attended and
* explicit-only: it needs the instance flag "Google Antigravity swarm", the
* pinned CLI installed with `paperclipai runtime setup antigravity-cli`, and
* the Antigravity CLI signed in to Google on this computer. These cells are
* listed and selectable but never run in CI; until an automated executor is
* built, the launcher refuses them and points at the live recipe in
* doc/plans/2026-11-22-antigravity-qualification.md ("/swarm live proof").
*/
export const ANTIGRAVITY_SWARM_SUITE = "antigravity-swarm";
export const ANTIGRAVITY_SWARM_MODEL = "gemini-3.8-flash-low";
export const ANTIGRAVITY_SWARM_CASES = [
"two-helpers-and-verifier", "stop-mid-swarm", "process-loss-retry", "follow-up-after-swarm", "flag-off-refusal",
] as const;
export const ANTIGRAVITY_SWARM_RECIPE = "doc/plans/2026-11-22-antigravity-qualification.md#swarm-live-proof";
const LABELS: Record<(typeof ANTIGRAVITY_SWARM_CASES)[number], { label: string; runs: number; issue: "done" | "in_progress" | "todo"; run: "succeeded" | "cancelled" | "failed" }> = {
"two-helpers-and-verifier": { label: "Two helpers write a.txt and b.txt, a verifier checks both; task Done", runs: 1, issue: "done", run: "succeeded" },
"stop-mid-swarm": { label: "Stop mid-swarm stops every helper and leaves no process", runs: 1, issue: "todo", run: "cancelled" },
"process-loss-retry": { label: "Kill the CLI mid-swarm, Retry starts a fresh swarm in the same task folder", runs: 2, issue: "done", run: "succeeded" },
"follow-up-after-swarm": { label: "An ordinary follow-up after a swarm runs on the registry route", runs: 2, issue: "done", run: "succeeded" },
"flag-off-refusal": { label: "With the flag off, /swarm gets the plain 'not available' message and nothing runs", runs: 0, issue: "todo", run: "succeeded" },
};
export function buildAntigravitySwarmSuite(environments: readonly EnvironmentFixture[]): RunnerSuiteFixture {
const profile: RunnerProfileFixture = { id: "runner-antigravity-swarm", label: "Google Antigravity swarm (CLI route)", generation: "native", groups: [],
adapterType: "paperclip_runner", provider: "acpx", model: ANTIGRAVITY_SWARM_MODEL, credential: "GEMINI_API_KEY",
supportedEnvironments: ["local"], expectedRuntimeMode: "native", expectedRuntimeMetadata: { adapterType: "paperclip_runner", provider: "acpx" },
modelQualification: { source: "candidate_runner_profile", qualificationId: "antigravity:operator-admitted-darwin-arm64-cli-swarm" },
buildAgent: () => { throw new Error("The swarm cells use an Antigravity agent created through the ordinary UI"); } };
const hash = createHash("sha256");
for (const file of ["antigravity-swarm-cases.ts", "../../packages/paperclip-runner/antigravity-cli-distributions.json"]) {
hash.update(file).update(readFileSync(new URL(`./${file}`, import.meta.url)));
}
const tasks: RunnerTaskFixture[] = ANTIGRAVITY_SWARM_CASES.map(id => ({
id, label: LABELS[id].label, groups: [], flow: "antigravity_swarm_journey", workMode: "standard",
expectedRunCount: LABELS[id].runs, minimumExpectedRunCount: LABELS[id].runs, automaticRetryPolicy: "single_attempt",
attemptTimeoutMs: { local: 1_800_000, daytona: 1_800_000 }, turnTimeoutMs: 1_200_000,
expectedTerminalState: { issue: LABELS[id].issue, run: LABELS[id].run },
buildTitle: nonce => `Antigravity swarm ${nonce}`,
buildPrompt: () => "/swarm two helpers: one writes a.txt containing A, one writes b.txt containing B; a verifier checks both",
buildVisibleMarker: nonce => nonce, buildMatchers: () => [],
}));
return { id: ANTIGRAVITY_SWARM_SUITE, label: "Google Antigravity native swarm", groups: [], manualOnly: true,
description: "Trusted /swarm from the task composer runs Antigravity's native swarm on the pinned CLI in the task folder: completion, Stop, process loss and Retry, follow-up, and the flag-off refusal.",
profiles: [profile], environments: environments.filter(environment => environment.id === "local"), expectedMatrixSize: ANTIGRAVITY_SWARM_CASES.length,
definitionMetadata: { version: 1, digest: hash.digest("hex"), scheduling: "explicit-only", route: "antigravity-cli",
authentication: "existing-antigravity-cli-google-sign-in-on-this-computer", setup: "attached-self-hosted-local-darwin-arm64",
requires: ["instance.experimental.enableAntigravitySwarm", "paperclipai runtime setup antigravity-cli"], recipe: ANTIGRAVITY_SWARM_RECIPE,
executor: "attended-recipe-only", globalQualification: "pending", mcpConnections: [] },
tasks };
}
@@ -0,0 +1,23 @@
import { describe, expect, it } from "vitest";
import { ANTIGRAVITY_SWARM_CASES, ANTIGRAVITY_SWARM_SUITE } from "./antigravity-swarm-cases.js";
import { runnerMatrix, runnerSuites } from "./catalog.js";
import { buildMatrixJobs, parseRunnerSelectors, selectRunnerExecutions } from "./selectors.js";
const select = (...args: string[]) => selectRunnerExecutions(parseRunnerSelectors(args));
describe("Antigravity swarm cells", () => {
it("lists one attended local cell per swarm behaviour, needing the CLI route and a Google sign-in", () => {
const suite = runnerSuites.find(entry => entry.id === ANTIGRAVITY_SWARM_SUITE)!;
expect(suite).toMatchObject({ manualOnly: true, definitionMetadata: expect.objectContaining({ route: "antigravity-cli", authentication: expect.stringMatching(/google-sign-in/) }) });
const cells = runnerMatrix.filter(row => row.suite.id === ANTIGRAVITY_SWARM_SUITE);
expect(cells.map(cell => cell.task.id).sort()).toEqual([...ANTIGRAVITY_SWARM_CASES].sort());
expect(new Set(cells.map(cell => cell.environment.id))).toEqual(new Set(["local"]));
expect(cells.every(cell => cell.task.flow === "antigravity_swarm_journey")).toBe(true);
});
it("is selectable by name but never part of the default run or CI matrix jobs", () => {
expect(select("--list", "--suite", ANTIGRAVITY_SWARM_SUITE)).toHaveLength(ANTIGRAVITY_SWARM_CASES.length);
expect(select("--all").some(execution => execution.suite.id === ANTIGRAVITY_SWARM_SUITE)).toBe(false);
expect(() => buildMatrixJobs(select("--suite", ANTIGRAVITY_SWARM_SUITE))).toThrow("Attended connection journeys");
});
});
+5 -5
View File
@@ -330,9 +330,9 @@ describe("runner E2E catalog", () => {
expect(localIntegrityTasks).toHaveLength(2);
expect(openRouterBreadthTasks).toHaveLength(3);
expect(runnerSuites.map((suite) => suite.expectedMatrixSize)).toEqual([
1, 9, 2, 9, 2, 4, 1, 1, 3, 2, 2, 4, 4, 4, 4, 4, 4, 8, 10, 6, 63, 12, 6, 4, 2, 4, 2, 30, 3, 16, 16, 20, 24, 14, 14, 2, 2, 1, 6, 8, 46, 2, 23, 15, 68, 6, 8, 20, 26, 2, 56, 1, 491, 28, 18, 2, 6, 6, 13, 10, 4, 48, 16, 10, 2, 1, 1, 4, 116, 2, 1, 2,
1, 9, 2, 9, 2, 4, 1, 1, 3, 2, 2, 4, 4, 4, 4, 4, 4, 8, 10, 6, 63, 12, 6, 4, 2, 4, 2, 30, 3, 16, 16, 20, 24, 14, 14, 2, 2, 1, 6, 8, 46, 2, 23, 15, 68, 6, 8, 20, 26, 2, 56, 1, 491, 28, 18, 2, 6, 6, 13, 10, 4, 48, 16, 10, 2, 1, 1, 4, 116, 2, 1, 5, 2,
]);
expect(validateRunnerCatalog()).toHaveLength(1387);
expect(validateRunnerCatalog()).toHaveLength(1392);
const frozenDirectory = new URL("./chat-scenarios/", import.meta.url);
const frozenIds = readdirSync(frozenDirectory).filter(name => name.endsWith(".yaml") && name !== "defaults.yaml")
.flatMap(name => parseDocument(readFileSync(new URL(name, frozenDirectory), "utf8")).toJS().scenarios.map((scenario: { id: string }) => scenario.id));
@@ -343,7 +343,7 @@ describe("runner E2E catalog", () => {
expect(chat.map(cell => legacyScenarioIds[cell.task.id] ?? cell.task.id).sort()).toEqual(frozenIds.sort());
for (const cell of chat) expect(selectRunnerExecutions(parseRunnerSelectors(["--id", cell.id]))).toEqual([cell]);
expect(selectRunnerExecutions(parseRunnerSelectors(["--all"])).some(cell => ["chat-features", "chat-setup-health"].includes(cell.suite.id))).toBe(false);
expect(new Set(runnerMatrix.map((entry) => entry.id)).size).toBe(1387);
expect(new Set(runnerMatrix.map((entry) => entry.id)).size).toBe(1392);
expect(
runnerMatrix.filter((entry) => entry.suite.id === "core-compatibility"),
).toHaveLength(48);
@@ -660,13 +660,13 @@ describe("runner E2E catalog", () => {
it("uses only declared secret references in generated payloads", () => {
expect(
runnerMatrix.filter(entry => !["provider_connection", "github_review_journey", "antigravity_agent_journey"].includes(entry.task.flow)).every((entry) =>
runnerMatrix.filter(entry => !["provider_connection", "github_review_journey", "antigravity_agent_journey", "antigravity_swarm_journey"].includes(entry.task.flow)).every((entry) =>
entry.requiredCredentials.includes(entry.profile.credential),
),
).toBe(true);
expect(
runnerMatrix
.filter((entry) => entry.environment.id === "daytona" && !["provider_connection", "github_review_journey", "antigravity_agent_journey"].includes(entry.task.flow))
.filter((entry) => entry.environment.id === "daytona" && !["provider_connection", "github_review_journey", "antigravity_agent_journey", "antigravity_swarm_journey"].includes(entry.task.flow))
.every((entry) =>
entry.requiredCredentials.includes("DAYTONA_API_KEY"),
),
+4 -2
View File
@@ -29,6 +29,7 @@ import { chatConfirmationTasks } from "./chat-cases.js";
import { buildConnectionSuite } from "./connection-cases.js";
import { buildGitHubReviewJourneySuite } from "./github-review-cases.js";
import { buildAntigravityJourneySuite } from "./antigravity-journey-cases.js";
import { buildAntigravitySwarmSuite } from "./antigravity-swarm-cases.js";
import { hiringTemplateTasks, hiringTemplateProfile, hiringTemplateDefinitionDigest } from "./hiring-template-cases.js";
import { copilotProviderDeathTasks } from "./copilot-active-stop-tasks.js";
import { instructionPersistenceTask } from "./instruction-persistence.js";
@@ -2134,6 +2135,7 @@ export const runnerSuites: readonly RunnerSuiteFixture[] = [
buildConnectionSuite(runnerProfiles, runnerEnvironments),
buildGitHubReviewJourneySuite(runnerProfiles, runnerEnvironments),
buildAntigravityJourneySuite(runnerEnvironments),
buildAntigravitySwarmSuite(runnerEnvironments),
{
id: "repository-skills", label: "Repository skill packages", manualOnly: true,
description: "Live private Poteto import and byte-for-byte delivery to local and Daytona agent runtimes.",
@@ -2218,8 +2220,8 @@ export function buildRunnerMatrix(
]),
],
requiredCredentials: [
...(["provider_connection", "github_review_journey", "antigravity_agent_journey"].includes(task.flow) ? [] : [profile.credential]),
...(!["provider_connection", "github_review_journey", "antigravity_agent_journey"].includes(task.flow) && selectedEnvironment.credential ? [selectedEnvironment.credential] : []),
...(["provider_connection", "github_review_journey", "antigravity_agent_journey", "antigravity_swarm_journey"].includes(task.flow) ? [] : [profile.credential]),
...(!["provider_connection", "github_review_journey", "antigravity_agent_journey", "antigravity_swarm_journey"].includes(task.flow) && selectedEnvironment.credential ? [selectedEnvironment.credential] : []),
...(task.requiredCredentials ?? []),
],
};
+4
View File
@@ -1253,6 +1253,10 @@ async function main() {
preflight: options.antigravityJourneyPreflight, recoverFile: options.antigravityJourneyRecover });
return;
}
if (executions.some(execution => execution.task.flow === "antigravity_swarm_journey")) {
const { ANTIGRAVITY_SWARM_RECIPE } = await import("./antigravity-swarm-cases.js");
throw new Error(`The Antigravity swarm cells are attended; run them with the live recipe in ${ANTIGRAVITY_SWARM_RECIPE}.`);
}
if (options.antigravityJourneyConfig || options.antigravityJourneyPreflight || options.antigravityJourneyRecover) throw new Error("Antigravity journey options require its explicit registered cell.");
if (executions.some(execution => execution.task.flow === "github_review_journey")) {
if (options.connectionConfig) throw new Error("Use --github-review-config for the GitHub journey.");
+1 -1
View File
@@ -248,7 +248,7 @@ export function selectRunnerExecutions(
export function buildMatrixJobs(
executions: readonly MatrixExecution[],
): MatrixJob[] {
if (executions.some(e => ["provider_connection", "github_review_journey", "antigravity_agent_journey"].includes(e.task.flow))) throw new RunnerSelectorError("Attended connection journeys require explicit private setup profiles; they are not admitted to paid CI matrix jobs yet.");
if (executions.some(e => ["provider_connection", "github_review_journey", "antigravity_agent_journey", "antigravity_swarm_journey"].includes(e.task.flow))) throw new RunnerSelectorError("Attended connection journeys require explicit private setup profiles; they are not admitted to paid CI matrix jobs yet.");
return executions
.map((execution) => ({
executionId: execution.id,
+1
View File
@@ -30,6 +30,7 @@ export type RunnerTaskFlow =
| "provider_connection"
| "github_review_journey"
| "antigravity_agent_journey"
| "antigravity_swarm_journey"
| "plan_task_guidance"
| "blocker_guidance"
| "public_mcp"