Skip to content

feat(autonomy): first flight - one real iteration against live Docker (P2) - #303

Merged
IanFrelinger merged 2 commits into
masterfrom
feat/autonomy-first-flight
Aug 14, 2026
Merged

feat(autonomy): first flight - one real iteration against live Docker (P2)#303
IanFrelinger merged 2 commits into
masterfrom
feat/autonomy-first-flight

Conversation

@IanFrelinger

Copy link
Copy Markdown
Owner

Summary

Phase 2 of the post-merge plan: the first flight — one real autonomy iteration, end to end, against a live container engine. This is the acceptance step docs/certification-evidence.md records as outstanding ("the loop has never run against a live container engine or a real proposer's output").

Stacked on #291 (P0 honesty docs + P1 AddNexoAutonomy), because the flight is the first consumer of AddNexoAutonomy.

What flies

spikes/autonomy-first-flight/ — deliberately outside Nexo.sln and every CI gate. Its deliverable is a recorded run in the evidence doc, not a shipped artifact (same contract as the existing spikes/ precedent).

One iteration, composed exactly the way a host would (AddCertificationGate + AddNexoAutonomy, ValidateOnBuild/ValidateScopes):

  1. Hand-authored Triage objective → ObjectiveTierClassifier → Tier 0
  2. Attested sandbox session against the real Docker daemon (image digest, engine version, effective caps recorded onto the certificate — provisioning evidence per the known-limitation docs; the session executes nothing)
  3. The real certification chain: analyzer fence + touch-set leg, witness, mutation gate, determinism, dependency cleanliness
  4. Autonomous Tier-0 swap with lineage key (AutonomousAdmission)
  5. Three post-swap ExecuteAsync invocations clearing the watch window
  6. AutonomyDigest.Render over the collected swap provenance

--dry swaps in the TestKit fake session runner (same wiring, no daemon) and asserts zero leaked sessions.

Design decisions worth reading

  • Sessions are sibling containers. The flight runs inside the devcontainer image with /var/run/docker.sock mounted through, so sessions it starts are siblings on the host daemon. Container-local paths would be meaningless to that daemon — which is why the flight's SandboxSpec carries no mounts. That is also the honest shape: the session's certified role today is provisioning attestation. Mount-path handling gets proven when build/test move in-container (Phase 3), not smuggled in here untested.
  • Only committed state flies.run-first-flight.ps1 mirrors scripts/test-in-container.ps1 (clone from read-only mirror; Smart App Control blocks fresh host DLLs) plus the socket mount and a static docker CLI fetch.
  • The objective→context projection lives in the spike. BackgroundAgents cannot see Infrastructure's context types and Infrastructure cannot see ObjectiveDocument; the host is where they meet, and the spike is the host.

Flight record

Recorded in docs/certification-evidence.md (this PR): dry run and real run, both PASS — outcome AdmittedAndSwapped, real attestation values from the live daemon, certificate inputs including session-attestation and session-environment, digest output.

Testing

  • Dry flight (fake sessions): PASS, zero leaked sessions
  • Real flight (live Docker daemon, alpine:3.20 session): PASS
  • make kernel-coverage-gate — n/a paths (spike + docs only), runs in CI regardless

🤖 Generated with Claude Code

PlzTouchGrassand others added 2 commits August 14, 2026 09:24
…Docker
The acceptance step recorded as outstanding in docs/certification-evidence.md:
the loop has never run against a live container engine. This spike is that
flight, deliberately OUTSIDE Nexo.sln and every CI gate - its output is a run
recorded in the evidence doc, not a shipped artifact.
Program.cs composes AddCertificationGate + AddNexoAutonomy exactly the way a
host would (ValidateOnBuild/ValidateScopes), hand-authors a Triage objective,
projects it to a ProposalIterationContext in the host glue (the one place
BackgroundAgents and Infrastructure types may meet), and runs ONE iteration:
tier classification, attested sandbox session, the real certification chain,
autonomous Tier-0 swap, three post-swap executions clearing the watch window,
and the digest render.
The SandboxSpec carries no mounts, deliberately: sessions are SIBLING
containers on the host daemon (docker.sock pass-through), so container-local
paths would be meaningless - and the session's certified role today is
provisioning attestation only. Mount handling gets proven when build/test
move in-container, not smuggled in here untested.
--dry swaps in the TestKit fake runner (same wiring, no daemon) and asserts
zero leaked sessions. run-first-flight.ps1 mirrors test-in-container.ps1
(Smart App Control blocks fresh host DLLs) plus the docker.sock mount and a
static docker CLI fetch.
The spike includes build/GlobalUsings.DomainBrick.cs directly because
spikes/ has no Directory.Build.props tree to inject it.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…engine
The acceptance step is no longer outstanding. One real iteration flew from
commit 1afac86: Triage objective -> Tier0Autonomous -> attested session on
the live daemon (alpine:3.20 @ sha256:d9e853e8..., engine 29.7.2, effective
caps verified) -> full certification chain ADMIT (signed, escape_rate=0,
all five inputs recorded) -> autonomous Tier-0 swap as generation 1 in
4.4s -> 3/3 post-swap invocations clearing the watch window -> digest.
Zero nexo-session-* containers left on the host daemon afterwards. The
--dry leg (fake runner, same wiring) passed with an explicit
zero-leaked-sessions assertion.
Known limitation 5 is rewritten to what actually remains: the loop has
still never admitted a MODEL-produced candidate - the flight brick was
hand-authored to the gate-teeth shape. Limitation 4 (session attests,
does not contain) is unchanged by the flight and the section says so.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@cursor

cursorBot commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

Bugbot is not enabled for your account, so this pull request was not reviewed.

Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs.

Base automatically changed from feat/autonomy-host-composition to masterAugust 14, 2026 16:04
@IanFrelinger
IanFrelinger merged commit 381f7bd into masterAug 14, 2026
4 checks passed
@IanFrelinger
IanFrelinger deleted the feat/autonomy-first-flight branch August 14, 2026 16:04
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@IanFrelinger@PlzTouchGrass