Skip to content

feat(chat-swarm): add transport-neutral Worker Auto Compact planner (#51-B/C source) #126

Description

@James3014

Parent / purpose

Child of #51 / #104. This issue owns the transport-neutral Worker Auto Compact source slice only after #120 / PR #122 established deterministic continuation.

Exact source base at creation: main@5256c40f56bbfd5a7eff7737ecf54da4b0359c4d.

Scope

Implement only:

context-pressure observation
-> compactRequired decision
-> safe-boundary / reconciliation gate
-> bounded continuity capsule
-> non-authorizing replacement-carrier intent

This child MUST consume the merged #120 continuation seam and MUST NOT:

#117/#105 remains owner of real replacement-carrier creation/wake/recover. The output of this slice is source material that #117 can consume before requesting a replacement carrier.

Pressure contract

  • exact ChatGPT token telemetry is unavailable unless a supported host-native signal explicitly supplies it;
  • estimated pressure must remain labeled ESTIMATED with provenance;
  • only host-native evidence may be labeled EXACT;
  • configured threshold is bounded and explicit; no hidden hard-coded token truth;
  • pressure alone never authorizes carrier transfer.

Safe-boundary contract

At/above the configured threshold:

  • AVAILABLE + no current task + valid checkpoint + no pending continuation/unknown effect => prepare allowed;
  • busy/current task => wait for safe boundary;
  • RECONCILE_REQUIRED, unknown effect, or unresolved continuation => reconciliation block;
  • missing checkpoint => checkpoint block;
  • no state may auto-requeue/retry an uncertain task.

Capsule contract

Capsule must be bounded/versioned/hash-bound and structurally limited to:

  • swarm/worker identity;
  • source continuation epoch;
  • checkpoint hash only (not arbitrary raw checkpoint truth);
  • pressure provenance;
  • stable role instructions;
  • bounded context-only summary;
  • task/result/evidence refs;
  • blockers;
  • explicit claim ceiling.

Do not include full transcript, hidden reasoning, raw tool history/output dumps, credentials/tokens/cookies/session secrets, or stale transport state.

Verification

Owner review policy

Per Owner instruction in this workstream, no independent reviewer is required for this child. Exact-head controller verification + repository CI is sufficient. Do not mislabel Owner/controller review as independent review.

Claim ceiling

After accepted source merge only:

WORKER_AUTO_COMPACT_PLANNER_SOURCE_ACCEPTED

This does not prove real worker carrier replacement, zero-touch runtime, live Auto Compact, #51 closure, #117 closure, or #104 Ultra parity.

Activity

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

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions