Commit graph

5 commits

Author SHA1 Message Date
Ouroboros
6d52bf4dea feat(tz2 B2): typed wake reasons (answer/owner_text/hurry/mail:<task_id>/timeout/control), no-rollback on a closed wait, one wake-notice seam warm and cold
Drafted by a delegated Claude Fable 5.1 session (run-4824fce9655c); patch read and applied by the host; 225 owner-wait/quiz/cancel tests pass.
2026-09-26 00:04:06 +03:00
Ouroboros
3f9fe1b654 WIP: preserve TZ-2 open-question and factual-terminal candidate
Keep this version-neutral contribution local. B1/B2/B3 and C1/C4/C5 are partial; C2/C3, exact diff review, full suite and PR are outstanding. Do not merge this checkpoint without final-candidate checks.
2026-09-25 06:03:38 +03:00
Ouroboros
4ddb7aa112 Consciousness: review round 3 fixes (review spend in the allowance, late-answer transport, timed-out wait card)
- A deep review a consciousness tree starts keeps the tree's ledger category, so the
  rolling allowance discovers its root and counts its spend (its rows said
  deep_self_review and the tree was invisible to the allowance).
- A late quiz answer relayed by a transport skill is forwarded with that skill as its
  source (answer_decision takes an additive `source`; the web card stays "web").
- A bounded owner wait that times out stops saying "waiting": the quiz block drops
  wait_for_answer (wait_ended_at for audit), the live card gets an additive
  quiz_state wait_for_answer=false, and the card stays open and answerable.
- Wake message: the newest unanswered cards first, bounded to four, then settled tasks
  newest first; one placeholder pass (a title containing "{daily_usd}" is a fact);
  "at least" before the spend when unmetered rows sit in the window.
- Only a consciousness refusal pauses an evolution campaign; any other refusal retries
  on the next pass without recording a cycle.
- A root consciousness started reads the runtime mode it actually runs in (the per-task
  light cap) in its Runtime block; the wake itself keeps Main's block byte-identical.
- A wake whose thread cannot start unregisters itself; /bg start after a long off
  period never announces a wake in the past; the nanny's "chose not to delegate"
  nudge respects a withheld delegate_start.
- docs/architecture/06 names the gates the mode cap binds at; a stale docstring
  mention of the retired observation inbox is gone.

Co-authored-by: Ouroboros <311266734+ouroboros-agent@users.noreply.github.com>
2026-09-16 11:24:07 +03:00
Ouroboros
c4d7669456 Bound a required owner wait with escalate(max_wait_minutes=N)
A root that must have an answer could only wait forever. escalate now takes an
optional max_wait_minutes: the task still parks at the completed-tool boundary,
and if no answer arrives within that window it resumes on its own with a
[SYSTEM NOTICE] instead of holding the task open indefinitely. The card is
untouched by the timeout — it stays open, and a later answer reaches the task's
chat as an ordinary owner message (the half that landed in the previous
commit).

The bound is validated by the shared quiz validator (a whole positive number of
minutes, only with wait_for_answer, capped by the task's absolute wall-clock
ceiling — beyond it the ceiling ends the task first, so a larger bound would be
a promise the runtime cannot keep) and refused as QUIZ_WAIT_BOUND_INVALID.

It travels as an ABSOLUTE instant in the owner-wait checkpoint
(wait_deadline_at plus the minutes it named), so a planned restart resumes the
SAME bound instead of granting the full wait again, and the cold continuation
emits the same notice as the warm one. Both continuation callbacks now return
"owner_input" or "timeout": the direct loop breaks on the deadline only AFTER
control_reason() is consulted, so Stop, cancel, the task deadline and the
absolute ceiling keep precedence; the pooled worker turns the spent bound into
a second reason for the SAME resume request the mailbox already sends, from
inside the parked gate, with no new scheduler (disclosed: that resume is a
request, not a guarantee — the grant can still be refused, and the hard axes
end the task in that case).

No new quiz or wait state: the row resumes with the additive
resume_reason: "timeout", which the activity projection now carries so the
project question pointer keeps reading "Answer needed" — the question was never
answered. The notice itself names the recorded assumption when there is one and
otherwise says plainly that no answer is not consent. The bound is deliberately
invisible on the cards and in Telegram (DESIGN: no timers, no countdowns); the
escalate receipts now state what the task actually agreed to.

Co-authored-by: Ouroboros <311266734+ouroboros-agent@users.noreply.github.com>
2026-09-16 05:19:22 +03:00
Ouroboros
f3ed795ea1 Preserve owner dialogue and required waiting
Keep the same task and live browser while required owner input lends active worker capacity. Restore acknowledged planned continuations without replaying effects or changing the original budget threshold. Align visible Publish admission, root questions, ongoing replies, display fallback names and definite publication failures with existing owners.

Co-authored-by: Ouroboros <311266734+ouroboros-agent@users.noreply.github.com>
2026-09-08 20:24:08 +03:00