Skip to content

Run isolated resumable Antigravity native goals #2009

Closed as not planned
Closed as not planned

Description

@integry

Context

Part of #2004 and #2002. Depends on #2007. The coding agent must own goal planning and continuation; ProPR only hosts one native Antigravity session.

The current Dockerfile.agent pin is Antigravity CLI 1.1.13. Its official CLI command reference does not currently document /goal, although the binary contains internal goal-stop-hook code. Treat native goal support as an unproven provider capability, not an assumption.

Capability gate

  1. Run an authenticated pinned-image smoke that enumerates slash commands and invokes /goal <verifiable no-op condition> in print/stream mode.
  2. If 1.1.13 does not expose a working native goal, update Dockerfile.agent through the existing pinned-version/supply-chain process to the first vendor release that officially supports it, then regenerate capability metadata and rerun the smoke.
  3. If no supported Antigravity release exposes native goal continuation, report Antigravity as goalCapable: false with an actionable reason. Do not recreate /goal with a ProPR evaluator, repeated prompts, planner, or scheduler.

The goal remains to ship Antigravity support; the capability gate determines the honest implementation pin rather than silently substituting different semantics.

Runtime contract after the gate passes

  • Use the existing unified agent container, credentials, project/worktree, and safe config handling.
  • Start the vendor's native goal command with the objective using argument arrays/stdin, never shell interpolation.
  • Use documented headless --output-format stream-json events and return the conversation ID plus required resume metadata to the Sub-epic: Durable control surface for agent-native goals #2003 SQL controller before recoverability is reported. The adapter owns no database.
  • Resume the exact conversation using --conversation <id> or the vendor-documented equivalent; never replay the objective as a second goal.
  • Emit bounded terminal, assistant/tool, native plan/todo, usage, checkpoint/status, and completion events into the shared sink.
  • Deliver one SQL-claimed FIFO correction to the same conversation and acknowledge only after provider acceptance.
  • Pause native continuation at a documented recoverable boundary; resume the same goal; cancel separately.
  • Apply supported model/reasoning changes at a documented boundary and capability-gate unsupported live changes.
  • Preserve the exact worktree/branch and isolated writable state; reject cross-goal reuse.

Acceptance

  • A real authenticated pinned-image smoke proves native goal activation, observable continuation, conversation identity, and status/output behavior.
  • Forced process/container replacement resumes the same active goal without a duplicate start.
  • FIFO steering, pause/resume, model boundary, cancel, completion, missing/corrupt state, and cross-goal isolation are tested.
  • Existing Antigravity one-shot and credential behavior remains green.
  • No ProPR goal planner, evaluator loop, issue hierarchy, or scheduler is introduced.

