Skip to content

[audit][ci] Shard anneal-audit across Pass 1, Pass 2, and canaries - #740

Merged
joshlf merged 1 commit into
mainfrom
joshlf/ci-t2-2b-audit-sharding
Dec 6, 2026
Merged

joshlf merged 1 commit into
mainfrom
joshlf/ci-t2-2b-audit-sharding

Conversation

@joshlf

@joshlf joshlf commented Dec 5, 2026 •

Copy link
Copy Markdown
Member

anneal-audit is the sole 38.7m CI critical-path straggler on 4-vCPU ubuntu-24.04 runners because one process compiles and kernel-replays all 379 Pass 1 theory/ modules before running Pass 2 correspondence and ci/check_pass2_canaries.py, even though Pass 2 transitively imports only a small subset of theory/.

Add minimal, fail-closed sharding scopes to anneal-audit and wire them as a 6-shard matrix on the existing anneal-audit check:

  • trusted/audit/src/{repo_audit,lib,cli}.rs:
    • Add AuditScope::{Full, Pass1TheoryShard { index, total }, CorrespondenceOnly} alongside parse_theory_shard_spec, theory_transitive_closure_order, and select_theory_shard_order. Default (Full) behavior and --json schema are unchanged (compiledTheoryModules, totalTheoryModules, and auditScope are emitted only for non-Full sharded scopes).
    • --pass1-theory-shard <index>/<total> (mutually exclusive with --require-correspondence, --correspondence-only, --miri-cache-dir, and --cargo-boundary-only) still runs full Cargo hygiene, full trusted/lean/ and theory/ staging, and full Pass 1 syntactic preflight across every theory/ file, then compiles and kernel-replays all trusted/lean/ modules plus the deterministic transitive closure of theory/ family shard index/total (always seeding Anneal.MirWp and Anneal.MirWp.Canaries whenever verifyMirWpCoreTheorems will fire). Fails closed if total exceeds discovered theory/ families (including an empty theory/ tree).
    • --correspondence-only (mutually exclusive with --pass1-theory-shard and --cargo-boundary-only; implies --require-correspondence) runs full Cargo hygiene, full Pass 1 staging/preflight, full cross-tree module uniqueness across Pass 1, Pass 2, and vendor/lean-miri/, compiles and Pass-1-audits all trusted/lean/ modules plus only the theory/ transitive closure imported by correspondence/ (and Anneal.MirWp / Anneal.MirWp.Canaries), and runs the full sandboxed Pass 2 correspondence-preflight, compilation, and correspondence-audit.
  • tests/testkit/src/assertions.rs and tests/audit/tests/boundary_audit/audit_sharding.rs: Accept optional sharded-scope JSON fields in AuditReport (#[serde(deny_unknown_fields)]) while asserting real AuditScope::Full anneal-audit --json omits them and parses cleanly under AuditReport::from_json_slice, plus positive and negative tests for malformed and conflicting CLI flags, disjoint-complete Pass 1 shard union, unassigned-family preflight sorry rejection, empty-tree and over-sharding rejection, and --correspondence-only missing-dir and unimported Pass 1/Pass 2 module-collision rejection.
  • ci/checks.toml, ci/run_anneal_check.sh, ci/check_pass2_canaries.py, and CI unit tests: Split anneal-audit into matrix = { shard = ["correspondence", "pass1-1/4", "pass1-2/4", "pass1-3/4", "pass1-4/4", "pass2-canaries"] } while keeping anneal-audit the sole check on anneal-audit-lite with caches = ["miri-v1"]. correspondence sorts lexicographically first so ci-core's cache publisher always selects the Pass 2 shard for miri-v1 on a cold miss. Default AUDIT_SHARD=all preserves full single-command local runs (while explicit empty AUDIT_SHARD="" and oversized >18-digit shard numbers fail closed), and ci/check_pass2_canaries.py enforces --lean wiring across both the all and pass2-canaries branches plus anneal-audit.matrix.shard.

Intentional policy relaxation (integrity/importability only, not soundness): Sharded CI (pass1-1/4..4/4 plus correspondence) no longer imports all theory/ modules into a single Lean environment simultaneously, so cross-family constant-name collisions across disjoint theory/ families (families sharing neither Trusted.*, Anneal.MirWp*, nor a common ancestor) are no longer rejected pre-merge in CI and are only jointly imported under local AUDIT_SHARD=all (AuditScope::Full). Impact is strictly integrity/importability rather than soundness: any collision fails closed if jointly imported, and verification claims remain Trusted.*-only. Full Cargo hygiene, full source staging, full syntactic preflight, module-name uniqueness across Pass 1, Pass 2, and vendor/lean-miri/, kernel replay gates, and bwrap sandboxing remain unchanged.

Authored by an AI agent acting on joshlf's behalf.

@joshlf

joshlf commented Dec 5, 2026

Copy link
Copy Markdown
Member Author

Verification receipt

  • Target base (main): c469ae0d9d724d6148fe8b53ae077d2e4e324a83
  • Merge base: cf1cd6e064db3ee9037c393c3be01a17510632f1
  • Head: b7627f25c2f327a6c71d5bcfdad2720451ca98f6
  • Tree: d892672f61f0f1e12b60162634e065ea0cf0391a

Checks run ([real measurement])

  • cargo clippy --locked --offline -p anneal-audit --all-targets -- -D warnings: PASS (0 warnings) on exact HEAD b7627f25c2f327a6.
  • cargo test --locked --offline -p anneal-audit --lib: PASS (29 passed; 0 failed) on exact HEAD b7627f25c2f327a6, including parse_theory_shard_spec_and_selection_preserve_complete_closure (complete union, topological closure, empty-tree fail-closed, and verifyMirWpCoreTheorems auto-seeding under force_mir_wp = false).
  • cargo test --locked --offline -p anneal-audit-tests --test cli_environment: PASS (4 passed; 0 failed) on exact HEAD b7627f25c2f327a6.
  • cargo test --locked --offline -p anneal-audit-tests --test boundary_audit audit_sharding -- --nocapture: PASS (2 passed; 0 failed in 319.5s) on exact HEAD b7627f25c2f327a6, covering malformed/conflicting CLI flags (exit 2), disjoint-complete Pass 1 shard union, over-sharding and empty-tree rejection (exit 1), Pass 1 + --require-correspondence conflict (exit 1), unassigned-family preflight sorry rejection (exit 1), and --correspondence-only missing-directory and unimported Pass 1/Pass 2 module-collision rejection (exit 1).
  • Live repository --pass1-theory-shard 1/4 (cargo run --locked --offline -p anneal-audit -- --pass1-theory-shard 1/4): PASS in 595s (33 Trusted modules, 136/379 Theory modules, 6791 Trusted kernel declarations, 31202 total replayed declarations, axioms=["propext","Classical.choice","Quot.sound"]) on 2503046b817bd7dc (identical pass1-1/4 closure on b7627f25c2f327a6).
  • Live repository --correspondence-only --require-correspondence (cargo run --locked --offline -p anneal-audit -- --correspondence-only --require-correspondence, cold without --miri-cache-dir): PASS in 1171s (39 Trusted modules, 9/379 Theory modules, 160 verified vendored Miri closure modules, 9456 correspondence replayed declarations, 30484 reachable declarations, axioms=["propext","Classical.choice","Quot.sound"]) on 2503046b817bd7dc (identical correspondence closure on b7627f25c2f327a6).
  • python3 -I -B ./ci/check_pass2_canaries.py --repo-root . --check-static: PASS (verified 15 Pass 2 canary specs, 6 witness theorems, TCB isolation, and sharded CI wiring).
  • python3 -B -m unittest ci.test_ci_workflow ci.test_run_anneal_check ci.test_workflow_yaml ci.test_check_pass2_canaries.Pass2CanariesStaticTests -q: PASS (101 tests OK).
  • ./ci/check_todo.sh, ./ci/scripts/check_shell_and_hooks.sh, ./ci/check_actions.sh, ./ci/check_job_dependencies.sh, python3 -I -B ./ci/run_fast_checks.py (3/3 PASS), python3 -I -B ci/check_pr_hygiene.py: PASS.
  • Not run locally: full GitHub Actions anneal-audit 6-shard matrix with warm miri-v1 cache (will execute directly on CI runners once opened).

Human review surface

  • ci/check_pass2_canaries.py
  • ci/checks.toml
  • ci/ci_workflow_tests/ci_core_workflows.py
  • ci/run_anneal_check.sh
  • ci/test_check_pass2_canaries.py
  • ci/test_run_anneal_check.py
  • trusted/audit/src/cli.rs
  • trusted/audit/src/lib.rs
  • trusted/audit/src/repo_audit.rs

Intentional policy relaxations: none.

Authored by an AI agent acting on joshlf's behalf.

@joshlf joshlf left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Authored by an AI agent acting on joshlf's behalf.

Gate 2 Independent Cross-Family Review — FINDINGS (tier2a_core_tcb, Round 1)

  • Identity: multi:c469ae0d9d724d6148fe8b53ae077d2e4e324a83:b7627f25c2f327a6c71d5bcfdad2720451ca98f6 (base=c469ae0d9d72, head=b7627f25c2f3, tree=d892672f61f0)
  • Separation: author_family=agent vs. reviewer_family=multi
  • Coverage: 11 inspected, 0 inapplicable, 0 blocked (of 11 changed file(s))
Seat Family Role Status Verdict Findings Latency
seat1 claude-frontier-thinking tcb_and_api_critic completed findings 1 586s
seat2 gemini-frontier-thinking tcb_and_spec_critic completed findings 2 1218s
seat3 gemini-executable-falsifier sandboxed_probe_runner completed clean 0 936s

Deduplicated Findings

ID Sev Consensus Verification Location Summary
G2-R1-01 P2 3 (seat1, seat2, seat3) static_verified trusted/audit/src/repo_audit.rs:251 The sharded CI audit no longer loads all theory/ modules into one Lean environment, so cross-family constant-name collisions are no longer rejected before merge, yet the commit body says nothing is relaxed.
G2-R1-02 P2 1 (seat2) static_verified trusted/audit/src/repo_audit.rs:1230 Unconditionally adding compiledTheoryModules, totalTheoryModules, and auditScope to anneal-audit --json breaks anneal_testkit::AuditReport strict deserialization and Workspace::run_audit.

G2-R1-01 [P2] (trusted/audit/src/repo_audit.rs:251, Pass 2 §3 (trusted/audit), static_verified): The sharded CI audit no longer loads all theory/ modules into one Lean environment, so cross-family constant-name collisions are no longer rejected before merge, yet the commit body says nothing is relaxed.

  • Invariant: AGENTS.md Code Review Rules: commit bodies must explain any rule relaxation; any omission or mischaracterization blocks merge or ready-for-review.
  • Evidence: Before: ci/run_anneal_check.sh audit ran one full anneal-audit whose Pass 1 audit request listed every theory/ module, so loading them together rejected duplicate constant names across modules. After: ci/checks.toml line 733 replaces it with correspondence, pass1-1/4..4/4, and pass2-canaries shards. Each shard's audit list (repo_audit.rs lines 1096-1214) holds only the import closure of its assigned families plus Anneal.MirWp. The doc note at repo_audit.rs lines 251-255 admits cross-family collisions are 'only jointly imported under AuditScope::Full', and no CI job runs Full now (AUDIT_SHARD=all is local-only). The commit body says 'No trust-boundary checks, preflight allowlists, kernel replay gates, or sandbox requirements are relaxed.' Impact is integrity and importability, not soundness: collisions fail closed and claims are Trusted.*-only. Fix: disclose in the commit body and Human review surface, or restore a cheap all-theory constant-name uniqueness check somewhere in CI.

G2-R1-02 [P2] (trusted/audit/src/repo_audit.rs:1230, Pass 2 §3 (trusted/audit), static_verified): Unconditionally adding compiledTheoryModules, totalTheoryModules, and auditScope to anneal-audit --json breaks anneal_testkit::AuditReport strict deserialization and Workspace::run_audit.

  • Invariant: anneal-audit --json output must remain compatible with the strict #[serde(deny_unknown_fields)] schema in tests/testkit/src/assertions.rs::AuditReport (and the commit claims default AuditScope::Full behavior is unchanged).
  • Evidence: trusted/audit/src/repo_audit.rs:1230-1246 unconditionally inserts compiledTheoryModules, totalTheoryModules, and auditScope into the JSON report object for all AuditScope variants including AuditScope::Full. tests/testkit/src/assertions.rs:216-269 defines pub struct AuditReport with #[serde(deny_unknown_fields)] without those three fields, and tests/testkit/src/workspace.rs:414-437 (Workspace::run_audit) parses real anneal-audit --json stdout through AuditReport::from_json_slice, which will now unconditionally fail with unknown field 'compiledTheoryModules'. Existing tests missed this because tests/testkit/src/assertions.rs:530-545 tests only a synthetic JSON literal and tests/cargo-anneal/tests/installed_smoke.rs:599 parses into untyped serde_json::Value.

Non-blocking advisories (P3, not Gate 2 findings)

These notes do not block merge and do not require another Gate 2 round.

  • G2-R1-A01 [P3] (ci/check_pass2_canaries.py:1215): No generic static guard requires the pass1-i/T shards to form a complete set (all of 1..T present) or the correspondence shard to stay in the matrix; only the exact-list assertion in ci/ci_workflow_tests/ci_core_workflows.py catches dropping one.
  • G2-R1-A02 [P3] (ci/check_pass2_canaries.py:1319): _check_ci_wiring uses a flat elif/else/fi lookahead regex when slicing case branches in ci/run_anneal_check.sh.
  • G2-R1-A03 [P3] (ci/checks.toml:733): The claim that ci-core's winning_cache_updaters picks the lexicographically first shard to publish miri-v1 can't be verified from this repo (ci-core is external, at pinned SHAs); the unit test only checks min(shards)=='correspondence'.
  • G2-R1-A04 [P3] (ci/run_anneal_check.sh:428): Bash arithmetic comparison (( idx > total )) wraps 64-bit signed values on oversized shard specs such as pass1-18446744073709551617/2 before Rust parse_theory_shard_spec rejects usize overflow.
  • G2-R1-A05 [P3] (ci/run_anneal_check.sh:684): The pass2-canaries shard now compiles untrusted correspondence/ and theory/ dependencies (Anneal.MirCorrespondence.*, Anneal.MirWp) inside check_pass2_canaries.py's bwrap --unshare-all jail without anneal-audit preflight having run first in the same job; before, canaries only ran after anneal-audit passed.
  • G2-R1-A06 [P3] (tests/audit/tests/boundary_audit/audit_sharding.rs:15): Synthetic integration tests verify CLI rejection and Pass1TheoryShard guards but lack a positive end-to-end AuditScope::CorrespondenceOnly compilation and audit test.
  • G2-R1-A07 [P3] (tests/audit/tests/boundary_audit/audit_sharding.rs:44): Conflicting CLI flag test checks exit status 2 without asserting clap's conflict diagnostic on stderr.
  • G2-R1-A08 [P3] (tests/audit/tests/boundary_audit/audit_sharding.rs:120): No Rust test exercises the success path of AuditScope::CorrespondenceOnly (narrowed theory set through correspondence-preflight, compile, and correspondence-audit); only the CI correspondence shard covers it.
  • G2-R1-A09 [P3] (trusted/audit/src/repo_audit.rs:395): Over-sharding error message reports the requested shard as empty even when index <= families.len() < total.

Executed Sandbox Probes

  • seat3 repo_wide_hygiene_and_diff_unicode_check: outcome=passed (rc=0)
  • seat3 theory_shard_partition_completeness: outcome=passed (rc=0)
  • seat3 root_manifest_sha256_strict: outcome=passed (rc=0)
  • seat3 test_run_anneal_check_unittest: outcome=passed_with_skips (rc=0)
  • seat3 test_ci_workflow_unittest: outcome=passed (rc=0)
  • seat3 test_check_minirust_pin_unittest: outcome=passed (rc=0)
  • seat3 test_check_experimental_isolation_unittest: outcome=passed (rc=0)
  • seat3 test_check_pass2_canaries_wiring_and_static_subsets: outcome=partial_timeout_with_lean_skips (rc=0)
  • seat3 test_check_job_dependencies_unittest: outcome=errored_missing_yq (rc=1)
  • seat3 test_check_pr_hygiene_unittest: outcome=timeout_incomplete (rc=124)
  • seat3 ci_python_and_shell_lints: outcome=passed_except_rg_missing (rc=0)
  • seat3 bash_parse_audit_shard_spec_and_fail_closed_dispatch: outcome=passed_with_p3_note (rc=0)

Comment thread trusted/audit/src/repo_audit.rs Resolved
Comment thread trusted/audit/src/repo_audit.rs Resolved
`anneal-audit` is the sole 38.7m CI critical-path straggler on 4-vCPU
`ubuntu-24.04` runners because one process compiles and kernel-replays
all 379 Pass 1 `theory/` modules before running Pass 2 correspondence
and `ci/check_pass2_canaries.py`, even though Pass 2 transitively
imports only a small subset of `theory/`.

Add minimal, fail-closed sharding scopes to `anneal-audit` and wire
them as a 6-shard matrix on the existing `anneal-audit` check:

- `trusted/audit/src/{repo_audit,lib,cli}.rs`:
  - Add `AuditScope::{Full, Pass1TheoryShard { index, total },
    CorrespondenceOnly}` alongside `parse_theory_shard_spec`,
    `theory_transitive_closure_order`, and `select_theory_shard_order`.
    Default (`Full`) behavior and `--json` schema are unchanged
    (`compiledTheoryModules`, `totalTheoryModules`, and `auditScope`
    are emitted only for non-`Full` sharded scopes).
  - `--pass1-theory-shard <index>/<total>` (mutually exclusive with
    `--require-correspondence`, `--correspondence-only`,
    `--miri-cache-dir`, and `--cargo-boundary-only`) still runs full
    Cargo hygiene, full `trusted/lean/` and `theory/` staging, and full
    Pass 1 syntactic preflight across every `theory/` file, then
    compiles and kernel-replays all `trusted/lean/` modules plus the
    deterministic transitive closure of `theory/` family shard
    `index/total` (always seeding `Anneal.MirWp` and
    `Anneal.MirWp.Canaries` whenever `verifyMirWpCoreTheorems` will
    fire). Fails closed if `total` exceeds discovered `theory/`
    families (including an empty `theory/` tree).
  - `--correspondence-only` (mutually exclusive with
    `--pass1-theory-shard` and `--cargo-boundary-only`; implies
    `--require-correspondence`) runs full Cargo hygiene, full Pass 1
    staging/preflight, full cross-tree module uniqueness across Pass 1,
    Pass 2, and `vendor/lean-miri/`, compiles and Pass-1-audits all
    `trusted/lean/` modules plus only the `theory/` transitive closure
    imported by `correspondence/` (and `Anneal.MirWp` /
    `Anneal.MirWp.Canaries`), and runs the full sandboxed Pass 2
    `correspondence-preflight`, compilation, and `correspondence-audit`.
- `tests/testkit/src/assertions.rs` and
  `tests/audit/tests/boundary_audit/audit_sharding.rs`: Accept optional
  sharded-scope JSON fields in `AuditReport`
  (`#[serde(deny_unknown_fields)]`) while asserting real
  `AuditScope::Full` `anneal-audit --json` omits them and parses
  cleanly under `AuditReport::from_json_slice`, plus positive and
  negative tests for malformed and conflicting CLI flags,
  disjoint-complete Pass 1 shard union, unassigned-family preflight
  `sorry` rejection, empty-tree and over-sharding rejection, and
  `--correspondence-only` missing-dir and unimported Pass 1/Pass 2
  module-collision rejection.
- `ci/checks.toml`, `ci/run_anneal_check.sh`,
  `ci/check_pass2_canaries.py`, and CI unit tests: Split `anneal-audit`
  into `matrix = { shard = ["correspondence", "pass1-1/4", "pass1-2/4",
  "pass1-3/4", "pass1-4/4", "pass2-canaries"] }` while keeping
  `anneal-audit` the sole check on `anneal-audit-lite` with
  `caches = ["miri-v1"]`. `correspondence` sorts lexicographically
  first so `ci-core`'s cache publisher always selects the Pass 2 shard
  for `miri-v1` on a cold miss. Default `AUDIT_SHARD=all` preserves
  full single-command local runs (while explicit empty `AUDIT_SHARD=""`
  and oversized >18-digit shard numbers fail closed), and
  `ci/check_pass2_canaries.py` enforces `--lean` wiring across both the
  `all` and `pass2-canaries` branches plus `anneal-audit.matrix.shard`.

Intentional policy relaxation (integrity/importability only, not
soundness): Sharded CI (`pass1-1/4..4/4` plus `correspondence`) no
longer imports all `theory/` modules into a single Lean environment
simultaneously, so cross-family constant-name collisions across
disjoint `theory/` families (families sharing neither `Trusted.*`,
`Anneal.MirWp*`, nor a common ancestor) are no longer rejected
pre-merge in CI and are only jointly imported under local
`AUDIT_SHARD=all` (`AuditScope::Full`). Impact is strictly
integrity/importability rather than soundness: any collision fails
closed if jointly imported, and verification claims remain
`Trusted.*`-only. Full Cargo hygiene, full source staging, full
syntactic preflight, module-name uniqueness across Pass 1, Pass 2, and
`vendor/lean-miri/`, kernel replay gates, and `bwrap` sandboxing remain
unchanged.

Agent-authored-by: AI agent acting on joshlf's behalf
@joshlf
joshlf force-pushed the joshlf/ci-t2-2b-audit-sharding branch from b7627f2 to 7ed18f0 Compare December 5, 2026 23:30
@joshlf

joshlf commented Dec 5, 2026

Copy link
Copy Markdown
Member Author

Verification receipt

  • Target base (main): 4ad81da4274cfa6a285a2e252c49d772bfba9c10
  • Merge base: 4ad81da4274cfa6a285a2e252c49d772bfba9c10
  • Head: 7ed18f0bfe035e1f7a0756bf2a21746f43ced9c4
  • Tree: 29f5af0ede60ee07c2737c1bf5a8e463857d1269

Checks run ([real measurement])

  • cargo clippy --locked --offline -p anneal-audit --all-targets -- -D warnings: PASS (0 warnings) on exact HEAD 7ed18f0bfe035e1f.
  • cargo clippy --locked --offline -p anneal-testkit --lib -- -D warnings: PASS (0 warnings) on exact HEAD 7ed18f0bfe035e1f.
  • cargo test --locked --offline -p anneal-testkit: PASS (96 passed; 0 failed) on exact HEAD 7ed18f0bfe035e1f, including strict AuditReport deserialization for default full reports (omitting sharding fields), sharded reports, and unknown-field rejection.
  • cargo test --locked --offline -p anneal-audit --lib: PASS (29 passed; 0 failed) on exact HEAD 7ed18f0bfe035e1f, including parse_theory_shard_spec_and_selection_preserve_complete_closure.
  • cargo test --locked --offline -p anneal-audit-tests --test cli_environment: PASS (4 passed; 0 failed) on exact HEAD 7ed18f0bfe035e1f.
  • cargo test --locked --offline -p anneal-audit-tests --test boundary_audit audit_sharding -- --nocapture: PASS (3 passed; 0 failed in 129.25s) on exact HEAD 7ed18f0bfe035e1f, including cli_full_audit_json_matches_testkit_audit_report (real anneal-audit --json under AuditScope::Full omits sharding fields and parses cleanly via anneal_testkit::AuditReport::from_json_slice), clap conflict diagnostics (exit 2), disjoint-complete Pass 1 shard union, over-sharding and empty-tree rejection (exit 1), Pass 1 + --require-correspondence conflict (exit 1), unassigned-family preflight sorry rejection (exit 1), and --correspondence-only missing-directory and unimported Pass 1/Pass 2 module-collision rejection (exit 1).
  • python3 -I -B ./ci/check_pass2_canaries.py --repo-root . --check-static: PASS (15 Pass 2 canary specs, 6 witness theorems, TCB isolation, and sharded CI wiring).
  • python3 -B -m unittest ci.test_ci_workflow ci.test_run_anneal_check ci.test_workflow_yaml ci.test_check_pass2_canaries.Pass2CanariesStaticTests -q: PASS (105 tests OK, including 18-digit shard overflow rejection in parse_audit_shard_spec).
  • ./ci/check_todo.sh, ./ci/scripts/check_shell_and_hooks.sh, ./ci/check_actions.sh, ./ci/check_job_dependencies.sh, python3 -I -B ./ci/run_fast_checks.py (3/3 PASS), python3 -I -B ci/check_pr_hygiene.py --base origin/main: PASS.
  • Prior live repository measurements (2503046b817bd7dc, identical Pass 1 and Pass 2 closures): --pass1-theory-shard 1/4 PASS in 595s (33 Trusted, 136/379 Theory, 31202 replayed decls); --correspondence-only --require-correspondence (cold without --miri-cache-dir) PASS in 1171s (39 Trusted, 9/379 Theory, 160 Miri closure modules, 9456 correspondence replayed decls).
  • Not run locally: full GitHub Actions anneal-audit 6-shard matrix with warm miri-v1 cache (runs directly on CI runners for this PR).

Human review surface

  • ci/check_pass2_canaries.py
  • ci/checks.toml
  • ci/ci_workflow_tests/ci_core_workflows.py
  • ci/run_anneal_check.sh
  • ci/test_check_pass2_canaries.py
  • ci/test_run_anneal_check.py
  • trusted/audit/src/cli.rs
  • trusted/audit/src/lib.rs
  • trusted/audit/src/repo_audit.rs

Intentional policy relaxations

  • No single-environment joint import of all theory/ modules in sharded CI (trusted/audit/src/repo_audit.rs, ci/checks.toml, ci/run_anneal_check.sh): Sharded CI (pass1-1/4..4/4 + correspondence) no longer imports every theory/ module into a single Lean environment simultaneously. Consequently, cross-family constant-name collisions across disjoint theory/ families (families sharing neither Trusted.*, Anneal.MirWp*, nor a common ancestor) are no longer rejected pre-merge in CI and are only jointly imported under local AUDIT_SHARD=all (AuditScope::Full). Impact is strictly integrity/importability rather than soundness: any collision fails closed if ever jointly imported, and verification claims remain Trusted.*-only. Full Cargo hygiene, full source staging, full Pass 1 syntactic preflight, cross-tree module-name uniqueness across Pass 1/Pass 2/vendor/lean-miri/, kernel replay gates, and bwrap sandboxing remain unchanged.

Authored by an AI agent acting on joshlf's behalf.

@joshlf joshlf left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Authored by an AI agent acting on joshlf's behalf.

Gate 2 Independent Cross-Family Review — CLEAN (tier2a_core_tcb, Round 2)

  • Identity: one:172aadcb0974480f470bb862329ce215a6b6235e:29f5af0ede60ee07c2737c1bf5a8e463857d1269:dacf27f3b881f2dfb721625e25d00fc2e9f139dab76e0db1fce585faafba8949 (base=4ad81da4274c, head=7ed18f0bfe03, tree=29f5af0ede60)
  • Separation: author_family=agent vs. reviewer_family=multi
  • Coverage: 12 inspected, 0 inapplicable, 0 blocked (of 12 changed file(s))
  • Review mode: delta_escalated relative to the prior Gate 2 review at head b7627f25c2f327a6c71d5bcfdad2720451ca98f6 (escalated to the full panel: range-diff alters 39% of the PR's diff lines (> 30%))
Seat Family Role Status Verdict Findings Latency
seat1 claude-frontier-thinking tcb_and_api_critic completed clean 0 542s
seat2 gemini-frontier-thinking tcb_and_spec_critic completed clean 0 886s
seat3 gemini-executable-falsifier sandboxed_probe_runner completed clean 0 791s

No unresolved P0-P2 findings raised across completed seats.

Non-blocking advisories (P3, not Gate 2 findings)

These notes do not block merge and do not require another Gate 2 round.

  • G2-R2-A01 [P3] (ci/run_anneal_check.sh:732): The audit) AUDIT_RUN_KIND if/elif dispatch has no terminal else that fails closed; currently unreachable because parse_audit_shard_spec validates the kind, but a future parser edit could silently run nothing.
  • G2-R2-A02 [P3] (ci/check_pass2_canaries.py:1217): The static CI wiring guard enforces only pass2-canaries membership and AUDIT_SHARD interpolation; completeness of the pass1-i/N set and presence of the correspondence shard rely solely on the exact-list assertion in ci/ci_workflow_tests/ci_core_workflows.py.
  • G2-R2-A03 [P3] (ci/checks.toml:733): Documentation in docs/trust-model.md and docs/contributing/testing-architecture.md does not yet reflect the 6-shard anneal-audit CI matrix and its cross-family constant-collision scope boundary.
  • G2-R2-A04 [P3] (docs/trust-model.md:765): The governing trust-model doc's CI description (section 2, Pass 1 kernel replay) is not updated to mention the sharded CI scopes or the disclosed no-joint-import relaxation; the relaxation is recorded only in the commit body, Review Receipt, and an AuditScope doc comment.

Executed Sandbox Probes

  • seat3 repo_hygiene_and_theory_shard_simulation: outcome=passed
  • seat3 bwrap_root_manifest_sha256: outcome=passed
  • seat3 bwrap_python_ci_unit_suites: outcome=passed
  • seat3 bwrap_python_canary_static_subset_and_timeouts: outcome=partial
  • seat3 bwrap_bash_syntax_and_parse_audit_shard_spec: outcome=passed
  • seat3 bwrap_check_ci_wiring_mutations: outcome=passed
  • seat3 bwrap_rustc_shard_logic_probe: outcome=passed
  • seat3 cargo_and_lean_builds_skipped_light_workload: outcome=not_run

@joshlf
joshlf marked this pull request as ready for review December 6, 2026 00:37
@joshlf
joshlf requested a review from jswrenn as a code owner December 6, 2026 00:37

@joshlf joshlf left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/ci-core approve 7ed18f0

@joshlf

joshlf commented Dec 6, 2026

Copy link
Copy Markdown
Member Author

Authored by an AI agent acting on joshlf's behalf. Posted /ci-core approve for 7ed18f0bfe035e1f7a0756bf2a21746f43ced9c4 under joshlf's standing authorization, after this head passed its independent review.

@joshlf
joshlf added this pull request to the merge queue Dec 6, 2026
Merged via the queue into main with commit 3afe6a6 Dec 6, 2026
118 of 121 checks passed
@joshlf
joshlf deleted the joshlf/ci-t2-2b-audit-sharding branch December 6, 2026 01:20
Sign up for free to 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.

1 participant