GeezerVison is showing github.com — id(phase-14 v4 step 3): presence, wake, and drain runtime contract for hosted agents · Issue #10664 · developing-today/code
id(phase-14 v4 step 3): presence, wake, and drain runtime contract for hosted agents #10664DescriptionStep 3 of the v4 outline (doc/2026-11-16_design_id6303_hosted_agent_services_v4_outline.md, section 2.3 + decisions 3-4), parent #6303. Design presence leases and heartbeat cadence, the wake-event set for event-driven listings, the drain state machine (announced, handing-off, detached) with timeouts and stalled-drain handling, and upgrade-by-drain-and-replace. Blocked by v4 step 2 (#10663) and v3 step #10052 (agent-majority profile + visitor role). Drew questions it depends on: none directly. Activitydeveloping-today commented on Nov 16, 2026 dezren39 commented on Nov 23, 2026 🤖 Agent note — triage, lane any-n (task 19340)
developing-today-fleet commented on Nov 25, 2026 🤖 Agent note — claim, lane ITEM-WORK-299 (queue task 23763, worker repo-worker-code / lane code-g)
Claiming #10664 for the bounded v4 step 3 design slice: settle §2.3 (presence, wake, drain) and §4 decisions 3–4 in doc/2026-11-16_design_id6303_hosted_agent_services_v4_outline.md, consistent with the completed §2.2 hire/attach design from #10663. Registry (#10662), host trust/operator surface (#10665), other v4 steps, and implementation code are out of scope.
Premise check (fresh reads, 2026-11-25): #10664 OPEN; #10663 CLOSED 2026-11-25T07:26:19Z; #10052 CLOSED 2026-11-25T06:40:12Z; 2 comments on this issue, neither a live claim.
developing-today-fleet commented on Nov 25, 2026 🤖 Agent note — design slice complete, lane ITEM-WORK-299 (queue task 23763)
The v4 step 3 runtime contract is settled and landed on main via PR #15007 (merged 2026-11-25T10:40:26Z, merge commit 627b9fe4e1d71ce440b7e48cfa5944f206e69b15). Only doc/2026-11-16_design_id6303_hosted_agent_services_v4_outline.md §2.3 and §4 decisions 3–4 changed (+201/−28); registry (#10662), host trust/operator surface (#10665), other v4 steps, and implementation code are untouched.
What §2.3 now specifies, per the acceptance bullets:
- Presence lease — one lease per (hire, world), held by the host for the agent; default TTL 90s (world-configurable 30s–10min); heartbeat every TTL/3, operator-attributed, quota-free; monotonic lease epoch fences stale holders so at most one instance holds presence. Expiry lapses presence only: the hire stays in force and outstanding claims run to their own v3 §2.2 claim leases — nothing strands.
- Wake contract — the complete set is six classes: claim-offer, mention, attachment-change, handoff-offer, hire-lifecycle, schedule. Delivery is charged to v3 §2.5 per-role rate budgets, bursts coalesce into one digest wake, suppression is recorded with its reason, and a wake grants no presence by itself.
- Asleep vs absent — owners and visitors render present / asleep (hire in force, wake subscription active, wake classes named) / absent (lease expired unexpectedly or hire ended), with state start time and accountable operator, through the existing
id-shell population rendering.
- Drain — announced → handing-off → detached with per-state entry/exit conditions; new claims refused from announcement; in-flight claims are completed, released with a v3 §2.4 handoff note, or expire as a distinctly-recorded unhanded release — never reassigned while held. Default deadline 15min (configurable 1min–24h), default stall window 5min with owner/operator surfacing and one extension, force-completion at the deadline (claims expire, delegation revoked, outcome forced, stall recorded in the listing's history).
- Upgrade — the same drain with trigger upgrade: drain-and-replace under the persisting hire/role/quota class/ledger, single-instance presence enforced by the lease epoch, replace window (default = drain deadline) with abort/rollback semantics, and the exact acting program version recorded in the audit for every action.
§4 decisions 3 and 4 are marked Settled with summaries pointing at §2.3. The design is consistent with the completed §2.2 hire/attach design from #10663 (same hire record, ledger, and delegation semantics).
Verification: git diff --check clean in the worktree; the committed file re-verified remotely via a fleet Actions dispatch against the PR branch (run 45594189939, session fp_d6137c28ff3aaa79e429ae17b6879ba6 — session result succeeded: 494 lines at HEAD, both Settled decisions and the wake/drain sections present, no trailing whitespace); merged content read back from main and confirmed (494 lines, §2.3 + §4 as designed).
Closing this step issue as completed; step 4 (#10665) names steps 1–3 as its blockers, so this landing is one of its unblocking edges.
MetadataMetadataDevelopmentNo branches or pull requestsIssue actions
|