Activity

  1. added
    enhancement
    base-2004-epic-goal-agent-runtimes
    and removed on Aug 31, 2026
  2. integry commented on Aug 31, 2026

    @integry
    OwnerAuthor

    Provider preflight refinement for implementation:

    • The repository-pinned Antigravity CLI is agy 1.1.13. It creates its conversation UUID only during the first real -p turn and has no documented multi-turn stdin/active pause channel. Implement Introduce a thin resumable native-goal session and container contract #2007's lazy first_turn ID binding plus after_turn pause/steering/model boundaries. Do not invent an ID or claim active-turn continuation.
    • Always resume with explicit --conversation <persisted UUID>; never --continue, which selects mutable “most recent” state. A missing/corrupt UUID currently warns and silently creates a different conversation, so validate state and observed conversation_id before accepting authoritative events; missing state must block with zero new provider work.
    • Verified minimal resumable state is the per-conversation SQLite .db/-wal/-shm trio under antigravity-cli/conversations/<uuid> plus brain/<uuid>/**. Exclude global summaries/cache/history/presence/logs. Quiesce/checkpoint DB+WAL atomically and store a bounded manifest/checksum/schema/CLI version; reject symlinks/devices/hardlinks/path escapes and test SIGKILL/corruption.
    • Use bounded incremental UTF-8 NDJSON parsing for actual 1.1.13 init/step_update/result variants. Real API-key init can omit init.model; surface result.error, correlate every event to the exact UUID, and deduplicate by a durable ordinal/content identity rather than step_index alone. Do not fabricate provider todos.
    • Model/reasoning applies only on the next invocation and must match an explicit supported mapping; do not rely on fallback label stripping or silent CLI fallback.
    • Add a goal-specific entrypoint with writable isolated state and credentials/settings outside retained snapshots. Do not reuse the one-shot RW source-sync or argv-valued secret injection.
    • Add authenticated pinned 1.1.13 resume smoke, lazy-ID crash windows, no-fork missing UUID, DB/WAL recovery, cross-goal mount attacks, chunk/malformed/oversize/mismatched-UUID protocol tests, FIFO next-turn acknowledgement, pause-after-turn, and existing one-shot regressions.
  3. integry commented on Aug 31, 2026

    @integry
    OwnerAuthor

    Owner foundation-conformance addendum

    • Implement the merged GoalSessionAdapter directly and export an injectable factory plus literal capability descriptor. The goal-session supervisor and injected container/recovery ports remain authoritative; do not couple this adapter to routes, Redis, queues, or a provider database.
    • Honor exact durable identities for turns (goal/session/controllerEpoch/turn/execution/attempt), steering (messageId), model changes (modelChangeId + monotonic application generation), cancellation (cancellationId), and reconciliation (controllerEpoch/operationToken/execution/attempt). Same-ID retries are effect-idempotent; stale generations cannot resume, emit, acknowledge, or overwrite. Reconcile ambiguous provider success instead of blindly replaying.
    • Persist only a versioned minimal credential-free recovery schema. Normalize explicit safe event fields with stable provider occurrences/cursors, one terminal completion, and retry-safe goal-attributable usage watermarks. Never attribute account-wide usage.
    • Keep auth/config read-only and separate from goal-scoped writable state; no secrets, host paths, argv, arbitrary envelopes, or cross-goal IDs in state/events/errors/logs/labels/recovery metadata. Use the hardened goal container supervisor and exact goal/session/execution/attempt/worktree identity.
    • Probe versions/capabilities before side effects and return typed incompatibility/blocked failures instead of fallback. Preserve one-shot execution. Contract tests inject crashes before/after provider acceptance, checkpoint, ack, model application, cancellation, and terminal output; retry identical IDs, reverse old/new completions, reopen fresh, and prove isolation/no post-terminal output.

    Antigravity protocol decisions

    • Pin Antigravity 1.1.13 and declare nativeSessionId: 'first_turn', firstTurnIdCrashPolicy: 'fail' unless deterministic pre-bind open is proven, steering: 'next_turn', pause: 'after_turn', and modelChange: 'next_turn'.
    • Bind providerSessionId only to the exact conversation UUID from the correlated stream init envelope; transient process IDs are not interchangeable. Checkpoint the first trusted UUID before accepting later output. A kill before checkpoint fails once with no replacement conversation; cancellation targets the exact pending container/attempt.
    • Resume only with the exact conversation-ID option. Bare --continue is forbidden unless the goal-scoped store provably contains exactly that conversation and returned identity is reverified. Limit recovery metadata to UUID, pinned protocol/CLI version, goal-relative state key, cursor, model, and usage watermark.
    • Persist only allowlisted conversation files in an isolated writable goal home; seed minimum auth/config read-only and prove goals cannot list/resume one another.
    • Incorporate FIFO corrective messages into discrete invocations with stable markers; acknowledge only after the exact conversation accepts them and reconcile ambiguous acceptance from transcript. Pause waits after the active invocation and prevents the next; it never kills the active invocation. Apply model/reasoning next turn and require effective-model evidence.
    • Normalize init, step_update, and result with a durable cursor; do not double-count cumulative usage or fabricate todo events from prose. Pinned-image tests cover kill before/after conversation ID, conflicting IDs, transcript replay/corruption, duplicate message retry, pause, reverse model intents, stale output, and exact-conversation fresh-home resume.
  4. integry commented on Aug 31, 2026

    @integry
    OwnerAuthor

    Provider launch gate addendum — do not start until corrected #2007/#2017 is merged into 2004-epic-goal-agent-runtimes. Use Codex GPT-5.6 Sol only and target #2004. Rebase on the frozen shared supervisor/security/recovery contract; this leaf must not fork or duplicate it.

    Antigravity-specific acceptance:

    • Pin and verify agy 1.1.13 protocol/CLI behavior. Capability is first_turn identity with fail-closed pre-ID crash; never fabricate a conversation ID.
    • Invoke/resume with the exact --conversation identity. Isolate per-goal writable provider state while mounting only explicitly approved read-only credentials.
    • Persist a versioned credential-free recovery codec for conversation identity, DB/WAL/SHM generation, brain manifest/checksums, protocol version, stream cursor, and usage watermarks. Reject missing/corrupt/version-mismatched/cross-goal state.
    • Consume only the shared supervised ordered/backpressured output observer. Parse incremental/chunk-split JSON safely into closed events; unknown/oversize/hostile records fail or redact without raw secret/path leakage. Never tail host logs or bypass the supervisor.
    • Steering, pause, and model changes apply at documented next-turn/after-turn boundaries. Settle model history only from the actual next invocation evidence tied to exact execution/attempt/occurrence.
    • Usage carries stable occurrence IDs and explicit delta/cumulative handling so retry/replay is exactly accounted.
    • Every external effect atomically enforces the shared provider barrier and idempotency identity.
    • Add fresh-container resume, response-loss, kill-window, corruption, concurrent-intent, cancellation, credential-isolation, parser/backpressure, and cross-goal adversarial tests; preserve existing one-shot Antigravity behavior.
  5. changed the title [-]Resume, pause, and steer isolated Antigravity goal conversations[/-] [+]Run isolated resumable Antigravity native goals[/+] on Sep 2, 2026
  6. integry commented on Sep 2, 2026

    @integry
    OwnerAuthor

    Superseded by #2071 and the simplified task-backed native /goal architecture. The unreleased branch is retained only for reference.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    base-2004-epic-goal-agent-runtimesenhancementllm-codex-gpt56-solpropr-planned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions