Skip to content

Redesign multi-agent proof harness for stability, helper reuse, and protocol convergence - #18

Merged
LikC1606 merged 1 commit into
mainfrom
feat/harness-redesign-20261124
Nov 24, 2026
Merged

LikC1606 merged 1 commit into
mainfrom
feat/harness-redesign-20261124

Conversation

@LikC1606

Copy link
Copy Markdown
Collaborator

Summary

Implements the P0–P3 multi-agent proof harness redesign motivated by trajectory audits of Erdős #677 and the 3D exponential conditional entropy problem:

  • P0 — Stability & runtime hygiene
    • Default outputDelivery: 'file' for formalization workers and permit top-level import Mathlib in solver proof sources.
    • Content-addressed (sha256) Web observation source deduplication (apps/web/observationSources.ts) and throttled/capped running reasoning previews (apps/web/agentActions.ts).
    • Host-disconnect watchdog (apps/web/workerDisconnect.ts) for graceful abort, checkpoint flush, and exit on broken host streams.
    • 180s minimum advisory protection window and preemption-mismatch cooldown in cooperative dispatch.
  • P1 — Incremental verified helper reuse & bounded slices
    • Independent Lean 4 kernel-checked incremental helper landing (src/solver/incrementalHelpers.ts) wired into both AgentResearchTeam (submit_helpers) and CooperativeResearch (helpers deliveries), preserving frozen declarations, 3-axiom whitelist, private markers, and isolated cache keys.
    • Configurable soft time/compaction milestone slices (src/solver/softSlice.ts).
    • Compact pointer-index context compilation (src/solver/contextCompiler.ts) and same-route warm thread retention.
  • P2 — Two-phase portfolio exploration & route control
    • Opt-in Phase 1 heterogeneous route scouts (structural-symmetry, explicit-constructive, falsification-obstruction), route selection gate, durable negative knowledge, and Phase 2 foundation lemma seeding (src/solver/portfolioExploration.ts).
    • Atomic route retirement (retire_route / retireRoutes via src/solver/cooperationRoutes.ts) and a 15-command Lead planning guardrail.
  • P3 — Protocol convergence & engine hardening
    • Flatten theoremos_team wire schemas above Codex CLI's 16-branch oneOf drop limit while keeping strict host-side Zod validation (src/solver/agentTeamTool.ts).
    • 0-turn native-agent-control startup failure fallback to host-tools (team_transport_fallback) and compact <8 KiB route_summary atomic operation.
    • Atomic plan-validate / plan-apply CLI and workspace helpers (src/solver/planTool.ts) plus private Lead feedback for malformed drafts without polluting shared deliveries; M5 frozen identity remains untouched.

Verification

  • bun run build --state-root /tmp/theoremos-host-build-rebased: 4 bundles built.
  • bun run typecheck and bun run typecheck:web: both passed.
  • Host Vitest (real Lean 4 + real codex-cli 0.171.0 loopback):
    • Core P0–P3 + native tools + team/solver suites: 21/21 files passed (476 passed, 4 opt-in skipped, 0 failed).
    • Web / worker / loopback suites + tests/webModuleIdentity.test.ts: 11/11 files passed (223 passed, 7 opt-in Docker skipped, 0 failed).
    • Full tests/solver.test.ts + tests/agentTeamSourceRecovery.test.ts: 2/2 files passed (489/489 passed, 0 failed).

…rotocol convergence

Implements the P0-P3 harness redesign derived from the Erdos #677 and 3D exponential entropy trajectory audits:

- P0 (Stability & hygiene): default file output delivery for formalization workers and permit top-level import Mathlib; deduplicate Web observation sources by SHA-256 blob reference and throttle/cap running reasoning previews; add a host-disconnect watchdog for containerized workers; add a 180s minimum advisory protection window and preemption-mismatch cooldown.
- P1 (Helper reuse & bounded slices): land standalone Lean-kernel-verified helpers incrementally in both AgentResearchTeam (submit_helpers) and CooperativeResearch (helpers deliveries) while preserving frozen declarations and the 3-axiom whitelist; enforce soft time/compaction milestone slices; compact context into pointer indexes and retain warm threads across same-route tasks.
- P2 (Portfolio exploration & route control): add opt-in Phase 1 heterogeneous route scouting (structural-symmetry, explicit-constructive, falsification-obstruction) with a route-selection gate and durable negative knowledge; add atomic route retirement (retire_route / retireRoutes) and a 15-command Lead planning guardrail.
- P3 (Protocol convergence): flatten theoremos_team wire schemas above Codex CLI's 16-branch oneOf drop threshold while keeping host-side strict Zod validation; add 0-turn native-agent-control startup fallback to host-tools and bounded route_summary; add atomic plan-validate/plan-apply commands and isolate malformed Lead drafts from shared deliveries while keeping M5 identity frozen.
@LikC1606
LikC1606 merged commit caca289 into main Nov 24, 2026
@LikC1606
LikC1606 deleted the feat/harness-redesign-20261124 branch December 1, 2026 20:12
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